You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@mesos.apache.org by Joseph Wu <jo...@mesosphere.io> on 2016/01/06 03:19:16 UTC

Review Request 41962: Logger Module: Add tests for module recovery after agent failover.

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

Review request for mesos, Benjamin Hindman, Gilbert Song, Artem Harutyunyan, Jie Yu, and Timothy Chen.


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


Repository: mesos


Description
-------

Adds two heavily-mocked tests for the Mesos containerizer and Docker containerizer.  Each checks that `ContainerLogger::recover` is called during `Containerizer::recover`.


Diffs
-----

  src/tests/container_logger_tests.cpp c6b2e597517c74a55649287dc5ae5a3115f9a640 
  src/tests/mesos.hpp a4811b0d8dee33ff2ca4968f532ce64b7ea95249 
  src/tests/mesos.cpp f4b0f82449c4b6a2b4b7b7f14518714485d5a13a 

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


Testing
-------

make (OSX & Centos7)

Tests are run in the next review.


Thanks,

Joseph Wu


Re: Review Request 41962: Logger Module: Add tests for module recovery after agent failover.

Posted by Jojy Varghese <jo...@mesosphere.io>.

> On Jan. 6, 2016, 7:32 p.m., Jojy Varghese wrote:
> > src/tests/container_logger_tests.cpp, line 158
> > <https://reviews.apache.org/r/41962/diff/1/?file=1183514#file1183514line158>
> >
> >     Can we have this as :
> >     
> >     ``` 
> >     Shared<Docker> docker(new MockDocker(...)); 
> >     
> >     ```
> 
> Joseph Wu wrote:
>     The trade-off (style-wise) is that later in the test, we'd need to do:
>     ```
>     EXPECT_CALL((MockDocker *) docker.get(), ps(_, _))
>       .WillOnce(Return(containers));
>     ```
>     
>     And I'm not really thrilled about that cast.

Ah i see. usually c++ style guides frown upon this style as its considered exception unsafe. using `make_shared` or `shared_ptr(new ...) ` is considered better as they guarantee exception safety. I guess for Mesos it doesnt matter.


- Jojy


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


On Jan. 9, 2016, 12:24 a.m., Joseph Wu wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/41962/
> -----------------------------------------------------------
> 
> (Updated Jan. 9, 2016, 12:24 a.m.)
> 
> 
> Review request for mesos, Benjamin Hindman, Gilbert Song, Artem Harutyunyan, Jie Yu, and Timothy Chen.
> 
> 
> Bugs: MESOS-4150
>     https://issues.apache.org/jira/browse/MESOS-4150
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Adds two heavily-mocked tests for the Mesos containerizer and Docker containerizer.  Each checks that `ContainerLogger::recover` is called during `Containerizer::recover`.
> 
> 
> Diffs
> -----
> 
>   src/tests/container_logger_tests.cpp c6b2e597517c74a55649287dc5ae5a3115f9a640 
>   src/tests/mesos.hpp 3d9ebc6c9dc3cd1be02dc3771fbd847386907fac 
>   src/tests/mesos.cpp 365ebe8335c37bfdb983a5424d4c995fa9b76a22 
> 
> Diff: https://reviews.apache.org/r/41962/diff/
> 
> 
> Testing
> -------
> 
> make (OSX & Centos7)
> 
> Tests are run in the next review.
> 
> 
> Thanks,
> 
> Joseph Wu
> 
>


Re: Review Request 41962: Logger Module: Add tests for module recovery after agent failover.

Posted by Joseph Wu <jo...@mesosphere.io>.

> On Jan. 6, 2016, 11:32 a.m., Jojy Varghese wrote:
> > src/tests/container_logger_tests.cpp, line 95
> > <https://reviews.apache.org/r/41962/diff/1/?file=1183514#file1183514line95>
> >
> >     What is the ownership semantics of this pointer? Here and other places.

Other than the `Docker` object (owned by containerizer and test), all these pointers are owned by the `Containerizer` object.


> On Jan. 6, 2016, 11:32 a.m., Jojy Varghese wrote:
> > src/tests/container_logger_tests.cpp, line 158
> > <https://reviews.apache.org/r/41962/diff/1/?file=1183514#file1183514line158>
> >
> >     Can we have this as :
> >     
> >     ``` 
> >     Shared<Docker> docker(new MockDocker(...)); 
> >     
> >     ```

The trade-off (style-wise) is that later in the test, we'd need to do:
```
EXPECT_CALL((MockDocker *) docker.get(), ps(_, _))
  .WillOnce(Return(containers));
```

And I'm not really thrilled about that cast.


- Joseph


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


On Jan. 5, 2016, 6:19 p.m., Joseph Wu wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/41962/
> -----------------------------------------------------------
> 
> (Updated Jan. 5, 2016, 6:19 p.m.)
> 
> 
> Review request for mesos, Benjamin Hindman, Gilbert Song, Artem Harutyunyan, Jie Yu, and Timothy Chen.
> 
> 
> Bugs: MESOS-4150
>     https://issues.apache.org/jira/browse/MESOS-4150
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Adds two heavily-mocked tests for the Mesos containerizer and Docker containerizer.  Each checks that `ContainerLogger::recover` is called during `Containerizer::recover`.
> 
> 
> Diffs
> -----
> 
>   src/tests/container_logger_tests.cpp c6b2e597517c74a55649287dc5ae5a3115f9a640 
>   src/tests/mesos.hpp a4811b0d8dee33ff2ca4968f532ce64b7ea95249 
>   src/tests/mesos.cpp f4b0f82449c4b6a2b4b7b7f14518714485d5a13a 
> 
> Diff: https://reviews.apache.org/r/41962/diff/
> 
> 
> Testing
> -------
> 
> make (OSX & Centos7)
> 
> Tests are run in the next review.
> 
> 
> Thanks,
> 
> Joseph Wu
> 
>


Re: Review Request 41962: Logger Module: Add tests for module recovery after agent failover.

Posted by Jojy Varghese <jo...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/41962/#review113119
-----------------------------------------------------------



src/tests/container_logger_tests.cpp (line 95)
<https://reviews.apache.org/r/41962/#comment173617>

    What is the ownership semantics of this pointer? Here and other places.



src/tests/container_logger_tests.cpp (line 158)
<https://reviews.apache.org/r/41962/#comment173624>

    Can we have this as :
    
    ``` 
    Shared<Docker> docker(new MockDocker(...)); 
    
    ```


- Jojy Varghese


On Jan. 6, 2016, 2:19 a.m., Joseph Wu wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/41962/
> -----------------------------------------------------------
> 
> (Updated Jan. 6, 2016, 2:19 a.m.)
> 
> 
> Review request for mesos, Benjamin Hindman, Gilbert Song, Artem Harutyunyan, Jie Yu, and Timothy Chen.
> 
> 
> Bugs: MESOS-4150
>     https://issues.apache.org/jira/browse/MESOS-4150
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Adds two heavily-mocked tests for the Mesos containerizer and Docker containerizer.  Each checks that `ContainerLogger::recover` is called during `Containerizer::recover`.
> 
> 
> Diffs
> -----
> 
>   src/tests/container_logger_tests.cpp c6b2e597517c74a55649287dc5ae5a3115f9a640 
>   src/tests/mesos.hpp a4811b0d8dee33ff2ca4968f532ce64b7ea95249 
>   src/tests/mesos.cpp f4b0f82449c4b6a2b4b7b7f14518714485d5a13a 
> 
> Diff: https://reviews.apache.org/r/41962/diff/
> 
> 
> Testing
> -------
> 
> make (OSX & Centos7)
> 
> Tests are run in the next review.
> 
> 
> Thanks,
> 
> Joseph Wu
> 
>


Re: Review Request 41962: Logger Module: Add tests for module recovery after agent failover.

Posted by Joseph Wu <jo...@mesosphere.io>.

> On Jan. 8, 2016, 1:29 p.m., Timothy Chen wrote:
> > src/tests/container_logger_tests.cpp, line 222
> > <https://reviews.apache.org/r/41962/diff/1/?file=1183514#file1183514line222>
> >
> >     Do we need to check that the correct container id is passed?

It wouldn't hurt.  I'll add it to both tests.

The second argument here is a the string `sandboxDirectory`, which is expected to be:
```
  slave::paths::getExecutorRunPath(
      flags.work_dir,
      slaveState.id,
      frameworkState.id,
      executorId,
      containerId)
```


- Joseph


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


On Jan. 5, 2016, 6:19 p.m., Joseph Wu wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/41962/
> -----------------------------------------------------------
> 
> (Updated Jan. 5, 2016, 6:19 p.m.)
> 
> 
> Review request for mesos, Benjamin Hindman, Gilbert Song, Artem Harutyunyan, Jie Yu, and Timothy Chen.
> 
> 
> Bugs: MESOS-4150
>     https://issues.apache.org/jira/browse/MESOS-4150
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Adds two heavily-mocked tests for the Mesos containerizer and Docker containerizer.  Each checks that `ContainerLogger::recover` is called during `Containerizer::recover`.
> 
> 
> Diffs
> -----
> 
>   src/tests/container_logger_tests.cpp c6b2e597517c74a55649287dc5ae5a3115f9a640 
>   src/tests/mesos.hpp a4811b0d8dee33ff2ca4968f532ce64b7ea95249 
>   src/tests/mesos.cpp f4b0f82449c4b6a2b4b7b7f14518714485d5a13a 
> 
> Diff: https://reviews.apache.org/r/41962/diff/
> 
> 
> Testing
> -------
> 
> make (OSX & Centos7)
> 
> Tests are run in the next review.
> 
> 
> Thanks,
> 
> Joseph Wu
> 
>


Re: Review Request 41962: Logger Module: Add tests for module recovery after agent failover.

Posted by Timothy Chen <tn...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/41962/#review113538
-----------------------------------------------------------



src/tests/container_logger_tests.cpp (line 222)
<https://reviews.apache.org/r/41962/#comment174276>

    Do we need to check that the correct container id is passed?


- Timothy Chen


On Jan. 6, 2016, 2:19 a.m., Joseph Wu wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/41962/
> -----------------------------------------------------------
> 
> (Updated Jan. 6, 2016, 2:19 a.m.)
> 
> 
> Review request for mesos, Benjamin Hindman, Gilbert Song, Artem Harutyunyan, Jie Yu, and Timothy Chen.
> 
> 
> Bugs: MESOS-4150
>     https://issues.apache.org/jira/browse/MESOS-4150
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Adds two heavily-mocked tests for the Mesos containerizer and Docker containerizer.  Each checks that `ContainerLogger::recover` is called during `Containerizer::recover`.
> 
> 
> Diffs
> -----
> 
>   src/tests/container_logger_tests.cpp c6b2e597517c74a55649287dc5ae5a3115f9a640 
>   src/tests/mesos.hpp a4811b0d8dee33ff2ca4968f532ce64b7ea95249 
>   src/tests/mesos.cpp f4b0f82449c4b6a2b4b7b7f14518714485d5a13a 
> 
> Diff: https://reviews.apache.org/r/41962/diff/
> 
> 
> Testing
> -------
> 
> make (OSX & Centos7)
> 
> Tests are run in the next review.
> 
> 
> Thanks,
> 
> Joseph Wu
> 
>


Re: Review Request 41962: Logger Module: Add tests for module recovery after agent failover.

Posted by Joseph Wu <jo...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/41962/
-----------------------------------------------------------

(Updated Jan. 23, 2016, 1:13 a.m.)


Review request for mesos, Benjamin Hindman, Gilbert Song, Artem Harutyunyan, Jie Yu, and Timothy Chen.


Changes
-------

Fix an unsatisfied call to `process::reap`, which interferes with the next test that needs to reap something.  `process::reap(0)` will end up doing the reap first.  The next reap will instead return `None` instead of a status code.


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


Repository: mesos


Description
-------

Adds two heavily-mocked tests for the Mesos containerizer and Docker containerizer. Each checks that `ContainerLogger::recover` is called during `Containerizer::recover`.


Diffs (updated)
-----

  src/tests/container_logger_tests.cpp c6b2e597517c74a55649287dc5ae5a3115f9a640 
  src/tests/mesos.hpp 3d9ebc6c9dc3cd1be02dc3771fbd847386907fac 
  src/tests/mesos.cpp 365ebe8335c37bfdb983a5424d4c995fa9b76a22 

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


Testing
-------

make (OSX & Centos7)

Tests are run in the next review.


Thanks,

Joseph Wu


Re: Review Request 41962: Logger Module: Add tests for module recovery after agent failover.

Posted by Joseph Wu <jo...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/41962/
-----------------------------------------------------------

(Updated Jan. 19, 2016, 7:42 p.m.)


Review request for mesos, Benjamin Hindman, Gilbert Song, Artem Harutyunyan, Jie Yu, and Timothy Chen.


Changes
-------

Restore another summary/description lost to the tweaked apply-reviews :)


Summary (updated)
-----------------

Logger Module: Add tests for module recovery after agent failover.


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


Repository: mesos


Description (updated)
-------

Adds two heavily-mocked tests for the Mesos containerizer and Docker containerizer. Each checks that `ContainerLogger::recover` is called during `Containerizer::recover`.


Diffs
-----

  src/tests/container_logger_tests.cpp c6b2e597517c74a55649287dc5ae5a3115f9a640 
  src/tests/mesos.hpp 3d9ebc6c9dc3cd1be02dc3771fbd847386907fac 
  src/tests/mesos.cpp 365ebe8335c37bfdb983a5424d4c995fa9b76a22 

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


Testing
-------

make (OSX & Centos7)

Tests are run in the next review.


Thanks,

Joseph Wu


Re: Review Request 41962: Add test for ContainerLogger recovery after agent failover.

Posted by Joseph Wu <jo...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/41962/
-----------------------------------------------------------

(Updated Jan. 15, 2016, 5:02 p.m.)


Review request for mesos, Benjamin Hindman, Gilbert Song, Artem Harutyunyan, Jie Yu, and Timothy Chen.


Changes
-------

Rebase and deal with an earlier change to the headers.


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


Repository: mesos


Description
-------

Add test for ContainerLogger recovery after agent failover.


Diffs (updated)
-----

  src/tests/container_logger_tests.cpp c6b2e597517c74a55649287dc5ae5a3115f9a640 
  src/tests/mesos.hpp 3d9ebc6c9dc3cd1be02dc3771fbd847386907fac 
  src/tests/mesos.cpp 365ebe8335c37bfdb983a5424d4c995fa9b76a22 

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


Testing
-------

make (OSX & Centos7)

Tests are run in the next review.


Thanks,

Joseph Wu


Re: Review Request 41962: Add test for ContainerLogger recovery after agent failover.

Posted by Joseph Wu <jo...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/41962/
-----------------------------------------------------------

(Updated Jan. 15, 2016, 1:03 p.m.)


Review request for mesos, Benjamin Hindman, Gilbert Song, Artem Harutyunyan, Jie Yu, and Timothy Chen.


Changes
-------

Move the mock expectation for `MockContainerLogger*` to before the containerizer is created, i.e. before `MockContainerLogger*` is `Owned<...>` by the containerizer.

Update test due to addition of `Provisioner` to the MesosContainerizer.


Summary (updated)
-----------------

Add test for ContainerLogger recovery after agent failover.


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


Repository: mesos


Description (updated)
-------

Add test for ContainerLogger recovery after agent failover.


Diffs (updated)
-----

  src/tests/container_logger_tests.cpp c6b2e597517c74a55649287dc5ae5a3115f9a640 
  src/tests/mesos.hpp 3d9ebc6c9dc3cd1be02dc3771fbd847386907fac 
  src/tests/mesos.cpp 365ebe8335c37bfdb983a5424d4c995fa9b76a22 

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


Testing
-------

make (OSX & Centos7)

Tests are run in the next review.


Thanks,

Joseph Wu


Re: Review Request 41962: Logger Module: Add tests for module recovery after agent failover.

Posted by Joseph Wu <jo...@mesosphere.io>.

> On Jan. 13, 2016, 9:02 p.m., Benjamin Hindman wrote:
> > src/tests/container_logger_tests.cpp, lines 153-154
> > <https://reviews.apache.org/r/41962/diff/3/?file=1194957#file1194957line153>
> >
> >     Ugh, using something we passed in as `Owned` above? Have we still not cleaned up this pattern in the code base?

We have not (in tests).  Is it really bad?  Presumably, mocking is all about violating this pattern :)

---

In most mocks (MockScheduler, MockExecutor, etc) we pass those around as pointers to stack-allocated variables.

For a few mocks (MockMesosContainerizerProcess, MockIsolator, MockContainerLogger), we pass these around as `Owned<...>`.
For example: https://github.com/apache/mesos/blob/master/src/tests/containerizer/mesos_containerizer_tests.cpp#L628


- Joseph


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


On Jan. 12, 2016, 2:31 p.m., Joseph Wu wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/41962/
> -----------------------------------------------------------
> 
> (Updated Jan. 12, 2016, 2:31 p.m.)
> 
> 
> Review request for mesos, Benjamin Hindman, Gilbert Song, Artem Harutyunyan, Jie Yu, and Timothy Chen.
> 
> 
> Bugs: MESOS-4150
>     https://issues.apache.org/jira/browse/MESOS-4150
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Adds two heavily-mocked tests for the Mesos containerizer and Docker containerizer.  Each checks that `ContainerLogger::recover` is called during `Containerizer::recover`.
> 
> 
> Diffs
> -----
> 
>   src/tests/container_logger_tests.cpp c6b2e597517c74a55649287dc5ae5a3115f9a640 
>   src/tests/mesos.hpp 3d9ebc6c9dc3cd1be02dc3771fbd847386907fac 
>   src/tests/mesos.cpp 365ebe8335c37bfdb983a5424d4c995fa9b76a22 
> 
> Diff: https://reviews.apache.org/r/41962/diff/
> 
> 
> Testing
> -------
> 
> make (OSX & Centos7)
> 
> Tests are run in the next review.
> 
> 
> Thanks,
> 
> Joseph Wu
> 
>


Re: Review Request 41962: Logger Module: Add tests for module recovery after agent failover.

Posted by Benjamin Hindman <be...@berkeley.edu>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/41962/#review114414
-----------------------------------------------------------



src/tests/container_logger_tests.cpp (lines 153 - 154)
<https://reviews.apache.org/r/41962/#comment175251>

    Ugh, using something we passed in as `Owned` above? Have we still not cleaned up this pattern in the code base?


- Benjamin Hindman


On Jan. 12, 2016, 10:31 p.m., Joseph Wu wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/41962/
> -----------------------------------------------------------
> 
> (Updated Jan. 12, 2016, 10:31 p.m.)
> 
> 
> Review request for mesos, Benjamin Hindman, Gilbert Song, Artem Harutyunyan, Jie Yu, and Timothy Chen.
> 
> 
> Bugs: MESOS-4150
>     https://issues.apache.org/jira/browse/MESOS-4150
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Adds two heavily-mocked tests for the Mesos containerizer and Docker containerizer.  Each checks that `ContainerLogger::recover` is called during `Containerizer::recover`.
> 
> 
> Diffs
> -----
> 
>   src/tests/container_logger_tests.cpp c6b2e597517c74a55649287dc5ae5a3115f9a640 
>   src/tests/mesos.hpp 3d9ebc6c9dc3cd1be02dc3771fbd847386907fac 
>   src/tests/mesos.cpp 365ebe8335c37bfdb983a5424d4c995fa9b76a22 
> 
> Diff: https://reviews.apache.org/r/41962/diff/
> 
> 
> Testing
> -------
> 
> make (OSX & Centos7)
> 
> Tests are run in the next review.
> 
> 
> Thanks,
> 
> Joseph Wu
> 
>


Re: Review Request 41962: Logger Module: Add tests for module recovery after agent failover.

Posted by Joseph Wu <jo...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/41962/
-----------------------------------------------------------

(Updated Jan. 12, 2016, 2:31 p.m.)


Review request for mesos, Benjamin Hindman, Gilbert Song, Artem Harutyunyan, Jie Yu, and Timothy Chen.


Changes
-------

Rebase onto the `RotatingContainerLogger` branch due to the (eventual) header inclusion conflict.


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


Repository: mesos


Description
-------

Adds two heavily-mocked tests for the Mesos containerizer and Docker containerizer.  Each checks that `ContainerLogger::recover` is called during `Containerizer::recover`.


Diffs (updated)
-----

  src/tests/container_logger_tests.cpp c6b2e597517c74a55649287dc5ae5a3115f9a640 
  src/tests/mesos.hpp 3d9ebc6c9dc3cd1be02dc3771fbd847386907fac 
  src/tests/mesos.cpp 365ebe8335c37bfdb983a5424d4c995fa9b76a22 

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


Testing
-------

make (OSX & Centos7)

Tests are run in the next review.


Thanks,

Joseph Wu


Re: Review Request 41962: Logger Module: Add tests for module recovery after agent failover.

Posted by Joseph Wu <jo...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/41962/
-----------------------------------------------------------

(Updated Jan. 8, 2016, 4:24 p.m.)


Review request for mesos, Benjamin Hindman, Gilbert Song, Artem Harutyunyan, Jie Yu, and Timothy Chen.


Changes
-------

Add check for `sandboxDirectory` in the mock tests.


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


Repository: mesos


Description
-------

Adds two heavily-mocked tests for the Mesos containerizer and Docker containerizer.  Each checks that `ContainerLogger::recover` is called during `Containerizer::recover`.


Diffs (updated)
-----

  src/tests/container_logger_tests.cpp c6b2e597517c74a55649287dc5ae5a3115f9a640 
  src/tests/mesos.hpp 3d9ebc6c9dc3cd1be02dc3771fbd847386907fac 
  src/tests/mesos.cpp 365ebe8335c37bfdb983a5424d4c995fa9b76a22 

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


Testing
-------

make (OSX & Centos7)

Tests are run in the next review.


Thanks,

Joseph Wu