Hello, I have the following question. I want to set up all of the
resource references in one place, such as standardjboss.xml, rather than
having to create a jboss.xml file for each bean. If only one bean is
specified in standardjboss.xml, then this approach works fine; however,
if more than one bean is defined, then this does not work. So, my
question is: Is it possible to set up multiple resource references in
standardjboss.xml, which will save the developer the trouble of having
to add jboss.xml to several pre-created beans?
Here's some background info which may be helpful...
I have set up a MySQL database server and properly configured
JBoss-2.4.4 to set up a datasource. I have also created an entity bean
that successfully connects to JBoss application server and inserts a row
into the database.
The ejb-jar.xml file is as follows:
<ejb-jar>
<enterprise-beans>
<session>
...
<resource-ref>
<res-ref-name>jdbc/TobyDB</res-ref-name>
<res-type>javax.sql.DataSource</res-type>
<res-auth>Container</res-auth>
</resource-ref>
</session>
</enterprise-beans>
...
</ejb-jar>
The standardjboss.xml file is as follows:
<enterprise-beans>
<entity>
<ejb-name>Converter</ejb-name>
<resource-ref>
<res-ref-name>jdbc/InfoDB</res-ref-name>
<jndi-name>java:/jdbc/InfoDS</jndi-name>
</resource-ref>
</entity>
<session>
<ejb-name>OtherBean</ejb-name>
<resource-ref>
<res-ref-name>jdbc/DataDB</res-ref-name>
<jndi-name>java:/jdbc/DataDS</jndi-name>
</resource-ref>
</session>
</enterprise-beans>
Thank you,
Toby
----------------------------------------------------------------------------
Bringing you mounds of caffeinated joy
>>> http://thinkgeek.com/sf <<<
_______________________________________________
Jboss-development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development