Ngone51 commented on a change in pull request #33812:
URL: https://github.com/apache/spark/pull/33812#discussion_r694423960
##########
File path: core/src/main/scala/org/apache/spark/status/LiveEntity.scala
##########
@@ -553,7 +553,7 @@ private class LiveRDDDistribution(exec: LiveExecutor) {
def toApi(): v1.RDDDataDistribution = {
if (lastUpdate == null) {
lastUpdate = new v1.RDDDataDistribution(
- weakIntern(exec.hostPort),
+ weakIntern(if (exec.hostPort != null) exec.hostPort else exec.host),
Review comment:
@tgravescs `exec.hostPort` or `exec.host` will be only called when
there's a corresponding `LiveExecutor`. And `LiveExecutor` is added either by
`onExecutorAdded` or `onBlockManagerAdded`, and `onExecutorAdded` set the
`host` and `onBlockManagerAdded` set the `hostPort`. So, `host` and `hostPort`
can't be `null` at the same time.
--
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]