(copied from a thread in MQ forum) Problem:
Looking up the jndi tree of a remote jboss, over http (http://192.168.20.11:80/invoker/JNDIFactory), works fine from stand-alone java client. When doing that from inside a servlet in a local jboss, it returns local jndi tree of local jboss. Doing the same without http (with jnp://...) works fine. Detailed: In a java client, i lookup context httpParentJndi.java.naming.factory.initial org.jboss.naming.HttpNamingContextFactory httpParentJndi.java.naming.provider.url http://192.168.20.11:80/invoker/JNDIFactory httpParentJndi.java.naming.factory.url.pkgs org.jboss.naming:org.jnp.interfaces;java.protocol.handler.pkgs In that context, i look for queue/Q, and post a message. On machine 20.11, i can see the message arriving (because there's a consumer there). When i do exectly the same client code, from inside a servlet inside a jboss on my client machine, it doesn't work anymore. The queue/Q is looked up in the local jndi of the jboss the client machine (running the servlet)! This results in a naming exception. It simply ignores my jndi context parameters (telling to look for the jndi remotely). I changed to normal jndi and jms (without http): java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory java.naming.provider.url=jnp://192.168.20.11:1099 java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces By simply changing these settings, it does work inside the war. This means something is wrong with my HttpNamingContextFactory, when it is created by a thread owned by a war. View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3873028#3873028 Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3873028 ------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click _______________________________________________ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user