mesos-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dominic Hamon" <dha...@twopensource.com>
Subject Re: Review Request 24124: Added a slave metric for exposing the number of active containers.
Date Wed, 06 Aug 2014 16:47:12 GMT

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

Ship it!



src/slave/slave.cpp
<https://reviews.apache.org/r/24124/#comment87052>

    you could simplify this with:
    
    double Slave::count_executors_in_state(ExecutorState state) const {
      double count = 0.0;
      foreachvalue (Framework* framework, frameworks) {
        foreachvalue (Executor* executor, framework->executors) {
          if (executor->state == state) {
            count++;
          }
        }
      }
      return count;
    }
    


- Dominic Hamon


On Aug. 5, 2014, 5:16 p.m., Jie Yu wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/24124/
> -----------------------------------------------------------
> 
> (Updated Aug. 5, 2014, 5:16 p.m.)
> 
> 
> Review request for mesos, Ben Mahler, Dominic Hamon, and Ian Downes.
> 
> 
> Repository: mesos-git
> 
> 
> Description
> -------
> 
> See summary.
> 
> 
> Diffs
> -----
> 
>   src/slave/slave.hpp c12cd0a 
>   src/slave/slave.cpp c56cac8 
>   src/tests/slave_tests.cpp 3a7fee6 
> 
> Diff: https://reviews.apache.org/r/24124/diff/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Jie Yu
> 
>


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message