You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hc.apache.org by ol...@apache.org on 2018/10/09 12:33:23 UTC

[4/4] httpcomponents-core git commit: Performance optimization: I/O sessions to trigger output event as early as there is interest in output

Performance optimization: I/O sessions to trigger output event as early as there is interest in output


Project: http://git-wip-us.apache.org/repos/asf/httpcomponents-core/repo
Commit: http://git-wip-us.apache.org/repos/asf/httpcomponents-core/commit/f3094546
Tree: http://git-wip-us.apache.org/repos/asf/httpcomponents-core/tree/f3094546
Diff: http://git-wip-us.apache.org/repos/asf/httpcomponents-core/diff/f3094546

Branch: refs/heads/master
Commit: f30945466dff55fb4870d883d3657f8c713ff02e
Parents: a915f30
Author: Oleg Kalnichevski <ol...@apache.org>
Authored: Tue Oct 9 13:26:53 2018 +0200
Committer: Oleg Kalnichevski <ol...@apache.org>
Committed: Tue Oct 9 14:30:22 2018 +0200

----------------------------------------------------------------------
 .../java/org/apache/hc/core5/reactor/InternalDataChannel.java     | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/httpcomponents-core/blob/f3094546/httpcore5/src/main/java/org/apache/hc/core5/reactor/InternalDataChannel.java
----------------------------------------------------------------------
diff --git a/httpcore5/src/main/java/org/apache/hc/core5/reactor/InternalDataChannel.java b/httpcore5/src/main/java/org/apache/hc/core5/reactor/InternalDataChannel.java
index d654003..1e8f5b7 100644
--- a/httpcore5/src/main/java/org/apache/hc/core5/reactor/InternalDataChannel.java
+++ b/httpcore5/src/main/java/org/apache/hc/core5/reactor/InternalDataChannel.java
@@ -128,7 +128,8 @@ final class InternalDataChannel extends InternalChannel implements ProtocolIOSes
                     }
                 } while (tlsSession.getReadCount() > 0);
             }
-            if ((readyOps & SelectionKey.OP_WRITE) != 0) {
+            if ((readyOps & SelectionKey.OP_WRITE) != 0
+                    || (ioSession.getEventMask() & SelectionKey.OP_WRITE) != 0) {
                 ioSession.updateWriteTime();
                 if (tlsSession.isAppOutputReady()) {
                     if (sessionListener != null) {