Created attachment 814459 [details] conf.zip Description of problem: Test scenario: 1. Start "source" server with deployed queue InQueue and JMS bridge 2. Start "target" server with deployed queue OutQueue - JMS bridge deployed on "source" server sends messages from "InQueue" (from "source" server) to "OutQueue" (to "target" server) Result: Sometimes there are exceptions in log of "source" server like (JMS bridge does not connect): 10:14:20,552 INFO [org.hornetq.jms.server] (pool-4-thread-1) HQ121000: Failed to set up JMS bridge connections. Most probably the source or target servers are unavailable. Will retry after a pause of 1,000 ms 10:14:21,553 WARN [org.hornetq.jms.server] (pool-4-thread-1) HQ122010: Failed to connect JMS Bridge: javax.naming.NamingException: JBAS011843: Failed instantiate InitialContextFactory org.jboss.naming.remote.client.InitialContextFactory from classloader ModuleClassLoader for Module "org.jboss.as.clustering.common:main" from local module loader @3b75078b (finder: local module finder @42552c (roots: /home/jbossqa/hornetq_eap6_testsuite/eap6.2.0.ER6/server1/jboss-eap-6.2/modules,/home/jbossqa/hornetq_eap6_testsuite/eap6.2.0.ER6/server1/jboss-eap-6.2/modules/system/layers/base)) at org.jboss.as.naming.InitialContextFactoryBuilder.createInitialContextFactory(InitialContextFactoryBuilder.java:64) at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:664) [rt.jar:1.6.0_38] at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:288) [rt.jar:1.6.0_38] at javax.naming.InitialContext.init(InitialContext.java:223) [rt.jar:1.6.0_38] at javax.naming.InitialContext.<init>(InitialContext.java:197) [rt.jar:1.6.0_38] at org.hornetq.jms.bridge.impl.JNDIFactorySupport.createObject(JNDIFactorySupport.java:55) at org.hornetq.jms.bridge.impl.JNDIDestinationFactory.createDestination(JNDIDestinationFactory.java:40) at org.hornetq.jms.bridge.impl.JMSBridgeImpl.setupJMSObjects(JMSBridgeImpl.java:1224) at org.hornetq.jms.bridge.impl.JMSBridgeImpl.setupJMSObjectsWithRetry(JMSBridgeImpl.java:1460) at org.hornetq.jms.bridge.impl.JMSBridgeImpl.access$2000(JMSBridgeImpl.java:83) at org.hornetq.jms.bridge.impl.JMSBridgeImpl$FailureHandler.run(JMSBridgeImpl.java:2049) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) [rt.jar:1.6.0_38] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) [rt.jar:1.6.0_38] at java.lang.Thread.run(Thread.java:662) [rt.jar:1.6.0_38] Configuration of JMS bridge: <jms-bridge name="myBridge"> <source> <connection-factory name="java:/ConnectionFactory"/> <destination name="jms/queue/InQueue"/> </source> <target> <connection-factory name="jms/RemoteConnectionFactory"/> <destination name="jms/queue/OutQueue"/> <context> <property key="java.naming.factory.initial" value="org.jboss.naming.remote.client.InitialContextFactory"/> <property key="java.naming.provider.url" value="remote://192.168.40.3:4447"/> </context> </target> <quality-of-service>AT_MOST_ONCE</quality-of-service> <failure-retry-interval>1000</failure-retry-interval> <max-retries>-1</max-retries> <max-batch-size>10</max-batch-size> <max-batch-time>100</max-batch-time> <add-messageID-in-header>true</add-messageID-in-header> </jms-bridge> Attaching configuration from "source" and "target" server. (conf.zip)
This problem occurs often and there is high risk that customer will hit it.
From the configuration it looks like HornetQ is the JMS implementation for both the jms-bridge target and source. Does the problem also occur if the jms-bridge configuration explicitly state to use the org.hornetq module to load the JMS bridge: <jms-bridge module="org.hornetq"> ... </jms-bridge>
With module="org.hornetq" I can't hit it again. I'll update bz#999344 to document it and close this bz. Thanks Jeff for help!