This is an automated email from the ASF dual-hosted git repository.
yunhong pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/fluss.git
The following commit(s) were added to refs/heads/main by this push:
new 1ed4fc54f [server] Last close ZookeeperClient to prevent exceptions
(#2018)
1ed4fc54f is described below
commit 1ed4fc54f31b0fe2c8091b0552ee8e9247cd20a5
Author: Liebing <[email protected]>
AuthorDate: Tue Nov 25 21:25:03 2025 +0800
[server] Last close ZookeeperClient to prevent exceptions (#2018)
---
.../java/org/apache/fluss/server/authorizer/DefaultAuthorizer.java | 4 ----
.../fluss/server/authorizer/ZkNodeChangeNotificationWatcher.java | 2 +-
.../src/main/java/org/apache/fluss/server/tablet/TabletServer.java | 7 +++----
3 files changed, 4 insertions(+), 9 deletions(-)
diff --git
a/fluss-server/src/main/java/org/apache/fluss/server/authorizer/DefaultAuthorizer.java
b/fluss-server/src/main/java/org/apache/fluss/server/authorizer/DefaultAuthorizer.java
index 69b007d7a..fac4aa740 100644
---
a/fluss-server/src/main/java/org/apache/fluss/server/authorizer/DefaultAuthorizer.java
+++
b/fluss-server/src/main/java/org/apache/fluss/server/authorizer/DefaultAuthorizer.java
@@ -159,10 +159,6 @@ public class DefaultAuthorizer extends AbstractAuthorizer
implements FatalErrorH
@Override
public void close() {
- if (zooKeeperClient != null) {
- zooKeeperClient.close();
- }
-
if (aclChangeNotificationWatcher != null) {
aclChangeNotificationWatcher.stop();
}
diff --git
a/fluss-server/src/main/java/org/apache/fluss/server/authorizer/ZkNodeChangeNotificationWatcher.java
b/fluss-server/src/main/java/org/apache/fluss/server/authorizer/ZkNodeChangeNotificationWatcher.java
index 497e72756..136673fb7 100644
---
a/fluss-server/src/main/java/org/apache/fluss/server/authorizer/ZkNodeChangeNotificationWatcher.java
+++
b/fluss-server/src/main/java/org/apache/fluss/server/authorizer/ZkNodeChangeNotificationWatcher.java
@@ -91,7 +91,7 @@ public class ZkNodeChangeNotificationWatcher {
return;
}
running = false;
- LOG.info("Stopping TableChangeWatcher");
+ LOG.info("Stopping ZkNodeChangeNotificationWatcher");
curatorCache.close();
}
diff --git
a/fluss-server/src/main/java/org/apache/fluss/server/tablet/TabletServer.java
b/fluss-server/src/main/java/org/apache/fluss/server/tablet/TabletServer.java
index 677035039..56d136741 100644
---
a/fluss-server/src/main/java/org/apache/fluss/server/tablet/TabletServer.java
+++
b/fluss-server/src/main/java/org/apache/fluss/server/tablet/TabletServer.java
@@ -382,10 +382,6 @@ public class TabletServer extends ServerBase {
}
try {
- if (zkClient != null) {
- zkClient.close();
- }
-
// TODO currently, rpc client don't have timeout logic. After
implementing the
// timeout logic, we need to move the closure of rpc client to
after the closure of
// replica manager.
@@ -431,6 +427,9 @@ public class TabletServer extends ServerBase {
lakeCatalogDynamicLoader.close();
}
+ if (zkClient != null) {
+ zkClient.close();
+ }
} catch (Throwable t) {
exception = ExceptionUtils.firstOrSuppressed(t, exception);
}