divijvaidya commented on PR #13435:
URL: https://github.com/apache/kafka/pull/13435#issuecomment-1479774799

   Thank for your reply @Stephan14. 
   
   `responseCallback` is called from:
   
   
https://github.com/apache/kafka/blob/trunk/core/src/main/scala/kafka/coordinator/group/GroupMetadataManager.scala#L323
 where it is called by the same thread
   
   or 
   
   
https://github.com/apache/kafka/blob/trunk/core/src/main/scala/kafka/coordinator/group/GroupMetadataManager.scala#L339
 where it is called with delayed produce by a different thread. In this 
scenario, we explicitly say that the completion of this response should be 
called in scope of delayedProduceLock which we set to group.lock at 
https://github.com/apache/kafka/blob/trunk/core/src/main/scala/kafka/coordinator/group/GroupMetadataManager.scala#L338
 Hence, the other thread will acquire the lock on `group` before calling the 
`responseCallback`
   
   What am I missing here?


-- 
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: jira-unsubscr...@kafka.apache.org

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

Reply via email to