Skip to Content
0
Mar 31, 2006 at 10:35 AM

Remote lookup of WAS-JMS-Factory from standalone nonJ2EE client?

35 Views

Hello,

I am working on a non-J2EE-Client which runs as a bundled application on OSGI, and need to send and receive messages to/from a queue which is adminstered by the WAS JMS provider. Unfortunately, I cannot even do a lookup of the ConnectionFactory so far..

A naive attempt was to do the following:

props.put(Context.PROVIDER_URL, "hostOfServer:50004");

Context jndiContext = new InitialContext(props);

factory = (QueueConnectionFactory) jndiContext.lookup(CONNECTION_FACTORY);

but as expected that didn't work with JNDI.

Does anybody have a hint what I have to do to to the remote lookup?