pvary commented on code in PR #15862:
URL: https://github.com/apache/iceberg/pull/15862#discussion_r3140262485
##########
core/src/main/java/org/apache/iceberg/util/LockManagers.java:
##########
@@ -109,9 +107,9 @@ public int heartbeatThreads() {
}
public ScheduledExecutorService scheduler() {
- if (scheduler == null) {
+ if (scheduler == null || scheduler.isShutdown()) {
Review Comment:
This would only be a partial measure if we want to handle the case where the
caller closes the scheduler. If the scheduler has already been exposed to
another component, concurrent closure could cause failures.
We should either document this behavior or prevent the scheduler from being
shut down. In this case, I’d suggest adding a Javadoc note stating that the
scheduler must not be shut down.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]