mesos-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alexander Rojas <alexan...@mesosphere.io>
Subject Re: Review Request 43880: Added allocator metrics for total and allocated scalar resources.
Date Sat, 05 Mar 2016 03:04:40 GMT

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



Most of my comments are based on an email @alex-mesos sent today, in which he suggests removing
metrics related code from the allocator and into the `Metrics` class, which is an idea I strongly
support. If we go that way, I would double down into that and move _all_ related code into
metrics.


src/master/allocator/mesos/hierarchical.cpp (lines 415 - 420)
<https://reviews.apache.org/r/43880/#comment184079>

    It just occurred to me, since @alex-mesos mentioned moving code related to metrics to
the `Metrics` class, and they are closely related, why not do the `foreach` there in a method
`Metrics::createGaugesForScalars(const std::set<std::string>& names)`



src/master/allocator/mesos/hierarchical.cpp (lines 528 - 533)
<https://reviews.apache.org/r/43880/#comment184080>

    ditto



src/master/allocator/mesos/hierarchical.cpp (lines 1705 - 1730)
<https://reviews.apache.org/r/43880/#comment184087>

    I wonder if we can move this code to the `Metrics` class. It can be in the code that actually
calls this method… Unless we plan to use this functions for other purposes than updating
the gauges.



src/master/allocator/mesos/metrics.hpp (line 43)
<https://reviews.apache.org/r/43880/#comment184089>

    A reference perhaps? I don't understand why is a const pointer better in this case.


Over

- Alexander Rojas


On March 4, 2016, 5:01 p.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/43880/
> -----------------------------------------------------------
> 
> (Updated March 4, 2016, 5:01 p.m.)
> 
> 
> Review request for mesos, Alexander Rukletsov and Ben Mahler.
> 
> 
> Bugs: MESOS-4720
>     https://issues.apache.org/jira/browse/MESOS-4720
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> See summary.
> 
> 
> Diffs
> -----
> 
>   docs/monitoring.md 827f7073204fcf8575ca980a5571c8be4f5e4110 
>   src/master/allocator/mesos/hierarchical.hpp 3043888630b066505410d3b32c5b3f813cc458c1

>   src/master/allocator/mesos/hierarchical.cpp 70291075c00a9a557529c2562dedcfc6c6c3ec32

>   src/master/allocator/mesos/metrics.hpp PRE-CREATION 
>   src/master/allocator/mesos/metrics.cpp PRE-CREATION 
>   src/tests/hierarchical_allocator_tests.cpp 3e4ad31925e1b815a74d67fa3962d23fa5bc89d1

> 
> Diff: https://reviews.apache.org/r/43880/diff/
> 
> 
> Testing
> -------
> 
> make check (OS X)
> 
> I confirmed that this does not lead to general performance regressions in the allocator;
this is partially expected since the added code only inserts metrics in the allocator while
the actual work is perform asynchronously. These tests where performed with `HierarchicalAllocator_BENCHMARK_Test.DeclineOffers`
on an optimized build under OS X using clang(trunk) as compiler.
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>


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