Unable to deploy rar
jboss.bettsockentraeger.d Feb 9, 2005 7:44 AMI have a problem deploying a rar for Jpox into Jboss4.0.1 default server on Windows XP, JDK 1.5.
I read the faq and have been looking around the net for an answer but with no solution. So any help will be appreciated! Here are the details
The error I receive
MBEANS THAT ARE THE ROOT CAUSE OF THE PROBLEM: ObjectName: jboss.jca:service=ManagedConnectionFactory,name=jpox state: FAILED I Depend On: jboss.jca:service=RARDeployment,name='jpox-1.0.4.rar' Depends On Me: jboss.jca:service=ManagedConnectionPool,name=jpox org.jboss.deployment.DeploymentException: couldn't get oldRarDeployment! jboss.jca:service=RARDeployment,name='jpox-1.0.4.rar'; - nested throwable: (org.jboss.deployment.DeploymentException: ConnectionDefinition 'org.jpox.resource.PersistenceManagerFactoryImpl' not found in rar 'jpox-1.0.4.rar')
In jpox-1.0.4.rar the directory structure is as following
jpox-1.0.4.rar
|- META-INF
| |- ra.xml
|- javax (containing the jdo api)
|- org/jpox/.. (containing the jpox stuff)
|-resource (containing the above mentioned class)
The ra.xml is as follows:
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE connector PUBLIC "-//Sun Microsystems, Inc.//DTD Connector 1.0//EN" "http://java.sun.com/dtd/connector_1_0.dtd"> <connector> <display-name>JPOX Connector</display-name> <description></description> <vendor-name>JPOX Team</vendor-name> <spec-version>1.0</spec-version> <eis-type>JDO Adaptor</eis-type> <version>1.0</version> <resourceadapter> <managedconnectionfactory-class>org.jpox.resource.ManagedConnectionFactoryImpl</managedconnectionfactory-class> <connectionfactory-interface>javax.resource.cci.ConnectionFactory</connectionfactory-interface> <connectionfactory-impl-class>org.jpox.resource.PersistenceManagerFactoryImpl</connectionfactory-impl-class> <connection-interface>javax.resource.cci.Connection</connection-interface> <connection-impl-class>org.jpox.resource.PersistenceManagerImpl</connection-impl-class> <transaction-support>LocalTransaction</transaction-support> <!-- Please Add your properties here --> <config-property> <config-property-name>ConnectionURL</config-property-name> <config-property-type>java.lang.String</config-property-type> <config-property-value>jdbc:mysql//localhost/test</config-property-value> </config-property> <config-property> <config-property-name>ConnectionDriverName</config-property-name> <config-property-type>java.lang.String</config-property-type> <config-property-value>com.mysql.jdbc.Driver</config-property-value> </config-property> <config-property> <config-property-name>ConnectionUserName</config-property-name> <config-property-type>java.lang.String</config-property-type> <config-property-value>jboss</config-property-value> </config-property> <config-property> <config-property-name>ConnectionPassword</config-property-name> <config-property-type>java.lang.String</config-property-type> <config-property-value>xxxx</config-property-value> </config-property> <config-property> <config-property-name>AutoCreateSchema</config-property-name> <config-property-type>boolean</config-property-type> <config-property-value>true</config-property-value> </config-property> <authentication-mechanism> <authentication-mechanism-type>BasicPassword</authentication-mechanism-type> <credential-interface>javax.resource.security.PasswordCredential</credential-interface> </authentication-mechanism> <reauthentication-support>false</reauthentication-support> </resourceadapter> </connector>
and the jpox-ds.xml :
<?xml version="1.0" encoding="UTF-8"?> <connection-factories> <tx-connection-factory> <jndi-name>jpox</jndi-name> <rar-name>jpox-1.0.4.rar</rar-name> <connection-definition>org.jpox.resource.PersistenceManagerFactoryImpl</connection-definition> <!--adapter-display-name>JPOX Connector</adapter-display-name--> <config-property name="ConnectionDriverName" type="java.lang.String">com.mysql.jdbc.Driver</config-property> <config-property name="ConnectionURL" type="java.lang.String">jdbc:mysql://localhost/test</config-property> <config-property name="UserName" type="java.lang.String">jboss</config-property> <config-property name="Password" type="java.lang.String">xxxx</config-property> <config-property name="AutoCreateSchema" type="boolean">true</config-property> </tx-connection-factory> </connection-factories>
I'm not quite sure if I have the correct class for the connection definition but I tried a couple of other classes with the same result. I also tried to unpack the rar into a directory with the same result.
It seems that the classloader is not able to pick up the jars inside the rar. or I am missing something.
Thanks in advanced.
Stefan