-
Notifications
You must be signed in to change notification settings - Fork 29k
[SPARK-32103][CORE] Support IPv6 host/port in core module #28931
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[SPARK-32103][CORE] Support IPv6 host/port in core module #28931
Conversation
|
ok to test |
| val prefix = WebAppUtils.getHttpSchemePrefix(conf) | ||
| val proxies = WebAppUtils.getProxyHostsAndPortsForAmFilter(conf) | ||
| val hosts = proxies.asScala.map(_.split(":").head) | ||
| val hosts = proxies.asScala.map(proxy => proxy.splitAt(proxy.lastIndexOf(":"))._1) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi, @PavithraRamachandran . If possible, could you check the code base if this is the last instance or not?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have identified few more places where IPV6 is not handled, i shall update my PR soon
|
Test build #124558 has finished for PR 28931 at commit
|
dongjoon-hyun
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In general, new implementation seems to introduce a new assumption and less robust as a result. For example, when we get host name only without port due to YARN API change, it will fail. It may be unlikely, but we had better keep the robustness here if there is no other reason @PavithraRamachandran .
scala> val proxies = Seq("host")
proxies: Seq[String] = List(host)
scala> proxies.map(_.split(":").head)
res16: Seq[String] = List(host)
scala> proxies.map(proxy => proxy.splitAt(proxy.lastIndexOf(":"))._1)
res17: Seq[String] = List("")
|
Gentle ping, @PavithraRamachandran . |
|
@dongjoon-hyun thank you for identifying the missed scenario, i shall handle it and update the PR |
3e2eb3a to
98a737b
Compare
98a737b to
becec4e
Compare
|
Test build #124919 has finished for PR 28931 at commit
|
|
Test build #124920 has finished for PR 28931 at commit
|
|
Retest this please. |
|
@dongjoon-hyun i am getting 502 proxy error when i try to access the CI to check for failures. Could u help me? |
|
GitHub Action CI is okay, but UCB AmbLab Jenkins CI seems to be completely down now. In this case, there is no way for us to do. Let's wait for a while. |
|
Test build #124942 has finished for PR 28931 at commit
|
becec4e to
4c9cb2e
Compare
|
Thank you for updating, @PavithraRamachandran . |
|
Retest this please |
|
cc @dbtsai |
| Utils.checkHost("0.0.0.0") | ||
| intercept[AssertionError] { | ||
| Utils.checkHost("0.0.0.0:0") | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In this case, it would be great if we check the error message to prevent future regression.
| assert(Utils.buildLocationMetadata(paths, 25) == "[path0, path1, path2, path3]") | ||
| } | ||
|
|
||
| test("checkHosts support IPV6 and IPV4") { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
checkHosts->checkHostsupport->supportsIPV6 and IPV4->both IPv4 and IPv6?
| assert(hostnamePort._1.equals("0.0.0.0")) | ||
| assert(hostnamePort._2 === 0) | ||
|
|
||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit. repeated blank lines.
|
Test build #125379 has finished for PR 28931 at commit
|
…reaks the logic when we use ipv6 deployment
4c9cb2e to
768e7c4
Compare
|
Test build #125609 has finished for PR 28931 at commit
|
dongjoon-hyun
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1, LGTM. Thank you, @PavithraRamachandran .
Merged to master for Apache Spark 3.1.0. Definitely, this is a good step toward IPv6 support.
|
thank u for merging @dongjoon-hyun |
|
Is it the only blocker for IPV6 support? |
|
Hi, @gatorsmile . Technically, this only handles |
### What changes were proposed in this pull request? In IPv6 scenario, the current logic to split hostname and port is not correct. ### Why are the changes needed? to support IPV6 deployment scenario ### Does this PR introduce _any_ user-facing change? No ### How was this patch tested? UT and IPV6 spark deployment with yarn Closes #28931 from PavithraRamachandran/ipv6_issue. Authored-by: Pavithraramachandran <[email protected]> Signed-off-by: Dongjoon Hyun <[email protected]>
What changes were proposed in this pull request?
In IPv6 scenario, the current logic to split hostname and port is not correct.
Why are the changes needed?
to support IPV6 deployment scenario
Does this PR introduce any user-facing change?
No
How was this patch tested?
UT and IPV6 spark deployment with yarn