rahul05ranjan commented on PR #23567:
URL: https://github.com/apache/kafka/pull/23567#issuecomment-5830442194

   Thanks for the detailed explanation — that makes sense, and I agree the 
current sequence is fine.
   
   You're right on both points:
   1. Placing the reset after \stopAndAwaitConnector\ + \ emoveConnectorConfig\ 
+ \onDeletion\ ensures the connector and its tasks are fully stopped before the 
active-topic set is cleared, so nothing can re-record topics after the reset. 
And the \DistributedHerder\ revocation path does the same (reset after the 
connector is no longer in \configState\), so this is consistent with the 
established pattern.
   2. A \inally\ around the whole sequence would indeed run the reset even 
when an earlier step failed (connector not fully stopped/deleted), which would 
be wrong. And since standalone \onDeletion()\ only writes to the in-memory 
\MemoryStatusBackingStore\ (no external I/O), the risk of it throwing is 
negligible.
   
   So no need for the narrower \        ry/finally\ — the current cleanup 
sequence and existing exception handling are the right call. My original 
comment was a non-blocking robustness note, and your reasoning resolves it.
   
   Thanks again for the fix and the thorough follow-up!


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