spark-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pwendell <>
Subject [GitHub] spark pull request: [SPARK-4857] [CORE] Adds Executor membership e...
Date Thu, 08 Jan 2015 20:37:57 GMT
Github user pwendell commented on a diff in the pull request:
    --- Diff: core/src/main/scala/org/apache/spark/scheduler/cluster/mesos/MesosSchedulerBackend.scala
    @@ -344,12 +354,20 @@ private[spark] class MesosSchedulerBackend(
       override def frameworkMessage(d: SchedulerDriver, e: ExecutorID, s: SlaveID, b: Array[Byte])
    +  /**
    +   * Remove executor associated with slaveId in a thread safe manner.
    +   */
    +  private def removeExecutor(slaveId: String) = {
    +    synchronized {
    --- End diff --
    Can you explain a bit what this synchronization is trying to protect? I did a small audit
of this class and I found the synchronization is a bit all over the place. For instance we
don't seem to hold any locks when adding to `slaveIdsWithExecutors` but we do hold a lock
when removing from it. Seems a bit odd.

If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at or file a JIRA ticket
with INFRA.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message