Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
2.2.0
-
None
Description
In CoarseGrainedSchedulerBackend.RegisterExecutor the executor data address (executorRef.address) can be null.
val data = new ExecutorData(executorRef, executorRef.address, hostname,
cores, cores, logUrls)
At this point the executorRef.address can be null, there is actually code above it that handles this case:
// If the executor's rpc env is not listening for incoming connections, `hostPort`
// will be null, and the client connection should be used to contact the executor.
val executorAddress = if (executorRef.address != null)
else
{ context.senderAddress }But it doesn't use executorAddress when it creates the ExecutorData.
This causes removeExecutor to never remove it properly from addressToExecutorId.
addressToExecutorId -= executorInfo.executorAddress
This is also a memory leak and can also call onDisconnected to call disableExecutor when it shouldn't.