vicennial commented on code in PR #39361:
URL: https://github.com/apache/spark/pull/39361#discussion_r1061305904


##########
connector/connect/server/src/main/scala/org/apache/spark/sql/connect/config/Connect.scala:
##########
@@ -18,14 +18,15 @@ package org.apache.spark.sql.connect.config
 
 import org.apache.spark.internal.config.ConfigBuilder
 import org.apache.spark.network.util.ByteUnit
+import org.apache.spark.sql.connect.common.config.ConnectCommon
 
 private[spark] object Connect {
 
   val CONNECT_GRPC_BINDING_PORT =
     ConfigBuilder("spark.connect.grpc.binding.port")
       .version("3.4.0")
       .intConf
-      .createWithDefault(15002)
+      .createWithDefault(ConnectCommon.CONNECT_GRPC_BINDING_PORT)

Review Comment:
   `ConfigBuilder` is part of spark core so we're unable to use it in 
common/client without the extra dep (unless we pull out the whole of 
`org.apache.spark.internal.config`). 
   
   Seeing that the user can build the client on the go with complete 
customizability of host/port, it lets us get away without needing full support 
of configs via environment variables/config files in this case since:
   - In a REPL environment, a new instance of the client can be made with an 
updated host/port. 
   - In the case of applications, the client is supposed to be lightweight and 
minimal and hence rebuilding the package should be a trivial step.
   
   WDYT?  



-- 
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]

Reply via email to