mridulm commented on code in PR #43238:
URL: https://github.com/apache/spark/pull/43238#discussion_r1357425365
##########
core/src/main/scala/org/apache/spark/SecurityManager.scala:
##########
@@ -269,9 +276,24 @@ private[spark] class SecurityManager(
* @return Whether to enable encryption when connecting to services that
support it.
*/
def isEncryptionEnabled(): Boolean = {
- sparkConf.get(Network.NETWORK_CRYPTO_ENABLED) ||
sparkConf.get(SASL_ENCRYPTION_ENABLED)
+ if (sparkConf.get(Network.NETWORK_CRYPTO_ENABLED) ||
sparkConf.get(SASL_ENCRYPTION_ENABLED)) {
+ if (rpcSSLOptions.enabled) {
+ logWarning("Network encryption disabled as RPC SSL encryption is
enabled")
+ false
+ } else {
+ true
+ }
+ } else {
+ false
+ }
Review Comment:
nit:
```suggestion
val encryptionEnabled = sparkConf.get(Network.NETWORK_CRYPTO_ENABLED) ||
sparkConf.get(SASL_ENCRYPTION_ENABLED)
if (encryptionEnabled && rpcSSLOptions.enabled) {
logWarning("Network encryption disabled as RPC SSL encryption is
enabled")
false
} else
encryptionEnabled
}
```
##########
core/src/main/scala/org/apache/spark/network/netty/SparkTransportConf.scala:
##########
@@ -31,19 +31,21 @@ object SparkTransportConf {
/**
* Utility for creating a [[TransportConf]] from a [[SparkConf]].
- * @param _conf the [[SparkConf]]
- * @param module the module name
+ * @param _conf the [[SparkConf]]
+ * @param module the module name
* @param numUsableCores if nonzero, this will restrict the server and
client threads to only
* use the given number of cores, rather than all of
the machine's cores.
* This restriction will only occur if these
properties are not already set.
* @param role optional role, could be driver, executor, worker
and master. Default is
- * [[None]], means no role specific configurations.
+ * [[None]], means no role specific configurations.
+ * @param sslOptions SSL config options
Review Comment:
nit: Remove white space changes ?
--
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]