5 Replies Latest reply on Jul 24, 2015 11:52 AM by Manish Sharma

    JBoss 6.4, Connection factory set-up in Domain giving javax.naming.NameNotFoundException

    Manish Sharma Newbie

      Hi,

      I am trying to access a connectionfactory locally on JBOSS server 6.4 but it is giving the NameNotFoundException.

      Details are as follows

      In domain.xml file under  <subsystem xmlns="urn:jboss:domain:messaging:1.4"> <hornetq-server><jms-connection-factories> tag

                             <connection-factory name="APR3_TES_Archive_Connection_Factory">

                                  <connectors>

                                      <connector-ref connector-name="netty"/>

                                  </connectors>

                                  <entries>

                                      <entry name="java:jboss/exported/APR3_TES_Archive_Connection_Factory"/>

                                  </entries>

                                  <compress-large-messages>false</compress-large-messages>

                                  <failover-on-initial-connection>false</failover-on-initial-connection>

                                  <use-global-pools>true</use-global-pools>

                              </connection-factory>

       

      In my EAR application file which contains a Java file with below code fails


      InitialContext ctx = new InitialContext();

      queueConnectionFactory = (javax.jms.QueueConnectionFactory) ctx.lookup("APR3_TES_Archive_Connection_Factory");

       

      Error comes on above line [ERROR] [23 Jul 2015 15:04:45,853] [stderr] : javax.naming.NameNotFoundException: APR3_TES_Connection_Factory -- service jboss.naming.context.java.APR3_TES_Connection_Factory

       

      Many thanks in advance.

       

      Regards,

      Manish Sharma