Re: Review Request 52972: Replaced POSIX `int` with `int_fd` abstraction in `stout` folder.

2016-11-29 Thread Daniel Pravat

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

(Updated Nov. 30, 2016, 7:55 a.m.)


Review request for mesos, Alex Naparu, Artem Harutyunyan, Alex Clemmer, Joseph 
Wu, and Michael Park.


Repository: mesos


Description
---

Replaced POSIX `int` with `int_fd` abstraction in `stout` folder.


Diffs (updated)
-

  3rdparty/stout/include/stout/net.hpp 083b8d1959dcd305d0aa8892082b39cb03786ebf 
  3rdparty/stout/include/stout/os/mktemp.hpp 
2dfd35605eb4202a5475fe0e0d2f1fd27690a2de 
  3rdparty/stout/include/stout/os/open.hpp 
2a357926860b1523c51f12c7edee2babe6afbfa3 
  3rdparty/stout/include/stout/os/read.hpp 
d0b657db5b7dc0c1e11edc13fd6830a9f6273867 
  3rdparty/stout/include/stout/os/socket.hpp 
e9d9306e63aff2be083b4254fbf6f31c37edc424 
  3rdparty/stout/include/stout/os/touch.hpp 
84d49bb8adc2612e380f037fd42c47166d55f593 
  3rdparty/stout/include/stout/os/windows/close.hpp 
9f1566bff19ee872418bce8a43a119c4f0a70a7c 
  3rdparty/stout/include/stout/os/windows/fcntl.hpp 
2bc794a405e59d80c1e8308c0049d2306347adfa 
  3rdparty/stout/include/stout/os/windows/ftruncate.hpp 
a7f53ad2e8735b515590af84c0efce3edcc1bebf 
  3rdparty/stout/include/stout/os/windows/read.hpp 
09190f97f33db5dfa023f937f8f2a4a62ed1ec15 
  3rdparty/stout/include/stout/os/windows/sendfile.hpp 
d6358cc02c1eea9298907da1f74eb7eeaeec7d21 
  3rdparty/stout/include/stout/os/windows/shell.hpp 
17e3d564564abebf1d558b7a7a277aef3c87e5ae 
  3rdparty/stout/include/stout/os/windows/socket.hpp 
1f6551bc30cf31842513df0fed43ee134c620ebd 
  3rdparty/stout/include/stout/os/windows/write.hpp 
23488708ae366b8571bb8b4805f67d2054223fff 
  3rdparty/stout/include/stout/os/write.hpp 
24a69d8f60efd3c2888d464d75164c758b3701a2 
  3rdparty/stout/include/stout/posix/os.hpp 
c37e64db662ba3cee83d2f55de0f9d71ad72c038 
  3rdparty/stout/include/stout/protobuf.hpp 
80cb20f40a7ddd4309d27973eef9fca9e4052b64 
  3rdparty/stout/include/stout/windows/os.hpp 
de9b04ad82443038a0f4408bc72cae1540a1beaf 
  3rdparty/stout/tests/os/filesystem_tests.cpp 
22460842c0db5dc5b6effbc2bdfce043ed47db6d 
  3rdparty/stout/tests/os_tests.cpp ad23ec00de7770a5024c084627b0ff1e4cc2a439 

Diff: https://reviews.apache.org/r/52972/diff/


Testing
---


Thanks,

Daniel Pravat



Re: Review Request 52544: Introduced `int_fd` class.

2016-11-29 Thread Daniel Pravat

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

(Updated Nov. 30, 2016, 7:54 a.m.)


Review request for mesos, Alex Naparu, Alex Clemmer, Joseph Wu, and Michael 
Park.


Repository: mesos


Description
---

In POSIX the `socket`,`pipe` and the `filedescriptor` are
represented by an int type. In Windows a socket is kept in a
`SOCKET` type (64 bit wide), a pipe in a `HANDLE` (64 bit wide) and
a file descriptor in an int. This class unifies all Windows types.
In POSIX this class is an int.


Diffs (updated)
-

  3rdparty/stout/include/stout/os.hpp bd085e4e29bbdb2d2baaaeff1d10c0bd95ca65ba 
  3rdparty/stout/include/stout/os/filedescriptor.hpp PRE-CREATION 
  3rdparty/stout/include/stout/os/windows/filedescriptor.hpp PRE-CREATION 

Diff: https://reviews.apache.org/r/52544/diff/


Testing
---


Thanks,

Daniel Pravat



Re: Review Request 53706: Implemented `os::user' on Windows.

2016-11-29 Thread Daniel Pravat

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

(Updated Nov. 30, 2016, 7:54 a.m.)


Review request for mesos, Alex Naparu, Artem Harutyunyan, Alex Clemmer, Joseph 
Wu, and Michael Park.


Repository: mesos


Description
---

Implemented `os::user' on Windows.


Diffs (updated)
-

  3rdparty/stout/include/stout/os/windows/su.hpp 
1bb70964adbb80aa6502fbfe69de2c34dc74e655 

Diff: https://reviews.apache.org/r/53706/diff/


Testing
---


Thanks,

Daniel Pravat



Re: Review Request 52544: Introduced `int_fd` class.

2016-11-29 Thread Daniel Pravat


> On Nov. 19, 2016, 3:28 a.m., Michael Park wrote:
> > 3rdparty/stout/include/stout/os/windows/filedescriptor.hpp, lines 381-384
> > 
> >
> > Do we actually need this? I think the `int` on the rhs should implicit 
> > convert to `WindowsFD` in which case this would be handled by:
> > 
> > ```
> > bool operator==(
> > const os::WindowsFileDescriptor& left,
> > const os::WindowsFileDescriptor& right);
> > ```

There are many conversion options and the compiler is not selecting bool 
operator==(
const os::WindowsFileDescriptor& left,
const os::WindowsFileDescriptor& right);


- Daniel


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


On Nov. 30, 2016, 7:54 a.m., Daniel Pravat wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/52544/
> ---
> 
> (Updated Nov. 30, 2016, 7:54 a.m.)
> 
> 
> Review request for mesos, Alex Naparu, Alex Clemmer, Joseph Wu, and Michael 
> Park.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> In POSIX the `socket`,`pipe` and the `filedescriptor` are
> represented by an int type. In Windows a socket is kept in a
> `SOCKET` type (64 bit wide), a pipe in a `HANDLE` (64 bit wide) and
> a file descriptor in an int. This class unifies all Windows types.
> In POSIX this class is an int.
> 
> 
> Diffs
> -
> 
>   3rdparty/stout/include/stout/os.hpp 
> bd085e4e29bbdb2d2baaaeff1d10c0bd95ca65ba 
>   3rdparty/stout/include/stout/os/filedescriptor.hpp PRE-CREATION 
>   3rdparty/stout/include/stout/os/windows/filedescriptor.hpp PRE-CREATION 
> 
> Diff: https://reviews.apache.org/r/52544/diff/
> 
> 
> Testing
> ---
> 
> 
> Thanks,
> 
> Daniel Pravat
> 
>



Re: Review Request 54192: Made IOSwitchboard an isolator.

2016-11-29 Thread Jie Yu


> On Nov. 30, 2016, 3:36 a.m., Kevin Klues wrote:
> > include/mesos/slave/container_logger.hpp, lines 121-123
> > 
> >
> > I haven't usually seen member variables ending in `_` like this. Is 
> > this a standard pattern?

Yeah, i used that in a couple of places. Basically the google style.


> On Nov. 30, 2016, 3:36 a.m., Kevin Klues wrote:
> > src/slave/containerizer/mesos/io/switchboard.hpp, line 81
> > 
> >
> > Why remove the `const` `&` here?

because ownership is supposed to be transferred here. Though our owned pointer 
is actually shared pointer


> On Nov. 30, 2016, 3:36 a.m., Kevin Klues wrote:
> > src/slave/containerizer/mesos/io/switchboard.cpp, lines 138-140
> > 
> >
> > Just curious, why is `_prepare()` preferred over a simple lambda here 
> > (as it was before)?

I prefer that if the lambda is too big.


- Jie


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


On Nov. 30, 2016, 2:07 a.m., Jie Yu wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/54192/
> ---
> 
> (Updated Nov. 30, 2016, 2:07 a.m.)
> 
> 
> Review request for mesos and Kevin Klues.
> 
> 
> Bugs: MESOS-6651
> https://issues.apache.org/jira/browse/MESOS-6651
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Made IOSwitchboard an isolator.
> 
> 
> Diffs
> -
> 
>   include/mesos/slave/container_logger.hpp 
> 43bd4b6b0365f67234477f8ed51024f342fa271f 
>   include/mesos/slave/containerizer.proto 
> cdb125a631c22d2e015b8ead421f13611ea56184 
>   src/slave/containerizer/mesos/containerizer.hpp 
> 45986c57e5d5b85ec153bd0380f57ebdf33c4f30 
>   src/slave/containerizer/mesos/containerizer.cpp 
> 4a03f97d10a1b34a0a13600af5ac6fc3679694fd 
>   src/slave/containerizer/mesos/io/switchboard.hpp 
> aaa3a35245b291f6003f519dbf8c0e1b82bc15fd 
>   src/slave/containerizer/mesos/io/switchboard.cpp 
> 25cbf2447d197134f0753b062b6f4130821005b2 
>   src/tests/containerizer/docker_volume_isolator_tests.cpp 
> 7c0349e423396b337b1e9cbed0d0073babcba79d 
>   src/tests/containerizer/mesos_containerizer_tests.cpp 
> 712bf750349d38ef30542b32358556c377ed602a 
> 
> Diff: https://reviews.apache.org/r/54192/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> 
> Thanks,
> 
> Jie Yu
> 
>



Re: Review Request 53690: Add namespaces/ipc documentation.

2016-11-29 Thread Mesos ReviewBot

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



Bad patch!

Reviews applied: [53690, 53689, 53688, 53628, 53627, 53626]

Failed command: ./support/apply-review.sh -n -r 53627

Error:
2016-11-30 04:50:22 URL:https://reviews.apache.org/r/53627/diff/raw/ 
[17209/17209] -> "53627.patch" [1]
error: patch failed: src/slave/containerizer/mesos/containerizer.cpp:1243
error: src/slave/containerizer/mesos/containerizer.cpp: patch does not apply
error: patch failed: src/slave/containerizer/mesos/launch.hpp:55
error: src/slave/containerizer/mesos/launch.hpp: patch does not apply
error: patch failed: src/slave/containerizer/mesos/launch.cpp:120
error: src/slave/containerizer/mesos/launch.cpp: patch does not apply
error: patch failed: src/tests/containerizer/isolator_tests.cpp:57
error: src/tests/containerizer/isolator_tests.cpp: patch does not apply

Full log: https://builds.apache.org/job/mesos-reviewbot/16270/console

- Mesos ReviewBot


On Nov. 29, 2016, 9:19 p.m., James Peach wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53690/
> ---
> 
> (Updated Nov. 29, 2016, 9:19 p.m.)
> 
> 
> Review request for mesos and Jie Yu.
> 
> 
> Bugs: MESOS-6557
> https://issues.apache.org/jira/browse/MESOS-6557
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Add namespaces/ipc documentation.
> 
> 
> Diffs
> -
> 
>   docs/mesos-containerizer.md 2bff35f6361f760a9001a249d2c01bbbc9e72932 
> 
> Diff: https://reviews.apache.org/r/53690/diff/
> 
> 
> Testing
> ---
> 
> Make check on Fedora 24.
> 
> 
> Thanks,
> 
> James Peach
> 
>



Review Request 54196: Added API handler for LAUNCH_NESTED_CONTAINER_SESSION.

2016-11-29 Thread Vinod Kone

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

Review request for mesos and Anand Mazumdar.


Bugs: MESOS-6471
https://issues.apache.org/jira/browse/MESOS-6471


Repository: mesos


Description
---

In addition to launching the nested container the API handler
ensures that the container is destroyed if the connection breaks.


Diffs
-

  src/slave/http.cpp 87189dd6e2e099cb74faabd3ad26aaca11e5cef2 
  src/slave/slave.hpp 05865a09724f7a46e9c06b02e59779513fc532aa 
  src/slave/validation.cpp 46e84361244394196ee5d431c1da34686d6c938a 
  src/tests/api_tests.cpp b2a70f3174824d3cb241a098d96e4d63a390f8bc 

Diff: https://reviews.apache.org/r/54196/diff/


Testing
---

make check

Added a basic test for now that tests the failure case. Will be adding more 
tests in subsequent reviews.


Thanks,

Vinod Kone



Review Request 54194: Added `devolve` helper for `ContainerID`.

2016-11-29 Thread Vinod Kone

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

Review request for mesos and Anand Mazumdar.


Bugs: MESOS-6471
https://issues.apache.org/jira/browse/MESOS-6471


Repository: mesos


Description
---

This will be used subsequently.


Diffs
-

  src/internal/devolve.hpp 15347e1822a686695284a6df6d6d078ee5a864d4 
  src/internal/devolve.cpp a94bafa4c3b657ade07889e4765ea6bfadf4ca4d 

Diff: https://reviews.apache.org/r/54194/diff/


Testing
---

make check

No new test but this code is tested in the subsequent review.


Thanks,

Vinod Kone



Review Request 54193: Refactored `Slave::Http::launcNestedContainer()`.

2016-11-29 Thread Vinod Kone

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

Review request for mesos and Anand Mazumdar.


Bugs: MESOS-6471
https://issues.apache.org/jira/browse/MESOS-6471


Repository: mesos


Description
---

This so that code can be reused for `launchNestedContainerSession()`
that will be added later. No functional change.


Diffs
-

  src/slave/http.cpp 87189dd6e2e099cb74faabd3ad26aaca11e5cef2 
  src/slave/slave.hpp 05865a09724f7a46e9c06b02e59779513fc532aa 

Diff: https://reviews.apache.org/r/54193/diff/


Testing
---

make check


Thanks,

Vinod Kone



Re: Review Request 54174: Removed superseded `slavePreLaunchDockerHook` hook.

2016-11-29 Thread Mesos ReviewBot

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



Bad patch!

Reviews applied: [54174, 54165, 54129, 54128, 54068, 54038]

Failed command: ./support/apply-review.sh -n -r 54128

Error:
2016-11-30 03:49:21 URL:https://reviews.apache.org/r/54128/diff/raw/ 
[5352/5352] -> "54128.patch" [1]
error: patch failed: src/examples/test_hook_module.cpp:217
error: src/examples/test_hook_module.cpp: patch does not apply

Full log: https://builds.apache.org/job/mesos-reviewbot/16269/console

- Mesos ReviewBot


On Nov. 29, 2016, 7:54 p.m., Till Toenshoff wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/54174/
> ---
> 
> (Updated Nov. 29, 2016, 7:54 p.m.)
> 
> 
> Review request for mesos, Adam B, Benjamin Bannier, Gastón Kleiman, and Kapil 
> Arya.
> 
> 
> Bugs: MESOS-6650
> https://issues.apache.org/jira/browse/MESOS-6650
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> see summary.
> 
> 
> Diffs
> -
> 
>   include/mesos/hook.hpp 134951ca5ee60d0cfb3cacd5ba2ae26420570d29 
>   src/examples/test_hook_module.cpp 094a92b8133f4be3d9533510863d3361e0e9d23f 
>   src/hook/manager.hpp ad52717fb043d03ca29063727656ebe1bbf55114 
>   src/hook/manager.cpp 59f402b1f8f076b151b771b2b1ae89a3b4d34d5b 
>   src/slave/containerizer/docker.cpp 5ce4667b61bb226f726beda6e21b839456e0b941 
> 
> Diff: https://reviews.apache.org/r/54174/diff/
> 
> 
> Testing
> ---
> 
> make check and sudo tests
> 
> 
> Thanks,
> 
> Till Toenshoff
> 
>



Re: Review Request 53974: Added support to handle ATTACH_CONTAINER_OUPUT in the io switchbaord.

2016-11-29 Thread Kevin Klues

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

(Updated Nov. 30, 2016, 3:51 a.m.)


Review request for mesos, Benjamin Hindman, Jie Yu, and Vinod Kone.


Changes
---

Rebased on previous patch changes. Also updated to add a new flag for waiting 
until the iurst connection comes before starting our redirect. Also updated to 
properly self terminate and close all connections when the server is ready to 
shutdown. We self terminate in a way that all outstanding messages in the event 
queue will be processed before we exit (thus ensuring we flush the IO to any 
open connections). Also added a test to make sure this all works.


Bugs: MESOS-6467
https://issues.apache.org/jira/browse/MESOS-6467


Repository: mesos


Description
---

Added support to handle ATTACH_CONTAINER_OUPUT in the io switchbaord.


Diffs (updated)
-

  src/slave/containerizer/mesos/io/switchboard.hpp 
aaa3a35245b291f6003f519dbf8c0e1b82bc15fd 
  src/slave/containerizer/mesos/io/switchboard.cpp 
25cbf2447d197134f0753b062b6f4130821005b2 
  src/slave/containerizer/mesos/io/switchboard_main.cpp PRE-CREATION 
  src/tests/containerizer/io_switchboard_tests.cpp PRE-CREATION 

Diff: https://reviews.apache.org/r/53974/diff/


Testing
---

GTEST_FILTER="" make -j check
sudo src/mesos-tests


Thanks,

Kevin Klues



Re: Review Request 54148: Updated the io switchboard to launch an external io switchboard server.

2016-11-29 Thread Kevin Klues

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

(Updated Nov. 30, 2016, 3:48 a.m.)


Review request for mesos and Jie Yu.


Changes
---

Rebased on master. Also updated to use the new `run()` call semantics of the 
switchboard server. Also moved the fd close() calls out of the parent hook on 
subprocess() and directly into the parent.


Bugs: MESOS-6639
https://issues.apache.org/jira/browse/MESOS-6639


Repository: mesos


Description
---

We don't currently handle recovering access to the io switchboard
server process after agent restarts. We will add that in a subsequent
commit.


Diffs (updated)
-

  src/Makefile.am d1cc1016b1642c504f52c27623bc12c7ddf07599 
  src/slave/containerizer/mesos/containerizer.cpp 
4a03f97d10a1b34a0a13600af5ac6fc3679694fd 
  src/slave/containerizer/mesos/io/switchboard.hpp 
aaa3a35245b291f6003f519dbf8c0e1b82bc15fd 
  src/slave/containerizer/mesos/io/switchboard.cpp 
25cbf2447d197134f0753b062b6f4130821005b2 
  src/slave/containerizer/mesos/io/switchboard_main.cpp PRE-CREATION 

Diff: https://reviews.apache.org/r/54148/diff/


Testing
---

GTEST_FILTER="" make -j check
sudo src/mesos-tests

[  FAILED  ] 
bool/UserContainerLoggerTest.ROOT_LOGROTATE_RotateWithSwitchUserTrueOrFalse/0, 
where GetParam() = true


Thanks,

Kevin Klues



Re: Review Request 54147: Added a server side component for the IOSwitchboard.

2016-11-29 Thread Kevin Klues

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

(Updated Nov. 30, 2016, 3:46 a.m.)


Review request for mesos and Jie Yu.


Changes
---

Renamed the test file, and moved the core logic of the server out of 
`initialize()` and into a `run()` function that must be explicitly called. The 
motivation for this was to ensure that the caller is able to *always* get a 
handle on the future used to mark termination of the server, even if it fails 
early on and calls terminate() on itself before the old `future()` call could 
be made.


Bugs: MESOS-6639
https://issues.apache.org/jira/browse/MESOS-6639


Repository: mesos


Description
---

The 'IOSwitchboardServer' component encapsulates the server side logic
for redirecting the 'stdin/stdout/stderr' of a container to/from
multiple sources/targets. For now, we only redirect IO from a
container to the FDs supplied to us by the logger.  We also send the
stdout/stderr data to a simple HTTP server that we launch on a unix
domain socket set up by the agent.  Right now this server is just a
stub and doesn't do anything useful.

In future commits, we will expand this HTTP server to handle
'ATTACH_CONTAINER_INPUT' and 'ATTACH_CONTAINER_OUTPUT' calls on behalf
of a container. It will use the stdout/stderr messages passed to it to
and send that data over the response stream to any clients connected
with an 'ATTACH_CONTAINER_OUTPUT' call. Likewise, it will take any
input streamed in over a 'ATTACH_CONTAINER_INPUT' request and write it
to a container's stdin.

In 'local' mode, it will be run inside the agent itself. In
'non-local' mode, it will be run as an external process to survive
agent restarts.


Diffs (updated)
-

  src/Makefile.am d1cc1016b1642c504f52c27623bc12c7ddf07599 
  src/slave/containerizer/mesos/io/switchboard.hpp 
aaa3a35245b291f6003f519dbf8c0e1b82bc15fd 
  src/slave/containerizer/mesos/io/switchboard.cpp 
25cbf2447d197134f0753b062b6f4130821005b2 
  src/tests/containerizer/io_switchboard_tests.cpp PRE-CREATION 

Diff: https://reviews.apache.org/r/54147/diff/


Testing
---

GTEST_FILTER="" make -j check
sudo src/mesos-tests


Thanks,

Kevin Klues



Re: Review Request 54192: Made IOSwitchboard an isolator.

2016-11-29 Thread Kevin Klues

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


Fix it, then Ship it!




Looks good overall. I'd probably add something to the commit message talking 
about how we currently don't implement recovery and watch, but we plan to add 
those in a subsequent commit.


include/mesos/slave/container_logger.hpp (lines 121 - 123)


I haven't usually seen member variables ending in `_` like this. Is this a 
standard pattern?



src/slave/containerizer/mesos/io/switchboard.hpp (line 66)


Why remove the `const` `&` here?



src/slave/containerizer/mesos/io/switchboard.cpp (lines 99 - 101)


Just curious, why is `_prepare()` preferred over a simple lambda here (as 
it was before)?


- Kevin Klues


On Nov. 30, 2016, 2:07 a.m., Jie Yu wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/54192/
> ---
> 
> (Updated Nov. 30, 2016, 2:07 a.m.)
> 
> 
> Review request for mesos and Kevin Klues.
> 
> 
> Bugs: MESOS-6651
> https://issues.apache.org/jira/browse/MESOS-6651
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Made IOSwitchboard an isolator.
> 
> 
> Diffs
> -
> 
>   include/mesos/slave/container_logger.hpp 
> 43bd4b6b0365f67234477f8ed51024f342fa271f 
>   include/mesos/slave/containerizer.proto 
> cdb125a631c22d2e015b8ead421f13611ea56184 
>   src/slave/containerizer/mesos/containerizer.hpp 
> 45986c57e5d5b85ec153bd0380f57ebdf33c4f30 
>   src/slave/containerizer/mesos/containerizer.cpp 
> 4a03f97d10a1b34a0a13600af5ac6fc3679694fd 
>   src/slave/containerizer/mesos/io/switchboard.hpp 
> aaa3a35245b291f6003f519dbf8c0e1b82bc15fd 
>   src/slave/containerizer/mesos/io/switchboard.cpp 
> 25cbf2447d197134f0753b062b6f4130821005b2 
>   src/tests/containerizer/docker_volume_isolator_tests.cpp 
> 7c0349e423396b337b1e9cbed0d0073babcba79d 
>   src/tests/containerizer/mesos_containerizer_tests.cpp 
> 712bf750349d38ef30542b32358556c377ed602a 
> 
> Diff: https://reviews.apache.org/r/54192/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> 
> Thanks,
> 
> Jie Yu
> 
>



Re: Review Request 53460: Refactored network::Address into inet::Address.

2016-11-29 Thread James Peach


> On Nov. 20, 2016, 11:31 p.m., James Peach wrote:
> > 3rdparty/libprocess/include/process/address.hpp, line 241
> > 
> >
> > My usual pattern for dealing with socket addresses is to use a union, 
> > which avoids the fiddly memory copies and casting. For example:
> > ```
> > union {
> >   sockaddr sa;
> >   sockaddr_storage storage;
> >   sockaddr_in sin;
> >   sockaddr_in6 sin6;
> >   sockaddr_un sun;
> > } addr = {0};
> > 
> > addr.sin.sin_family = AF_INET;
> > addr.sin.sin_addr = ip.in().get();
> > addr.sin.sin_port = htons(port);
> > return network::Address(addr.storage);
> > ```
> > 
> > This union helps in lots of places to make code cleaner and to avoid 
> > explicit casting.
> > 
> > I'm not a fan of building APIs that accept `sockaddr_storage`, since 
> > that is what `sockaddr` is for, but that could jut be a matter of taste :)
> 
> Benjamin Hindman wrote:
> I like the `union`, thanks! I'm still using `sockaddr_storage` however, 
> because IIUC `sockaddr` is not actually big enough to deal with things like 
> `sockaddr_in6`, hence the introduction of `sockaddr_storage`. I still see 
> `sockaddr` being sufficient when passing by pointer/reference, but not when 
> wanting to copy all the bits. Am I missing something here?

Yes, you would need either the same union or  `sockaddr_storage` to copy the 
bits into.


- James


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


On Nov. 29, 2016, 8:22 p.m., Benjamin Hindman wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53460/
> ---
> 
> (Updated Nov. 29, 2016, 8:22 p.m.)
> 
> 
> Review request for mesos, Benjamin Mahler and Jie Yu.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Also added unix::Address.
> 
> 
> Diffs
> -
> 
>   3rdparty/libprocess/Makefile.am 71319891a451bd1d565210dcce2fb61fc69e1f61 
>   3rdparty/libprocess/include/process/address.hpp 
> 04e3155d65f476208fa852e83b79d173b66288fd 
>   3rdparty/libprocess/include/process/network.hpp 
> 52110667185370a4c92e2fa524819ab1f34bdec9 
>   3rdparty/libprocess/include/process/pid.hpp 
> 36453b600c91c2ddc057db15ec5938e6c819260b 
>   3rdparty/libprocess/include/process/socket.hpp 
> f798af7879546d71e8ef4a295c9cf489a70cb61f 
>   3rdparty/libprocess/include/process/ssl/gtest.hpp 
> 21a0fc45b55a368a21b3e616c751ab43eebd4902 
>   3rdparty/libprocess/src/http.cpp 3f16f293a5c5cd0b31a85efe94cb6f8019543d45 
>   3rdparty/libprocess/src/libevent_ssl_socket.cpp 
> 5c0929d3d9f5595bd2f343b98b899fd6b06a67b2 
>   3rdparty/libprocess/src/pid.cpp f9313cde006dd067be265343eed60412ad6b0b95 
>   3rdparty/libprocess/src/poll_socket.cpp 
> eb7b48713edd30b545d7be95b5d51b0f71bd422a 
>   3rdparty/libprocess/src/process.cpp 
> e9a4bbb0b2410e0260d120b97e73972c94eb0f26 
>   3rdparty/libprocess/src/socket.cpp 7f93168e1572f8669f67a4c5e6e5467259b7a407 
>   3rdparty/libprocess/src/tests/process_tests.cpp 
> ea798d00a0d0bf6b6623c39904ab3c1c7fd2e555 
>   3rdparty/libprocess/src/tests/socket_tests.cpp PRE-CREATION 
>   3rdparty/libprocess/src/tests/ssl_tests.cpp 
> 55c8c309571b1892b0acc4d766eda9bb98085a6f 
>   3rdparty/libprocess/src/tests/test_linkee.cpp 
> 1f6cfafcb73fd41ef350b13e3ac6023d78f16f5a 
> 
> Diff: https://reviews.apache.org/r/53460/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> 
> Thanks,
> 
> Benjamin Hindman
> 
>



Review Request 54192: Made IOSwitchboard an isolator.

2016-11-29 Thread Jie Yu

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

Review request for mesos and Kevin Klues.


Bugs: MESOS-6651
https://issues.apache.org/jira/browse/MESOS-6651


Repository: mesos


Description
---

Made IOSwitchboard an isolator.


Diffs
-

  include/mesos/slave/container_logger.hpp 
43bd4b6b0365f67234477f8ed51024f342fa271f 
  include/mesos/slave/containerizer.proto 
cdb125a631c22d2e015b8ead421f13611ea56184 
  src/slave/containerizer/mesos/containerizer.hpp 
45986c57e5d5b85ec153bd0380f57ebdf33c4f30 
  src/slave/containerizer/mesos/containerizer.cpp 
4a03f97d10a1b34a0a13600af5ac6fc3679694fd 
  src/slave/containerizer/mesos/io/switchboard.hpp 
aaa3a35245b291f6003f519dbf8c0e1b82bc15fd 
  src/slave/containerizer/mesos/io/switchboard.cpp 
25cbf2447d197134f0753b062b6f4130821005b2 
  src/tests/containerizer/docker_volume_isolator_tests.cpp 
7c0349e423396b337b1e9cbed0d0073babcba79d 
  src/tests/containerizer/mesos_containerizer_tests.cpp 
712bf750349d38ef30542b32358556c377ed602a 

Diff: https://reviews.apache.org/r/54192/diff/


Testing
---

make check


Thanks,

Jie Yu



Review Request 54183: Improved management of unreachable and completed tasks in master.

2016-11-29 Thread Neil Conway

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

Review request for mesos and Vinod Kone.


Bugs: MESOS-6619
https://issues.apache.org/jira/browse/MESOS-6619


Repository: mesos


Description
---

Before partition-awareness, when an agent failed health checks, the
master removed the agent from the registry, marked all of its tasks
TASK_LOST, and moved them to the `completedTasks` list in the master's
memory. Although "lost" tasks might still be running, partitioned agents
would only be allowed to re-register if the master failed over, in which
case the `completedTasks` map would be emptied.

When partition-awareness was introduced, we initially followed the same
scheme, with the only difference that partition-aware tasks are marked
TASK_UNREACHABLE, not TASK_LOST.

This scheme has a few shortcomings. First, partition-aware tasks might
resume running when the partitioned agent re-registers. Second, we
re-added non-partition aware tasks when the agent re-registered but then
marked them completed when the framework is shutdown, resulting in two
entries in `completedTasks`.

This commit introduces a separate bounded map, `unreachableTasks`. These
tasks are reported separately via the HTTP endpoints, because they have
different semantics (unlike completed tasks, unreachable tasks can
resume running). The size of this map is limited by a new master flag,
`--max_unreachable_tasks_per_framework`. This commit also changes the
master to omit re-adding non-partition-aware tasks on re-registering
agents (unless the master has failed over): those tasks will shortly be
shutdown anyway.

Finally, this commit fixes a minor bug in the previous code: the
previous coding neglected to shutdown non-partition-aware frameworks
running on pre-1.0 Mesos agents that re-register with the master after
a network partition.


Diffs
-

  docs/configuration.md efe3e9bd9d203a7ba44adf4ead24f14b8b577637 
  include/mesos/master/master.proto 3553c683c17004ac1831ec90271aa8584c950e53 
  include/mesos/v1/master/master.proto 022b491b7d5c49c5aeddf4ffc97c148f55629c95 
  src/master/constants.hpp 5dd0667f62d2c0617cc0d5aed8cc005bd8344c88 
  src/master/flags.hpp 6a17b763dc76daa10073394f416b049e97a44238 
  src/master/flags.cpp 9bfb40e22820c3ced40b128280ec63288fea8b41 
  src/master/http.cpp ac560d1fdd219d0de0c5d987a32a7112e149602f 
  src/master/master.hpp b6c610b79aab146ece6b9be59be86f283d1c9ee8 
  src/master/master.cpp e03a2e8025943825a2902102c43dc0eb66bacb6a 
  src/tests/partition_tests.cpp 5a0d4bd2de6a5aa0e9fdf0d34cd10d16fd4e34a1 

Diff: https://reviews.apache.org/r/54183/diff/


Testing
---

`make check`


Thanks,

Neil Conway



Review Request 54182: Improved various comments.

2016-11-29 Thread Neil Conway

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

Review request for mesos and Vinod Kone.


Repository: mesos


Description
---

Improved various comments.


Diffs
-

  src/master/master.hpp b6c610b79aab146ece6b9be59be86f283d1c9ee8 
  src/master/master.cpp e03a2e8025943825a2902102c43dc0eb66bacb6a 
  src/tests/partition_tests.cpp 5a0d4bd2de6a5aa0e9fdf0d34cd10d16fd4e34a1 

Diff: https://reviews.apache.org/r/54182/diff/


Testing
---

`make check`


Thanks,

Neil Conway



Review Request 54181: Synchronized v1 and unversioned master.proto.

2016-11-29 Thread Neil Conway

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

Review request for mesos and Vinod Kone.


Repository: mesos


Description
---

Synchronized v1 and unversioned master.proto.


Diffs
-

  include/mesos/master/master.proto 3553c683c17004ac1831ec90271aa8584c950e53 

Diff: https://reviews.apache.org/r/54181/diff/


Testing
---

`make check`


Thanks,

Neil Conway



Review Request 54179: Updated master to use BoundedHashMap.

2016-11-29 Thread Neil Conway

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

Review request for mesos and Vinod Kone.


Bugs: MESOS-6619
https://issues.apache.org/jira/browse/MESOS-6619


Repository: mesos


Description
---

This replaces a few instances where boost::circular_buffer was
previously used.


Diffs
-

  src/master/http.cpp ac560d1fdd219d0de0c5d987a32a7112e149602f 
  src/master/master.hpp b6c610b79aab146ece6b9be59be86f283d1c9ee8 
  src/master/master.cpp e03a2e8025943825a2902102c43dc0eb66bacb6a 

Diff: https://reviews.apache.org/r/54179/diff/


Testing
---

`make check`


Thanks,

Neil Conway



Review Request 54180: Updated agent to use BoundedHashMap.

2016-11-29 Thread Neil Conway

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

Review request for mesos and Vinod Kone.


Bugs: MESOS-6619
https://issues.apache.org/jira/browse/MESOS-6619


Repository: mesos


Description
---

Updated agent to use BoundedHashMap.


Diffs
-

  src/slave/http.cpp 87189dd6e2e099cb74faabd3ad26aaca11e5cef2 
  src/slave/slave.hpp 05865a09724f7a46e9c06b02e59779513fc532aa 
  src/slave/slave.cpp 7eb45036f49289972c0b706c3c8e2ed96553d279 

Diff: https://reviews.apache.org/r/54180/diff/


Testing
---

`make check`


Thanks,

Neil Conway



Re: Review Request 54112: Added support for http::connect to take an network::Address.

2016-11-29 Thread Mesos ReviewBot

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



Patch looks great!

Reviews applied: [53457, 53458, 53459, 53460, 54173, 53461, 53462, 54108, 
54109, 54111, 54112]

Passed command: export OS='ubuntu:14.04' BUILDTOOL='autotools' COMPILER='gcc' 
CONFIGURATION='--verbose' ENVIRONMENT='GLOG_v=1 MESOS_VERBOSE=1'; 
./support/docker_build.sh

- Mesos ReviewBot


On Nov. 29, 2016, 8:23 p.m., Benjamin Hindman wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/54112/
> ---
> 
> (Updated Nov. 29, 2016, 8:23 p.m.)
> 
> 
> Review request for mesos and Benjamin Mahler.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Added support for http::connect to take an network::Address.
> 
> 
> Diffs
> -
> 
>   3rdparty/libprocess/include/process/http.hpp 
> a684e09c8353112a0656b7e899a469c1e022e93b 
>   3rdparty/libprocess/src/http.cpp 3f16f293a5c5cd0b31a85efe94cb6f8019543d45 
> 
> Diff: https://reviews.apache.org/r/54112/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> 
> Thanks,
> 
> Benjamin Hindman
> 
>



Review Request 54178: Added a fixed-capacity hashmap to stout.

2016-11-29 Thread Neil Conway

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

Review request for mesos and Vinod Kone.


Bugs: MESOS-6619
https://issues.apache.org/jira/browse/MESOS-6619


Repository: mesos


Description
---

This is similar to the LinkedHashMap and Cache constructs.

Unlike LinkedHashMap, a BoundedHashMap has a fixed maximum capacity:
when the BoundedHashMap is at capacity, inserting another element
results in removing the oldest element still in the map (i.e., FIFO
order is used for eviction).

Unlike Cache, reading an element from a BoundedHashMap does not change
which entry is evicted next.


Diffs
-

  3rdparty/stout/Makefile.am 4e10ae25a6c8a2d01d7b98b04ccf06a216611938 
  3rdparty/stout/include/stout/boundedhashmap.hpp PRE-CREATION 
  3rdparty/stout/tests/boundedhashmap_tests.cpp PRE-CREATION 

Diff: https://reviews.apache.org/r/54178/diff/


Testing
---

`make check`

Note that this is based on the revised design of LinkedHashMap, which in a 
concurrent RR has been modified to support `foreachpair` and friends. See 
https://reviews.apache.org/r/54018/


Thanks,

Neil Conway



Review Request 54177: Slightly simplified two test cases.

2016-11-29 Thread Neil Conway

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

Review request for mesos and Vinod Kone.


Bugs: MESOS-6619
https://issues.apache.org/jira/browse/MESOS-6619


Repository: mesos


Description
---

Slightly simplified two test cases.


Diffs
-

  src/tests/slave_tests.cpp 3d06c3a4a74bbcba4c9b6bdba4258c5aefdab845 

Diff: https://reviews.apache.org/r/54177/diff/


Testing
---

`make check`


Thanks,

Neil Conway



Re: Review Request 53460: Refactored network::Address into inet::Address.

2016-11-29 Thread Joseph Wu

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



A small followup commit:
```
commit 727cbef97a3a1a51abf0d2df9076eac157d35c42
Author: Joseph Wu 
Date:   Tue Nov 29 14:16:21 2016 -0800

CMake: Added socket_tests.cpp to the libprocess tests.

This test was added in: https://reviews.apache.org/r/53460/
```

- Joseph Wu


On Nov. 29, 2016, 12:22 p.m., Benjamin Hindman wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53460/
> ---
> 
> (Updated Nov. 29, 2016, 12:22 p.m.)
> 
> 
> Review request for mesos, Benjamin Mahler and Jie Yu.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Also added unix::Address.
> 
> 
> Diffs
> -
> 
>   3rdparty/libprocess/Makefile.am 71319891a451bd1d565210dcce2fb61fc69e1f61 
>   3rdparty/libprocess/include/process/address.hpp 
> 04e3155d65f476208fa852e83b79d173b66288fd 
>   3rdparty/libprocess/include/process/network.hpp 
> 52110667185370a4c92e2fa524819ab1f34bdec9 
>   3rdparty/libprocess/include/process/pid.hpp 
> 36453b600c91c2ddc057db15ec5938e6c819260b 
>   3rdparty/libprocess/include/process/socket.hpp 
> f798af7879546d71e8ef4a295c9cf489a70cb61f 
>   3rdparty/libprocess/include/process/ssl/gtest.hpp 
> 21a0fc45b55a368a21b3e616c751ab43eebd4902 
>   3rdparty/libprocess/src/http.cpp 3f16f293a5c5cd0b31a85efe94cb6f8019543d45 
>   3rdparty/libprocess/src/libevent_ssl_socket.cpp 
> 5c0929d3d9f5595bd2f343b98b899fd6b06a67b2 
>   3rdparty/libprocess/src/pid.cpp f9313cde006dd067be265343eed60412ad6b0b95 
>   3rdparty/libprocess/src/poll_socket.cpp 
> eb7b48713edd30b545d7be95b5d51b0f71bd422a 
>   3rdparty/libprocess/src/process.cpp 
> e9a4bbb0b2410e0260d120b97e73972c94eb0f26 
>   3rdparty/libprocess/src/socket.cpp 7f93168e1572f8669f67a4c5e6e5467259b7a407 
>   3rdparty/libprocess/src/tests/process_tests.cpp 
> ea798d00a0d0bf6b6623c39904ab3c1c7fd2e555 
>   3rdparty/libprocess/src/tests/socket_tests.cpp PRE-CREATION 
>   3rdparty/libprocess/src/tests/ssl_tests.cpp 
> 55c8c309571b1892b0acc4d766eda9bb98085a6f 
>   3rdparty/libprocess/src/tests/test_linkee.cpp 
> 1f6cfafcb73fd41ef350b13e3ac6023d78f16f5a 
> 
> Diff: https://reviews.apache.org/r/53460/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> 
> Thanks,
> 
> Benjamin Hindman
> 
>



Re: Review Request 53938: Added helper to get the io switchboard server address.

2016-11-29 Thread Jie Yu

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


Ship it!




I rebased it for you as BenH removed the unix::Address constructor.

- Jie Yu


On Nov. 24, 2016, 5:07 a.m., Kevin Klues wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53938/
> ---
> 
> (Updated Nov. 24, 2016, 5:07 a.m.)
> 
> 
> Review request for mesos, Benjamin Hindman, Jie Yu, and Vinod Kone.
> 
> 
> Bugs: MESOS-6467
> https://issues.apache.org/jira/browse/MESOS-6467
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> For now, the io switchboard server will always hosted on a unix domain
> socket. The path limit for a unix domain socket is 100 bytes, so we
> can't just use a file in our runtime directory as the socket file we
> connect to. Instead, we store the path to the socket file in our
> runtime directory and read it from there.
> 
> 
> Diffs
> -
> 
>   src/slave/containerizer/mesos/paths.hpp 
> 883cc263c58cf24c3e515dad7bda97efd32f2f17 
>   src/slave/containerizer/mesos/paths.cpp 
> 361307f21422c046672fb7ed29add8fe7e5c4354 
> 
> Diff: https://reviews.apache.org/r/53938/diff/
> 
> 
> Testing
> ---
> 
> make
> 
> 
> Thanks,
> 
> Kevin Klues
> 
>



Re: Review Request 53626: Add net::setDomainname() helper API.

2016-11-29 Thread James Peach

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

(Updated Nov. 29, 2016, 9:19 p.m.)


Review request for mesos, Alex Clemmer and Jie Yu.


Bugs: MESOS-6556
https://issues.apache.org/jira/browse/MESOS-6556


Repository: mesos


Description
---

Add net::setDomainname() helper API.


Diffs (updated)
-

  3rdparty/stout/include/stout/posix/net.hpp 
39b89828d350d83bf1d4b0badcd3e63eb9d1a630 
  3rdparty/stout/include/stout/windows/net.hpp 
1bed115cb848332bf9c31e455b2d001c173face9 

Diff: https://reviews.apache.org/r/53626/diff/


Testing
---

make check


Thanks,

James Peach



Re: Review Request 53628: Document the namespaces/uts isolator.

2016-11-29 Thread James Peach

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

(Updated Nov. 29, 2016, 9:19 p.m.)


Review request for mesos and Jie Yu.


Bugs: MESOS-6556
https://issues.apache.org/jira/browse/MESOS-6556


Repository: mesos


Description
---

Document the namespaces/uts isolator.


Diffs (updated)
-

  docs/mesos-containerizer.md 2bff35f6361f760a9001a249d2c01bbbc9e72932 

Diff: https://reviews.apache.org/r/53628/diff/


Testing
---

make check.


Thanks,

James Peach



Re: Review Request 53690: Add namespaces/ipc documentation.

2016-11-29 Thread James Peach

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

(Updated Nov. 29, 2016, 9:19 p.m.)


Review request for mesos and Jie Yu.


Bugs: MESOS-6557
https://issues.apache.org/jira/browse/MESOS-6557


Repository: mesos


Description
---

Add namespaces/ipc documentation.


Diffs (updated)
-

  docs/mesos-containerizer.md 2bff35f6361f760a9001a249d2c01bbbc9e72932 

Diff: https://reviews.apache.org/r/53690/diff/


Testing
---

Make check on Fedora 24.


Thanks,

James Peach



Re: Review Request 53688: Implement a namespace/ipc isolator.

2016-11-29 Thread James Peach

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

(Updated Nov. 29, 2016, 9:19 p.m.)


Review request for mesos and Jie Yu.


Bugs: MESOS-6557
https://issues.apache.org/jira/browse/MESOS-6557


Repository: mesos


Description
---

Implement a namespace/ipc isolator.


Diffs (updated)
-

  src/Makefile.am 85eda538caf39f81f052896e744b7b0c724f81bb 
  src/slave/containerizer/mesos/containerizer.cpp 
9b33495d9babc3ee489a8712fe1977746c41043f 
  src/slave/containerizer/mesos/isolators/namespaces/ipc.hpp PRE-CREATION 
  src/slave/containerizer/mesos/isolators/namespaces/ipc.cpp PRE-CREATION 
  src/tests/containerizer/isolator_tests.cpp 
9766aaf144722b18d88f694ff37ffd53974cb60d 

Diff: https://reviews.apache.org/r/53688/diff/


Testing
---

Make check on Fedora 24.


Thanks,

James Peach



Re: Review Request 53627: Implement a namespaces/uts isolator.

2016-11-29 Thread James Peach

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

(Updated Nov. 29, 2016, 9:19 p.m.)


Review request for mesos and Jie Yu.


Bugs: MESOS-6556
https://issues.apache.org/jira/browse/MESOS-6556


Repository: mesos


Description
---

Implement a very simple namespaces/uts isolator that can be used to set
the hostname and domainname of a container without the necessity of a
CNI plugin.

Since we already had a `hostname` field in the ContainerInfo, we can
use that to set the host name once we are in the UTS namespace. Add a
corresponding `domainname` to the ContainerInfo to allow setting the
domain name.


Diffs (updated)
-

  include/mesos/mesos.proto cbfcd8a666e0b4a486f6dcd9e8356c9d5a1cea05 
  include/mesos/slave/containerizer.proto 
2621522ae59cf9275f607679b4678ac54508993d 
  src/Makefile.am 85eda538caf39f81f052896e744b7b0c724f81bb 
  src/cli/execute.cpp ddf7ecac21f2680c3027fafeb4194a2dd4a66d47 
  src/slave/containerizer/mesos/containerizer.cpp 
9b33495d9babc3ee489a8712fe1977746c41043f 
  src/slave/containerizer/mesos/isolators/namespaces/uts.hpp PRE-CREATION 
  src/slave/containerizer/mesos/isolators/namespaces/uts.cpp PRE-CREATION 
  src/slave/containerizer/mesos/launch.hpp 
155e3c5a27b8c710971ee4b508600d3b5589a2e0 
  src/slave/containerizer/mesos/launch.cpp 
320e42748adbabf09f77cb4f5951e2a7ea58fe64 
  src/tests/containerizer/isolator_tests.cpp 
9766aaf144722b18d88f694ff37ffd53974cb60d 

Diff: https://reviews.apache.org/r/53627/diff/


Testing
---

make check.


Thanks,

James Peach



Re: Review Request 54174: Removed superseded `slavePreLaunchDockerHook` hook.

2016-11-29 Thread Till Toenshoff


> On Nov. 29, 2016, 8:37 p.m., Kapil Arya wrote:
> > src/examples/test_hook_module.cpp, line 228
> > 
> >
> > Do we have a test where we are testing for the presence of `foo`?

`HookTest.ROOT_DOCKER_VerifySlavePreLaunchDockerHook` - see 
https://github.com/apache/mesos/blob/a85e284013a10e0ca036ab16128530c8cfd17087/src/tests/hook_tests.cpp#L899


- Till


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


On Nov. 29, 2016, 7:54 p.m., Till Toenshoff wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/54174/
> ---
> 
> (Updated Nov. 29, 2016, 7:54 p.m.)
> 
> 
> Review request for mesos, Adam B, Benjamin Bannier, Gastón Kleiman, and Kapil 
> Arya.
> 
> 
> Bugs: MESOS-6650
> https://issues.apache.org/jira/browse/MESOS-6650
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> see summary.
> 
> 
> Diffs
> -
> 
>   include/mesos/hook.hpp 134951ca5ee60d0cfb3cacd5ba2ae26420570d29 
>   src/examples/test_hook_module.cpp 094a92b8133f4be3d9533510863d3361e0e9d23f 
>   src/hook/manager.hpp ad52717fb043d03ca29063727656ebe1bbf55114 
>   src/hook/manager.cpp 59f402b1f8f076b151b771b2b1ae89a3b4d34d5b 
>   src/slave/containerizer/docker.cpp 5ce4667b61bb226f726beda6e21b839456e0b941 
> 
> Diff: https://reviews.apache.org/r/54174/diff/
> 
> 
> Testing
> ---
> 
> make check and sudo tests
> 
> 
> Thanks,
> 
> Till Toenshoff
> 
>



Re: Review Request 54148: Updated the io switchboard to launch an external io switchboard server.

2016-11-29 Thread Kevin Klues

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

(Updated Nov. 29, 2016, 8:38 p.m.)


Review request for mesos and Jie Yu.


Changes
---

Updated to account for the API change to the `IOSwitchboardServer`.


Bugs: MESOS-6639
https://issues.apache.org/jira/browse/MESOS-6639


Repository: mesos


Description
---

We don't currently handle recovering access to the io switchboard
server process after agent restarts. We will add that in a subsequent
commit.


Diffs (updated)
-

  src/Makefile.am 85eda538caf39f81f052896e744b7b0c724f81bb 
  src/slave/containerizer/mesos/containerizer.cpp 
9b33495d9babc3ee489a8712fe1977746c41043f 
  src/slave/containerizer/mesos/io/switchboard.hpp 
aaa3a35245b291f6003f519dbf8c0e1b82bc15fd 
  src/slave/containerizer/mesos/io/switchboard.cpp 
25cbf2447d197134f0753b062b6f4130821005b2 
  src/slave/containerizer/mesos/io/switchboard_main.cpp PRE-CREATION 

Diff: https://reviews.apache.org/r/54148/diff/


Testing
---

GTEST_FILTER="" make -j check
sudo src/mesos-tests

[  FAILED  ] 
bool/UserContainerLoggerTest.ROOT_LOGROTATE_RotateWithSwitchUserTrueOrFalse/0, 
where GetParam() = true


Thanks,

Kevin Klues



Re: Review Request 54147: Added a server side component for the IOSwitchboard.

2016-11-29 Thread Kevin Klues

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

(Updated Nov. 29, 2016, 8:37 p.m.)


Review request for mesos and Jie Yu.


Changes
---

Updated to include a unit test. This changed the API slightly (for the better).


Bugs: MESOS-6639
https://issues.apache.org/jira/browse/MESOS-6639


Repository: mesos


Description
---

The 'IOSwitchboardServer' component encapsulates the server side logic
for redirecting the 'stdin/stdout/stderr' of a container to/from
multiple sources/targets. For now, we only redirect IO from a
container to the FDs supplied to us by the logger.  We also send the
stdout/stderr data to a simple HTTP server that we launch on a unix
domain socket set up by the agent.  Right now this server is just a
stub and doesn't do anything useful.

In future commits, we will expand this HTTP server to handle
'ATTACH_CONTAINER_INPUT' and 'ATTACH_CONTAINER_OUTPUT' calls on behalf
of a container. It will use the stdout/stderr messages passed to it to
and send that data over the response stream to any clients connected
with an 'ATTACH_CONTAINER_OUTPUT' call. Likewise, it will take any
input streamed in over a 'ATTACH_CONTAINER_INPUT' request and write it
to a container's stdin.

In 'local' mode, it will be run inside the agent itself. In
'non-local' mode, it will be run as an external process to survive
agent restarts.


Diffs (updated)
-

  src/Makefile.am 85eda538caf39f81f052896e744b7b0c724f81bb 
  src/slave/containerizer/mesos/io/switchboard.hpp 
aaa3a35245b291f6003f519dbf8c0e1b82bc15fd 
  src/slave/containerizer/mesos/io/switchboard.cpp 
25cbf2447d197134f0753b062b6f4130821005b2 
  src/tests/containerizer/io_switchboard.cpp PRE-CREATION 

Diff: https://reviews.apache.org/r/54147/diff/


Testing
---

GTEST_FILTER="" make -j check
sudo src/mesos-tests


Thanks,

Kevin Klues



Re: Review Request 54129: Removed superseded `slavePreLaunchDockerEnvironmentDecorator` hook.

2016-11-29 Thread Kapil Arya

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


Ship it!




Ship It!

- Kapil Arya


On Nov. 29, 2016, 2:54 p.m., Till Toenshoff wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/54129/
> ---
> 
> (Updated Nov. 29, 2016, 2:54 p.m.)
> 
> 
> Review request for mesos, Adam B and Kapil Arya.
> 
> 
> Bugs: MESOS-6650
> https://issues.apache.org/jira/browse/MESOS-6650
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> see summary.
> 
> 
> Diffs
> -
> 
>   include/mesos/hook.hpp 134951ca5ee60d0cfb3cacd5ba2ae26420570d29 
>   src/examples/test_hook_module.cpp 094a92b8133f4be3d9533510863d3361e0e9d23f 
>   src/hook/manager.hpp ad52717fb043d03ca29063727656ebe1bbf55114 
>   src/hook/manager.cpp 59f402b1f8f076b151b771b2b1ae89a3b4d34d5b 
>   src/slave/containerizer/docker.cpp 5ce4667b61bb226f726beda6e21b839456e0b941 
>   src/tests/hook_tests.cpp d334d6c5ff7f966d55b395bfbf4f25ee3fa2 
> 
> Diff: https://reviews.apache.org/r/54129/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> 
> Thanks,
> 
> Till Toenshoff
> 
>



Re: Review Request 54174: Removed superseded `slavePreLaunchDockerHook` hook.

2016-11-29 Thread Kapil Arya

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


Fix it, then Ship it!




Ship It!


src/examples/test_hook_module.cpp (line 228)


Do we have a test where we are testing for the presence of `foo`?


- Kapil Arya


On Nov. 29, 2016, 2:54 p.m., Till Toenshoff wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/54174/
> ---
> 
> (Updated Nov. 29, 2016, 2:54 p.m.)
> 
> 
> Review request for mesos, Adam B, Benjamin Bannier, Gastón Kleiman, and Kapil 
> Arya.
> 
> 
> Bugs: MESOS-6650
> https://issues.apache.org/jira/browse/MESOS-6650
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> see summary.
> 
> 
> Diffs
> -
> 
>   include/mesos/hook.hpp 134951ca5ee60d0cfb3cacd5ba2ae26420570d29 
>   src/examples/test_hook_module.cpp 094a92b8133f4be3d9533510863d3361e0e9d23f 
>   src/hook/manager.hpp ad52717fb043d03ca29063727656ebe1bbf55114 
>   src/hook/manager.cpp 59f402b1f8f076b151b771b2b1ae89a3b4d34d5b 
>   src/slave/containerizer/docker.cpp 5ce4667b61bb226f726beda6e21b839456e0b941 
> 
> Diff: https://reviews.apache.org/r/54174/diff/
> 
> 
> Testing
> ---
> 
> make check and sudo tests
> 
> 
> Thanks,
> 
> Till Toenshoff
> 
>



Re: Review Request 54165: Fixed conflict in hook result handling.

2016-11-29 Thread Kapil Arya

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


Ship it!




Ship It!

- Kapil Arya


On Nov. 29, 2016, 11:37 a.m., Till Toenshoff wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/54165/
> ---
> 
> (Updated Nov. 29, 2016, 11:37 a.m.)
> 
> 
> Review request for mesos, Adam B, Benjamin Bannier, Gastón Kleiman, and Kapil 
> Arya.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> see summary.
> 
> 
> Diffs
> -
> 
>   src/slave/containerizer/docker.cpp 5ce4667b61bb226f726beda6e21b839456e0b941 
> 
> Diff: https://reviews.apache.org/r/54165/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> 
> Thanks,
> 
> Till Toenshoff
> 
>



Re: Review Request 54128: Added test for `slavePreLaunchDockerTaskExecutorDecorator` hook.

2016-11-29 Thread Kapil Arya

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


Ship it!




- Kapil Arya


On Nov. 29, 2016, 11:38 a.m., Till Toenshoff wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/54128/
> ---
> 
> (Updated Nov. 29, 2016, 11:38 a.m.)
> 
> 
> Review request for mesos, Adam B, Gastón Kleiman, and Kapil Arya.
> 
> 
> Bugs: MESOS-6396
> https://issues.apache.org/jira/browse/MESOS-6396
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> see summary.
> 
> 
> Diffs
> -
> 
>   src/examples/test_hook_module.cpp 5e91a71f2450cf3c37eb9039ef28c026095c917e 
>   src/tests/hook_tests.cpp d334d6c5ff7f966d55b395bfbf4f25ee3fa2 
> 
> Diff: https://reviews.apache.org/r/54128/diff/
> 
> 
> Testing
> ---
> 
> make check and sudo tests
> 
> 
> Thanks,
> 
> Till Toenshoff
> 
>



Re: Review Request 54114: Updated http::Connection::disconnect to do a complete socket shutdown.

2016-11-29 Thread Benjamin Hindman

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

(Updated Nov. 29, 2016, 8:24 p.m.)


Review request for mesos and Benjamin Mahler.


Repository: mesos


Description
---

Updated http::Connection::disconnect to do a complete socket shutdown.


Diffs (updated)
-

  3rdparty/libprocess/src/http.cpp 3f16f293a5c5cd0b31a85efe94cb6f8019543d45 

Diff: https://reviews.apache.org/r/54114/diff/


Testing
---

make check


Thanks,

Benjamin Hindman



Re: Review Request 54113: Added support for specifying how a socket should be shutdown.

2016-11-29 Thread Benjamin Hindman

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

(Updated Nov. 29, 2016, 8:24 p.m.)


Review request for mesos and Benjamin Mahler.


Repository: mesos


Description
---

Added support for specifying how a socket should be shutdown.


Diffs (updated)
-

  3rdparty/libprocess/include/process/socket.hpp 
f798af7879546d71e8ef4a295c9cf489a70cb61f 

Diff: https://reviews.apache.org/r/54113/diff/


Testing
---

make check


Thanks,

Benjamin Hindman



Re: Review Request 54112: Added support for http::connect to take an network::Address.

2016-11-29 Thread Benjamin Hindman

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

(Updated Nov. 29, 2016, 8:23 p.m.)


Review request for mesos and Benjamin Mahler.


Repository: mesos


Description
---

Added support for http::connect to take an network::Address.


Diffs (updated)
-

  3rdparty/libprocess/include/process/http.hpp 
a684e09c8353112a0656b7e899a469c1e022e93b 
  3rdparty/libprocess/src/http.cpp 3f16f293a5c5cd0b31a85efe94cb6f8019543d45 

Diff: https://reviews.apache.org/r/54112/diff/


Testing
---

make check


Thanks,

Benjamin Hindman



Re: Review Request 54111: Removed unused Socket from Encoder.

2016-11-29 Thread Benjamin Hindman

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

(Updated Nov. 29, 2016, 8:23 p.m.)


Review request for mesos and Benjamin Mahler.


Repository: mesos


Description
---

Removed unused Socket from Encoder.


Diffs (updated)
-

  3rdparty/libprocess/src/encoder.hpp 515821acb20d2a09d10781af17dcac472a7c117a 
  3rdparty/libprocess/src/process.cpp e9a4bbb0b2410e0260d120b97e73972c94eb0f26 
  3rdparty/libprocess/src/tests/decoder_tests.cpp 
5f84d84dc8ff5e1f2684da14d30c1866ad8562d5 

Diff: https://reviews.apache.org/r/54111/diff/


Testing
---

make check


Thanks,

Benjamin Hindman



Re: Review Request 54109: Changes in Mesos to make http::Request::client optional.

2016-11-29 Thread Benjamin Hindman

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

(Updated Nov. 29, 2016, 8:23 p.m.)


Review request for mesos and Benjamin Mahler.


Repository: mesos


Description
---

Changes in Mesos to make http::Request::client optional.


Diffs (updated)
-

  src/master/http.cpp 90cbed1ba411e18906fe9c26bc14576a26d1b7b9 
  src/slave/http.cpp 91bb882270a65add754180ff107024257b873642 

Diff: https://reviews.apache.org/r/54109/diff/


Testing
---

make check


Thanks,

Benjamin Hindman



Re: Review Request 54108: Changes in libprocess to make http::Request::client optional.

2016-11-29 Thread Benjamin Hindman

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

(Updated Nov. 29, 2016, 8:23 p.m.)


Review request for mesos and Benjamin Mahler.


Repository: mesos


Description
---

Changes in libprocess to make http::Request::client optional.


Diffs (updated)
-

  3rdparty/libprocess/include/process/http.hpp 
a684e09c8353112a0656b7e899a469c1e022e93b 
  3rdparty/libprocess/src/tests/http_tests.cpp 
d41929a9c8b2469c10b9e31985c447076c1684dc 

Diff: https://reviews.apache.org/r/54108/diff/


Testing
---

make check


Thanks,

Benjamin Hindman



Re: Review Request 53462: Updated usage of network::Address and network::Socket in Mesos.

2016-11-29 Thread Benjamin Hindman

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

(Updated Nov. 29, 2016, 8:22 p.m.)


Review request for mesos, Benjamin Mahler and Jie Yu.


Repository: mesos


Description
---

Updated usage of network::Address in Mesos.


Diffs (updated)
-

  src/tests/fetcher_tests.cpp 79526ae7719eaef1456a0986d191b0b36b5f1ae6 
  src/tests/utils.cpp d36aa9ca32b45da304059210de83c55bf9181847 

Diff: https://reviews.apache.org/r/53462/diff/


Testing
---

make check


Thanks,

Benjamin Hindman



Re: Review Request 53461: Inlined function only used one place.

2016-11-29 Thread Benjamin Hindman

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

(Updated Nov. 29, 2016, 8:22 p.m.)


Review request for mesos, Benjamin Mahler and Jie Yu.


Repository: mesos


Description
---

Inlined function only used one place.


Diffs (updated)
-

  3rdparty/stout/include/stout/net.hpp 083b8d1959dcd305d0aa8892082b39cb03786ebf 

Diff: https://reviews.apache.org/r/53461/diff/


Testing
---

make check


Thanks,

Benjamin Hindman



Re: Review Request 53459: Refactored `Socket` to support a templated version.

2016-11-29 Thread Benjamin Hindman

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

(Updated Nov. 29, 2016, 8:22 p.m.)


Review request for mesos, Benjamin Mahler and Jie Yu.


Repository: mesos


Description
---

The templated `Socket` will enable us to provide type safe
functionality for different addresses, ultimately `inet::Address` and
`unix::Address` (and likely eventually `inet6::Address` as well).

Also introduced the `inet` namespace and updated the code to
explicitly use `inet::Address` and `inet::Socket`.


Diffs (updated)
-

  3rdparty/libprocess/include/process/address.hpp 
04e3155d65f476208fa852e83b79d173b66288fd 
  3rdparty/libprocess/include/process/firewall.hpp 
ad461caaa95c1098d5449307b0c07508e22c3c37 
  3rdparty/libprocess/include/process/http.hpp 
a684e09c8353112a0656b7e899a469c1e022e93b 
  3rdparty/libprocess/include/process/pid.hpp 
36453b600c91c2ddc057db15ec5938e6c819260b 
  3rdparty/libprocess/include/process/process.hpp 
de23f0cfef4bf95ce33c5b336e2901f416a8502e 
  3rdparty/libprocess/include/process/socket.hpp 
f798af7879546d71e8ef4a295c9cf489a70cb61f 
  3rdparty/libprocess/include/process/ssl/gtest.hpp 
21a0fc45b55a368a21b3e616c751ab43eebd4902 
  3rdparty/libprocess/src/encoder.hpp 515821acb20d2a09d10781af17dcac472a7c117a 
  3rdparty/libprocess/src/http.cpp 3f16f293a5c5cd0b31a85efe94cb6f8019543d45 
  3rdparty/libprocess/src/libevent_ssl_socket.hpp 
acb00d41c637a318b2f16fff9e97998b9c79b809 
  3rdparty/libprocess/src/libevent_ssl_socket.cpp 
5c0929d3d9f5595bd2f343b98b899fd6b06a67b2 
  3rdparty/libprocess/src/pid.cpp f9313cde006dd067be265343eed60412ad6b0b95 
  3rdparty/libprocess/src/poll_socket.hpp 
d04f3f2d1bcf70464ac659b29f96574bbd233414 
  3rdparty/libprocess/src/poll_socket.cpp 
eb7b48713edd30b545d7be95b5d51b0f71bd422a 
  3rdparty/libprocess/src/process.cpp e9a4bbb0b2410e0260d120b97e73972c94eb0f26 
  3rdparty/libprocess/src/socket.cpp 7f93168e1572f8669f67a4c5e6e5467259b7a407 
  3rdparty/libprocess/src/tests/decoder_tests.cpp 
5f84d84dc8ff5e1f2684da14d30c1866ad8562d5 
  3rdparty/libprocess/src/tests/http_tests.cpp 
d41929a9c8b2469c10b9e31985c447076c1684dc 
  3rdparty/libprocess/src/tests/process_tests.cpp 
ea798d00a0d0bf6b6623c39904ab3c1c7fd2e555 
  3rdparty/libprocess/src/tests/ssl_client.cpp 
8d62fc2975b585013a8d9a6efc967314d6d8ec47 
  3rdparty/libprocess/src/tests/ssl_tests.cpp 
55c8c309571b1892b0acc4d766eda9bb98085a6f 
  3rdparty/libprocess/src/tests/test_linkee.cpp 
1f6cfafcb73fd41ef350b13e3ac6023d78f16f5a 

Diff: https://reviews.apache.org/r/53459/diff/


Testing
---

make check


Thanks,

Benjamin Hindman



Re: Review Request 54173: Refactor necessary after removing default Address constructor.

2016-11-29 Thread Benjamin Hindman

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

(Updated Nov. 29, 2016, 8:22 p.m.)


Review request for mesos and Jie Yu.


Repository: mesos


Description
---

Refactor necessary after removing default Address constructor.


Diffs (updated)
-

  3rdparty/libprocess/src/process.cpp e9a4bbb0b2410e0260d120b97e73972c94eb0f26 

Diff: https://reviews.apache.org/r/54173/diff/


Testing
---

make check


Thanks,

Benjamin Hindman



Re: Review Request 53460: Refactored network::Address into inet::Address.

2016-11-29 Thread Benjamin Hindman

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

(Updated Nov. 29, 2016, 8:22 p.m.)


Review request for mesos, Benjamin Mahler and Jie Yu.


Repository: mesos


Description
---

Also added unix::Address.


Diffs (updated)
-

  3rdparty/libprocess/Makefile.am 71319891a451bd1d565210dcce2fb61fc69e1f61 
  3rdparty/libprocess/include/process/address.hpp 
04e3155d65f476208fa852e83b79d173b66288fd 
  3rdparty/libprocess/include/process/network.hpp 
52110667185370a4c92e2fa524819ab1f34bdec9 
  3rdparty/libprocess/include/process/pid.hpp 
36453b600c91c2ddc057db15ec5938e6c819260b 
  3rdparty/libprocess/include/process/socket.hpp 
f798af7879546d71e8ef4a295c9cf489a70cb61f 
  3rdparty/libprocess/include/process/ssl/gtest.hpp 
21a0fc45b55a368a21b3e616c751ab43eebd4902 
  3rdparty/libprocess/src/http.cpp 3f16f293a5c5cd0b31a85efe94cb6f8019543d45 
  3rdparty/libprocess/src/libevent_ssl_socket.cpp 
5c0929d3d9f5595bd2f343b98b899fd6b06a67b2 
  3rdparty/libprocess/src/pid.cpp f9313cde006dd067be265343eed60412ad6b0b95 
  3rdparty/libprocess/src/poll_socket.cpp 
eb7b48713edd30b545d7be95b5d51b0f71bd422a 
  3rdparty/libprocess/src/process.cpp e9a4bbb0b2410e0260d120b97e73972c94eb0f26 
  3rdparty/libprocess/src/socket.cpp 7f93168e1572f8669f67a4c5e6e5467259b7a407 
  3rdparty/libprocess/src/tests/process_tests.cpp 
ea798d00a0d0bf6b6623c39904ab3c1c7fd2e555 
  3rdparty/libprocess/src/tests/socket_tests.cpp PRE-CREATION 
  3rdparty/libprocess/src/tests/ssl_tests.cpp 
55c8c309571b1892b0acc4d766eda9bb98085a6f 
  3rdparty/libprocess/src/tests/test_linkee.cpp 
1f6cfafcb73fd41ef350b13e3ac6023d78f16f5a 

Diff: https://reviews.apache.org/r/53460/diff/


Testing
---

make check


Thanks,

Benjamin Hindman



Re: Review Request 53457: Updated Socket::Impl::accept to return std::shared_ptr.

2016-11-29 Thread Benjamin Hindman

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

(Updated Nov. 29, 2016, 8:21 p.m.)


Review request for mesos, Benjamin Mahler and Jie Yu.


Repository: mesos


Description
---

Updated Socket::Impl::accept to return std::shared_ptr.


Diffs (updated)
-

  3rdparty/libprocess/include/process/socket.hpp 
f798af7879546d71e8ef4a295c9cf489a70cb61f 
  3rdparty/libprocess/src/poll_socket.hpp 
d04f3f2d1bcf70464ac659b29f96574bbd233414 
  3rdparty/libprocess/src/poll_socket.cpp 
eb7b48713edd30b545d7be95b5d51b0f71bd422a 

Diff: https://reviews.apache.org/r/53457/diff/


Testing
---

make check


Thanks,

Benjamin Hindman



Re: Review Request 53458: Removed `Socket` dependency on `Socket::Impl`.

2016-11-29 Thread Benjamin Hindman

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

(Updated Nov. 29, 2016, 8:21 p.m.)


Review request for mesos, Benjamin Mahler and Jie Yu.


Repository: mesos


Description
---

Removed `Socket` dependency on `Socket::Impl`.


Diffs (updated)
-

  3rdparty/libprocess/include/process/socket.hpp 
f798af7879546d71e8ef4a295c9cf489a70cb61f 
  3rdparty/libprocess/src/libevent_ssl_socket.hpp 
acb00d41c637a318b2f16fff9e97998b9c79b809 
  3rdparty/libprocess/src/libevent_ssl_socket.cpp 
5c0929d3d9f5595bd2f343b98b899fd6b06a67b2 
  3rdparty/libprocess/src/poll_socket.cpp 
eb7b48713edd30b545d7be95b5d51b0f71bd422a 
  3rdparty/libprocess/src/socket.cpp 7f93168e1572f8669f67a4c5e6e5467259b7a407 

Diff: https://reviews.apache.org/r/53458/diff/


Testing
---

make check


Thanks,

Benjamin Hindman



Re: Review Request 54110: Added `process::loop` abstraction.

2016-11-29 Thread Michael Park

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




3rdparty/libprocess/include/process/loop.hpp (lines 126 - 127)


Do you want these to be by value?

This code as-is, `Iterate` and `Body` can be l-value references.

In the `loop` implementation below, we do something like:

```cpp
template 
Future loop(const UPID& pid, Iterate&& iterate, Body&& body)
{
  /* ... */
  
  Owned> loop(/* ... */);
}
```

`Iterate&&` (and `Body&&`) are forwarding references here, which means that 
`Iterate` can be deduced to be an l-value reference.
If you want to store them by value, the standard practice here is to pass 
`typename std::decay::type` to `Loop`.


- Michael Park


On Nov. 28, 2016, 10:33 a.m., Benjamin Hindman wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/54110/
> ---
> 
> (Updated Nov. 28, 2016, 10:33 a.m.)
> 
> 
> Review request for mesos, Benjamin Mahler and Michael Park.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Added `process::loop` abstraction.
> 
> 
> Diffs
> -
> 
>   3rdparty/libprocess/Makefile.am 71319891a451bd1d565210dcce2fb61fc69e1f61 
>   3rdparty/libprocess/include/process/loop.hpp PRE-CREATION 
>   3rdparty/libprocess/src/tests/loop_tests.cpp PRE-CREATION 
> 
> Diff: https://reviews.apache.org/r/54110/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> 
> Thanks,
> 
> Benjamin Hindman
> 
>



Re: Review Request 54113: Added support for specifying how a socket should be shutdown.

2016-11-29 Thread Benjamin Hindman


> On Nov. 28, 2016, 6:25 p.m., Greg Mann wrote:
> > 3rdparty/libprocess/include/process/socket.hpp, lines 394-396
> > 
> >
> > BenM pointed out on my similar review that we need to alter our Windows 
> > headers to map the POSIX constants `SHUT_WR` and `SHUT_RDWR` onto their 
> > Windows equivalents. Something like this: 
> > https://reviews.apache.org/r/53990/

I'll commit your patch first, thanks Greg!


- Benjamin


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


On Nov. 28, 2016, 6:19 a.m., Benjamin Hindman wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/54113/
> ---
> 
> (Updated Nov. 28, 2016, 6:19 a.m.)
> 
> 
> Review request for mesos and Benjamin Mahler.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Added support for specifying how a socket should be shutdown.
> 
> 
> Diffs
> -
> 
>   3rdparty/libprocess/include/process/socket.hpp 
> f798af7879546d71e8ef4a295c9cf489a70cb61f 
> 
> Diff: https://reviews.apache.org/r/54113/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> 
> Thanks,
> 
> Benjamin Hindman
> 
>



Re: Review Request 53460: Refactored network::Address into inet::Address.

2016-11-29 Thread Benjamin Hindman


> On Nov. 28, 2016, 10:08 p.m., Jie Yu wrote:
> > 3rdparty/libprocess/include/process/socket.hpp, line 433
> > 
> >
> > inline is not necessary for template specification? Let's be consistent 
> > here (either use inline for all of them, or none of them).

`inline` is necessary for a completely specialized template definition, but not 
for the deleted function so I'll remove it there but keep it the other places.


- Benjamin


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


On Nov. 28, 2016, 6:15 a.m., Benjamin Hindman wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53460/
> ---
> 
> (Updated Nov. 28, 2016, 6:15 a.m.)
> 
> 
> Review request for mesos, Benjamin Mahler and Jie Yu.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Also added unix::Address.
> 
> 
> Diffs
> -
> 
>   3rdparty/libprocess/Makefile.am 71319891a451bd1d565210dcce2fb61fc69e1f61 
>   3rdparty/libprocess/include/process/address.hpp 
> 04e3155d65f476208fa852e83b79d173b66288fd 
>   3rdparty/libprocess/include/process/network.hpp 
> 52110667185370a4c92e2fa524819ab1f34bdec9 
>   3rdparty/libprocess/include/process/socket.hpp 
> f798af7879546d71e8ef4a295c9cf489a70cb61f 
>   3rdparty/libprocess/include/process/ssl/gtest.hpp 
> 21a0fc45b55a368a21b3e616c751ab43eebd4902 
>   3rdparty/libprocess/src/address.cpp PRE-CREATION 
>   3rdparty/libprocess/src/libevent_ssl_socket.cpp 
> 5c0929d3d9f5595bd2f343b98b899fd6b06a67b2 
>   3rdparty/libprocess/src/poll_socket.cpp 
> eb7b48713edd30b545d7be95b5d51b0f71bd422a 
>   3rdparty/libprocess/src/process.cpp 
> e9a4bbb0b2410e0260d120b97e73972c94eb0f26 
>   3rdparty/libprocess/src/socket.cpp 7f93168e1572f8669f67a4c5e6e5467259b7a407 
>   3rdparty/libprocess/src/tests/socket_tests.cpp PRE-CREATION 
>   3rdparty/libprocess/src/tests/ssl_tests.cpp 
> 55c8c309571b1892b0acc4d766eda9bb98085a6f 
>   3rdparty/libprocess/src/tests/test_linkee.cpp 
> 1f6cfafcb73fd41ef350b13e3ac6023d78f16f5a 
> 
> Diff: https://reviews.apache.org/r/53460/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> 
> Thanks,
> 
> Benjamin Hindman
> 
>



Re: Review Request 53460: Refactored network::Address into inet::Address.

2016-11-29 Thread Benjamin Hindman


> On Nov. 20, 2016, 11:31 p.m., James Peach wrote:
> > 3rdparty/libprocess/include/process/address.hpp, line 129
> > 
> >
> > Suggest that this should be `explicit`. There's some risk that strings 
> > like `127.0.0.1` would be coverted implicitly, whereas if you have to 
> > explicitly convert to `unix::Address` this is unlikely.

Agreed, done.


> On Nov. 20, 2016, 11:31 p.m., James Peach wrote:
> > 3rdparty/libprocess/include/process/address.hpp, line 241
> > 
> >
> > My usual pattern for dealing with socket addresses is to use a union, 
> > which avoids the fiddly memory copies and casting. For example:
> > ```
> > union {
> >   sockaddr sa;
> >   sockaddr_storage storage;
> >   sockaddr_in sin;
> >   sockaddr_in6 sin6;
> >   sockaddr_un sun;
> > } addr = {0};
> > 
> > addr.sin.sin_family = AF_INET;
> > addr.sin.sin_addr = ip.in().get();
> > addr.sin.sin_port = htons(port);
> > return network::Address(addr.storage);
> > ```
> > 
> > This union helps in lots of places to make code cleaner and to avoid 
> > explicit casting.
> > 
> > I'm not a fan of building APIs that accept `sockaddr_storage`, since 
> > that is what `sockaddr` is for, but that could jut be a matter of taste :)

I like the `union`, thanks! I'm still using `sockaddr_storage` however, because 
IIUC `sockaddr` is not actually big enough to deal with things like 
`sockaddr_in6`, hence the introduction of `sockaddr_storage`. I still see 
`sockaddr` being sufficient when passing by pointer/reference, but not when 
wanting to copy all the bits. Am I missing something here?


- Benjamin


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


On Nov. 28, 2016, 6:15 a.m., Benjamin Hindman wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53460/
> ---
> 
> (Updated Nov. 28, 2016, 6:15 a.m.)
> 
> 
> Review request for mesos, Benjamin Mahler and Jie Yu.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Also added unix::Address.
> 
> 
> Diffs
> -
> 
>   3rdparty/libprocess/Makefile.am 71319891a451bd1d565210dcce2fb61fc69e1f61 
>   3rdparty/libprocess/include/process/address.hpp 
> 04e3155d65f476208fa852e83b79d173b66288fd 
>   3rdparty/libprocess/include/process/network.hpp 
> 52110667185370a4c92e2fa524819ab1f34bdec9 
>   3rdparty/libprocess/include/process/socket.hpp 
> f798af7879546d71e8ef4a295c9cf489a70cb61f 
>   3rdparty/libprocess/include/process/ssl/gtest.hpp 
> 21a0fc45b55a368a21b3e616c751ab43eebd4902 
>   3rdparty/libprocess/src/address.cpp PRE-CREATION 
>   3rdparty/libprocess/src/libevent_ssl_socket.cpp 
> 5c0929d3d9f5595bd2f343b98b899fd6b06a67b2 
>   3rdparty/libprocess/src/poll_socket.cpp 
> eb7b48713edd30b545d7be95b5d51b0f71bd422a 
>   3rdparty/libprocess/src/process.cpp 
> e9a4bbb0b2410e0260d120b97e73972c94eb0f26 
>   3rdparty/libprocess/src/socket.cpp 7f93168e1572f8669f67a4c5e6e5467259b7a407 
>   3rdparty/libprocess/src/tests/socket_tests.cpp PRE-CREATION 
>   3rdparty/libprocess/src/tests/ssl_tests.cpp 
> 55c8c309571b1892b0acc4d766eda9bb98085a6f 
>   3rdparty/libprocess/src/tests/test_linkee.cpp 
> 1f6cfafcb73fd41ef350b13e3ac6023d78f16f5a 
> 
> Diff: https://reviews.apache.org/r/53460/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> 
> Thanks,
> 
> Benjamin Hindman
> 
>



Re: Review Request 53627: Implement a namespaces/uts isolator.

2016-11-29 Thread Avinash sridharan


> On Nov. 29, 2016, 6:48 p.m., Avinash sridharan wrote:
> > src/slave/containerizer/mesos/isolators/namespaces/uts.cpp, lines 70-79
> > 
> >
> > Wouldn't this conflict with what we are doing in the `network/cni` 
> > isolator. For containers with a `NetworkInfo` we end up creating a new UTS 
> > namespace in the `network/cni` isolator. More importantly the isolator sets 
> > the hostname to the `ContianerID` and also sets this information up in 
> > `/etc/hosts` for DNS to resolve correctly. 
> > 
> > Since the `network/cni` isolator is enabled by default, this would end 
> > up conflicting with the UTS isolator.

would it make sense to add support for `hostname` and `domainname` in the 
`network/cni` isolator and avoid having a separate UTS isolator? Or is the 
requirement to not use the CNI isolator (and use the port-mapping isolator) ?


- Avinash


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


On Nov. 28, 2016, 5:07 p.m., James Peach wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53627/
> ---
> 
> (Updated Nov. 28, 2016, 5:07 p.m.)
> 
> 
> Review request for mesos and Jie Yu.
> 
> 
> Bugs: MESOS-6556
> https://issues.apache.org/jira/browse/MESOS-6556
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Implement a very simple namespaces/uts isolator that can be used to set
> the hostname and domainname of a container without the necessity of a
> CNI plugin.
> 
> Since we already had a `hostname` field in the ContainerInfo, we can
> use that to set the host name once we are in the UTS namespace. Add a
> corresponding `domainname` to the ContainerInfo to allow setting the
> domain name.
> 
> 
> Diffs
> -
> 
>   include/mesos/mesos.proto cbfcd8a666e0b4a486f6dcd9e8356c9d5a1cea05 
>   include/mesos/slave/containerizer.proto 
> 2621522ae59cf9275f607679b4678ac54508993d 
>   src/Makefile.am 85eda538caf39f81f052896e744b7b0c724f81bb 
>   src/cli/execute.cpp ddf7ecac21f2680c3027fafeb4194a2dd4a66d47 
>   src/slave/containerizer/mesos/containerizer.cpp 
> 9b33495d9babc3ee489a8712fe1977746c41043f 
>   src/slave/containerizer/mesos/isolators/namespaces/uts.hpp PRE-CREATION 
>   src/slave/containerizer/mesos/isolators/namespaces/uts.cpp PRE-CREATION 
>   src/slave/containerizer/mesos/launch.hpp 
> 155e3c5a27b8c710971ee4b508600d3b5589a2e0 
>   src/slave/containerizer/mesos/launch.cpp 
> 320e42748adbabf09f77cb4f5951e2a7ea58fe64 
>   src/tests/containerizer/isolator_tests.cpp 
> 9766aaf144722b18d88f694ff37ffd53974cb60d 
> 
> Diff: https://reviews.apache.org/r/53627/diff/
> 
> 
> Testing
> ---
> 
> make check.
> 
> 
> Thanks,
> 
> James Peach
> 
>



Re: Review Request 54101: Removed MesosContainerizerLaunchTest.

2016-11-29 Thread Joseph Wu

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



```
commit a85e284013a10e0ca036ab16128530c8cfd17087
Author: Joseph Wu 
Date:   Tue Nov 29 11:58:09 2016 -0800

CMake: Removed launch_tests.cpp from the tests.

This test was removed in: https://reviews.apache.org/r/54101/
```

- Joseph Wu


On Nov. 26, 2016, 11:48 p.m., Jie Yu wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/54101/
> ---
> 
> (Updated Nov. 26, 2016, 11:48 p.m.)
> 
> 
> Review request for mesos, Gilbert Song and Kevin Klues.
> 
> 
> Bugs: MESOS-6648
> https://issues.apache.org/jira/browse/MESOS-6648
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> This test is not necessary as we already test that in linux filesystem
> isolator tests. This patch removes it.
> 
> 
> Diffs
> -
> 
>   src/Makefile.am dd1626d177b38a6613f18f32bb0668abbb5100e0 
>   src/tests/containerizer/launch_tests.cpp 
> 680c147198c84879c6ab728c65ea686379b216b7 
> 
> Diff: https://reviews.apache.org/r/54101/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> 
> Thanks,
> 
> Jie Yu
> 
>



Re: Review Request 54173: Refactor necessary after removing default Address constructor.

2016-11-29 Thread Jie Yu

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


Ship it!




Ship It!

- Jie Yu


On Nov. 29, 2016, 7:27 p.m., Benjamin Hindman wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/54173/
> ---
> 
> (Updated Nov. 29, 2016, 7:27 p.m.)
> 
> 
> Review request for mesos and Jie Yu.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Refactor necessary after removing default Address constructor.
> 
> 
> Diffs
> -
> 
>   3rdparty/libprocess/src/process.cpp 
> e9a4bbb0b2410e0260d120b97e73972c94eb0f26 
> 
> Diff: https://reviews.apache.org/r/54173/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> 
> Thanks,
> 
> Benjamin Hindman
> 
>



Re: Review Request 54129: Removed superseded `slavePreLaunchDockerEnvironmentDecorator` hook.

2016-11-29 Thread Till Toenshoff

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

(Updated Nov. 29, 2016, 7:54 p.m.)


Review request for mesos, Adam B and Kapil Arya.


Bugs: MESOS-6650
https://issues.apache.org/jira/browse/MESOS-6650


Repository: mesos


Description
---

see summary.


Diffs
-

  include/mesos/hook.hpp 134951ca5ee60d0cfb3cacd5ba2ae26420570d29 
  src/examples/test_hook_module.cpp 094a92b8133f4be3d9533510863d3361e0e9d23f 
  src/hook/manager.hpp ad52717fb043d03ca29063727656ebe1bbf55114 
  src/hook/manager.cpp 59f402b1f8f076b151b771b2b1ae89a3b4d34d5b 
  src/slave/containerizer/docker.cpp 5ce4667b61bb226f726beda6e21b839456e0b941 
  src/tests/hook_tests.cpp d334d6c5ff7f966d55b395bfbf4f25ee3fa2 

Diff: https://reviews.apache.org/r/54129/diff/


Testing
---

make check


Thanks,

Till Toenshoff



Re: Review Request 54174: Removed superseded `slavePreLaunchDockerHook` hook.

2016-11-29 Thread Till Toenshoff

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

(Updated Nov. 29, 2016, 7:54 p.m.)


Review request for mesos, Adam B, Benjamin Bannier, Gastón Kleiman, and Kapil 
Arya.


Bugs: MESOS-6650
https://issues.apache.org/jira/browse/MESOS-6650


Repository: mesos


Description
---

see summary.


Diffs
-

  include/mesos/hook.hpp 134951ca5ee60d0cfb3cacd5ba2ae26420570d29 
  src/examples/test_hook_module.cpp 094a92b8133f4be3d9533510863d3361e0e9d23f 
  src/hook/manager.hpp ad52717fb043d03ca29063727656ebe1bbf55114 
  src/hook/manager.cpp 59f402b1f8f076b151b771b2b1ae89a3b4d34d5b 
  src/slave/containerizer/docker.cpp 5ce4667b61bb226f726beda6e21b839456e0b941 

Diff: https://reviews.apache.org/r/54174/diff/


Testing
---

make check and sudo tests


Thanks,

Till Toenshoff



Review Request 54174: Removed superseded `slavePreLaunchDockerHook` hook.

2016-11-29 Thread Till Toenshoff

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

Review request for mesos, Adam B, Benjamin Bannier, Gastón Kleiman, and Kapil 
Arya.


Repository: mesos


Description
---

see summary.


Diffs
-

  include/mesos/hook.hpp 134951ca5ee60d0cfb3cacd5ba2ae26420570d29 
  src/examples/test_hook_module.cpp 094a92b8133f4be3d9533510863d3361e0e9d23f 
  src/hook/manager.hpp ad52717fb043d03ca29063727656ebe1bbf55114 
  src/hook/manager.cpp 59f402b1f8f076b151b771b2b1ae89a3b4d34d5b 
  src/slave/containerizer/docker.cpp 5ce4667b61bb226f726beda6e21b839456e0b941 

Diff: https://reviews.apache.org/r/54174/diff/


Testing
---

make check and sudo tests


Thanks,

Till Toenshoff



Re: Review Request 54129: Removed superseded `slavePreLaunchDockerEnvironmentDecorator` hook.

2016-11-29 Thread Till Toenshoff

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

(Updated Nov. 29, 2016, 7:52 p.m.)


Review request for mesos, Adam B and Kapil Arya.


Summary (updated)
-

Removed superseded `slavePreLaunchDockerEnvironmentDecorator` hook.


Bugs: MESOS-6396
https://issues.apache.org/jira/browse/MESOS-6396


Repository: mesos


Description
---

see summary.


Diffs (updated)
-

  include/mesos/hook.hpp 134951ca5ee60d0cfb3cacd5ba2ae26420570d29 
  src/examples/test_hook_module.cpp 094a92b8133f4be3d9533510863d3361e0e9d23f 
  src/hook/manager.hpp ad52717fb043d03ca29063727656ebe1bbf55114 
  src/hook/manager.cpp 59f402b1f8f076b151b771b2b1ae89a3b4d34d5b 
  src/slave/containerizer/docker.cpp 5ce4667b61bb226f726beda6e21b839456e0b941 
  src/tests/hook_tests.cpp d334d6c5ff7f966d55b395bfbf4f25ee3fa2 

Diff: https://reviews.apache.org/r/54129/diff/


Testing
---

make check


Thanks,

Till Toenshoff



Re: Review Request 54110: Added `process::loop` abstraction.

2016-11-29 Thread Michael Park


> On Nov. 28, 2016, 6:47 p.m., Benjamin Hindman wrote:
> > 3rdparty/libprocess/include/process/loop.hpp, line 137
> > 
> >
> > Future condition = true;
> > 
> > while (condition.get()) {
> >   Future next = discard_if_necessary(iterate());
> >   if (next.isReady()) {
> > condition = discard_if_necessary(body(next.get()));
> > if (condition.isReady()) {
> >   continue;
> > } else {
> >   block_on_condition();
> >   return;
> > }
> >   } else {
> > block_on_next();
> > return;
> >   }
> > }
> > 
> > promise.set(Nothing()); // All done!
> > 
> > 
> > 
> > void block_on_next()
> > {
> > next
> >   .onAny([]() {
> >   if (next.isReady()) {
> > condition = discard_if_necessary(body(next.get()));
> > if (condition.isReady()) {
> >   run(loop);
> > } else {
> >   block_on_condition();
> > }
> >   } else if (isDiscarded) {
> >   } else if (isFailed) {
> >   }
> >   });
> > 
> > }
> > 
> > 
> > void block_on_condition()
> > {
> >   condition
> > .onAny([]() {
> >   if (condition.isReady()) {
> > if (condition.get()) {
> >   run(loop);
> > } else {
> >   promise.set(Nothing());
> > }
> >   } else if (isDiscarded) {
> >   } else if (isFailed) {
> >   }
> > });
> > }

I think would suggest breaking this up into stages instead.
This approach removes duplicate code such as `body(next.get())`, handling of 
`condition` and `promise.set(Nothing())`.

The transitions are: `run` --`next.isReady`--> `run_body` 
--`condition.isReady`--> `run_condition`.

```cpp
template 
class Loop {
public:
  void run() {
// This is the tight loop that we ideally stay in. We leave
// if we're gonna be blocked by `next`, or if we're done.
for (;;) {
  next = propagate_discard(iterate());
  if (!next.isReady()) {
break;
  }
  if (!run_body()) {
return;
  }
}

// We're here because we're blocked on `next`,
// so let's defer a continuation on it.
next.onAny(defer(pid, [=](const Future&) {
  if (next.isReady()) {
if (run_body()) {
  run();
}
  } else if (next.isFailed()) {
promise.fail(next.failure());
  } else if (next.isDiscarded()) {
promise.discard();
  }
}));
  }
  
private:
  template 
  Future propagate_discard(Future future) const {
if (promise.future().hasDiscard()) {
  future.discard();
}
return future;
  }
  
  bool run_body() {
condition = propagate_discard(body(next.get()));

// This is the short-circuit. Ideally we go through here,
// but if the `condition` is blocked, then we proceed.
if (condition.isReady()) {
  return run_condition();
};

// We're here because we're blocked on `condition`,
// so let's defer a continuation on it.
condition.onAny(defer(pid, [=](const Future&) {
  if (condition.isReady()) {
if (run_condition()) {
  run();
}
  } else if (condition.isFailed()) {
promise.fail(next.failure());
  } else if (condition.isDiscarded()) {
promise.discard();
  }
}));

return false;
  }
  
  bool run_condition() {
bool cont = condition.get();
if (!cont) {
  promise.set(Nothing());
}
return cont;
  }
  
  /* members... */
};
```


- Michael


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


On Nov. 28, 2016, 10:33 a.m., Benjamin Hindman wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/54110/
> ---
> 
> (Updated Nov. 28, 2016, 10:33 a.m.)
> 
> 
> Review request for mesos, Benjamin Mahler and Michael Park.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Added `process::loop` abstraction.
> 
> 
> Diffs
> -
> 
>   3rdparty/libprocess/Makefile.am 71319891a451bd1d565210dcce2fb61fc69e1f61 
>   3rdparty/libprocess/include/process/loop.hpp PRE-CREATION 
>   3rdparty/libprocess/src/tests/loop_tests.cpp PRE-CREATION 
> 
> Diff: https://reviews.apache.org/r/54110/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> 
> Thanks,
> 
> Benjamin Hindman
> 
>



Re: Review Request 53627: Implement a namespaces/uts isolator.

2016-11-29 Thread James Peach


> On Nov. 29, 2016, 7:02 p.m., Avinash sridharan wrote:
> > src/slave/containerizer/mesos/launch.cpp, line 431
> > 
> >
> > Wouldn't we need to set up something in `/etc/hosts`. I believe DNS 
> > lookups on the hostname would fail if the `/etc/nsswitch.conf` does not 
> > have `myhostname` set in the `hosts` field.
> 
> James Peach wrote:
> There's no requirement for the hostname to be resolvable or map to any IP 
> address on the system. However, since the hostname is set by the framework, 
> one option could be to set it to the name of the service VIP.
> 
> Avinash sridharan wrote:
> I think libprocess might find this problematic. Currently libprocess 
> tries to resolve the `hostname` to an IP if no IP is explicitly provided:
> 
> https://github.com/apache/mesos/blob/1fc0551db54cd4492c3772d68212b9d7c6571728/3rdparty/libprocess/src/process.cpp#L1145
> 
> Setting the name to the service IP might not work since the service IP 
> (as I understand) could be a virtual IP and might not exist on the host, and 
> for libprocess this needs to be a "bindable" IP. I am assuming you were 
> implying that by setting the name to the service VIP the hostname can be 
> resolved through DNS?

I'd call that libprocess code optimistic :)


- James


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


On Nov. 28, 2016, 5:07 p.m., James Peach wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53627/
> ---
> 
> (Updated Nov. 28, 2016, 5:07 p.m.)
> 
> 
> Review request for mesos and Jie Yu.
> 
> 
> Bugs: MESOS-6556
> https://issues.apache.org/jira/browse/MESOS-6556
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Implement a very simple namespaces/uts isolator that can be used to set
> the hostname and domainname of a container without the necessity of a
> CNI plugin.
> 
> Since we already had a `hostname` field in the ContainerInfo, we can
> use that to set the host name once we are in the UTS namespace. Add a
> corresponding `domainname` to the ContainerInfo to allow setting the
> domain name.
> 
> 
> Diffs
> -
> 
>   include/mesos/mesos.proto cbfcd8a666e0b4a486f6dcd9e8356c9d5a1cea05 
>   include/mesos/slave/containerizer.proto 
> 2621522ae59cf9275f607679b4678ac54508993d 
>   src/Makefile.am 85eda538caf39f81f052896e744b7b0c724f81bb 
>   src/cli/execute.cpp ddf7ecac21f2680c3027fafeb4194a2dd4a66d47 
>   src/slave/containerizer/mesos/containerizer.cpp 
> 9b33495d9babc3ee489a8712fe1977746c41043f 
>   src/slave/containerizer/mesos/isolators/namespaces/uts.hpp PRE-CREATION 
>   src/slave/containerizer/mesos/isolators/namespaces/uts.cpp PRE-CREATION 
>   src/slave/containerizer/mesos/launch.hpp 
> 155e3c5a27b8c710971ee4b508600d3b5589a2e0 
>   src/slave/containerizer/mesos/launch.cpp 
> 320e42748adbabf09f77cb4f5951e2a7ea58fe64 
>   src/tests/containerizer/isolator_tests.cpp 
> 9766aaf144722b18d88f694ff37ffd53974cb60d 
> 
> Diff: https://reviews.apache.org/r/53627/diff/
> 
> 
> Testing
> ---
> 
> make check.
> 
> 
> Thanks,
> 
> James Peach
> 
>



Re: Review Request 53627: Implement a namespaces/uts isolator.

2016-11-29 Thread Avinash sridharan


> On Nov. 29, 2016, 7:02 p.m., Avinash sridharan wrote:
> > src/slave/containerizer/mesos/launch.cpp, line 431
> > 
> >
> > Wouldn't we need to set up something in `/etc/hosts`. I believe DNS 
> > lookups on the hostname would fail if the `/etc/nsswitch.conf` does not 
> > have `myhostname` set in the `hosts` field.
> 
> James Peach wrote:
> There's no requirement for the hostname to be resolvable or map to any IP 
> address on the system. However, since the hostname is set by the framework, 
> one option could be to set it to the name of the service VIP.

I think libprocess might find this problematic. Currently libprocess tries to 
resolve the `hostname` to an IP if no IP is explicitly provided:
https://github.com/apache/mesos/blob/1fc0551db54cd4492c3772d68212b9d7c6571728/3rdparty/libprocess/src/process.cpp#L1145

Setting the name to the service IP might not work since the service IP (as I 
understand) could be a virtual IP and might not exist on the host, and for 
libprocess this needs to be a "bindable" IP. I am assuming you were implying 
that by setting the name to the service VIP the hostname can be resolved 
through DNS?


- Avinash


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


On Nov. 28, 2016, 5:07 p.m., James Peach wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53627/
> ---
> 
> (Updated Nov. 28, 2016, 5:07 p.m.)
> 
> 
> Review request for mesos and Jie Yu.
> 
> 
> Bugs: MESOS-6556
> https://issues.apache.org/jira/browse/MESOS-6556
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Implement a very simple namespaces/uts isolator that can be used to set
> the hostname and domainname of a container without the necessity of a
> CNI plugin.
> 
> Since we already had a `hostname` field in the ContainerInfo, we can
> use that to set the host name once we are in the UTS namespace. Add a
> corresponding `domainname` to the ContainerInfo to allow setting the
> domain name.
> 
> 
> Diffs
> -
> 
>   include/mesos/mesos.proto cbfcd8a666e0b4a486f6dcd9e8356c9d5a1cea05 
>   include/mesos/slave/containerizer.proto 
> 2621522ae59cf9275f607679b4678ac54508993d 
>   src/Makefile.am 85eda538caf39f81f052896e744b7b0c724f81bb 
>   src/cli/execute.cpp ddf7ecac21f2680c3027fafeb4194a2dd4a66d47 
>   src/slave/containerizer/mesos/containerizer.cpp 
> 9b33495d9babc3ee489a8712fe1977746c41043f 
>   src/slave/containerizer/mesos/isolators/namespaces/uts.hpp PRE-CREATION 
>   src/slave/containerizer/mesos/isolators/namespaces/uts.cpp PRE-CREATION 
>   src/slave/containerizer/mesos/launch.hpp 
> 155e3c5a27b8c710971ee4b508600d3b5589a2e0 
>   src/slave/containerizer/mesos/launch.cpp 
> 320e42748adbabf09f77cb4f5951e2a7ea58fe64 
>   src/tests/containerizer/isolator_tests.cpp 
> 9766aaf144722b18d88f694ff37ffd53974cb60d 
> 
> Diff: https://reviews.apache.org/r/53627/diff/
> 
> 
> Testing
> ---
> 
> make check.
> 
> 
> Thanks,
> 
> James Peach
> 
>



Re: Review Request 53627: Implement a namespaces/uts isolator.

2016-11-29 Thread James Peach


> On Nov. 29, 2016, 7:02 p.m., Avinash sridharan wrote:
> > src/slave/containerizer/mesos/launch.cpp, line 431
> > 
> >
> > Wouldn't we need to set up something in `/etc/hosts`. I believe DNS 
> > lookups on the hostname would fail if the `/etc/nsswitch.conf` does not 
> > have `myhostname` set in the `hosts` field.

There's no requirement for the hostname to be resolvable or map to any IP 
address on the system. However, since the hostname is set by the framework, one 
option could be to set it to the name of the service VIP.


- James


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


On Nov. 28, 2016, 5:07 p.m., James Peach wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53627/
> ---
> 
> (Updated Nov. 28, 2016, 5:07 p.m.)
> 
> 
> Review request for mesos and Jie Yu.
> 
> 
> Bugs: MESOS-6556
> https://issues.apache.org/jira/browse/MESOS-6556
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Implement a very simple namespaces/uts isolator that can be used to set
> the hostname and domainname of a container without the necessity of a
> CNI plugin.
> 
> Since we already had a `hostname` field in the ContainerInfo, we can
> use that to set the host name once we are in the UTS namespace. Add a
> corresponding `domainname` to the ContainerInfo to allow setting the
> domain name.
> 
> 
> Diffs
> -
> 
>   include/mesos/mesos.proto cbfcd8a666e0b4a486f6dcd9e8356c9d5a1cea05 
>   include/mesos/slave/containerizer.proto 
> 2621522ae59cf9275f607679b4678ac54508993d 
>   src/Makefile.am 85eda538caf39f81f052896e744b7b0c724f81bb 
>   src/cli/execute.cpp ddf7ecac21f2680c3027fafeb4194a2dd4a66d47 
>   src/slave/containerizer/mesos/containerizer.cpp 
> 9b33495d9babc3ee489a8712fe1977746c41043f 
>   src/slave/containerizer/mesos/isolators/namespaces/uts.hpp PRE-CREATION 
>   src/slave/containerizer/mesos/isolators/namespaces/uts.cpp PRE-CREATION 
>   src/slave/containerizer/mesos/launch.hpp 
> 155e3c5a27b8c710971ee4b508600d3b5589a2e0 
>   src/slave/containerizer/mesos/launch.cpp 
> 320e42748adbabf09f77cb4f5951e2a7ea58fe64 
>   src/tests/containerizer/isolator_tests.cpp 
> 9766aaf144722b18d88f694ff37ffd53974cb60d 
> 
> Diff: https://reviews.apache.org/r/53627/diff/
> 
> 
> Testing
> ---
> 
> make check.
> 
> 
> Thanks,
> 
> James Peach
> 
>



Review Request 54173: Refactor necessary after removing default Address constructor.

2016-11-29 Thread Benjamin Hindman

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

Review request for mesos and Jie Yu.


Repository: mesos


Description
---

Refactor necessary after removing default Address constructor.


Diffs
-

  3rdparty/libprocess/src/process.cpp e9a4bbb0b2410e0260d120b97e73972c94eb0f26 

Diff: https://reviews.apache.org/r/54173/diff/


Testing
---

make check


Thanks,

Benjamin Hindman



Re: Review Request 54099: Used environment to pass flags to launch helper.

2016-11-29 Thread Jie Yu


> On Nov. 28, 2016, 10:39 p.m., Kevin Klues wrote:
> > src/slave/containerizer/mesos/containerizer.cpp, lines 1559-1570
> > 
> >
> > Hmm. As it is written, an environment variable set on the agent will 
> > override any environment variables we set up via our launchFlags. Is this 
> > the intended behaviour?
> > 
> > It seems like this could lead to unexpected consequences if (for 
> > example), we happen to have `MESOS_CONTAINERIZER_USER=root` set when we 
> > launch our agent.

Will reverse the order to be more fail proof.


- Jie


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


On Nov. 27, 2016, 7:47 a.m., Jie Yu wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/54099/
> ---
> 
> (Updated Nov. 27, 2016, 7:47 a.m.)
> 
> 
> Review request for mesos, Gilbert Song and Kevin Klues.
> 
> 
> Bugs: MESOS-6648
> https://issues.apache.org/jira/browse/MESOS-6648
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Instead of doing that just for command environment variables, this
> patch does it consistently by using environment variables to pass
> launch helper flags. This will be more secure.
> 
> 
> Diffs
> -
> 
>   src/slave/containerizer/mesos/containerizer.cpp 
> 9b33495d9babc3ee489a8712fe1977746c41043f 
> 
> Diff: https://reviews.apache.org/r/54099/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> 
> Thanks,
> 
> Jie Yu
> 
>



Re: Review Request 54167: Removed cyclic header dependency in libprocess.

2016-11-29 Thread Mesos ReviewBot

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



Patch looks great!

Reviews applied: [54167]

Passed command: export OS='ubuntu:14.04' BUILDTOOL='autotools' COMPILER='gcc' 
CONFIGURATION='--verbose' ENVIRONMENT='GLOG_v=1 MESOS_VERBOSE=1'; 
./support/docker_build.sh

- Mesos ReviewBot


On Nov. 29, 2016, 3:59 p.m., Ilya Pronin wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/54167/
> ---
> 
> (Updated Nov. 29, 2016, 3:59 p.m.)
> 
> 
> Review request for mesos, Benjamin Bannier and Benjamin Mahler.
> 
> 
> Bugs: MESOS-6647
> https://issues.apache.org/jira/browse/MESOS-6647
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> `executor.hpp` doesn't need anything from `defer.hpp` but defines a macro 
> that is used in it.
> 
> 
> Diffs
> -
> 
>   3rdparty/libprocess/include/process/executor.hpp 
> 48c1b34b6bd117653c1728321cf96b909e535964 
> 
> Diff: https://reviews.apache.org/r/54167/diff/
> 
> 
> Testing
> ---
> 
> ```
> make && make check
> ```
> 
> 
> Thanks,
> 
> Ilya Pronin
> 
>



Re: Review Request 53627: Implement a namespaces/uts isolator.

2016-11-29 Thread Avinash sridharan

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




src/slave/containerizer/mesos/launch.cpp (line 431)


Wouldn't we need to set up something in `/etc/hosts`. I believe DNS lookups 
on the hostname would fail if the `/etc/nsswitch.conf` does not have 
`myhostname` set in the `hosts` field.


- Avinash sridharan


On Nov. 28, 2016, 5:07 p.m., James Peach wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53627/
> ---
> 
> (Updated Nov. 28, 2016, 5:07 p.m.)
> 
> 
> Review request for mesos and Jie Yu.
> 
> 
> Bugs: MESOS-6556
> https://issues.apache.org/jira/browse/MESOS-6556
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Implement a very simple namespaces/uts isolator that can be used to set
> the hostname and domainname of a container without the necessity of a
> CNI plugin.
> 
> Since we already had a `hostname` field in the ContainerInfo, we can
> use that to set the host name once we are in the UTS namespace. Add a
> corresponding `domainname` to the ContainerInfo to allow setting the
> domain name.
> 
> 
> Diffs
> -
> 
>   include/mesos/mesos.proto cbfcd8a666e0b4a486f6dcd9e8356c9d5a1cea05 
>   include/mesos/slave/containerizer.proto 
> 2621522ae59cf9275f607679b4678ac54508993d 
>   src/Makefile.am 85eda538caf39f81f052896e744b7b0c724f81bb 
>   src/cli/execute.cpp ddf7ecac21f2680c3027fafeb4194a2dd4a66d47 
>   src/slave/containerizer/mesos/containerizer.cpp 
> 9b33495d9babc3ee489a8712fe1977746c41043f 
>   src/slave/containerizer/mesos/isolators/namespaces/uts.hpp PRE-CREATION 
>   src/slave/containerizer/mesos/isolators/namespaces/uts.cpp PRE-CREATION 
>   src/slave/containerizer/mesos/launch.hpp 
> 155e3c5a27b8c710971ee4b508600d3b5589a2e0 
>   src/slave/containerizer/mesos/launch.cpp 
> 320e42748adbabf09f77cb4f5951e2a7ea58fe64 
>   src/tests/containerizer/isolator_tests.cpp 
> 9766aaf144722b18d88f694ff37ffd53974cb60d 
> 
> Diff: https://reviews.apache.org/r/53627/diff/
> 
> 
> Testing
> ---
> 
> make check.
> 
> 
> Thanks,
> 
> James Peach
> 
>



Re: Review Request 53627: Implement a namespaces/uts isolator.

2016-11-29 Thread Avinash sridharan

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




src/slave/containerizer/mesos/isolators/namespaces/uts.cpp (lines 70 - 79)


Wouldn't this conflict with what we are doing in the `network/cni` 
isolator. For containers with a `NetworkInfo` we end up creating a new UTS 
namespace in the `network/cni` isolator. More importantly the isolator sets the 
hostname to the `ContianerID` and also sets this information up in `/etc/hosts` 
for DNS to resolve correctly. 

Since the `network/cni` isolator is enabled by default, this would end up 
conflicting with the UTS isolator.


- Avinash sridharan


On Nov. 28, 2016, 5:07 p.m., James Peach wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53627/
> ---
> 
> (Updated Nov. 28, 2016, 5:07 p.m.)
> 
> 
> Review request for mesos and Jie Yu.
> 
> 
> Bugs: MESOS-6556
> https://issues.apache.org/jira/browse/MESOS-6556
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Implement a very simple namespaces/uts isolator that can be used to set
> the hostname and domainname of a container without the necessity of a
> CNI plugin.
> 
> Since we already had a `hostname` field in the ContainerInfo, we can
> use that to set the host name once we are in the UTS namespace. Add a
> corresponding `domainname` to the ContainerInfo to allow setting the
> domain name.
> 
> 
> Diffs
> -
> 
>   include/mesos/mesos.proto cbfcd8a666e0b4a486f6dcd9e8356c9d5a1cea05 
>   include/mesos/slave/containerizer.proto 
> 2621522ae59cf9275f607679b4678ac54508993d 
>   src/Makefile.am 85eda538caf39f81f052896e744b7b0c724f81bb 
>   src/cli/execute.cpp ddf7ecac21f2680c3027fafeb4194a2dd4a66d47 
>   src/slave/containerizer/mesos/containerizer.cpp 
> 9b33495d9babc3ee489a8712fe1977746c41043f 
>   src/slave/containerizer/mesos/isolators/namespaces/uts.hpp PRE-CREATION 
>   src/slave/containerizer/mesos/isolators/namespaces/uts.cpp PRE-CREATION 
>   src/slave/containerizer/mesos/launch.hpp 
> 155e3c5a27b8c710971ee4b508600d3b5589a2e0 
>   src/slave/containerizer/mesos/launch.cpp 
> 320e42748adbabf09f77cb4f5951e2a7ea58fe64 
>   src/tests/containerizer/isolator_tests.cpp 
> 9766aaf144722b18d88f694ff37ffd53974cb60d 
> 
> Diff: https://reviews.apache.org/r/53627/diff/
> 
> 
> Testing
> ---
> 
> make check.
> 
> 
> Thanks,
> 
> James Peach
> 
>



Re: Review Request 53897: Changed how master represents "recovered" frameworks.

2016-11-29 Thread Neil Conway

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

(Updated Nov. 29, 2016, 5:55 p.m.)


Review request for mesos and Vinod Kone.


Changes
---

Tweak test code.


Bugs: MESOS-6419
https://issues.apache.org/jira/browse/MESOS-6419


Repository: mesos


Description
---

After master failover, the new master doesn't know which frameworks were
registered with the previous master (because this information is not
currently stored in the registry). In the period after the master fails
over but before the framework scheduler has re-registered, the master
learns about the frameworks in the cluster when agents re-register (an
agent reports the FrameworkInfo for all of the frameworks it is running
when it re-registers).

Such frameworks were previously represented separately from the normal
list of frameworks in the master: the master kept a collection of
`FrameworkInfo` for these "recovered" frameworks.

This commit removes this separate collection of "recovered" frameworks.
Instead, the master now treats recovered frameworks very similarly to
frameworks that are registered but currently disconnected. For example,
recovered frameworks will now have a `Framework` object which tracks the
tasks/executors running under that framework; recovered frameworks will
be reported via the normal "frameworks" key when querying HTTP
endpoints. Similarly, "teardown" operations on recovered frameworks will
now work correctly (MESOS-6419).

This means there is no longer a concept of "orphan tasks" [1]: if the
master knows about a task, the task will be running under a framework
(albeit the framework might be recovered or disconnected). A new
"recovered" key has been added to various HTTP endpoints/APIs to
determine if a framework hasn't yet re-registered after master failover.

[1] The exception here is if the cluster contains Mesos agents older
than 1.0, because old Mesos agents don't report `FrameworkInfo`s when
they re-register.


Diffs (updated)
-

  include/mesos/master/master.proto 3553c683c17004ac1831ec90271aa8584c950e53 
  include/mesos/v1/master/master.proto 022b491b7d5c49c5aeddf4ffc97c148f55629c95 
  src/master/http.cpp 90cbed1ba411e18906fe9c26bc14576a26d1b7b9 
  src/master/master.hpp b6c610b79aab146ece6b9be59be86f283d1c9ee8 
  src/master/master.cpp e03a2e8025943825a2902102c43dc0eb66bacb6a 
  src/tests/api_tests.cpp b2a70f3174824d3cb241a098d96e4d63a390f8bc 
  src/tests/fault_tolerance_tests.cpp 1ade7faee56d394de30b798982dbb6e32f81 
  src/tests/master_allocator_tests.cpp bb94e38d5bb472801366c172cfc036f2eecdcbcb 
  src/tests/master_authorization_tests.cpp 
06c6e47250003cd467bf37e1daa8bd636ef8fef5 
  src/tests/master_tests.cpp dfedbbdf78e8054813872e9eeebccc7504097751 
  src/tests/partition_tests.cpp 5a0d4bd2de6a5aa0e9fdf0d34cd10d16fd4e34a1 
  src/tests/teardown_tests.cpp 0babf8c99f133c3f0dada772bd5cd2601c47a080 

Diff: https://reviews.apache.org/r/53897/diff/


Testing
---

`make check`


Thanks,

Neil Conway



Re: Review Request 54165: Fixed conflict in hook result handling.

2016-11-29 Thread Mesos ReviewBot

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



Patch looks great!

Reviews applied: [54165]

Passed command: export OS='ubuntu:14.04' BUILDTOOL='autotools' COMPILER='gcc' 
CONFIGURATION='--verbose' ENVIRONMENT='GLOG_v=1 MESOS_VERBOSE=1'; 
./support/docker_build.sh

- Mesos ReviewBot


On Nov. 29, 2016, 4:37 p.m., Till Toenshoff wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/54165/
> ---
> 
> (Updated Nov. 29, 2016, 4:37 p.m.)
> 
> 
> Review request for mesos, Adam B, Benjamin Bannier, Gastón Kleiman, and Kapil 
> Arya.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> see summary.
> 
> 
> Diffs
> -
> 
>   src/slave/containerizer/docker.cpp 5ce4667b61bb226f726beda6e21b839456e0b941 
> 
> Diff: https://reviews.apache.org/r/54165/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> 
> Thanks,
> 
> Till Toenshoff
> 
>



Re: Review Request 54128: Added test for `slavePreLaunchDockerTaskExecutorDecorator` hook.

2016-11-29 Thread Till Toenshoff

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

(Updated Nov. 29, 2016, 4:38 p.m.)


Review request for mesos, Adam B, Gastón Kleiman, and Kapil Arya.


Bugs: MESOS-6396
https://issues.apache.org/jira/browse/MESOS-6396


Repository: mesos


Description (updated)
---

see summary.


Diffs
-

  src/examples/test_hook_module.cpp 5e91a71f2450cf3c37eb9039ef28c026095c917e 
  src/tests/hook_tests.cpp d334d6c5ff7f966d55b395bfbf4f25ee3fa2 

Diff: https://reviews.apache.org/r/54128/diff/


Testing (updated)
---

make check and sudo tests


Thanks,

Till Toenshoff



Re: Review Request 54165: Fixed conflict in hook result handling.

2016-11-29 Thread Till Toenshoff

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

(Updated Nov. 29, 2016, 4:37 p.m.)


Review request for mesos, Adam B, Benjamin Bannier, Gastón Kleiman, and Kapil 
Arya.


Changes
---

Small code readability fix.


Repository: mesos


Description
---

see summary.


Diffs (updated)
-

  src/slave/containerizer/docker.cpp 5ce4667b61bb226f726beda6e21b839456e0b941 

Diff: https://reviews.apache.org/r/54165/diff/


Testing
---

make check


Thanks,

Till Toenshoff



Re: Review Request 52695: Harden libprocess

2016-11-29 Thread Aaron Wood

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

(Updated Nov. 29, 2016, 4:26 p.m.)


Review request for mesos, James Peach, Michael Park, and Neil Conway.


Changes
---

Changed version of macro to work with CentOS 6.


Bugs: MESOS-6229
https://issues.apache.org/jira/browse/MESOS-6229


Repository: mesos


Description (updated)
---

Add hardened flags for libprocess.
Take compile flag macro at 391cb680171d3889965b1ead43d3a326c913bc25.
The macro at 1a869696e4129279f7b99c3f9052717354b79a86 requires autoconf 2.64 
which breaks on CentOS 6.


Diffs (updated)
-

  3rdparty/libprocess/Makefile.am 7131989 
  3rdparty/libprocess/configure.ac e65e5ca 
  3rdparty/libprocess/m4/ax_check_compile_flag.m4 PRE-CREATION 

Diff: https://reviews.apache.org/r/52695/diff/


Testing
---

Compared the benchmarks with and without the flags being used. Also did a 
comparsion with the flags being used with and without optimizations and without 
the flags being used with and without optimizations. Overall the performance 
hit was very small with a 3-8% overhead (optimizations brings this down 
slightly). Most benchmarks were about 5% (or less) slower.


File Attachments


--enable-optimized with hardening applied
  
https://reviews.apache.org/media/uploaded/files/2016/11/02/875c9e6e-c73b-4e3c-8265-0f7c6dc00351__hardened-optimized.txt
Hardening applied but no --enable-optimized
  
https://reviews.apache.org/media/uploaded/files/2016/11/02/932d28a7-2d31-471a-b438-647841a6853c__hardened-unoptimized.txt
--enable-optimized with no hardening applied
  
https://reviews.apache.org/media/uploaded/files/2016/11/02/896944ea-9b31-4d62-b1b9-97fb4700a882__optimized.txt
No hardening applied and no --enable-optimized
  
https://reviews.apache.org/media/uploaded/files/2016/11/02/b32667ce-3e3b-4d2b-b4f8-4c2404a0fc1c__unoptimized.txt


Thanks,

Aaron Wood



Re: Review Request 52696: Harden stout

2016-11-29 Thread Aaron Wood

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

(Updated Nov. 29, 2016, 4:24 p.m.)


Review request for mesos, James Peach, Michael Park, and Neil Conway.


Changes
---

Changed the version of the macro to work with CentOS 6.


Bugs: MESOS-6229
https://issues.apache.org/jira/browse/MESOS-6229


Repository: mesos


Description (updated)
---

Add hardened flags for stout.
Take compile flag macro at 391cb680171d3889965b1ead43d3a326c913bc25.
The macro at 1a869696e4129279f7b99c3f9052717354b79a86 requires autoconf 2.64 
which breaks on CentOS 6.


Diffs (updated)
-

  3rdparty/stout/Makefile.am 4e10ae2 
  3rdparty/stout/configure.ac f071f61 
  3rdparty/stout/m4/ax_check_compile_flag.m4 PRE-CREATION 

Diff: https://reviews.apache.org/r/52696/diff/


Testing
---

Compared the benchmarks with and without the flags being used. Also did a 
comparsion with the flags being used with and without optimizations and without 
the flags being used with and without optimizations. Overall the performance 
hit was very small with a 3-8% overhead (optimizations brings this down 
slightly). Most benchmarks were about 5% (or less) slower.


File Attachments


--enable-optimized with hardening applied
  
https://reviews.apache.org/media/uploaded/files/2016/11/02/18a2f590-75ad-49c5-a697-56b746f28cae__hardened-optimized.txt
Hardening applied but no --enable-optimized
  
https://reviews.apache.org/media/uploaded/files/2016/11/02/a6e07766-80cc-4bd7-856d-8952cac12562__hardened-unoptimized.txt
--enable-optimized with no hardening applied
  
https://reviews.apache.org/media/uploaded/files/2016/11/02/046b37a9-5aff-4543-b3bb-5ac60daaf498__optimized.txt
No hardening applied and no --enable-optimized
  
https://reviews.apache.org/media/uploaded/files/2016/11/02/3baa96cf-be05-4ac0-ad4c-ef571386e8f4__unoptimized.txt


Thanks,

Aaron Wood



Re: Review Request 52645: Harden Mesos

2016-11-29 Thread Aaron Wood

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

(Updated Nov. 29, 2016, 4:21 p.m.)


Review request for mesos, James Peach, Michael Park, and Neil Conway.


Bugs: MESOS-6229
https://issues.apache.org/jira/browse/MESOS-6229


Repository: mesos


Description
---

Add hardened flags for Mesos.
Take compile flag macro at 391cb680171d3889965b1ead43d3a326c913bc25.
The macro at 1a869696e4129279f7b99c3f9052717354b79a86 requires autoconf 2.64 
which breaks on CentOS 6.


Diffs (updated)
-

  configure.ac 5380cbc 
  m4/ax_check_compile_flag.m4 PRE-CREATION 
  src/Makefile.am 85eda53 

Diff: https://reviews.apache.org/r/52645/diff/


Testing
---

Compared the benchmarks with and without the flags being used. Also did a 
comparsion with the flags being used with and without optimizations and without 
the flags being used with and without optimizations. Overall the performance 
hit was very small with a 3-8% overhead (optimizations brings this down 
slightly). Most benchmarks were about 5% (or less) slower.


Thanks,

Aaron Wood



Re: Review Request 54165: Fixed conflict in hook result handling.

2016-11-29 Thread Benjamin Bannier

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


Ship it!




- Benjamin Bannier


On Nov. 29, 2016, 4:32 p.m., Till Toenshoff wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/54165/
> ---
> 
> (Updated Nov. 29, 2016, 4:32 p.m.)
> 
> 
> Review request for mesos, Adam B, Benjamin Bannier, Gastón Kleiman, and Kapil 
> Arya.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> see summary.
> 
> 
> Diffs
> -
> 
>   src/slave/containerizer/docker.cpp 5ce4667b61bb226f726beda6e21b839456e0b941 
> 
> Diff: https://reviews.apache.org/r/54165/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> 
> Thanks,
> 
> Till Toenshoff
> 
>



Re: Review Request 52645: Harden Mesos

2016-11-29 Thread Aaron Wood

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

(Updated Nov. 29, 2016, 4:15 p.m.)


Review request for mesos, James Peach, Michael Park, and Neil Conway.


Bugs: MESOS-6229
https://issues.apache.org/jira/browse/MESOS-6229


Repository: mesos


Description (updated)
---

Add hardened flags for Mesos.
Take compile flag macro at 391cb680171d3889965b1ead43d3a326c913bc25.
The macro at 1a869696e4129279f7b99c3f9052717354b79a86 requires autoconf 2.64 
which breaks on CentOS 6.


Diffs
-

  configure.ac 5380cbc 
  m4/ax_check_compile_flag.m4 PRE-CREATION 
  src/Makefile.am 85eda53 

Diff: https://reviews.apache.org/r/52645/diff/


Testing
---

Compared the benchmarks with and without the flags being used. Also did a 
comparsion with the flags being used with and without optimizations and without 
the flags being used with and without optimizations. Overall the performance 
hit was very small with a 3-8% overhead (optimizations brings this down 
slightly). Most benchmarks were about 5% (or less) slower.


Thanks,

Aaron Wood



Re: Review Request 52645: Harden Mesos

2016-11-29 Thread Aaron Wood

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

(Updated Nov. 29, 2016, 4:13 p.m.)


Review request for mesos, James Peach, Michael Park, and Neil Conway.


Changes
---

Changed the version of the macro (taken from 
391cb680171d3889965b1ead43d3a326c913bc25)


Bugs: MESOS-6229
https://issues.apache.org/jira/browse/MESOS-6229


Repository: mesos


Description (updated)
---

Add hardened flags for Mesos.
Take compile flag macro at 391cb680171d3889965b1ead43d3a326c913bc25.


Diffs (updated)
-

  configure.ac 5380cbc 
  m4/ax_check_compile_flag.m4 PRE-CREATION 
  src/Makefile.am 85eda53 

Diff: https://reviews.apache.org/r/52645/diff/


Testing
---

Compared the benchmarks with and without the flags being used. Also did a 
comparsion with the flags being used with and without optimizations and without 
the flags being used with and without optimizations. Overall the performance 
hit was very small with a 3-8% overhead (optimizations brings this down 
slightly). Most benchmarks were about 5% (or less) slower.


Thanks,

Aaron Wood



Re: Review Request 54167: Removed cyclic header dependency in libprocess.

2016-11-29 Thread Benjamin Bannier

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


Ship it!




Ship It!

- Benjamin Bannier


On Nov. 29, 2016, 4:39 p.m., Ilya Pronin wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/54167/
> ---
> 
> (Updated Nov. 29, 2016, 4:39 p.m.)
> 
> 
> Review request for mesos and Benjamin Bannier.
> 
> 
> Bugs: MESOS-6647
> https://issues.apache.org/jira/browse/MESOS-6647
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> `executor.hpp` doesn't need anything from `defer.hpp` but defines a macro 
> that is used in it.
> 
> 
> Diffs
> -
> 
>   3rdparty/libprocess/include/process/executor.hpp 
> 48c1b34b6bd117653c1728321cf96b909e535964 
> 
> Diff: https://reviews.apache.org/r/54167/diff/
> 
> 
> Testing
> ---
> 
> ```
> make && make check
> ```
> 
> 
> Thanks,
> 
> Ilya Pronin
> 
>



Re: Review Request 54167: Removed cyclic header dependency in libprocess.

2016-11-29 Thread Ilya Pronin

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

(Updated Nov. 29, 2016, 3:39 p.m.)


Review request for mesos and Benjamin Bannier.


Bugs: MESOS-6647
https://issues.apache.org/jira/browse/MESOS-6647


Repository: mesos


Description (updated)
---

`executor.hpp` doesn't need anything from `defer.hpp` but defines a macro that 
is used in it.


Diffs
-

  3rdparty/libprocess/include/process/executor.hpp 
48c1b34b6bd117653c1728321cf96b909e535964 

Diff: https://reviews.apache.org/r/54167/diff/


Testing
---

```
make && make check
```


Thanks,

Ilya Pronin



Review Request 54165: Fixed conflict in hook result handling.

2016-11-29 Thread Till Toenshoff

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

Review request for mesos, Adam B, Benjamin Bannier, Gastón Kleiman, and Kapil 
Arya.


Repository: mesos


Description
---

see summary.


Diffs
-

  src/slave/containerizer/docker.cpp 5ce4667b61bb226f726beda6e21b839456e0b941 

Diff: https://reviews.apache.org/r/54165/diff/


Testing
---

make check


Thanks,

Till Toenshoff



Review Request 54167: Removed cyclic header dependency in libprocess.

2016-11-29 Thread Ilya Pronin

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

Review request for mesos and Benjamin Bannier.


Bugs: MESOS-6647
https://issues.apache.org/jira/browse/MESOS-6647


Repository: mesos


Description
---

Removed cyclic header dependency in libprocess.


Diffs
-

  3rdparty/libprocess/include/process/executor.hpp 
48c1b34b6bd117653c1728321cf96b909e535964 

Diff: https://reviews.apache.org/r/54167/diff/


Testing
---

```
make && make check
```


Thanks,

Ilya Pronin



Re: Review Request 53541: Added authorization actions for Nested Container and Debug API.

2016-11-29 Thread Alexander Rojas

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

(Updated Nov. 29, 2016, 4:18 p.m.)


Review request for mesos, Adam B, Kapil Arya, Kevin Klues, and Till Toenshoff.


Bugs: MESOS-6474
https://issues.apache.org/jira/browse/MESOS-6474


Repository: mesos


Description
---

Creates new authorization action for all the API's related to
nested containers. This patch does not add the code necesary to
call use those actions, this is done in a latter patch.


Diffs (updated)
-

  include/mesos/authorizer/acls.proto e3fd6a4a1b617a75714ebd6e08ab10cffa1a7d1b 
  include/mesos/authorizer/authorizer.hpp 
3cd0f84e25c0ea91a6f20eba26341a1b830d8cf2 
  include/mesos/authorizer/authorizer.proto 
0696a629ac2d2b9950e20708f0c3666b58ff7ca0 
  src/authorizer/local/authorizer.cpp 77e05dd2475d6e7511e7c7eeea578ec31ff3d198 
  src/tests/authorization_tests.cpp d23f551c2caa454da0c0f6cb7d77a8c2bd75a474 

Diff: https://reviews.apache.org/r/53541/diff/


Testing
---

make check


Thanks,

Alexander Rojas



Re: Review Request 53541: Added authorization actions for Nested Container and Debug API.

2016-11-29 Thread Alexander Rojas


> On Nov. 29, 2016, 10:47 a.m., Adam B wrote:
> > src/authorizer/local/authorizer.cpp, line 471
> > 
> >
> > Why check the command_info? It's optional either way, so leave it out. 
> > Your current logic would allow an executor_info without a framework_info 
> > (or vice versa) as long as there's a command_info. I don't think that's 
> > what we want. I assumed you were trying to check that if there's an object 
> > present, then it should have both executor_info and framework_info.

I will just remove the whole check here


> On Nov. 29, 2016, 10:47 a.m., Adam B wrote:
> > src/authorizer/local/authorizer.cpp, lines 468-471
> > 
> >
> > When will object ever be None?

Not at this point.


> On Nov. 29, 2016, 10:47 a.m., Adam B wrote:
> > src/tests/authorization_tests.cpp, line 2554
> > 
> >
> > `"foo" principal cannot launch nested container sessions as any user.`?
> > Can foo still launch container_info's instead of command_info's?

that really depends of the other ACL (the one related to executor), since in 
that case we don't verify this ACL.


> On Nov. 29, 2016, 10:47 a.m., Adam B wrote:
> > src/tests/authorization_tests.cpp, line 2546
> > 
> >
> > What's the comment here? I can't tell if this is equivalent to a 
> > permissive=false for this ACL.

pretty much so, but `permissive=false` affects all the ACLs.


- Alexander


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


On Nov. 29, 2016, 4:18 p.m., Alexander Rojas wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53541/
> ---
> 
> (Updated Nov. 29, 2016, 4:18 p.m.)
> 
> 
> Review request for mesos, Adam B, Kapil Arya, Kevin Klues, and Till Toenshoff.
> 
> 
> Bugs: MESOS-6474
> https://issues.apache.org/jira/browse/MESOS-6474
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Creates new authorization action for all the API's related to
> nested containers. This patch does not add the code necesary to
> call use those actions, this is done in a latter patch.
> 
> 
> Diffs
> -
> 
>   include/mesos/authorizer/acls.proto 
> e3fd6a4a1b617a75714ebd6e08ab10cffa1a7d1b 
>   include/mesos/authorizer/authorizer.hpp 
> 3cd0f84e25c0ea91a6f20eba26341a1b830d8cf2 
>   include/mesos/authorizer/authorizer.proto 
> 0696a629ac2d2b9950e20708f0c3666b58ff7ca0 
>   src/authorizer/local/authorizer.cpp 
> 77e05dd2475d6e7511e7c7eeea578ec31ff3d198 
>   src/tests/authorization_tests.cpp d23f551c2caa454da0c0f6cb7d77a8c2bd75a474 
> 
> Diff: https://reviews.apache.org/r/53541/diff/
> 
> 
> Testing
> ---
> 
> make check
> 
> 
> Thanks,
> 
> Alexander Rojas
> 
>



Re: Review Request 53982: Added documentation for posix/rlimit isolator.

2016-11-29 Thread Neil Conway

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



I'd still like to see more discussion of how someone might actually use this 
feature. For example, when you say "With these constraints operators can use a
global hard limit to contain resource limits set by users" -- how would the 
operator do this? Presumably the operator cannot enforce global resource limits 
via a user-specified flag in `ContainerInfo`.


docs/posix_rlimits.md (line 16)


Is it actually possible to increase the soft limit above the hard limit? I 
don't believe so.



docs/posix_rlimits.md (line 19)


Using "contain" here is a bit confusing: I'd say "Operators can use a hard 
resource limit to define the maximum amount of resources that can be consumed 
by a user; users can employ soft resource limits to ensure that one of their 
tasks only consumes a limited amount of the global hard resource limit."


F

- Neil Conway


On Nov. 29, 2016, 12:54 p.m., Benjamin Bannier wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53982/
> ---
> 
> (Updated Nov. 29, 2016, 12:54 p.m.)
> 
> 
> Review request for mesos, Jie Yu and Neil Conway.
> 
> 
> Bugs: MESOS-6427
> https://issues.apache.org/jira/browse/MESOS-6427
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Added documentation for posix/rlimit isolator.
> 
> 
> Diffs
> -
> 
>   docs/mesos-containerizer.md 2bff35f6361f760a9001a249d2c01bbbc9e72932 
>   docs/posix_rlimits.md PRE-CREATION 
> 
> Diff: https://reviews.apache.org/r/53982/diff/
> 
> 
> Testing
> ---
> 
> Tested with github markdown renderer, and with build setup from `site/`.
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>



Re: Review Request 53982: Added documentation for posix/rlimit isolator.

2016-11-29 Thread Mesos ReviewBot

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



Patch looks great!

Reviews applied: [53982]

Passed command: export OS='ubuntu:14.04' BUILDTOOL='autotools' COMPILER='gcc' 
CONFIGURATION='--verbose' ENVIRONMENT='GLOG_v=1 MESOS_VERBOSE=1'; 
./support/docker_build.sh

- Mesos ReviewBot


On Nov. 29, 2016, 12:54 p.m., Benjamin Bannier wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53982/
> ---
> 
> (Updated Nov. 29, 2016, 12:54 p.m.)
> 
> 
> Review request for mesos, Jie Yu and Neil Conway.
> 
> 
> Bugs: MESOS-6427
> https://issues.apache.org/jira/browse/MESOS-6427
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Added documentation for posix/rlimit isolator.
> 
> 
> Diffs
> -
> 
>   docs/mesos-containerizer.md 2bff35f6361f760a9001a249d2c01bbbc9e72932 
>   docs/posix_rlimits.md PRE-CREATION 
> 
> Diff: https://reviews.apache.org/r/53982/diff/
> 
> 
> Testing
> ---
> 
> Tested with github markdown renderer, and with build setup from `site/`.
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>



Re: Review Request 53982: Added documentation for posix/rlimit isolator.

2016-11-29 Thread Benjamin Bannier


> On Nov. 28, 2016, 8:36 p.m., Neil Conway wrote:
> > docs/posix_rlimits.md, line 48
> > 
> >
> > s/In addition many limits defined on Linux/Linux defines a number of 
> > additional resource limits that are not included in the POSIX standard. 
> > These are also supported by this isolator; see the definition of 
> > `RLimitInfo::RLimit` for the list of currently exposed types."
> > 
> > Is there a reason to not include all the rlimit types in this document? 
> > The list is probably not going to change very often.

I expanded the current list inline. The original motivation was to avoid 
duplication information (which could go out of sync), but in the end we should 
make the documentation as useful as possible.


- Benjamin


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


On Nov. 29, 2016, 1:54 p.m., Benjamin Bannier wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53982/
> ---
> 
> (Updated Nov. 29, 2016, 1:54 p.m.)
> 
> 
> Review request for mesos, Jie Yu and Neil Conway.
> 
> 
> Bugs: MESOS-6427
> https://issues.apache.org/jira/browse/MESOS-6427
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Added documentation for posix/rlimit isolator.
> 
> 
> Diffs
> -
> 
>   docs/mesos-containerizer.md 2bff35f6361f760a9001a249d2c01bbbc9e72932 
>   docs/posix_rlimits.md PRE-CREATION 
> 
> Diff: https://reviews.apache.org/r/53982/diff/
> 
> 
> Testing
> ---
> 
> Tested with github markdown renderer, and with build setup from `site/`.
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>



Re: Review Request 53982: Added documentation for posix/rlimit isolator.

2016-11-29 Thread Benjamin Bannier

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

(Updated Nov. 29, 2016, 1:54 p.m.)


Review request for mesos, Jie Yu and Neil Conway.


Changes
---

Addressed neilc's comments.


Bugs: MESOS-6427
https://issues.apache.org/jira/browse/MESOS-6427


Repository: mesos


Description
---

Added documentation for posix/rlimit isolator.


Diffs (updated)
-

  docs/mesos-containerizer.md 2bff35f6361f760a9001a249d2c01bbbc9e72932 
  docs/posix_rlimits.md PRE-CREATION 

Diff: https://reviews.apache.org/r/53982/diff/


Testing
---

Tested with github markdown renderer, and with build setup from `site/`.


Thanks,

Benjamin Bannier