dcsimg
JNDI Lookup : Pls help
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Shan_Thiruvarur
Posted On:   Thursday, December 23, 2004 03:57 AM

in the client i code Properties props = System.getProperties(); Context ctx = new InitialContext(props); Object obj = ctx.lookup("HelloHome"); as said in the book. if i do this i get communication exception due to some context provider. first of all Object obj = ctx.lookup("HelloHome"); where will this lookup happen ? in which file will it look for HelloHome ? i'm not able to understand this. it will lookup if i say ctx.lookup but from where ? pls help.    More>>

in the client i code




Properties props = System.getProperties();


Context ctx = new InitialContext(props);


Object obj = ctx.lookup("HelloHome");




as said in the book.





if i do this i get communication exception due to some context provider.





first of all


Object obj = ctx.lookup("HelloHome");



where will this lookup happen ? in which file will it look for HelloHome ?


i'm not able to understand this. it will lookup if i say ctx.lookup but from where ?



pls help.


   <<Less

Re: JNDI Lookup : Pls help

Posted By:   sini_s  
Posted On:   Wednesday, December 29, 2004 02:59 AM

You have to use "HelloHome" as the jndi name. You are not specified which Appserver you are using.If it is J2ee you have to give this JNDI name in deployment descriptor.
About | Sitemap | Contact