lhotari edited a comment on pull request #3110:
URL: https://github.com/apache/bookkeeper/pull/3110#issuecomment-1067626623


   > @lhotari The `if (!complete.compareAndSet(false, true)) {` in 
PendingReadOp#submitCallback just change the complete flag in PendingReadOp 
instance.
   > 
   > But the
   > 
   > ```
   > if (complete.compareAndSet(false, true)) {
   >                 entryImpl.close();
   >             }
   > ```
   > 
   > Change the `complete` flag in LedgerEntryRequest. They are different 
instances.
   
   @hangc0276 My question was different. I'll try to rephrase: I meant that 
since LedgerEntryRequest.close seems to only get called via call chains 
originating from PendingReadOp.submitCallback, why isn't the PendingReadOp's 
complete field preventing the duplicate calls to LedgerEntryRequest.close ?


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