Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

JNDI  RSS feed

 
Ally Cavs
Ranch Hand
Posts: 95
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I believe there is a way to point at a properties file and read from the properties file using JNDI.
I want to be able to pass in a JVM arg pointing to my JNDI properties file and then know how to read from this file

JVM arg:


Then I want to know a code snippet that will show me how to access that file and the properties in that file. I dont know much about JNDI and cant really find a code snippet for the above requirement but I think it is possible?

Thanks

 
R K Singh
Ranch Hand
Posts: 5390
1
Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I did not get your requirement.

Yes, you can pass properties file location as JVM param.
Yes, you can read prop file.

Where is JNDI coming in to picture ???
 
Ally Cavs
Ranch Hand
Posts: 95
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have been doing some research and seen I can use System.get to retrieve JVM args. The use java.util.Properties to read the properties file.
So I dont think I need JNDI as you were saying. Thanks for your reply
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!