Skip to content

Consumer restart causes duplicate messages #161

Closed
@sobychacko

Description

@sobychacko

Scenario:

  1. Start an exclusive consumer--> Receive message.
  2. Stop the consumer.
  3. Restart the consumer or start another consumer under the same subscription name.
  4. Occasionally, the same message that was already seen by the first consumer reappears in the second consumer.

The reason is because in step 2 above, when we stop the container if there are any acks in progress, they are immediately aborted by stopping the consumer and then the container is stopped. We need to wait for the consumer thread to finish what it is doing before stopping the consumer.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions