[jboss-user] [Beginners Corner] - Re: How to lookup for a bean
rrusinkiewicz
do-not-reply at jboss.com
Tue Oct 31 07:01:26 EST 2006
I adjusted my client code to the following:
Hashtable environment = new Hashtable();
environment.put(Context.INITIAL_CONTEXT_FACTORY, "org.jnp.interfaces.NamingContextFactory");
environment.put(Context.URL_PKG_PREFIXES, "org.jboss.naming:org.jnp.interfaces");
environment.put(Context.PROVIDER_URL, "jnp://localhost:1099");
InitialContext ctx = new InitialContext(environment);
cal = (ApptransCalculatorLocal) ctx.lookup(
"ejb1/ApptransCalculator/local");
But it still returns null as cal
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3982031#3982031
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3982031
More information about the jboss-user
mailing list