[jboss-user] [Messaging, JMS & JBossMQ] - HELP! JBoss JMS cluster - cannot get a connection factory

paulpark do-not-reply at jboss.com
Fri May 11 07:14:54 EDT 2007


I tried to configure my client to access queues in a clustered JBoss environment.

JBoss errors out and says that "ConnectionFactory" cannot be found. I have tried java:/JmsXA, JmsXA, java:/ConnectionFactory and XAConnectionFactory, java:/XAConnectionFactory, QueueConnectionFactory as well many other configurations for connectionFactoryJndiName. For the life of me, Mule cannot get a connectionFactory. BTW, my app works fine in JBoss if it is not clustered ie "default" mode as opposed to "all" mode. 

Client snippet
==========


public void myJMS(){
  try {
    Properties p = new Properties(); 
    p.put(Context.INITIAL_CONTEXT_FACTORY,    "org.jnp.interfaces.NamingContextFactory"); 
    p.put(Context.URL_PKG_PREFIXES, "jboss.naming:org.jnp.interfaces"); 
    p.put(Context.PROVIDER_URL, "localhost:1100"); // HA-JNDI port. 
    InitialContext iniCtx = new InitialContext(p);
    Object ConnFactory = iniCtx.lookup("ConnectionFactory"); 
  } catch (Exception e) {
    e.printStackTrace();
    fail();
  }
}  

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

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



More information about the jboss-user mailing list