jojochuang commented on code in PR #8816:
URL: https://github.com/apache/hadoop/pull/8816#discussion_r4255616436
##########
hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/crypto/key/kms/KMSClientProvider.java:
##########
@@ -130,6 +132,21 @@ public class KMSClientProvider extends KeyProvider
implements CryptoExtension,
+ "authentication.retry-count";
public static final int DEFAULT_AUTH_RETRY = 1;
+ /* Whether to fully consume a response body before closing it, so that the
+ * JDK can return the connection to its keep-alive cache. For a chunked
+ * response the terminating chunk is framing that the JSON parser never
+ * reads, and the JDK's non-blocking fallback cannot always recover it, so
+ * the socket is otherwise torn down and the next call pays for a fresh
+ * connection and TLS handshake.
+ * <p/>
+ * Off by default: the drain blocks until the remaining bytes arrive (bounded
+ * by the read timeout), so a server that stops writing after the payload
+ * would make a call wait where it previously returned at once.
+ */
+ public static final String DRAIN_RESPONSE_UNREAD_BYTES =
CONFIG_PREFIX
+ + "drain.response.unread.bytes";
+ public static final boolean DEFAULT_DRAIN_RESPONSE_UNREAD_BYTES = false;
Review Comment:
let's make it true by default, because we'll rely on this new behavior into
the future.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]