You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In a situation where the RabbitMQ connection drops and a consumer/publisher are using a Lyra managed connection with a RetryPolicy, a situation can occur whereby calling "channel.getNextPublishSeqNo()" will return the sequence number for the old Channel before the Channel is recovered. The code typically then goes onto "channel.basicPublish(...)" which will then block, and eventually publish, but under a sequence number different to that which was previously acquired.
Since in my scenario the issue was being driven by the consumer being recovered first and immediately feeding a publisher that hadn't been recovered, I inverted the Channel declarations so the publisher always recovered first.
However, there is a question here of whether "channel.getNextPublishSeqNo()" should block with a RetryPolicy, as the intent of the programmer is almost certainly to publish a message subsequently and utilise the sequence number.
The text was updated successfully, but these errors were encountered:
In a situation where the RabbitMQ connection drops and a consumer/publisher are using a Lyra managed connection with a RetryPolicy, a situation can occur whereby calling "channel.getNextPublishSeqNo()" will return the sequence number for the old Channel before the Channel is recovered. The code typically then goes onto "channel.basicPublish(...)" which will then block, and eventually publish, but under a sequence number different to that which was previously acquired.
Since in my scenario the issue was being driven by the consumer being recovered first and immediately feeding a publisher that hadn't been recovered, I inverted the Channel declarations so the publisher always recovered first.
However, there is a question here of whether "channel.getNextPublishSeqNo()" should block with a RetryPolicy, as the intent of the programmer is almost certainly to publish a message subsequently and utilise the sequence number.
The text was updated successfully, but these errors were encountered: