swuferhong opened a new issue, #1721: URL: https://github.com/apache/fluss/issues/1721
### Search before asking - [x] I searched in the [issues](https://github.com/apache/fluss/issues) and found nothing similar. ### Fluss version main (development) ### Please describe the bug 🐞 A `ServerConnection` that has already been set to `DISCONNECTED` is still processing requests. The error occurs as follows: ```java org.apache.fluss.server.replica.fetcher.ReplicaFetcherThread [] - Error in response for fetch log request org.apache.fluss.rpc.messages.FetchLogRequest@691b6a8b java.util.concurrent.ExecutionException: org.apache.fluss.exception.NetworkException: org.apache.fluss.exception.DisconnectException: Cannot send request to server xxx (id: ts-131, rack: xxx) because it is disconnected. at java.util.concurrent.CompletableFuture.reportGet(CompletableFuture.java:396) ~[?:?] at java.util.concurrent.CompletableFuture.get(CompletableFuture.java:2096) ~[?:?] at org.apache.fluss.server.replica.fetcher.ReplicaFetcherThread.processFetchLogRequest(ReplicaFetcherThread.java:227) ~[fluss-server-0.8-SNAPSHOT.jar:0.8-SNAPSHOT] at java.util.Optional.ifPresent(Optional.java:178) [?:?] at org.apache.fluss.server.replica.fetcher.ReplicaFetcherThread.maybeFetch(ReplicaFetcherThread.java:153) [fluss-server-0.8-SNAPSHOT.jar:0.8-SNAPSHOT] at org.apache.fluss.server.replica.fetcher.ReplicaFetcherThread.doWork(ReplicaFetcherThread.java:124) [fluss-server-0.8-SNAPSHOT.jar:0.8-SNAPSHOT] at org.apache.fluss.utils.concurrent.ShutdownableThread.run(ShutdownableThread.java:96) [fluss-server-0.8-SNAPSHOT.jar:0.8-SNAPSHOT] Caused by: org.apache.fluss.exception.NetworkException: org.apache.fluss.exception.DisconnectException: Cannot send request to server xxx (id: ts-131, rack: xxx) because it is disconnected. Caused by: org.apache.fluss.exception.DisconnectException: Cannot send request to server 33.207.188.44:35367 (id: ts-131, rack: xxx) because it is disconnected. ``` This error is unexpected. In theory, once a `serverConnection` is set to `DISCONNECTED`, it must have reached `serverConnection.close()`, which should definitely trigger either `closeFuture.complete()` or `closeFuture.completeExceptionally()`. However, the current behavior suggests that neither of these methods is being called. At present, we strongly suspect that the issue lies in `channel.close().addListener()` not being invoked as expected. ### Solution _No response_ ### Are you willing to submit a PR? - [ ] I'm willing to submit a 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: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
