You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@mesos.apache.org by "Yan Xu (JIRA)" <ji...@apache.org> on 2015/09/24 20:33:06 UTC

[jira] [Commented] (MESOS-3511) Generalize fetcher to handle container image fetching

    [ https://issues.apache.org/jira/browse/MESOS-3511?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14906796#comment-14906796 ] 

Yan Xu commented on MESOS-3511:
-------------------------------

How does this sound? [~idownes] [~bernd-mesos]

> Generalize fetcher to handle container image fetching
> -----------------------------------------------------
>
>                 Key: MESOS-3511
>                 URL: https://issues.apache.org/jira/browse/MESOS-3511
>             Project: Mesos
>          Issue Type: Task
>          Components: containerization
>            Reporter: Yan Xu
>
> Currently the fetcher is designed specifically for fetching the executor. Through some parameter hacking like below we can make it work for the provisioner code.
> {noformat:title=}
>   // Use the random staging name for the containerId
>   ContainerID containerId;
>   containerId.set_value(os::basename(stage).get());
>   // Disable caching because this is effectively done by the store.
>   CommandInfo::URI uri_;
>   uri_.set_value(uri);
>   uri_.set_extract(false);
>   uri_.set_cache(false);
>   CommandInfo commandInfo;
>   commandInfo.add_uris()->CopyFrom(uri_);
>   // The slaveId is only used for caching, which we disable, so just
>   // use "store" for it.
>   SlaveID slaveId;
>   slaveId.set_value("store");
>   return fetcher->fetch(
>         containerId,
>         commandInfo,
>         stage,
>         None(),
>         slaveId,
>         flags)
>   ...  
> {noformat}
> It would be great if we don't have to do this. We can add another fetcher method for image fetching.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)