Github user jiangxb1987 commented on a diff in the pull request:
https://github.com/apache/spark/pull/20802#discussion_r174032702
--- Diff: core/src/main/scala/org/apache/spark/util/Utils.scala ---
@@ -975,6 +975,8 @@ private[spark] object Utils extends Logging {
def checkHost(host: String) {
assert(host != null && host.indexOf(':') == -1, s"Expected hostname
(not IP) but got $host")
+ assert(host.matches("^[a-zA-Z0-9-.]+$"),
--- End diff --
I don't feel this is the right place to do the check, if you really like a
detailed error message then you shall produce that in
`RpcEndpointAddress.apply(sparkUrl: String)`, but I don't think that shall add
much value for users either.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]