Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consumer restart causes duplicate messages #162

Closed
wants to merge 2 commits into from

Conversation

sobychacko
Copy link
Collaborator

When we stop the consumer, there is a race condition that forces the messages to not get acknowledged. This results in duplicate messages on the restart of the consumer.

This PR addresses the issue by waiting for the consumer thread to complete before stopping the consumer.

Resolves #161

Copy link
Collaborator

@onobc onobc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice fix @sobychacko ! I have left some minor suggestions / questions.

When we stop the consumer, there is a race condition that forces
the messages to not get acknowledged. This results in duplicate
messages on the restart of the consumer.

This PR addresses the issue by waiting for the consumer thread to
complete before stopping the consumer.

Resolves spring-projects#161
Copy link
Collaborator

@onobc onobc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work @sobychacko - thx for the updates.

@onobc
Copy link
Collaborator

onobc commented Oct 20, 2022

Closed via 2360a9d

@onobc onobc closed this Oct 20, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Consumer restart causes duplicate messages
2 participants