I had a problem deleting an Oracle database when deploying to JBoss. Deployment in Tomcat works fine - no problem. I suspect the problem is with the conflicting library that comes with JBoss. When I try to query the database (using Hibernate), I get the following:
2011-12-08 08:02:53,640 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/xxxx].[xxxx]] (http-0.0.0.0-8080-9) Servlet.service() for servlet xxxx threw exception java.lang.IllegalStateException: BaseClassLoader@50d81341 {vfszip:/opt/jboss/jboss-eap-5.1/jboss-as/server/web/deploy/xxxxx.war/} classLoader is not connected to a domain (probably undeployed?) for class oracle.sql.DATE at org.jboss.classloader.spi.base.BaseClassLoader.loadClassFromDomain(BaseClassLoader.java:857) at org.jboss.classloader.spi.base.BaseClassLoader.doLoadClass(BaseClassLoader.java:502) at org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:447)
Again, there is no such problem when working in Tomcat. I installed the jboss-class download file in my webroot, which contains the following:
<classloading xmlns="urn:jboss:classloading:1.0" parent-first="false" domain="DefaultDomain" top-level-classloader="true" parent-domain="Ignored" export-all="NON_EMPTY" import-all="true" />
But that doesn't seem to help. Oddly enough, I'm connecting to two different databases with two different sleep configurations, one Oracle 11i and one Oracle 8i. An Oracle 11 connection never causes a problem ... Its only connection is an 8i connection. 11 connection works very well.
I have no idea why this is happening, but maybe JBoss contains Oracle Hibernate dialogs, not Oracle 11 dialogs? In any case, how can I tell JBoss to use my packaged libraries, and not the ones that were found in his class path (if this is my problem)?
source share