[
https://issues.apache.org/jira/browse/MESOS-922?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13890222#comment-13890222
]
Ian Downes commented on MESOS-922:
----------------------------------
I could see the following initial changes to address the two dependencies:
Containerizer::launch() takes the TaskInfo and returns a Future<ExecutorInfo>,
extracted from the TaskInfo if present or generated in the same way as is
currently done in the slave. This gets satisfied when the executor has been
started (exec'ed).
We require the ExecutorID in the returned ExecutorInfo to be the same as the
TaskID when no ExecutorInfo is present. This requirement means we don't need
the full ExecutorInfo for runTask() to do preparation, just the ExecutorID
which the slave can get from the TaskInfo. _runTask() is then split in the
middle around where the framework->getExecutor() currently is and continues
with new __runTask() to actually send the task to the (now) running executor.
This completely pushes (aside from the ExecutorID requirement) the
determination of the executor to the containerizer.
> Containerizer to support launching tasks by TaskInfo
> ----------------------------------------------------
>
> Key: MESOS-922
> URL: https://issues.apache.org/jira/browse/MESOS-922
> Project: Mesos
> Issue Type: Improvement
> Components: isolation
> Reporter: Ian Downes
> Fix For: 0.18.0
>
>
> Currently the slave runs tasks by using an existing executor or by launching
> a new executor. When a task's TaskInfo doesn't specify the executor with an
> ExecutorInfo (has a CommandInfo instead) the slave will create an
> ExecutorInfo specifying the mesos-command executor.
> The decision on how to launch a task could instead be delegated to the
> containerizer and the TaskInfo would be passed unmodifed. This would have the
> following advantages:
> 1) The containerizer can decide on the executor to run the task, either the
> mesos-executor or a specialized executor appropriate for the containerization
> implementation. Furthermore, the containerizer can allocate appropriate
> additional resources for the executor.
> 2) The containerizer can see the task's resources and can allocate these when
> the executor is launched. This is useful for such containerizer
> implementations as KVM where it is harder to dynamically adjust a
> containerized executor's resources. This is most applicable when the executor
> will only run a single task.
--
This message was sent by Atlassian JIRA
(v6.1.5#6160)