[jboss-user] [JBoss Messaging] - Re: where do i need to specify the JNP port which is used fo

phanisekhar do-not-reply at jboss.com
Wed Nov 29 11:43:31 EST 2006


I have tried using the below code, but i was unable to create connection , i am getting the Communication exception

Hashtable properties1 = new Hashtable();
properties1.put(Context.INITIAL_CONTEXT_FACTORY,
        "org.jnp.interfaces.NamingContextFactory");
properties1.put(Context.URL_PKG_PREFIXES,
        "org.jboss.naming:org.jnp.interfaces");
properties1.put(Context.PROVIDER_URL, "jnp://localhost:1099");

ConnectionFactory connectionFactory1 = null;

try {
  Context context1 = new InitialContext(properties1);
  connectionFactory1 = (ConnectionFactory) context1
      .lookup("ConnectionFactory");
} catch (NamingException ne) {
  throw new RuntimeException(ne);
}
	

can any one specify what should be my provider url ...


View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3989768#3989768

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3989768



More information about the jboss-user mailing list