Hi i've found this article how to bind MBean to JNDI
http://wiki.jboss.org/wiki/BindMBeanToJNDI
But for some reason I can't get the object back using JNDI lookup, it's always
null
| Object obj = remoteCtx.lookup("service/Engine");
| Assert.assertNotNull(obj);
|
The jndi is correct for sure because there is no NamingException and I can see the name in
JndiView
I've added some debuging code to rebind() method to be sure that the object is being
put to the Context but this look ok, see below.
| Name fullName = rootCtx.getNameParser("").parse(jndiName);
| System.out.println("Binding to '"+fullName+"' object:
"+getObjectToBind());
| NonSerializableFactory.rebind(fullName, getObjectToBind(), true);
|
output
| [STDOUT] Binding to 'service/Engine' object: core.EngineService@4e94a4
|
Any ideas what's missing?
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4159604#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...