You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mesos.apache.org by Yifan Gu <yi...@mesosphere.io> on 2014/06/05 00:01:32 UTC

Re: Review Request 21968: MESOS-878: Prevented slave from reregistering when TERMINATING.

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

(Updated June 4, 2014, 10:01 p.m.)


Review request for mesos, Adam B, Niklas Nielsen, and Vinod Kone.


Changes
-------

Changed commit message.


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

MESOS-878: Prevented slave from reregistering when TERMINATING.


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


Repository: mesos-git


Description
-------

Added a sentence to check the slave's state in doReliableRegistration() to make sure that the function returns when the slave's state is TERMINATING.
Also, to write the test, I need to make sure there's no additional doReliableRegistration() calls, so I added EXPECT_NO_FUTURE_PROTOBUFS() and EXPECT_NO_FUTURE_MESSAGES() to make sure there's no more SlaveReregisteredMessages.


Diffs
-----

  3rdparty/libprocess/include/process/gmock.hpp daba7e3 
  src/slave/slave.cpp 3b10a4c 
  src/tests/mesos.hpp 9ece77a 
  src/tests/slave_tests.cpp 80fe3cf 

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


Testing
-------

Slave_tests.cpp:TerminatingSlaveDoesNotReregister.


File Attachments
----------------

Using DROP_PROTOBUF()
  https://reviews.apache.org/media/uploaded/files/2014/05/30/7c0e1b69-19c1-4868-865e-d47fbb739585__mesos.diff


Thanks,

Yifan Gu


Re: Review Request 21968: MESOS-878: Prevented slave from (re-)registering when TERMINATING.

Posted by Vinod Kone <vi...@gmail.com>.
I highly recommend using the git pre-commit hook.

$ ln -s ../../support/hooks/pre-commit .git/hooks/pre-commit


On Wed, Jun 4, 2014 at 4:58 PM, Yifan Gu <yi...@mesosphere.io> wrote:

>    This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/21968/
>   Review request for mesos, Adam B, Niklas Nielsen, and Vinod Kone.
> By Yifan Gu.
>
> *Updated June 4, 2014, 11:58 p.m.*
> Changes
>
> I am so sorry, one line exceeds the 80-character limitation.
>
>   *Bugs: * MESOS-878 <https://issues.apache.org/jira/browse/MESOS-878>
>  *Repository: * mesos-git
> Description
>
> Checked the slave's state before (re-)registering.
> Introduced EXPECT_NO_FUTURE_PROTOBUFS() and EXPECT_NO_FUTURE_MESSAGES().
>
>   Testing
>
> Slave_tests.cpp:TerminatingSlaveDoesNotReregister.
>
>   Diffs (updated)
>
>    - 3rdparty/libprocess/include/process/gmock.hpp (daba7e3)
>    - src/slave/slave.cpp (3b10a4c)
>    - src/tests/mesos.hpp (9ece77a)
>    - src/tests/slave_tests.cpp (80fe3cf)
>
> View Diff <https://reviews.apache.org/r/21968/diff/>
>

Re: Review Request 21968: MESOS-878: Prevented slave from (re-)registering when TERMINATING.

Posted by Yifan Gu <yi...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/21968/
-----------------------------------------------------------

(Updated June 4, 2014, 11:58 p.m.)


Review request for mesos, Adam B, Niklas Nielsen, and Vinod Kone.


Changes
-------

I am so sorry, one line exceeds the 80-character limitation.


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


Repository: mesos-git


Description
-------

Checked the slave's state before (re-)registering.
Introduced EXPECT_NO_FUTURE_PROTOBUFS() and EXPECT_NO_FUTURE_MESSAGES().


Diffs (updated)
-----

  3rdparty/libprocess/include/process/gmock.hpp daba7e3 
  src/slave/slave.cpp 3b10a4c 
  src/tests/mesos.hpp 9ece77a 
  src/tests/slave_tests.cpp 80fe3cf 

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


Testing
-------

Slave_tests.cpp:TerminatingSlaveDoesNotReregister.


Thanks,

Yifan Gu


Re: Review Request 21968: MESOS-878: Prevented slave from (re-)registering when TERMINATING.

Posted by Yifan Gu <yi...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/21968/
-----------------------------------------------------------

(Updated June 4, 2014, 10:19 p.m.)


Review request for mesos, Adam B, Niklas Nielsen, and Vinod Kone.


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

MESOS-878: Prevented slave from (re-)registering when TERMINATING.


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


Repository: mesos-git


Description (updated)
-------

Checked the slave's state before (re-)registering.
Introduced EXPECT_NO_FUTURE_PROTOBUFS() and EXPECT_NO_FUTURE_MESSAGES().


Diffs
-----

  3rdparty/libprocess/include/process/gmock.hpp daba7e3 
  src/slave/slave.cpp 3b10a4c 
  src/tests/mesos.hpp 9ece77a 
  src/tests/slave_tests.cpp 80fe3cf 

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


Testing
-------

Slave_tests.cpp:TerminatingSlaveDoesNotReregister.


Thanks,

Yifan Gu


Re: Review Request 21968: MESOS-878: Prevented slave from reregistering when TERMINATING.

Posted by Yifan Gu <yi...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/21968/
-----------------------------------------------------------

(Updated June 4, 2014, 10:15 p.m.)


Review request for mesos, Adam B, Niklas Nielsen, and Vinod Kone.


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


Repository: mesos-git


Description (updated)
-------

Checked the slave's state before doing (re-)registration.
Introduced EXPECT_NO_FUTURE_PROTOBUFS() and EXPECT_NO_FUTURE_MESSAGES().


Diffs
-----

  3rdparty/libprocess/include/process/gmock.hpp daba7e3 
  src/slave/slave.cpp 3b10a4c 
  src/tests/mesos.hpp 9ece77a 
  src/tests/slave_tests.cpp 80fe3cf 

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


Testing
-------

Slave_tests.cpp:TerminatingSlaveDoesNotReregister.


Thanks,

Yifan Gu


Re: Review Request 21968: MESOS-878: Prevented slave from reregistering when TERMINATING.

Posted by Yifan Gu <yi...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/21968/
-----------------------------------------------------------

(Updated June 4, 2014, 10:14 p.m.)


Review request for mesos, Adam B, Niklas Nielsen, and Vinod Kone.


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


Repository: mesos-git


Description (updated)
-------

Checked the slave's state before doing (re-)registering.
Introduced EXPECT_NO_FUTURE_PROTOBUFS() and EXPECT_NO_FUTURE_MESSAGES().


Diffs
-----

  3rdparty/libprocess/include/process/gmock.hpp daba7e3 
  src/slave/slave.cpp 3b10a4c 
  src/tests/mesos.hpp 9ece77a 
  src/tests/slave_tests.cpp 80fe3cf 

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


Testing
-------

Slave_tests.cpp:TerminatingSlaveDoesNotReregister.


Thanks,

Yifan Gu


Re: Review Request 21968: MESOS-878: Prevented slave from reregistering when TERMINATING.

Posted by Yifan Gu <yi...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/21968/
-----------------------------------------------------------

(Updated June 4, 2014, 10:10 p.m.)


Review request for mesos, Adam B, Niklas Nielsen, and Vinod Kone.


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


Repository: mesos-git


Description
-------

Added a sentence to check the slave's state in doReliableRegistration() to make sure that the function returns immediately when the slave's state is TERMINATING.
Beside, in order to make sure there's no more ReregistereSlaveMessage being sent.I introduced EXPECT_NO_FUTURE_PROTOBUFS() and EXPECT_NO_FUTURE_MESSAGES().


Diffs
-----

  3rdparty/libprocess/include/process/gmock.hpp daba7e3 
  src/slave/slave.cpp 3b10a4c 
  src/tests/mesos.hpp 9ece77a 
  src/tests/slave_tests.cpp 80fe3cf 

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


Testing
-------

Slave_tests.cpp:TerminatingSlaveDoesNotReregister.


Thanks,

Yifan Gu


Re: Review Request 21968: MESOS-878: Prevented slave from reregistering when TERMINATING.

Posted by Yifan Gu <yi...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/21968/
-----------------------------------------------------------

(Updated June 4, 2014, 10:08 p.m.)


Review request for mesos, Adam B, Niklas Nielsen, and Vinod Kone.


Changes
-------

Clean up the Summary and description.


Repository: mesos-git


Description (updated)
-------

Added a sentence to check the slave's state in doReliableRegistration() to make sure that the function returns immediately when the slave's state is TERMINATING.
Beside, in order to make sure there's no more ReregistereSlaveMessage being sent.I introduced EXPECT_NO_FUTURE_PROTOBUFS() and EXPECT_NO_FUTURE_MESSAGES().


Diffs (updated)
-----

  3rdparty/libprocess/include/process/gmock.hpp daba7e3 
  src/slave/slave.cpp 3b10a4c 
  src/tests/mesos.hpp 9ece77a 
  src/tests/slave_tests.cpp 80fe3cf 

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


Testing
-------

Slave_tests.cpp:TerminatingSlaveDoesNotReregister.


Thanks,

Yifan Gu