in order to use a datasource specified in the jboss.jcml in the embedded tomcat you will need to add a resoruce reference in a jboss-web.xml file for the web application. The  datasource will then be accessible under java:comp/env.
 
Vinay
----- Original Message -----
Sent: Tuesday, June 05, 2001 10:53 AM
Subject: [JBoss-user] jdbc jndi question

Hi,
 
I'm working on a small application which uses MySQL as the database. In my entitybean i have a class getConnection which is used for the database connection. If i want to use jndi do i have to insert the connection in jboss.jcml as wel in Tomcat's server.xml? Do i have to insert the connection in de deployment decriptor?IF so can someone send me the tags to use for the driver and url?
 
Should i use jndi in the EJB getConnection() method?
 
Thanks,
Maarten

Reply via email to