I have a method that sends messages to a jms queue and this method can be called inside and outside the appserver.
In that method I need to create an InitialContext to lookup the jms queue. This is great from within the appserver because when I create the InitialContext the PROVIDER_URL is already set. I am hoping that there is a system property that I can lookup. That way I can also set that system property in my app that runs outside the server and I don't need to change the method. I.E. | Properties p = new Properties() | // This works because this system property seems to be set by jboss | p.put(Context.INITIAL_CONTEXT_FACTORY, System.getProperty(Context.INITIAL_CONTEXT_FACTORY)); | // This does not work becuase this property is not set | p.put(Context.PROVIDER_URL, System.getProperty(Context.PROVIDER_URL)); | So as you can see from the code it does not seem jboss stores the PROVIDER_URL system property the same way it store the INITIAL_CONTEXT_FACTORY. Which seems wrong because jboss should know its own URL. Any ideas? View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4237451#4237451 Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4237451 _______________________________________________ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user