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(consumer): call interceptors when MaxProcessingTime expire #1962

Merged
merged 1 commit into from
Jun 22, 2021

Conversation

hanxiaolin
Copy link
Contributor

@hanxiaolin hanxiaolin commented Jun 7, 2021

Missing call for interception when MaxProcessingTime timed out and we process the remaining messages

@hanxiaolin hanxiaolin requested a review from bai as a code owner June 7, 2021 05:51
@ghost ghost added the cla-needed label Jun 7, 2021
@hanxiaolin
Copy link
Contributor Author

mod

@ghost ghost removed the cla-needed label Jun 9, 2021
@dnwe dnwe requested a review from d1egoaz June 9, 2021 09:53
@dnwe
Copy link
Collaborator

dnwe commented Jun 22, 2021

@d1egoaz please could you take a look and confirm you're happy with the interceptor changes?

@d1egoaz
Copy link
Contributor

d1egoaz commented Jun 22, 2021

@d1egoaz please could you take a look and confirm you're happy with the interceptor changes?

@dnwe it looks it's doing the right think

for _, msg = range msgs[i:] {

apparently, something breaks the major loop and not all messages are being intercepted

https://github.com/Shopify/sarama/blob/7d06a470f1eeb5d51f48b9a69de7e02f778ecdd6/consumer.go#L470

I'm not too familiar with this block of code
https://github.com/Shopify/sarama/blob/7d06a470f1eeb5d51f48b9a69de7e02f778ecdd6/consumer.go#L474-L502

but thinks look ok to me

@dnwe dnwe changed the title fix: consumer interceptors fix(consumer): call interceptors when MaxProcessingTime expire Jun 22, 2021
Copy link
Collaborator

@dnwe dnwe left a comment

Choose a reason for hiding this comment

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

Thanks, LGTM too

@dnwe dnwe merged commit 0676fc2 into IBM:master Jun 22, 2021
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.

3 participants