You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mesos.apache.org by Ben Mahler <be...@gmail.com> on 2014/07/15 20:11:43 UTC

Re: Review Request 22367: Second phase: Mesos-slave support for "node drain"

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

Ship it!


Looks great, I made a few comments below. Since everything is pretty minor I made the updates and will commit this for you!


src/master/master.cpp
<https://reviews.apache.org/r/22367/#comment83955>

    Would this be better as a WARNING, since there is no erroneous condition?
    
    It's also what we use for all of our other ignored messages.



src/master/master.cpp
<https://reviews.apache.org/r/22367/#comment83956>

    Why not just pass 'slave' here since we've already looked it up?



src/slave/slave.cpp
<https://reviews.apache.org/r/22367/#comment83959>

    We might want to still mention that we're shutting down, how about:
    
    "; unregistering and shutting down"



src/tests/slave_recovery_tests.cpp
<https://reviews.apache.org/r/22367/#comment83968>

    Let's store the status so we can verify that it is running:
    
    
      Future<TaskStatus> status;
      EXPECT_CALL(sched, statusUpdate(_, _))
        .WillOnce(FutureArg<1>(&status));
    
      ...
    
      AWAIT_READY(status);
      ASSERT_EQ(TASK_RUNNING, status.get().state());
    
    
    Down below, let's then make sure we get the following:
    
    (1) A TASK_LOST update, this means we don't need the .WillRepeatedly on the statusUpdate above, and
    (2) A slaveLost callback on the scheduler.



src/tests/slave_recovery_tests.cpp
<https://reviews.apache.org/r/22367/#comment83960>

    We can specify the direction of this message, and FUTURE_PROTOBUF saves the need for getting the type name:
    
    FUTURE_MESSAGE(UnregisterSlaveMessage(), slave.get(), master.get());


- Ben Mahler


On June 30, 2014, 1:38 p.m., Alexandra Sava wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/22367/
> -----------------------------------------------------------
> 
> (Updated June 30, 2014, 1:38 p.m.)
> 
> 
> Review request for mesos and Ben Mahler.
> 
> 
> Bugs: MESOS-544
>     https://issues.apache.org/jira/browse/MESOS-544
> 
> 
> Repository: mesos-git
> 
> 
> Description
> -------
> 
> Second phase: Mesos-slave support for "node drain"
> * send UnregisterRequest message to the master
> * test that the message is being delivered to the master
> 
> ** This review relies on https://reviews.apache.org/r/21379/
> 
> 
> Diffs
> -----
> 
>   src/master/master.hpp 5fef35406c2ce2ad11e030aa7752eb691aab5857 
>   src/master/master.cpp 474014b24982449f2f64c2e8d835c25a28cbcbb8 
>   src/slave/slave.cpp f42ab60f29f38bcd8857f72fde9fc77cbfc36dde 
>   src/tests/slave_recovery_tests.cpp 582f52d73eba0e3ab089ec573d9a6c43bff0339e 
> 
> Diff: https://reviews.apache.org/r/22367/diff/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Alexandra Sava
> 
>