I'm having trouble binding a standalone application to the JNDI naming service on a
1.3 RI server:
public static void main( String[] args ) {
Hashtable env = new Hashtable();
env.put( Context.INITIAL_CONTEXT_FACTORY, "com.sun.jndi.cosnaming.CNCtxFactory" );
env.put( "java.naming.provider.url", "iiop://localhost:1050" );
Context context = new InitialContext( env );
context.lookup( args[ 0 ]);
}
The lookup() method always throws a
NameNotFoundException. I've tried various names, including
java:comp/env
ejb/TheConverter (the JNDI name of the deployed bean)
java:comp/env/ejb/TheConverter
but none works.
Is this the correct way to bind to the naming service?
cheers
kenny
===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST". For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".