Question

AMQP Subscriber/Publisher for Red Hat AMQ 7

  • 11 May 2020
  • 1 reply
  • 4 views

Hi All,

I have been looking at configuring JMS Subscribers and Publishers for an AMQP connection to a Red Hat AMQ 7 (Based on ActiveMQ Artemis) broker.

Using the included ActiveMQ libraries, I can validate with the following parameters:

Provider Type or Context

ACTIVEMQ

Provider URL

tcp:localhost:61616

Connection Factory

ConnectionFactory

Destination(s)

dynamicQueues/test

However, when I attempt to validate using the AMQP URI (with correct port), it returns an error stating that it is Unable to Connect provider with URL. No connection attempt is recognised by the message broker service.

I sourced the ActiveMQ AMQP library (activemq-amqp-5.15.12.jar) and hawtbuf libraries (hawtbuf-1.11.jar & hawtbuf-proto.jar) from the most recent ActiveMQ libraries, and reattempted, now getting a timeout that is seen at least seen by the message broker. The error from the JMS subscriber is shown below.

Connecting to message brokers is a fairly new topic to me unfortunately, I was looking to see if anyone has had any luck implementing the AMQP protocol, or had any general advice to assist.

Thank you in advance!

Wed-29-Apr-2020 10:00:43.115 PM INFORM main 806001 : Subscriber "jms" is starting up ...
COM.safe.fmeserver.plugin.jms.JMSClientException: javax.jms.JMSException: java.io.EOFException
at COM.safe.fmeserver.plugin.jms.JMSClient.connect(JMSClient.java:114)
at COM.safe.fmeserver.notification.plugin.FMESubscriberPluginJMS.onTest(FMESubscriberPluginJMS.java:170)
at COM.safe.fmeserver.api.notification.subscriber.FMESubscriberManagerSession.init(FMESubscriberManagerSession.java:192)
at COM.safe.fmeserver.plugin.FMESubscriberPluginBase.init(FMESubscriberPluginBase.java:136)
at COM.safe.fmeserver.notification.plugin.FMESubscriberPluginJMS.main(FMESubscriberPluginJMS.java:57)
Caused by: javax.jms.JMSException: java.io.EOFException
at org.apache.activemq.util.JMSExceptionSupport.create(JMSExceptionSupport.java:49)
at org.apache.activemq.ActiveMQConnection.syncSendPacket(ActiveMQConnection.java:1362)
at org.apache.activemq.ActiveMQConnection.ensureConnectionInfoSent(ActiveMQConnection.java:1466)
at org.apache.activemq.ActiveMQConnection.start(ActiveMQConnection.java:503)
at COM.safe.fmeserver.plugin.jms.JMSClient.connect(JMSClient.java:99)
... 4 more
Caused by: java.io.EOFException
at java.io.DataInputStream.readFully(DataInputStream.java:197)
at org.fusesource.hawtbuf.Buffer.readFrom(Buffer.java:412)
at org.apache.activemq.transport.amqp.AmqpWireFormat.unmarshal(AmqpWireFormat.java:107)
at org.apache.activemq.transport.tcp.TcpTransport.readCommand(TcpTransport.java:229)
at org.apache.activemq.transport.tcp.TcpTransport.doRun(TcpTransport.java:221)
at org.apache.activemq.transport.tcp.TcpTransport.run(TcpTransport.java:204)
at java.lang.Thread.run(Thread.java:748)

1 reply

Badge +11

@sammcdonald filed a Case and with the help of our Dev - Stephen we were able to get Qpid AMQP client to function with the AMQP. We will update this question when a new article is published outlining the solution. You can get Qpid here https://qpid.apache.org/releases/qpid-jms-0.51.0/index.html.

Reply