Hi,

I'm trying to set up a data source for an Entity Bean with BMP, and I
keep getting the following message when jBoss starts up (and on each
subsequent deploy):

[Container factory] No resource manager found for AccountDBResource

I've double checked that I have declared an "AccountDBResource"
resource in the jboss.xml file of the deployed jar. Here are the
relevant files:

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

<!DOCTYPE ejb-jar PUBLIC '-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 1.1//EN' 
'http://java.sun.com/j2ee/dtds/ejb-jar_1_1.dtd'>

<ejb-jar>
  <description>no description</description>
  <display-name>AccountJAR</display-name>
  <enterprise-beans>
    ....
    <entity>
      <description>Bean that represents a customer account in a DB</description>
      <display-name>AccountBean</display-name>
      <ejb-name>AccountBean</ejb-name>
      <home>AccountHome</home>
      <remote>Account</remote>
      <ejb-class>AccountEJB</ejb-class>
      <persistence-type>Bean</persistence-type>
      <prim-key-class>java.lang.Integer</prim-key-class>
      <reentrant>False</reentrant>
      <resource-ref>
        <description>A description for ResourceRefName</description>
        <res-ref-name>jdbc/AccountDB</res-ref-name>
        <res-type>javax.sql.DataSource</res-type>
        <res-auth>Container</res-auth>
      </resource-ref>
    </entity>
  </enterprise-beans>
  .....
</ejb-jar>
-------------------


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

<jboss>

  <enterprise-beans>

    <entity>
      <ejb-name>AccountBean</ejb-name>

      <resource-ref>
        <res-ref-name>jdbc/AccountDB</res-ref-name>
        <resource-name>AccountDBResource</resource-name>
      </resource-ref>

    </entity>

    <resource-managers>

      <resource-manager>
        <res-name>AccountDBResource</res-name>
        <res-jndi-name>OracleDS</res-jndi-name>
      </resource-manager>

    </resource-managers>

  </enterprise-beans>

</jboss>
-------------------


---jboss.conf------
....
<MLET CODE="org.jboss.jdbc.XADataSourceLoader" ARCHIVE="jboss.jar,classes111.zip" 
CODEBASE="../../lib/ext/">
    <ARG TYPE="java.lang.String" VALUE="OracleDS">
    <ARG TYPE="java.lang.String" VALUE="org.jboss.minerva.xa.XADataSourceImpl">
</MLET>
....
-------------------


--jboss.jcml-------
<?xml version="1.0"?>

<server>
     <mbean name="Adaptor:name=html">
       <attribute name="MaxActiveClientCount">10</attribute>
       <attribute name="Parser" />
       <attribute name="Port">8082</attribute>
     </mbean>
     <mbean name="DefaultDomain:service=MLet">
       <attribute name="LibraryDirectory">/local/home/oklischa/jboss/bin</attribute>
     </mbean>
     <mbean name="DefaultDomain:service=TransactionManager">
       <attribute name="TransactionTimeout">300</attribute>
     </mbean>
     <mbean name="DefaultDomain:service=Webserver">
       <attribute name="Port">8083</attribute>
     </mbean>
     <mbean name="DefaultDomain:service=Logging,type=File">
       <attribute name="LogName">../log/server</attribute>
       <attribute name="Format">[{2}] {4}</attribute>
     </mbean>
     <mbean name="DefaultDomain:service=XADataSource,name=OracleDS">
       <attribute name="Properties"></attribute>
       <attribute name="URL">jdbc:oracle:thin:@spider:1521:ora8</attribute>
       <attribute name="GCMinIdleTime">1200000</attribute>
       <attribute name="JDBCUser">intbas1</attribute>
       <attribute name="MaxSize">0</attribute>
       <attribute name="Password">PASSWORD</attribute>
       <attribute name="GCEnabled">false</attribute>
       <attribute name="InvalidateOnError">false</attribute>
       <attribute name="TimestampUsed">false</attribute>
       <attribute name="Blocking">true</attribute>
       <attribute name="GCInterval">120000</attribute>
       <attribute name="IdleTimeout">1800000</attribute>
       <attribute name="IdleTimeoutEnabled">false</attribute>
       <attribute name="LoggingEnabled">false</attribute>
       <attribute name="MaxIdleTimeoutPercent">1.0</attribute>
       <attribute name="MinSize">0</attribute>
     </mbean>
     <mbean name="EJB:service=ContainerFactory">
       <attribute name="VerifyDeployments">true</attribute>
       <attribute name="MetricsEnabled">false</attribute>
       <attribute name="VerifierVerbose">true</attribute>
     </mbean>
   </server>
-------------------


I can work around the problem by defining a data source named
"DefaultDS" and having it point to the exact same database as my
"OracleDS" above (obviously, the code in
org.jboss.ejb.Container.setupEnvironment() looks for a "DefaultDS"
data source if there was a resource of type "javax.sql.DataSource" for
which no resource manager was found).

But that can't be more than a temporary workaround.


I'm using a checked-out version of jBoss (CVS tag
"jboss_2_0_Final"). I've also tried the latest source archive
(jBoss-2.0_FINAL.zip) from www.jboss.org -- same result.

Could somebody shed some light please?

Thanks in advance,
Olaf
-- 
Olaf Klischat            | Fraunhofer ISST
Oberfeldstrasse 132      | Mollstrasse 1
12683 Berlin, Germany    | 10178 Berlin, Germany
phone: +49 30 54986231   | mail: [EMAIL PROTECTED]


--
--------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
List Help?:          [EMAIL PROTECTED]

Reply via email to