Details
-
Improvement
-
Status: Closed
-
Major
-
Resolution: Fixed
-
None
Description
While debugging resource leaks (FLINK-24131), I found that any connector is immediately interrupted on cancel. Hence, any attempts of using blocking calls in close to cleanup resources are immediately unreliable (e.g. aborting transactions).
It would be nice if tasks get a grace period (e.g. task.cancellation.interval) where they can try to free resources in a proper, potentially blocking fashion before being interrupted.
Nevertheless, connectors should always expect interruptions during shutdown, in particular when the user-configurable grace period is depleted. I'd add that to the connector documentation in a separate effort.
Attachments
Issue Links
- is related to
-
FLINK-23527 Clarify `SourceFunction#cancel()` contract about interrupting
- Closed
-
FLINK-24184 Potential race condition leading to incorrectly issued interruptions
- Closed
- relates to
-
FLINK-21181 Buffer pool is destroyed error when outputting data over a timer after cancellation.
- Resolved
-
FLINK-24357 ZooKeeperLeaderElectionConnectionHandlingTest#testLoseLeadershipOnLostConnectionIfTolerateSuspendedConnectionsIsEnabled fails with an Unhandled error
- Closed
- links to