If you publish to a queue without any consumers using that code, you can
then browse the messages via the web console to see if they have the
JMSExpiration header set.  If not, the question is why it's not getting set
by your producer code.  If it is set, then the question is why the broker
isn't acting upon it in the way you expect.  So finding out the answer to
that question helps narrow the search space for the problem.

(The other) Tim

On Oct 20, 2016 10:48 AM, "mkoppala" <mkopp...@broadsoft.com> wrote:

> Sorry for less information.
> I tried the following:-
>
> Just now I changed the delivery mode to PERSISTENT and setting the ttl. The
> messages are getting delivered to the broker now.
>
> But still I see the messages are not discarded at broker after the timer
> expiry.
> I suppose the api call to setTimeToLive is not overriding the default
> value!?
> Some post says I need to set setExplicitQosEnabled(true) to set the below
> values. If so, how can I set this?
>
> producer->send(message.get(),DeliveryMode::PERSISTENT,4,60000);
>
> I also tried setting the ttl at producer and send(message.get()) But no
> help.
>
>
>
>
> --
> View this message in context: http://activemq.2283324.n4.
> nabble.com/activemq-cms-timeToLive-is-creating-an-
> issue-tp4718128p4718135.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>

Reply via email to