[jboss-user] [Messaging, JMS & JBossMQ] - namenotfound exception in JMS Client

nsv do-not-reply at jboss.com
Fri Dec 8 15:52:27 EST 2006


I need help very urgent

I have configured the connection factory in jms-ds.xml as below

        <tx-connection-factory>
  |           <jndi-name>AlarmMgrConnectionFactory</jndi-name>
  |           <xa-transaction/>
  |           <rar-name>jms-ra.rar</rar-name>
  |           <connection-definition>org.jboss.resource.adapter.jms.JmsConnectionFactory</connection-definition>
  |           <config-property name="SessionDefaultType" type="java.lang.String">javax.jms.Queue</config-property>
  |           <config-property name="JmsProviderAdapterJNDI" type="java.lang.String">java:/DefaultJMSProvider</config-property>
  |           <max-pool-size>20</max-pool-size>
  |       </tx-connection-factory>
  |       
  | 
  |   
  |     <tx-connection-factory>
  |       <jndi-name>EventConnectionFactory</jndi-name>
  |       <xa-transaction/>
  |       <rar-name>jms-ra.rar</rar-name>
  |       <connection-definition>org.jboss.resource.adapter.jms.JmsConnectionFactory</connection-definition>
  |       <config-property name="SessionDefaultType" type="java.lang.String">javax.jms.Topic</config-property>
  |       <config-property name="JmsProviderAdapterJNDI" type="java.lang.String">java:/DefaultJMSProvider</config-property>
  |       <max-pool-size>20</max-pool-size>
  |       <security-domain-and-application>JmsXARealm</security-domain-and-application>
  |     </tx-connection-factory>
  |     

When i try to lookup for the conection factory from the lookup i get the Namenotbound exception, Below is the lines from JMS Client program

  Properties properties = new Properties();
  |       properties.put(Context.INITIAL_CONTEXT_FACTORY, "org.jnp.interfaces.NamingContextFactory");
  |       properties.put(Context.URL_PKG_PREFIXES, "org.jnp.interfaces");
  |       properties.put(Context.PROVIDER_URL, "localhost:3099");
  |       InitialContext ctx = new InitialContext(properties);
  |       Object obj =  ctx.lookup("java:AlarmMgrConnectionFactory");

Please please help

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

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



More information about the jboss-user mailing list