Uh oh!
There was an error while loading. Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork 29.4k
[SPARK-14849][CORE]Always set an address for the executor#12613
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
Uh oh!
There was an error while loading. Please reload this page.
Changes from all commits
File filter
Filter by extension
Conversations
Uh oh!
There was an error while loading. Please reload this page.
Jump to
Uh oh!
There was an error while loading. Please reload this page.
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -120,9 +120,15 @@ private[netty] class NettyRpcEnv( | ||
| RpcEndpointVerifier.NAME, new RpcEndpointVerifier(this, dispatcher)) | ||
| } | ||
| @Nullable | ||
| override lazy val address: RpcAddress = { | ||
| if (server != null) RpcAddress(host, server.getPort()) else null | ||
| // When running in client mode (i.e.: not opening a listening port, but connecting to a | ||
| // 'server' with an open port), the server value is null. | ||
| // But a valid host still has to be provided, as it is needed later on. | ||
| // Previously, the server side of the connection was attempting to guess the client | ||
| // hostname, using the connection information. But the value generated is wrong when | ||
| // the connection is NATed. | ||
| // [SPARK-14849] | ||
| if (server != null) RpcAddress(host, server.getPort()) else RpcAddress(host, -1) | ||
Member There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
| ||
| } | ||
| override def setupEndpoint(name: String, endpoint: RpcEndpoint): RpcEndpointRef = { | ||
| @@ -152,8 +158,8 @@ private[netty] class NettyRpcEnv( | ||
| if (receiver.client != null) { | ||
| message.sendWith(receiver.client) | ||
| } else { | ||
| require(receiver.address != null, | ||
| "Cannot send message to client endpoint with no listen address.") | ||
| require(receiver.address.port != -1, | ||
| "Cannot send message to client endpoint with no listen port.") | ||
| val targetOutbox = { | ||
| val outbox = outboxes.get(receiver.address) | ||
| if (outbox == null) { | ||
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.
while you are at it, we should probably document when server is null and explain the choices here