Hi, i have a DB helper class which all the EJBs are using. Now for initializing the DB Helper class, i am using a prperty file (for example to read the Data source JNDI name). Can someone tell me where should i put the .propeteis file so that it would be visible to the DB Helper class? DB helper class is packaged in the ejb jar along with other EJB classes. the property file is also required for Log4J initialization.
Thanks in advance
Manabendra
-
Property file in EJB (2 messages)
- Posted by: Manab Sarkar
- Posted on: November 27 2003 12:27 EST
Threaded Messages (2)
- Property file in EJB by Badrish Agarwal on November 28 2003 00:30 EST
- Property file in EJB by Rajesh Natarajan on November 28 2003 02:04 EST
-
Property file in EJB[ Go to top ]
- Posted by: Badrish Agarwal
- Posted on: November 28 2003 00:30 EST
- in response to Manab Sarkar
One of the options is to pass the path of properties file to JVM ,
thus you can construct the file path at run time.
Badrish -
Property file in EJB[ Go to top ]
- Posted by: Rajesh Natarajan
- Posted on: November 28 2003 02:04 EST
- in response to Badrish Agarwal
Use resource bundles to look up the property file for yourself. If you are writing EJB code then you should be using the Deployment descriptor to provide this information to the bean. Please look at the resource mappings in the deployment descriptors.
Hope this helps.