This is an automated email from the ASF dual-hosted git repository.

kenhuuu pushed a commit to branch jstream2
in repository https://gitbox.apache.org/repos/asf/tinkerpop.git


The following commit(s) were added to refs/heads/jstream2 by this push:
     new c3c63831f4 Slight options modifications.
c3c63831f4 is described below

commit c3c63831f4089cefbdd28d607b8a0cd46fc80fc6
Author: Ken Hu <[email protected]>
AuthorDate: Thu May 14 20:25:15 2026 -0700

    Slight options modifications.
---
 .../gremlin/driver/handler/HttpStreamingResponseHandler.java      | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git 
a/gremlin-driver/src/main/java/org/apache/tinkerpop/gremlin/driver/handler/HttpStreamingResponseHandler.java
 
b/gremlin-driver/src/main/java/org/apache/tinkerpop/gremlin/driver/handler/HttpStreamingResponseHandler.java
index ea0d897aac..602148d848 100644
--- 
a/gremlin-driver/src/main/java/org/apache/tinkerpop/gremlin/driver/handler/HttpStreamingResponseHandler.java
+++ 
b/gremlin-driver/src/main/java/org/apache/tinkerpop/gremlin/driver/handler/HttpStreamingResponseHandler.java
@@ -90,7 +90,7 @@ public class HttpStreamingResponseHandler extends 
MessageToMessageDecoder<HttpOb
         this.graphBinaryReader = graphBinaryReader;
         this.pendingResultSet = pendingResultSet;
         this.maxResponseContentLength = maxResponseContentLength;
-        this.readerExecutor = new ThreadPoolExecutor(0, 1, 60L, 
TimeUnit.SECONDS,
+        this.readerExecutor = new ThreadPoolExecutor(0, 1, 30L, 
TimeUnit.SECONDS,
                 new LinkedBlockingQueue<>(),
                 new BasicThreadFactory.Builder().namingPattern(
                         "gremlin-driver-stream-reader-" + 
UUID.randomUUID().toString().substring(0, 8)).build());
@@ -179,9 +179,9 @@ public class HttpStreamingResponseHandler extends 
MessageToMessageDecoder<HttpOb
             queueInputStream.signalEndOfStream();
         }
         releaseErrorBody();
-        // shutdownNow() interrupts the reader thread if it's blocked waiting 
for data,
-        // ensuring it doesn't linger after the connection is gone.
-        readerExecutor.shutdownNow();
+        // The reader thread terminates naturally after consuming 
END_OF_STREAM.
+        // The executor's idle timeout reclaims the thread. We intentionally 
avoid
+        // shutdownNow() because the interrupt races with the reader's EOF 
handling.
         super.channelInactive(ctx);
     }
 

Reply via email to