View Full Version : jboss 4.0.5.ga notes w/ 1.6 RC1

08-20-2007, 01:47 PM
Just one note thus far, and to be precise related to EAR deployments -

The infamous "java.lang.NoSuchMethodError: org.apache.commons.httpclient.HttpConnectionManager.getParams()" has raised its ugly head again.

Updating from 3.0-rc4 to 3.1-rc1 commons-httpclient did not make a difference (shouldn't have anyway). Since I was attempting an EAR deploy, also placed the jar within the /WEB-INF/lib, no difference.

Root of $JBOSS_HOME/lib/commons-httpclient.jar updated, no difference.

*$JBOSS_HOME/server/<default?>/lib/commons-httpclient.jar updated -- this was the ticket, updating this to one of the 3.x series.

I see some class-loader configs in jboss-web.xml, would one of these correct this behavior? And if it can, could it be turned on by default?

08-21-2007, 08:33 AM
Enabling the classLoading repository following http://wiki.jboss.org/wiki/Wiki.jsp?page=ClassLoadingConfiguration . The reason the setup classLoading was to

1) See if it would fix a NoClassDefFound: org.pentaho.repository.HibernateUtil after successful login.

2) Check commons-httpclient back to 2.x series on the default 4.0.5.GA server, but have the recent (3.x series) within the app. Using Java2DelegateParent=false should allow this.

<!-- setup classLoader repository. java2ParentDelegation to always have package libs override server libs for this application -->
<class-loading java2ClassLoadingCompliance="false">

After configuring jboss-app.xml and jboss-web.xml, ran into the linkage problem mentioned here: http://forums.pentaho.org/showthread.php?t=56039

Removing jtidy.jar corrected the linkage problem.

However, still having HibernateUtil problem after initial login.

Edit: HibernateUtil problem same as here - http://forums.pentaho.org/showthread.php?t=54939&page=2

Other errors when dom4j missing from classpath/HibernateUtil problems:

dom4j/HibernateUtil also experiences this problem when dom4j is not in classpath during startup
11:04:02,583 ERROR [HibernateUtil] HIBUTIL.ERROR_0006 - Building SessionFactory failed.
org.hibernate.HibernateException: Could not instantiate cache implementation
11:04:03,005 FATAL [Logger] misc-org.pentaho.core.system.PentahoSystem: PentahoSystem.ERROR_0013 - Could not create obje
ct com.pentaho.repository.subscribe.SubscriptionRepository

08-21-2007, 03:53 PM
Stuck --

The org.pentaho.repository.HibernateUtil NoClassDefFound problem seems related to dom4j.

However, by adding dom4j to the classpath, the template engine stops working (although HibernateUtil now works fine).

What to do or test, I'm out of ideas...

08-22-2007, 09:59 AM
Template engine errors

Template engine could not be loaded

server log:
2007-08-22 09:46:14,044 ERROR [org.pentaho.util.logging.Logger] misc-org.pentaho.core.system.PentahoSystem: PentahoSystem.ERROR_0023 - Could not return object IUITemplater of scope null

I want to reiterate - when I did not have dom4j-1.6.1 in the classpath, the template engine was working fine, but HibernateUtil was not. With dom4j-1.6.1 now in the classpath, the template engine now no longer works (But HibernateUtil does).

08-28-2007, 09:57 AM
....and running into similar problems with WAR deployments. Default install with no modifications, then with some fixes, still can not test Pentaho 1.6 as simply can not get it installed.

Does Pentaho 1.6 just plain not work on jboss 4.0.5.GA?

08-28-2007, 10:02 AM
There seems to be quite a few jboss issues.

One of note is the plan to upgrade to 4.2 for the PCI in 1.6 RC2:


Other posts elsewhere seem to imply that work is complete, never-the-less it's a blocker for RC2 anyway.

Maybe the fixes for Jboss 4.2 will also fix these problems with 4.0.5?

( if you search for jboss at jira.pentaho.org and order by the date (newest first ) you'll see the various issues i'm talking about..

08-28-2007, 11:50 AM
The PCI has been upgraded. The bug has not been closed since not all of the paths through the build scripts have been tested.

08-31-2007, 10:25 AM
I tested build 807, created a J2EE_Deployment zip, then tried to create a jboss-non-portal-ear - with the same results related to HibernateUtil exception problems on jboss 4.0.5.ga.

09-04-2007, 09:35 AM
Who has not resolved their deployment issues? I'd like to get the the bottom of the problems mentioned in this thread and this one (http://forums.pentaho.org/showthread.php?t=54939&page=3). Please list the following information:

Java version.
If not using PCI, what app server are you using? If JBoss, are you using JBoss Portal too?
Name of Pentaho file downloaded including build number (e.g. 1.6.0-RC2.808).
What database you're using.
Any modifications to original download including Ant properties files, files under pentaho-solutions, etc.
Name(s) of Ant target(s) run.
Complete server.log from startup to shutdown.

I've tested the EAR built with Ant target "ear-pentaho-jboss-hsqldb-no-portal" from nightly j2ee deployments v1.6.0-RC2.808 on JBoss 4.2.1 and it seems to work.

09-04-2007, 11:37 AM
Java version 1.6.0-b105
Jboss 4.0.5.GA, no portal, no library modifications.
web.xml: enabled hibernateManaged=true.
web.xml: Acegi security stuff.
web.xml: base-url of the server.
application.xml: added dao-ldap-authorities-populator.jar.
application.xml: removed legacy/older lib references related to pentaho-*.jar, so just use pentaho-*-RC2.jar.
application.xml: removed datasource references, managed from jboss *-ds.xml files in a seperate SAR (this has worked fine, no challenges related to this).
Name(s) of Ant target(s) run -- "build-all" (use jboss-mysql-no-portal ear)
Complete server.log from startup to shutdown -- clipped datasource/acegi security. Debug on.

09-05-2007, 11:11 AM
If using hibernateManaged=true, need to add the following lines to the PENTAHO_SOLUTIONS/system/hibernate/hibernate-jboss-managed.xml file. Recommend adding to default solutions:

<!-- property name="hibernate.cache.provider_class">org.hibernate.cache.EhCacheProvider</property -->
<property name="hibernate.cache.use_second_level_cache">false</property>
<property name="hibernate.cache.use_query_cache">false</property>

09-05-2007, 11:48 AM
To re-iterate the problems I run into on Jboss 4.0.5 -

1) The default Jboss server libs use commons-httpclient 2.X

2) By enabling the classloaders (java2ParentDelegation=false) in both jboss-app.xml and jboss-web.xml, work around the commons-httpclient problem, but introduces new problems.

--linkage, supposedly fixed by removing Tidy.jar from classpath.

As of build 813, it looks like the HibernateUtil/template problem related to dom4j seems to have magically gone away. However, I do not understand the impact of removing Tidy.jar from classpath (nor why it causes linkage problems).

This is still based on FileSolutionRepo, so not sure if DBSolutionRepo will have different results.

edit: This is with the jfreeReport and Mondrian system listeners disabled as still having problems with them.

09-06-2007, 08:26 AM
Some of my problems have been related to dirty classpaths - I've just been updating from SVN for quite some time, and old libs were still in-place and being added to application.xml.

See Thomas's response from the JfreeSystemListener thread:

The application.xml file is auto-generated from within ant. So ultimately it comes from the third-party/lib directory (which (I assume) get copied to the deployment directory, which then get used to generate that file).

At least the version from the SVN repository is clean and does not contain the jfreereport-jars anymore. If you work with a SVN version, then such obsolete files are usually caused by manual changes done to a previous version. If you only use release versions, then it is up to you to make sure that there are no old files. (And for a project like pentaho, with its numerous dependencies, this can be a tough job.)

Will update with more information once I have re-built and re-tested.

09-06-2007, 02:01 PM
Got everything working fine with file-based repository. Just had to set the hibernate cache on hibernateManaged=true to either false, or specify cache mechanism.

Also, enabled classloader to work around the jboss 4.0.5.ga having different commons-httpclient version.

--good for filebased, but not db-based repo.

However, with DB-based repo enabled running into the UItemplate/HibernateUtil/dom4j problems. Also, needed to set hibernate.autocommit=false to work around some type of problem with the hibernateManaged=true when using DB-based repo.

EDIT: spoke prematurly - went to show someone the filebased repo version of 1.6, and low and behold, HibernateUtil problems. No changes other than swapping the repo in /system/pentaho.xml and restarting.

09-07-2007, 05:35 PM
Can you try enabling classloader logging as described here (http://wiki.jboss.org/wiki/Wiki.jsp?page=EnableClassloaderLogging)?

09-19-2007, 09:31 AM
UCL log is 3mb zipped, 2.5mb rar (even with maximum compression) - is there a portion of it you wish to look at?

Starting from the beginning, httpclient with jboss 4.0.5.ga is still a problem on RC2.820.

09-19-2007, 10:18 AM
Have the DeploymentExceptions been fixed? For example:

org.jboss.deployment.DeploymentException: url file:/lib/kettle-2.5.1a.jar could not be opened, does it exist?

Also, have you updated dom4j.jar in pentaho.war at all?

09-19-2007, 12:01 PM
I pulled everything out of SVN as-is, from scratch. Above is the first error I came across (httpclients version conflicts as described earlier in the thread), and rather than trying to fix it myself and describe other problems, going one at a time until it gets fixed and then move to the next problem. Httpclients isn't fixed.

Has anyone been able to deploy Pentaho 1.6 on Jboss 4.0.5.GA without any problems, or is it just me? And, to make it very clear: JBoss 4.0.5.GA, not 4.2.1

If you can prove me wrong that it deploys on 4.0.5.GA fine, great!!

Build 838 tested as well, same httpclient issue

edit, error log:
java.lang.NoSuchMethodError: org.apache.commons.httpclient.HttpConnectionManager.getParams()Lorg/apache/commons/httpclient/params/HttpConnectionManagerParams;

problem identified as Jboss 4.0.5.ga uses an older version of commons-httpclient within the /server/<default>/lib. The EAR contains the newer version, but is not propertly class-loaded. Potential solution in using jboss-app.xml class-loading feature as detailed previously in this thread.

09-26-2007, 09:10 AM
This will be the 19th post in the thread.

I have attempted to give as much information in as detailed as feasible regarding the usecase of testing 1.6 RC on the Jboss 4.0.5 platform.

Please, Pentaho, try it yourself. Seeing it in action will speak many more volumes than thread-post after thread-post.

EAR deployment on a standard, unmodified, non-portal, jboss 4.0.5.GA platform.

[[edit: FYI, if you fix httpclients with something like jboss-app.xml, the dom4j problem -seems- to have been fixed with file-based repo]]

09-28-2007, 07:52 AM
Damn, I just got this error myself! But I could swear I got this working before. I'll make a few tests and get back here

09-28-2007, 08:10 AM
Solved. I was getting the HibernateUtil exception (class not found) because my database was not running (!!!)

I had a connection error exception thrown before, but I missed it.

dhartford (http://forums.pentaho.org/member.php?u=19115), I'm sure your problem is not as simple as this, but at least I've (accidentally) shown that this error may be related not to jars but to the database structure itself. Try to use the database from hsql to see if it works and only after switch to mysql.

Good luck

09-28-2007, 09:04 AM
did you get past the httpclients problem first?

The hibernateUtil being related to not connecting to the database is interesting. I remember someone else's post about problems related to that...but it looks like I'm o.k. on that side (my recent deployed have not hit that yet, but that is FILE-BASED repo only, haven't gotten to DB-based repo testing yet).

I was trying to be pro-active, and solve one problem, move to the next problem, try to solve that one, then 3rd one in hit a bottleneck...but then at that point, the first problem hasn't been officially-solved in SVN yet. So, I need to start taking it slower ;-)

09-28-2007, 09:11 AM
But I'm also using a file-based repo, and I got that error nonetheless. No, I had no errors related to httpclients. I'm using the PCI.

Even using file-based repository, try pointing hibernate.cfg.xml to hypersonic from pentaho-data. It's a 1 minute test, and nothing to loose :) Good luck

09-28-2007, 10:54 AM
I have not recieved the HibernateUtil problem for a while yet. I'm using the j2ee-deployment package to build EAR's for jboss 4.0.5.

when browsing to /home after login, should get the httpclients error.

09-28-2007, 02:53 PM
This post is a response to post #19 in this thread by dhartford.

I have successfully logged in to the platform without exceptions using both the file-based and db-based repositories. Here is my setup:

* Java version 1.5.0_11-b03
* Jboss 4.0.5.GA, no portal, no library modifications.
* pentaho_j2ee_deployments-1.6.0.RC3.844
* MySQL 5
* Ant target: build-all (used jboss-mysql5-no-portal ear)
* OS: Ubuntu 7.04

Here are the modifications that I made (after building):

* Removed *.txt java modules in pentaho.ear/META-INF/application.xml.
* Added java.io.tmpdir and MaxPermSize parameters to JAVA_OPTS in bin/run.conf. See the JAVA_OPTS here (http://wiki.pentaho.org/display/PentahoDoc/Upgrading+the+Pentaho+Pre-Configured+Install).
* Unzipped pentaho-solutions next to the jboss directory.
* Dropped MySQL driver into server/default/lib.
* Copied *-ds.xml from pentaho-res to server/default/deploy.
* Changed classloader config: (This page (http://wiki.jboss.org/wiki/Wiki.jsp?page=ClassLoadingConfiguration) says that when using an EAR, any classloading specified in WAR has no affect.)
** Removed classloader lines from pentaho.ear/pentaho.war/WEB-INF/jboss-web.xml.
** Added classloader lines to pentaho.ear/META-INF/jboss-app.xml.
* Turned on db-based repository in pentaho.xml.
* Did a refresh of the default ACLs. See the "manual method" here (http://wiki.pentaho.org/display/PentahoDoc/Re-Applying+Default+ACL).

10-01-2007, 08:26 AM
* Changed classloader config: (This page (http://wiki.jboss.org/wiki/Wiki.jsp?page=ClassLoadingConfiguration) says that when using an EAR, any classloading specified in WAR has no affect.)
** Removed classloader lines from pentaho.ear/pentaho.war/WEB-INF/jboss-web.xml.
** Added classloader lines to pentaho.ear/META-INF/jboss-app.xml.

Thanks Mat,
That is consistent with my findings regarding classloading (if you leave the classloading in the jboss-web.xml, it will complain but still load correctly). Is there any way to have this be part of the EAR building scripts (j2ee-deployment, if PCI is fine as pmalves states that may not need modifications) so others do not run into these challenges?

As of build 838, the HibernateUtil/Template Rendering problem seems to have been corrected. Previous linkage issues related to Tidy.jar have been corrected. Classloading as Matt described to correct the httpclient version-conflicts in the classpath is the last (known) missing piece.

10-01-2007, 10:22 AM
If your issue is resolved, can you mark BISERVER-230 (http://jira.pentaho.org/browse/BISERVER-230) resolved?

10-01-2007, 11:48 AM
Done, with the note that dom4j problem resolved, but Pentaho 1.6 will not deploy correctly without the classLoading configuration.

10-01-2007, 11:57 AM
Created BISERVER-391 (http://jira.pentaho.org/browse/BISERVER-391).