-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/57190/#review167297
-----------------------------------------------------------




src/tests/role_tests.cpp
Lines 812 (patched)
<https://reviews.apache.org/r/57190/#comment239673>

    This might be better placed in `persistent_volume_tests.cpp`.



src/tests/role_tests.cpp
Lines 832 (patched)
<https://reviews.apache.org/r/57190/#comment239680>

    "Helper function that starts a framework in a role and creates a persistent 
volume with the given id."



src/tests/role_tests.cpp
Lines 833 (patched)
<https://reviews.apache.org/r/57190/#comment239681>

    No comma after "volume".



src/tests/role_tests.cpp
Lines 876 (patched)
<https://reviews.apache.org/r/57190/#comment239683>

    "Create a task that uses the volume and checks that the volume does not 
contain any files leaked from any role."



src/tests/role_tests.cpp
Lines 879 (patched)
<https://reviews.apache.org/r/57190/#comment239685>

    Seems like this would be a bit more readable if we split it into two or 
more separate statements. We could pull `offers.get()[0]` out into a separate 
variable, and maybe the filtered resources w/o the disk as well?



src/tests/role_tests.cpp
Lines 887 (patched)
<https://reviews.apache.org/r/57190/#comment239696>

    We can't depend on `ls` and `grep` being available on Windows.
    
    We could write the test with `#ifdef`s, although that seems unfortunate. 
Not sure there's a better alternative, given the current agent volume creation 
logic...



src/tests/role_tests.cpp
Lines 907 (patched)
<https://reviews.apache.org/r/57190/#comment239415>

    Why `ASSERT_EQ` rather than `EXPECT_EQ`?



src/tests/role_tests.cpp
Lines 918 (patched)
<https://reviews.apache.org/r/57190/#comment239414>

    "in that case"



src/tests/role_tests.cpp
Lines 923 (patched)
<https://reviews.apache.org/r/57190/#comment239688>

    Would be a bit more readable to move this function declaration up above the 
`runTask` calls.



src/tests/role_tests.cpp
Lines 937 (patched)
<https://reviews.apache.org/r/57190/#comment239690>

    Do we really need the `v1` prefix to these variable names? Seems 
unnecessary.



src/tests/role_tests.cpp
Lines 957 (patched)
<https://reviews.apache.org/r/57190/#comment239692>

    Capturing `CONTENT_TYPE` seems unnecessary.



src/tests/role_tests.cpp
Lines 967 (patched)
<https://reviews.apache.org/r/57190/#comment239693>

    "Destroy both volumes. Even though the role `a/b/c` is a prefix of the role 
`a/b/c/d`, destroying the former role's volume `d` should not interfere with 
the latter's volume `id`."


- Neil Conway


On March 2, 2017, 5 p.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/57190/
> -----------------------------------------------------------
> 
> (Updated March 2, 2017, 5 p.m.)
> 
> 
> Review request for mesos, Benjamin Mahler, Michael Park, and Neil Conway.
> 
> 
> Bugs: MESOS-7047
>     https://issues.apache.org/jira/browse/MESOS-7047
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> This commit adjusts the way persistent volumes are stored on the
> agent. Instead of interpreting the role of the volume as a literal
> path, we replace `/` with ` ` when creating the path. This prevents
> that subdirectories are created for volumes with hierarchical roles.
> Directly interpreting the role as a path is undesirable as it can lead
> to volumes overlapping (e.g., a volume with role `a/b/c/d` and id `id`
> would be visible as `id` in a volume with role `a/b/c` and id `d`).
> 
> 
> Diffs
> -----
> 
>   src/slave/paths.cpp 38ad1993aa36a627ec97a7865488677495ee4c5a 
>   src/tests/role_tests.cpp 77f3d46a544a51ba71476e2f0735bb32758dd9e1 
> 
> 
> Diff: https://reviews.apache.org/r/57190/diff/1/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>

Reply via email to