Hi,
In my
Tomcat(4.1) application, I am trying to create a
servlet to lookup a JBossMQ jms name in
JBoss 3.2.1. The code is like this:
String icf = "org.jnp.interfaces.NamingContextFactory";
String url="jnp://localhost:1099";
Properties props = new Properties();
props.put( Context.INITIAL_CONTEXT_FACTORY, icf );
props.put( Context.PROVIDER_URL, url );
InitialContext ctx = new InitialContext(props);
System.out.println("got context!");
QueueConnectionFactory qcf = (QueueConnectionFactory)ctx.lookup
("java:/XAConnectionFactory");
System.out.println("found qcf!");
...
But I got an exception: "Name XAConnectionFactory is not bound in this Context".
What's wrong with above code? Or what kinds of jar files do I have to copy to Tomcat lib from Jboss?
Thank for any help!!!
Chris
[ May 02, 2005: Message edited by: chris wang ]