C0urante commented on pull request #10112:
URL: https://github.com/apache/kafka/pull/10112#issuecomment-781565662


   Yeah, the unit tests for the worker classes in general can be a little 
gnarly. The boilerplate segments (for things like setting up the converter, 
transformation chain, task context, headers, topic tracking, offset buffering, 
status tracking, and performing metrics assertions) are in line with the other 
tests in this class, though. The only difference with the new unit test here is 
that we want to test task behavior under some pretty fine-grained 
circumstances, which is accomplished right now by setting up latches and 
awaiting them to ensure that the task (which is running on a separate thread) 
has reached certain points in its lifecycle and not gone any further. If you 
have suggestions for how to improve that I'm all ears!
   
   I'm not sure what you're referring to with task restart--that's not tested 
for at the moment, and any tests for that would likely be dependent on the 
success (or lack thereof) of any prior offset commit attempts, which are 
already tested for. Can you clarify or provide a brief example?


----------------------------------------------------------------
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:
us...@infra.apache.org


Reply via email to