This week's book giveaway is in the Jython/Python forum.
We're giving away four copies of Murach's Python Programming and have Michael Urban and Joel Murach on-line!
See this thread for details.
Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Problem in using Inital Context Factory class  RSS feed

 
Issac Abbas
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have installed J2EE 1.3.1. I have deployed my EJBs. When i wanted to lookup, I specify INITIAL_CONTEXT_FACTORY as "com.sun.enterprise.naming.SerialInitContextFactory". I got another new installation of J2EE 1.3.1 with the same beans deployed. When i try to create initial context with the same factory class, i am unable to connect. When i change my factory class to "com.sun.jndi.cosnaming.CNCtxFactory", it is working fine. What is the factor that decides which factory class to use? When i use the same version of J2EE, why should i need different factory classes to connect.?? Any clarifications on this regards is highly appreciated.
You can also reach me by : issac.abbas@wipro.com
 
Mon Mayor
Ranch Hand
Posts: 40
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Let me try!
The CNCtxFactory is the sun's cosnaming implementation. This is the naming service used for iiop. The SerialInitCtxFactory class instantiates the class name provided by the Context.Initial_Context parameter, whatever it be and that is all the work it does. If you provide a LDAP implementation then it will instantiate that class. So if you just provide the SerialInitCtx name as a parameter you still do not have a naming service. Hope this helps.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!