0 Replies Latest reply on May 16, 2002 3:31 PM by Calvin

    CMP Bean hangs with Oracle on startup

    Calvin Newbie

      I'm using JBoss 3.0.0RC2. I have one entity bean that uses CMP and my database is Oracle. Sometimes when starting up JBoss it deploys this bean successfully. However, most of the time it just hangs on deployment.

      I've seen many post about this problem and it usually was a configuration issue but I didn't see any where sometimes it worked and sometimes it didn't as here.

      My Oracle DataSource deploys just fine and I've had no problem using it. Maybe I do have something weird with my configuration but not that I can see. Below is my oracle-service.xml file.

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



      <depends optional-attribute-name="ManagedConnectionFactoryName">


      OracleDS


      <config-property name="ConnectionURL" type="java.lang.String">jdbc:oracle:thin:@101.123.7.3:1521:mysip</config-property>
      <config-property name="DriverClass" type="java.lang.String">oracle.jdbc.driver.OracleDriver</config-property>
      <!--set these only if you want only default logins, not through JAAS-->
      <config-property name="UserName" type="java.lang.String">tiger</config-property>
      <config-property name="Password" type="java.lang.String">tiger</config-property>



      <depends optional-attribute-name="OldRarDeployment">jboss.jca:service=RARDeployment,name=JBoss LocalTransaction JDBC Wrapper



      <depends optional-attribute-name="ManagedConnectionPool">


      5
      50
      5000
      15
      ByContainer



      <depends optional-attribute-name="CachedConnectionManager">jboss.jca:service=CachedConnectionManager
      <!--<depends optional-attribute-name="JaasSecurityManagerService">jboss.security:name=JaasSecurityManager-->
      java:/TransactionManager
      jboss.jca:service=RARDeployer


      >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

      Nothing too strange about my jbosscmp-jdbc.xml file I don't think.
      >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
      <?xml version="1.0" encoding="UTF-8"?>
      <!DOCTYPE jbosscmp-jdbc>
      <jbosscmp-jdbc>

      java:/OracleDS
      <datasource-mapping>Oracle8</datasource-mapping>
      <create-table>false</create-table>
      <remove-table>false</remove-table>
      <read-only>false</read-only>
      <time-out>300</time-out>
      <pk-constraint>true</pk-constraint>
      <fk-constraint>false</fk-constraint>
      <row-locking>false</row-locking>
      <preferred-relation-mapping>foreign-key</preferred-relation-mapping>
      <read-ahead>
      on-load
      <page-size>1000</page-size>
      <eager-load-group>*</eager-load-group>
      </read-ahead>
      <list-cache-max>1000</list-cache-max>


      <enterprise-beans>

      <ejb-name>MyEJB</ejb-name>
      <table-name>customer</table-name>
      <create-table>false</create-table>
      <cmp-field>
      <field-name>customer</field-name>
      <column-name>customer_id</column-name>
      <jdbc-type>VARCHAR</jdbc-type>
      <sql-type>VARCHAR(64)</sql-type>
      </cmp-field>
      <cmp-field>
      <field-name>clientId</field-name>
      <column-name>client_Id</column-name>
      <jdbc-type>VARCHAR</jdbc-type>
      <sql-type>VARCHAR(12)</sql-type>
      </cmp-field>
      <cmp-field>
      <field-name>requestId</field-name>
      <column-name>request_id</column-name>
      <jdbc-type>VARCHAR</jdbc-type>
      <sql-type>VARCHAR(32)</sql-type>
      </cmp-field>

      </enterprise-beans>
      </jbosscmp-jdbc>
      >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

      I'm really at a lost here because like I said, sometimes it works but more often than not it doesn't. If anyone has any ideas, I'd really appreciate the help. Thanks guys.