Github user andrewor14 commented on a diff in the pull request:

    https://github.com/apache/spark/pull/8872#discussion_r51480776
  
    --- Diff: 
core/src/main/scala/org/apache/spark/scheduler/cluster/mesos/MesosClusterScheduler.scala
 ---
    @@ -497,28 +505,28 @@ private[spark] class MesosClusterScheduler(
                 container, image, volumes = volumes, portmaps = portmaps)
               taskInfo.setContainer(container.build())
             }
    -        val queuedTasks = tasks.getOrElseUpdate(offer.offer.getId, new 
ArrayBuffer[TaskInfo])
    +        val queuedTasks = tasks.getOrElseUpdate(offer.offerId, new 
ArrayBuffer[TaskInfo])
             queuedTasks += taskInfo.build()
    -        logTrace(s"Using offer ${offer.offer.getId.getValue} to launch 
driver " +
    +        logTrace(s"Using offer ${offer.offerId.getValue} to launch driver 
" +
               submission.submissionId)
    -        val newState = new MesosClusterSubmissionState(submission, taskId, 
offer.offer.getSlaveId,
    +        val newState = new MesosClusterSubmissionState(submission, taskId, 
offer.slaveId,
               None, new Date(), None)
             launchedDrivers(submission.submissionId) = newState
             launchedDriversState.persist(submission.submissionId, newState)
             afterLaunchCallback(submission.submissionId)
           }
         }
    +    currentOffers
    --- End diff --
    
    @tnachen I also don't get it. If the caller called us with `currentOffers`, 
they already have access to it, so what's the point in returning them here? 
AFAIK we don't mutate this list in this method


---
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 [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to