You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by GitBox <gi...@apache.org> on 2020/10/13 09:27:45 UTC

[GitHub] [kafka] tombentley opened a new pull request #9422: KAFKA-10602: Make RetryWithToleranceOperator thread safe

tombentley opened a new pull request #9422:
URL: https://github.com/apache/kafka/pull/9422


   ErrantRecordReporter uses a RetryWithToleranceOperator instance, which is necessarily
   stateful, having a ProcessingContext of which there's supposed to be one per
   task. That ProcessingContext is used by both
   RetryWithToleranceOperator.executeFailed() and execute(), so it's not enough
   to just synchronize executeFailed().
   
   So make all public methods of RetryWithToleranceOperator synchronized so that
   RetryWithToleranceOperator is now threadsafe.
   
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [kafka] kkonstantine commented on pull request #9422: KAFKA-10602: Make RetryWithToleranceOperator thread safe

Posted by GitBox <gi...@apache.org>.
kkonstantine commented on pull request #9422:
URL: https://github.com/apache/kafka/pull/9422#issuecomment-709525339


   The single failure in JDK 8 is unrelated. 


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [kafka] tombentley commented on pull request #9422: KAFKA-10602: Make RetryWithToleranceOperator thread safe

Posted by GitBox <gi...@apache.org>.
tombentley commented on pull request #9422:
URL: https://github.com/apache/kafka/pull/9422#issuecomment-708974318


   @kkonstantine thanks for taking a look, now sorted.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [kafka] tombentley commented on pull request #9422: KAFKA-10602: Make RetryWithToleranceOperator thread safe

Posted by GitBox <gi...@apache.org>.
tombentley commented on pull request #9422:
URL: https://github.com/apache/kafka/pull/9422#issuecomment-708294583


   @kkonstantine I've written a small test which interleaves calls to `RetryWithToleranceOperator.execute` and `RetryWithToleranceOperator.executeFailed` and detects conflicts which can arise when those methods are not `synchronized`. It fails reliable for me when they're not `synchronized` and passes reliably when they are.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [kafka] tombentley commented on pull request #9422: KAFKA-10602: Make RetryWithToleranceOperator thread safe

Posted by GitBox <gi...@apache.org>.
tombentley commented on pull request #9422:
URL: https://github.com/apache/kafka/pull/9422#issuecomment-707621004


   @aakashnshah @rhauch @kkonstantine please could one of you review? 
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [kafka] kkonstantine merged pull request #9422: KAFKA-10602: Make RetryWithToleranceOperator thread safe

Posted by GitBox <gi...@apache.org>.
kkonstantine merged pull request #9422:
URL: https://github.com/apache/kafka/pull/9422


   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [kafka] tombentley commented on pull request #9422: KAFKA-10602: Make RetryWithToleranceOperator thread safe

Posted by GitBox <gi...@apache.org>.
tombentley commented on pull request #9422:
URL: https://github.com/apache/kafka/pull/9422#issuecomment-708222714


   @kkonstantine yeah, I was hoping someone would recommend a testing approach. I'll see if I'm able to reproduce it in a test.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org