ok2c commented on a change in pull request #149: HTTPCORE-601 URL: https://github.com/apache/httpcomponents-core/pull/149#discussion_r324680248
########## File path: httpcore5/src/main/java/org/apache/hc/core5/reactor/ssl/SSLIOSession.java ########## @@ -345,6 +347,13 @@ private void updateEventMask() { } if (this.status == CLOSING && !this.outEncrypted.hasData()) { this.sslEngine.closeOutbound(); + final int n = this.outboundClosedCount.incrementAndGet(); + // This is to avoid an infinite session spin in case + // SSLEngine#closeOutbound() fails to trigger a graceful + // session shutdown + if (n > 5) { Review comment: @michael-o What good would that make? This value is not supposed to be reused anywhere, so I see little value in externalizing it. What I can do is mention in the comment that 5 is completely arbitrary. ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org For additional commands, e-mail: dev-h...@hc.apache.org