munendrasn commented on code in PR #11979:
URL: https://github.com/apache/iceberg/pull/11979#discussion_r1958273011
##########
core/src/main/java/org/apache/iceberg/rest/HTTPClient.java:
##########
@@ -374,13 +375,17 @@ static HttpRequestInterceptor loadInterceptorDynamically(
return instance;
}
- static HttpClientConnectionManager configureConnectionManager(Map<String,
String> properties) {
+ static HttpClientConnectionManager configureConnectionManager(
+ Map<String, String> properties, TlsSocketStrategy tlsSocketStrategy) {
PoolingHttpClientConnectionManagerBuilder connectionManagerBuilder =
PoolingHttpClientConnectionManagerBuilder.create();
ConnectionConfig connectionConfig = configureConnectionConfig(properties);
if (connectionConfig != null) {
connectionManagerBuilder.setDefaultConnectionConfig(connectionConfig);
}
+ if (tlsSocketStrategy != null) {
+ connectionManagerBuilder.setTlsSocketStrategy(tlsSocketStrategy);
Review Comment:
@nastra
The idea was similar to how
[httpProxy](https://github.com/apache/iceberg/blob/f9b9621e77ef44d4e5fd72bf6014e3037514ba98/core/src/main/java/org/apache/iceberg/rest/HTTPClient.java#L455-L461)
is supported. HttpProxy can be configured via system properties (note: it is
not configurable via properties map) or via explicitly specifying host and port
where applicable (might not be possible in case of spark). Same in case of
`ProxyCredentialProvider` too
Similarly, here, I'm adding an additional way to configure tlsSocketStrategy
where more granular control is required like custom keystore to construct
sslContext and so on.
--
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]