You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@mesos.apache.org by Joris Van Remoortere <jo...@gmail.com> on 2016/01/18 22:23:34 UTC
Review Request 42474: Multiple Disk: Updated Slave initialize to
create DiskInfo paths.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/42474/
-----------------------------------------------------------
Review request for mesos, Jie Yu and Michael Park.
Bugs: MESOS-4403
https://issues.apache.org/jira/browse/MESOS-4403
Repository: mesos
Description
-------
Create disk paths based on 'DiskInfo.Source' if the type is 'PATH'
and the directory does not yet exist.
Diffs
-----
src/slave/slave.cpp bb501810d7bb1261ebbbdd147c49948e5a2f8665
Diff: https://reviews.apache.org/r/42474/diff/
Testing
-------
make check
Thanks,
Joris Van Remoortere
Re: Review Request 42474: Multiple Disk: Updated Slave initialize to
create DiskInfo paths.
Posted by Mesos ReviewBot <re...@mesos.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/42474/#review115064
-----------------------------------------------------------
Patch looks great!
Reviews applied: [42470, 42471, 42472, 42473, 42474]
Passed command: export OS=ubuntu:14.04;export CONFIGURATION="--verbose";export COMPILER=gcc; ./support/docker_build.sh
- Mesos ReviewBot
On Jan. 18, 2016, 9:23 p.m., Joris Van Remoortere wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/42474/
> -----------------------------------------------------------
>
> (Updated Jan. 18, 2016, 9:23 p.m.)
>
>
> Review request for mesos, Jie Yu and Michael Park.
>
>
> Bugs: MESOS-4403
> https://issues.apache.org/jira/browse/MESOS-4403
>
>
> Repository: mesos
>
>
> Description
> -------
>
> Create disk paths based on 'DiskInfo.Source' if the type is 'PATH'
> and the directory does not yet exist.
>
>
> Diffs
> -----
>
> src/slave/slave.cpp bb501810d7bb1261ebbbdd147c49948e5a2f8665
>
> Diff: https://reviews.apache.org/r/42474/diff/
>
>
> Testing
> -------
>
> make check
>
>
> Thanks,
>
> Joris Van Remoortere
>
>
Re: Review Request 42474: Multiple Disk: Updated Slave initialize to
create DiskInfo paths.
Posted by Jie Yu <yu...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/42474/#review115472
-----------------------------------------------------------
Ship it!
src/slave/slave.cpp (lines 369 - 372)
<https://reviews.apache.org/r/42474/#comment176449>
You may want to print the error message here (will be useful for triaging).
```
Try<Nothing> mkdir = os::mkdir(...);
if (mkdir.isError()) {
EXIT(1) << "...: " << mkdir.error();
}
```
- Jie Yu
On Jan. 20, 2016, 7:15 p.m., Joris Van Remoortere wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/42474/
> -----------------------------------------------------------
>
> (Updated Jan. 20, 2016, 7:15 p.m.)
>
>
> Review request for mesos, Jie Yu and Michael Park.
>
>
> Bugs: MESOS-4403
> https://issues.apache.org/jira/browse/MESOS-4403
>
>
> Repository: mesos
>
>
> Description
> -------
>
> Create disk paths based on 'DiskInfo.Source' if the type is 'PATH'
> and the directory does not yet exist.
>
>
> Diffs
> -----
>
> src/slave/slave.cpp bd7fe03f8a8b07c6201db2f876f4f9cd7dc337cf
>
> Diff: https://reviews.apache.org/r/42474/diff/
>
>
> Testing
> -------
>
> make check
>
>
> Thanks,
>
> Joris Van Remoortere
>
>
Re: Review Request 42474: Multiple Disk: Updated Slave initialize to
create DiskInfo paths.
Posted by Jie Yu <yu...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/42474/#review115876
-----------------------------------------------------------
Ship it!
src/slave/slave.cpp (line 364)
<https://reviews.apache.org/r/42474/#comment176936>
I would still prefer to capture the reference 'const Resource::DiskInfo::Source& source' first to avoid calling `resource.disk().source()` all the time:
```
const Resource::DiskInfo::Source& source = resource.disk.source();
if (source.type() == PATH) {
CHECK(source.has_path());
Try<Nothing> mkdir = os::mkdir(source.path().root());
...
}
```
src/slave/slave.cpp (lines 365 - 368)
<https://reviews.apache.org/r/42474/#comment176935>
We should validate the Resources (i.e., call `Resources::validate` in `Containerizer::resources(flag)`), and this should a CHECK instead.
Also, can you add a TODO to move `internal::validateCommandLineResources(result);` in Resources::parse to top level (e.g., in `Containerizer::resources`). I don't think that function belongs to the parse function.
- Jie Yu
On Jan. 22, 2016, 9:30 a.m., Joris Van Remoortere wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/42474/
> -----------------------------------------------------------
>
> (Updated Jan. 22, 2016, 9:30 a.m.)
>
>
> Review request for mesos, Jie Yu and Michael Park.
>
>
> Bugs: MESOS-4403
> https://issues.apache.org/jira/browse/MESOS-4403
>
>
> Repository: mesos
>
>
> Description
> -------
>
> Create disk paths based on 'DiskInfo.Source' if the type is 'PATH'
> and the directory does not yet exist.
>
>
> Diffs
> -----
>
> src/slave/slave.cpp e23c3295c8ebed580751a5aabaf26e1773c54859
>
> Diff: https://reviews.apache.org/r/42474/diff/
>
>
> Testing
> -------
>
> make check
>
>
> Thanks,
>
> Joris Van Remoortere
>
>
Re: Review Request 42474: Multiple Disk: Updated Slave initialize to
create DiskInfo paths.
Posted by Jie Yu <yu...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/42474/#review115988
-----------------------------------------------------------
Ship it!
Ship It!
- Jie Yu
On Jan. 23, 2016, 10:51 a.m., Joris Van Remoortere wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/42474/
> -----------------------------------------------------------
>
> (Updated Jan. 23, 2016, 10:51 a.m.)
>
>
> Review request for mesos, Jie Yu and Michael Park.
>
>
> Bugs: MESOS-4403
> https://issues.apache.org/jira/browse/MESOS-4403
>
>
> Repository: mesos
>
>
> Description
> -------
>
> Create disk paths based on 'DiskInfo.Source' if the type is 'PATH'
> and the directory does not yet exist.
>
>
> Diffs
> -----
>
> src/slave/containerizer/containerizer.cpp 5e7e55e2dd4e451bb754a6a888e9683760d95873
> src/slave/slave.cpp 1bd973a9cf4d8b922db9bd2f3df93bad7cc743bb
> src/v1/resources.cpp 8de6672ba9b34947db81c74b8e03e8965e8af5fc
>
> Diff: https://reviews.apache.org/r/42474/diff/
>
>
> Testing
> -------
>
> make check
>
>
> Thanks,
>
> Joris Van Remoortere
>
>
Re: Review Request 42474: Multiple Disk: Updated Slave initialize to
create DiskInfo paths.
Posted by Joris Van Remoortere <jo...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/42474/
-----------------------------------------------------------
(Updated Jan. 23, 2016, 10:51 a.m.)
Review request for mesos, Jie Yu and Michael Park.
Bugs: MESOS-4403
https://issues.apache.org/jira/browse/MESOS-4403
Repository: mesos
Description
-------
Create disk paths based on 'DiskInfo.Source' if the type is 'PATH'
and the directory does not yet exist.
Diffs (updated)
-----
src/slave/containerizer/containerizer.cpp 5e7e55e2dd4e451bb754a6a888e9683760d95873
src/slave/slave.cpp 1bd973a9cf4d8b922db9bd2f3df93bad7cc743bb
src/v1/resources.cpp 8de6672ba9b34947db81c74b8e03e8965e8af5fc
Diff: https://reviews.apache.org/r/42474/diff/
Testing
-------
make check
Thanks,
Joris Van Remoortere
Re: Review Request 42474: Multiple Disk: Updated Slave initialize to
create DiskInfo paths.
Posted by Joris Van Remoortere <jo...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/42474/
-----------------------------------------------------------
(Updated Jan. 22, 2016, 9:30 a.m.)
Review request for mesos, Jie Yu and Michael Park.
Changes
-------
Added comment regarding `realpath` for `MOUNT` root.
Bugs: MESOS-4403
https://issues.apache.org/jira/browse/MESOS-4403
Repository: mesos
Description (updated)
-------
Create disk paths based on 'DiskInfo.Source' if the type is 'PATH'
and the directory does not yet exist.
Diffs (updated)
-----
src/slave/slave.cpp e23c3295c8ebed580751a5aabaf26e1773c54859
Diff: https://reviews.apache.org/r/42474/diff/
Testing
-------
make check
Thanks,
Joris Van Remoortere
Re: Review Request 42474: Multiple Disk: Updated Slave initialize to
create DiskInfo paths.
Posted by Joris Van Remoortere <jo...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/42474/
-----------------------------------------------------------
(Updated Jan. 21, 2016, 7:38 a.m.)
Review request for mesos, Jie Yu and Michael Park.
Changes
-------
Added support for `Mount` type, and validation against the `/proc/mounts` table.
Bugs: MESOS-4403
https://issues.apache.org/jira/browse/MESOS-4403
Repository: mesos
Description (updated)
-------
Create disk paths based on 'DiskInfo.Source' if the type is 'PATH'
and the directory does not yet exist.
Validate 'MOUNT' sources against the /proc/mounts table in linux.
Diffs (updated)
-----
src/slave/slave.cpp bd7fe03f8a8b07c6201db2f876f4f9cd7dc337cf
Diff: https://reviews.apache.org/r/42474/diff/
Testing
-------
make check
Thanks,
Joris Van Remoortere
Re: Review Request 42474: Multiple Disk: Updated Slave initialize to
create DiskInfo paths.
Posted by Joris Van Remoortere <jo...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/42474/
-----------------------------------------------------------
(Updated Jan. 20, 2016, 7:15 p.m.)
Review request for mesos, Jie Yu and Michael Park.
Bugs: MESOS-4403
https://issues.apache.org/jira/browse/MESOS-4403
Repository: mesos
Description
-------
Create disk paths based on 'DiskInfo.Source' if the type is 'PATH'
and the directory does not yet exist.
Diffs (updated)
-----
src/slave/slave.cpp bd7fe03f8a8b07c6201db2f876f4f9cd7dc337cf
Diff: https://reviews.apache.org/r/42474/diff/
Testing
-------
make check
Thanks,
Joris Van Remoortere
Re: Review Request 42474: Multiple Disk: Updated Slave initialize to
create DiskInfo paths.
Posted by Jie Yu <yu...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/42474/#review115268
-----------------------------------------------------------
src/slave/slave.cpp (line 360)
<https://reviews.apache.org/r/42474/#comment176223>
you can do `resources->filter(...)`
src/slave/slave.cpp (lines 364 - 365)
<https://reviews.apache.org/r/42474/#comment176220>
Can we use EXIT(1) instead of CHECK here so that it's less confusing to operators.
- Jie Yu
On Jan. 18, 2016, 9:23 p.m., Joris Van Remoortere wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/42474/
> -----------------------------------------------------------
>
> (Updated Jan. 18, 2016, 9:23 p.m.)
>
>
> Review request for mesos, Jie Yu and Michael Park.
>
>
> Bugs: MESOS-4403
> https://issues.apache.org/jira/browse/MESOS-4403
>
>
> Repository: mesos
>
>
> Description
> -------
>
> Create disk paths based on 'DiskInfo.Source' if the type is 'PATH'
> and the directory does not yet exist.
>
>
> Diffs
> -----
>
> src/slave/slave.cpp bb501810d7bb1261ebbbdd147c49948e5a2f8665
>
> Diff: https://reviews.apache.org/r/42474/diff/
>
>
> Testing
> -------
>
> make check
>
>
> Thanks,
>
> Joris Van Remoortere
>
>