qpid-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Vince Cole ...@vincecole.co.uk>
Subject synchronous sending - using javax.jms.MessageProducer::send
Date Tue, 07 Mar 2017 14:15:54 GMT
I have a requirement to for my JMS client to block, and only return once
the message has been accepted onto the specified queue or topic. If the
message is not accepted, then an exception should be thrown. We don't care
whether anything actually consumes the message.

However, my client can only seem to produce messages in asynchronous mode!
So if there's an exception, all we can do is log it. That's not enough, I
need the client application to keep the message (so it can retry later) and
only drop it once the broker has accepted it into the specified

I am using:
* javax.jms : javax.jms-api : 2.0.1
* org.apache.qpid : qpid-jms-client : 0.11.1
* org.apache.qpid : qpid-amqp-1-0-client-jms : 0.32
* The broker is ActiveMQ 5.14.0, if that makes any difference.

Please could you advise if the Qpid Java client library supports
synchronous production
and if so what settings to use, to acheive that, in the following (where
* Options in the transport URI (in activemq.xml)
* Options in the connection URI (used by the client)
* Whether messages need to be 'persistent' or not?
* Whether the producer's JMS session should be transacted or not?
* What 'acknowledge mode' to set?
* Whether having a 'ConnectionListener' set on the connection will force it
to be asynchronous, regardless?

Thanks in advance.

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message