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

fix: add nil check while producer is retrying #2387

Conversation

hsweif
Copy link
Contributor

@hsweif hsweif commented Nov 11, 2022

The function newHighWatermark send fin message to the input channel; it might panic when the pp.brokerProducer is nil. I added a simple check to fix it. Please help double-check if there are any unwanted side effects when you have time. Thanks a lot!

Check nil and update the leader, if needed, before updating the new
watermark

Refs: IBM#2322
@hsweif hsweif marked this pull request as draft November 11, 2022 16:50
@hsweif hsweif closed this Nov 11, 2022
@hsweif hsweif reopened this Nov 11, 2022
@hsweif
Copy link
Contributor Author

hsweif commented Nov 11, 2022

I put it in the draft stage first as I'm still learning the codebase, will update and make it ready when I confirm there's no side effect.

@dnwe dnwe marked this pull request as ready for review December 21, 2022 11:51
@dnwe dnwe closed this Dec 21, 2022
@dnwe dnwe reopened this Dec 21, 2022
@dnwe dnwe added the fix label Dec 21, 2022
@dnwe dnwe changed the title fix: add nil check while retrying fix: add nil check while producer is retrying Dec 21, 2022
@dnwe dnwe merged commit 2379257 into IBM:main Dec 21, 2022
@dnwe
Copy link
Collaborator

dnwe commented Dec 21, 2022

Thank you for your contribution, approved and merged

@hsweif hsweif deleted the hsuanwei.fan/fix/producer-panic-while-retrying-sending-the-message branch March 1, 2023 15:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants