Github user mccheah commented on a diff in the pull request:

    https://github.com/apache/spark/pull/19717#discussion_r155040383
  
    --- Diff: core/src/main/scala/org/apache/spark/util/Utils.scala ---
    @@ -2744,6 +2744,25 @@ private[spark] object Utils extends Logging {
         }
       }
     
    +  /**
    +   * Check the validity of the given Kubernetes master URL and return the 
resolved URL.
    +   */
    +  def checkAndGetK8sMasterUrl(rawMasterURL: String): String = {
    +    require(rawMasterURL.startsWith("k8s://"),
    +      "Kubernetes master URL must start with k8s://.")
    +    val masterWithoutK8sPrefix = rawMasterURL.substring("k8s://".length)
    --- End diff --
    
    All of the following should be supported and resolved as follows:
    
    - `k8s://host:port` -> `https://host:port`
    - `k8s://https://host:port` -> `https://host:port`
    - `k8s://http://host:port` -> `http://host:port`
    
    Think we just need to use whatever code that is necessary to get to this 
state.


---

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to