Bug 977496

Summary: HornetQ connection error
Product: OpenShift Online Reporter: matzew
Component: ContainersAssignee: Paul Morie <pmorie>
Status: CLOSED UPSTREAM QA Contact: libra bugs <libra-bugs>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 2.xCC: bhatiam, dmcphers, kborcher, matzew
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-09-06 18:58:19 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description matzew 2013-06-24 17:45:01 UTC
Description of problem:
I created a JBoss AS7 instance (http://stomp-mwessendorf.rhcloud.com/) and tried to active the STOMP handler for HornetQ 


Steps to Reproduce:
1. create a JBoss AS7 application
2. checkout the git repo 
3. Add the following to the standalone.xml (and push):

Replace the <acceptors> element with:
<acceptors>
  <netty-acceptor name="netty" socket-binding="messaging"/>
  <netty-acceptor name="netty-throughput" socket-binding="messaging-throughput">
  <param key="batch-delay" value="50"/>
  <param key="direct-deliver" value="false"/>
  </netty-acceptor>
  <netty-acceptor name="netty-stomp" socket-binding="messaging-stomp">
  <param key="protocol" value="stomp_ws"/>
  </netty-acceptor>
  <in-vm-acceptor name="in-vm" server-id="0"/>
</acceptors>

Also add this entry to the <socket-binding-group> section:
<socket-binding name="messaging-stomp" port="61614"/>


Actual results:

I get this stack-trace, when the JBoss server comes up:
 WARN  [org.hornet
q.jms.server.recovery.HornetQXAResourceWrapper] (Periodic Recovery) Can't connect to any hornetq server on recovery [XARecoveryConfig [hornetQConnectionFactory=HornetQConnectionFactory [serverLocator=ServerLocatorImpl [initialConnectors=[org-hornetq-core-remoting-impl-invm-InVMConnectorFactory?server-id=0
], discoveryGroupConfiguration=null], clientID=null, dupsOKBatchSize=1048576, transactionBatchSize=
1048576, readOnly=false], usern
ame=null, password=null]]
2013/06/24 13:36:18
,390 WARN  [com.arj
u
na.ats.jta] (Periodic Recovery
)
 
A
RJ
UNA016027: Loc
a
l XARecoveryModu
le.xaRecovery got XA exceptio
n XAExcept
ion.XAER_RMERR: javax.tra
nsactio
n.xa.XAException: 
Error tr
ying to connect to any provi
ders for xa recover
y
	at org.hornetq.jms.server
.recovery.HornetQX
AResourceWrapper.getDel
egate(HornetQXAResourceWrap
pe
r.java:2
75) [hornetq-jms-2.2.13.F
inal.jar:]
	at org.hornetq.
jms.server.re
covery.HornetQXAResourceWrapper.recover(HornetQXAResourceWrapper.java:77) [hornetq-jms-2.2
.13.Final.jar:]
	at com.arj
una.ats.internal.jta.recovery.arjunacore.XAReco
v
e
ryModule.xaRecovery(XARecoveryModule.java:503) [jbossjts-4.16.2.Final.jar:]
	at com.arjuna.ats.internal.jta.recovery.arjunacore.XA
R
e
coveryModule.resourceI
nitiatedRecoveryForReco
veryHelpers(XARecoveryModule.java:471) [jbo
ssjts-4.16.2.Final.jar:]
	at
 com.arjuna.ats.internal.jta.recovery.arjunacore.XARecoveryModule.bottomUpRecovery(XARecoveryModule.java:385) [jbossjts-4.16.2.Final.jar:]
	at com.arjuna.ats.internal.jta.recovery.arjunacore.XAReco
veryModule.periodicWorkSecondPass(XAReco
veryModule.java:166) [jbos
sjts-4.16.2.Final.jar:]
	at com.ar
juna.ats.internal.arjuna.rec
overy.PeriodicRecover
y.doWorkInternal(PeriodicRecovery.j
ava:78
9) [jbossjts-4.16.2.Final.jar:]
	at com.arjuna.ats.internal.arjuna.recovery.PeriodicRecovery.run(PeriodicRecovery.java:371) [jbossjts-4.16.2.Final.jar:]
Caused by: HornetQException[errorCode=2 mes
sage=null]
	at org.hornetq.jms.s
erv
er.recovery.HornetQXAResour
ceWrap
per.connect(HornetQXAResourceWrapper.java:351) [hornetq-jms-2.2.13.Final.jar:]
	at org.hornetq.jms.server.recovery.HornetQXAResou
rceWrapper.get
Delegate(Horn
etQXAResourceWrapp
er.java:25
1) [hornetq-jms-2.2.13.Final.jar:]
	... 7 more

2013/06/24 13:36:18,565 WARN  [org.hornetq.jms.server.recovery.HornetQXAResourceWrapper] (Periodic Recovery) Can't connect to any hornetq ser
ve
r on recovery [XARecoveryConfig [hornetQConnectionFactory=HornetQC
onnectionFactory [serverLocator=ServerLocatorImpl [initialCo
nnectors=[org-ho
rnetq-core-remoting-impl-invm-InVMConnectorFactory?s
erver-id=0], discovery
GroupConfiguration=null], clie
ntID=null, dupsOKBatchSize=1048576, trans
actionBatchSize
=1048576, readOnly=false], username=null, password=null]]




Expected results:

I was expecting that I am able to receive Stomp frames (over WebSocket), on port 61614 of my server.




Additional info:

Comment 1 Paul Morie 2013-06-26 12:58:04 UTC
Just so I have the complete context - do you want your application to act as a hornetQ broker, or just receive and publish messages to a broker external to your application?

Comment 2 matzew 2013-06-26 13:14:12 UTC
Hi,

thanks for looking into that

The OpenShift app, where I did the configuration for HornetQ should be the "broker".

I'd like to deploy another app, that is basically the client (e.g. sending/receiving messages from/to that "broker").


Since I got the above exceptions, indicating "no connection", I did not yet "deploy" a client.

However, a quick telnet check :) did tell me that nothing is working on that particular port (see my config)

Comment 3 Paul Morie 2013-06-26 20:20:00 UTC
Unfortunately, running an MQ broker as an openshift app isn't currently supported.  We have this on the roadmap, but do not have an ETA on when it will be available yet.