You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@iggy.apache.org by "cstruct (via GitHub)" <gi...@apache.org> on 2025/07/11 10:21:07 UTC
[I] SDK cancellation safety [iggy]
cstruct opened a new issue, #1997:
URL: https://github.com/apache/iggy/issues/1997
The SDK is not cancellation safe which can lead to deadlocks and bad state. This can be observed by calling `consume_messages` on a consumer group with no `poll_interval` set and then cancelling, the underlying TcpClient is most often cancelled still holding the `Mutex` around the underlying stream.
I tried to change to `RobustMutex` from `cancel-safe-futures` but the [stream lock has to be held across await points](https://github.com/apache/iggy/blob/d4288aaf4bba76f6df945d4fcce52e80d4f712df/core/sdk/src/tcp/tcp_client.rs#L492-L530) so `perform_async_boxed` had to be used resulting in a poisoned mutex on cancellation.
--
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: commits-unsubscribe@iggy.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] SDK cancellation safety [iggy]
Posted by "cstruct (via GitHub)" <gi...@apache.org>.
cstruct commented on issue #1997:
URL: https://github.com/apache/iggy/issues/1997#issuecomment-3111627144
I think this was fixed in [2990e82](https://github.com/apache/iggy/pull/1973/commits/2990e8270ccc6cc35a8d0b4bcf11803b04018328) part of #1973 I don't know why this wasn't automatically closed when merging that PR 🤷
--
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: commits-unsubscribe@iggy.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] SDK cancellation safety [iggy]
Posted by "hubcio (via GitHub)" <gi...@apache.org>.
hubcio commented on issue #1997:
URL: https://github.com/apache/iggy/issues/1997#issuecomment-3061752870
good find! perhaps SDK has to have internal channel for cancellation, and it should use select macro to poll both next message and this control channel?
--
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: commits-unsubscribe@iggy.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] SDK cancellation safety [iggy]
Posted by "cstruct (via GitHub)" <gi...@apache.org>.
cstruct closed issue #1997: SDK cancellation safety
URL: https://github.com/apache/iggy/issues/1997
--
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: commits-unsubscribe@iggy.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org