eemario commented on issue #1294:
URL: https://github.com/apache/flink-agents/issues/1294#issuecomment-6288344937

   Thanks for the precise trace — the interrupt chain checks out. One addition: 
this is not shutdown-only. If user code leaves the interrupt flag set when the 
supplier returns (e.g. catching an inner InterruptedException and 
re-interrupting, the recommended pattern), lockInterruptibly throws immediately 
even though the lock is free, with no shutdown involved: a completed result (or 
the supplier's real exception, lost without suppression) is discarded, restore 
never runs, and the follow-up markDone()/releaseToMain() produce the ISE you 
saw.
   
   I'd go with your option 2: a coordinator-side guard alone isn't enough, 
since it can't recover the discarded result/exception/context. Re-acquire with 
the flag stashed (one-shot clear-and-restore), which fully covers the 
non-shutdown case; the indefinite-wait concern stays bounded because close() 
re-issues interrupts every second, so the coordinator's finally only needs a 
shutdown-only branch that tolerates returning without the lock.


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