0

I send a message to the queue with property "timetolive" with activemq producer and then receive with activemq consumer function receive(long long timeout).After receive some messages the receive always timeout and cannot receive any messages again.

It is work well when the message not have property timetolive.

why ,and how can I do when receive timeout.

Version Activemq 5.4.2 activemq-cpp 3.2.5

tshepang
  • 12,111
  • 21
  • 91
  • 136
jaylong35
  • 3
  • 2

1 Answers1

0

If you messages are exceeding you TTL value then the receive calls won't return anything. You either need to set a longer TTL, or ensure that the clocks are synced on your client and server machines. Otherwise you need to provide more info here to help diagnose the problem.

Tim Bish
  • 17,475
  • 4
  • 32
  • 42
  • Thanks very much. The problem has been resolved. As you said, I sync the clocks on my client and server machines, and client return to work normal. – jaylong35 Dec 30 '11 at 03:23
  • If this is resolved make sure you mark this thread as answered so others no there is a solution. Thanks. – Tim Bish Dec 30 '11 at 11:32