C0urante commented on PR #12478:
URL: https://github.com/apache/kafka/pull/12478#issuecomment-1220695831

   I think a `Supplier<Boolean> isCancelled` would be fine to check if the 
operator should prematurely exit. One other thing worth accounting for is the 
backoff logic, which currently uses `Time::sleep` to wait in between retries. 
We could replace those calls with `CountDownLatch::await`, and when the task is 
cancelled, invoke `CountDownLatch::countDown` so that any in-progress calls to 
`await` return early.


-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to