1 Reply Latest reply on May 18, 2002 12:49 PM by davidjencks

    exception using cmp with oracle

    ejbclinic

      I can't find oracle-service.xml in jboss-3.0.0rc1.(jboss3,0orc2 version can't find any where only orc1 available)
      Well i was trying on jboss3.0 alpha and oracle 8.0 and have done a lot of struggle to work with cmp but fails i have done the follwing work.
      1)make oracle-service.xml accoringly and put in deploy folder and don't remove the hsqldb-default-service.
      2)put the classes102.jar in lib\ext folder which i have downloaded it from
      http://otn.oracle.com/software/htdocs/distlic.html?/software/tech/java/sqlj_jdbc/htdocs/winsoft.html

      3)change standardjaws.xml as

      java:/OracleDS
      <type-mapping>Oracle8</type-mapping>
      false
      ..................


      4)change standardjbosscmp-jdbc like
      ...........................
      <!DOCTYPE jbosscmp-jdbc PUBLIC
      "-//JBoss//DTD JBOSSCMP-JDBC 3.0//EN"
      "http://www.jboss.org/j2ee/dtd/jbosscmp-jdbc_3_0.dtd">
      <jbosscmp-jdbc>

      <!-- Andrew changed: -->
      java:/OracleDS
      <datasource-mapping>Oracle8</datasource-mapping>
      true
      <create-table>false</create-table>
      ...........................


      but i am getting the following exception n middle(i have not deployed databaserelated bean and my session bean based programs are being deployed )


      [2002-05-18 16:17:29,270,AutoDeployer,DEBUG] Received notification of mbean ZClassLoaders:id=1231171914's deployment.
      [2002-05-18 16:17:29,270,ServiceCreator,INFO] About to create the beanjboss.jca:service=LocalTxCM,name=oracledb
      [2002-05-18 16:17:29,380,ServiceController,ERROR] Could not create MBean: jboss.jca:service=LocalTxCM,name=oracledb
      javax.management.ReflectionException: The MBean class could not be loaded by the specified loader
      at com.sun.management.jmx.MBeanServerImpl.createMBean(MBeanServerImpl.java:754)
      at org.jboss.system.ServiceCreator.create(ServiceCreator.java:85)
      at org.jboss.system.ServiceController.deploy(ServiceController.java:178)
      at java.lang.reflect.Method.invoke(Native Method)
      at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1628)
      at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)
      at org.jboss.deployment.ServiceDeployer.invoke(ServiceDeployer.java:732)
      at org.jboss.deployment.ServiceDeployer.addMBeans(ServiceDeployer.java:668)
      at org.jboss.deployment.ServiceDeployer.deploy(ServiceDeployer.java:215)
      at org.jboss.deployment.DeployerMBeanSupport.deploy(DeployerMBeanSupport.java:107)
      at java.lang.reflect.Method.invoke(Native Method)
      at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1628)
      at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)
      at org.jboss.deployment.AutoDeployer.deploy(AutoDeployer.java:654)
      at org.jboss.deployment.AutoDeployer.run(AutoDeployer.java:327)
      at org.jboss.deployment.AutoDeployer.startService(AutoDeployer.java:509)
      at org.jboss.system.ServiceMBeanSupport.start(ServiceMBeanSupport.java:117)
      at java.lang.reflect.Method.invoke(Native Method)
      at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1628)
      at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)
      at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:775)
      at $Proxy0.start(Unknown Source)
      at org.jboss.system.ServiceController.start(ServiceController.java:479)
      at org.jboss.system.ServiceController.registerAndStartService(ServiceController.java:273)
      at org.jboss.system.ServiceController.deploy(ServiceController.java:257)
      at java.lang.reflect.Method.invoke(Native Method)
      at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1628)
      at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)
      at org.jboss.deployment.ServiceDeployer.invoke(ServiceDeployer.java:732)
      at org.jboss.deployment.ServiceDeployer.addMBeans(ServiceDeployer.java:668)
      at org.jboss.deployment.ServiceDeployer.deploy(ServiceDeployer.java:215)
      at org.jboss.deployment.DeployerMBeanSupport.deploy(DeployerMBeanSupport.java:107)
      at java.lang.reflect.Method.invoke(Native Method)
      at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1628)
      at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)
      at org.jboss.Main.(Main.java:199)
      at org.jboss.Main$1.run(Main.java:411)
      at java.security.AccessController.doPrivileged(Native Method)
      at org.jboss.Main.main(Main.java:406)
      [2002-05-18 16:17:29,440,ServiceDeployer,ERROR] Mbean exception while executing deploy on [Ljava.lang.Object;@aeed0
      javax.management.ReflectionException: The MBean class could not be loaded by the specified loader
      at com.sun.management.jmx.MBeanServerImpl.createMBean(MBeanServerImpl.java:754)
      at org.jboss.system.ServiceCreator.create(ServiceCreator.java:85)
      at org.jboss.system.ServiceController.deploy(ServiceController.java:178)
      at java.lang.reflect.Method.invoke(Native Method)
      at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1628)
      at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)
      at org.jboss.deployment.ServiceDeployer.invoke(ServiceDeployer.java:732)
      at org.jboss.deployment.ServiceDeployer.addMBeans(ServiceDeployer.java:668)
      at org.jboss.deployment.ServiceDeployer.deploy(ServiceDeployer.java:215)
      at org.jboss.deployment.DeployerMBeanSupport.deploy(DeployerMBeanSupport.java:107)
      at java.lang.reflect.Method.invoke(Native Method)
      at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1628)
      at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)
      at org.jboss.deployment.AutoDeployer.deploy(AutoDeployer.java:654)
      at org.jboss.deployment.AutoDeployer.run(AutoDeployer.java:327)
      at org.jboss.deployment.AutoDeployer.startService(AutoDeployer.java:509)
      at org.jboss.system.ServiceMBeanSupport.start(ServiceMBeanSupport.java:117)
      at java.lang.reflect.Method.invoke(Native Method)
      at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1628)
      at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)
      at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:775)
      at $Proxy0.start(Unknown Source)
      at org.jboss.system.ServiceController.start(ServiceController.java:479)
      at org.jboss.system.ServiceController.registerAndStartService(ServiceController.java:273)
      at org.jboss.system.ServiceController.deploy(ServiceController.java:257)
      at java.lang.reflect.Method.invoke(Native Method)
      at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1628)
      at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)
      at org.jboss.deployment.ServiceDeployer.invoke(ServiceDeployer.java:732)
      at org.jboss.deployment.ServiceDeployer.addMBeans(ServiceDeployer.java:668)
      at org.jboss.deployment.ServiceDeployer.deploy(ServiceDeployer.java:215)
      at org.jboss.deployment.DeployerMBeanSupport.deploy(DeployerMBeanSupport.java:107)
      at java.lang.reflect.Method.invoke(Native Method)
      at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1628)
      at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)
      at org.jboss.Main.(Main.java:199)
      at org.jboss.Main$1.run(Main.java:411)
      at java.security.AccessController.doPrivileged(Native Method)
      at org.jboss.Main.main(Main.java:406)
      [2002-05-18 16:17:29,440,ServiceDeployer,DEBUG] deploying with ServiceController


      My oracle-service.xml file is as:


      <?xml version="1.0" encoding="UTF-8"?>

      <!-- ===================================================================== -->
      <!-- -->
      <!-- JBoss Server Configuration -->
      <!-- -->
      <!-- ===================================================================== -->






      <!-- ==================================================================== -->
      <!-- New ConnectionManager setup for OracleDB -->
      <!-- ==================================================================== -->


      <!--make the rar deploy! hack till better deployment-->
      jboss.jca:service=RARDeployer


      <depends optional-attribute-name="ManagedConnectionFactoryName">
      <!--embedded mbean-->

      <!--hack-->
      <depends optional-attribute-name="OldRarDeployment">jboss.jca:service=RARDeployment,name=Minerva JDBC LocalTransaction ResourceAdapter

      <!--real attributes-->


      <config-property>
      <config-property-name>ConnectionURL</config-property-name>
      <config-property-type>java.lang.String</config-property-type>
      <config-property-value>jdbc:odbc:first</config-property-value>
      </config-property>
      <config-property>
      <config-property-name>DriverClass</config-property-name>
      <config-property-type>java.lang.String</config-property-type>
      <config-property-value>sun.jdbc.odbc.JdbcOdbcDriver</config-property-value>
      </config-property>
      <config-property>
      <config-property-name>UserName</config-property-name>
      <config-property-type>java.lang.String</config-property-type>
      <config-property-value>scott</config-property-value>
      </config-property>
      <config-property>
      <config-property-name>Password</config-property-name>
      <config-property-type>java.lang.String</config-property-type>
      <config-property-value>tiger</config-property-value>
      </config-property>


      jdbc/oracledb


      <depends optional-attribute-name="ManagedConnectionPool">
      <!--embedded mbean-->


      0
      50
      5000
      15
      <!--criteria indicates if Subject (from security domain) or app supplied
      parameters (such as from getConnection(user, pw)) are used to distinguish
      connections in the pool. Choices are
      ByContainerAndApplication (use both),
      ByContainer (use Subject),
      ByApplication (use app supplied params only),
      ByNothing (all connections are equivalent, usually if adapter supports
      reauthentication)-->
      ByContainer


      <depends optional-attribute-name="CachedConnectionManager">jboss.jca:service=CachedConnectionManager
      java:/jaas/OracleDbRealm
      java:/TransactionManager




      Please help where i am wrong