> On Feb. 24, 2016, 1:26 a.m., Guangya Liu wrote: > > src/master/allocator/mesos/hierarchical.cpp, lines 432-444 > > <https://reviews.apache.org/r/43880/diff/1/?file=1265547#file1265547line432> > > > > The allocatd may keeps changing due the resource offer and resource > > recovery, I think that this logic should be in `allocate(slaveIds)`? > > Benjamin Bannier wrote: > We do not read out `slave.allocated` here, we just install a callback > doing that. The calculation of the actual value is triggered if the metrics > endpoint is hit. Or am I missing an implicit value copy here? > > Guangya Liu wrote: > Yes, you are right. So can you please add some comments here to clairfy > that you install a callback to get the allocated resources?
In addition to the existing one on l.413? - Benjamin ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/43880/#review120415 ----------------------------------------------------------- On Feb. 24, 2016, 9:46 a.m., Benjamin Bannier wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/43880/ > ----------------------------------------------------------- > > (Updated Feb. 24, 2016, 9:46 a.m.) > > > Review request for mesos, Alexander Rukletsov and Ben Mahler. > > > Bugs: MESOS-4720 > https://issues.apache.org/jira/browse/MESOS-4720 > > > Repository: mesos > > > Description > ------- > > Added allocator metrics for total and allocated scalar resources. > > > Diffs > ----- > > src/master/allocator/mesos/hierarchical.hpp > 3043888630b066505410d3b32c5b3f813cc458c1 > src/master/allocator/mesos/hierarchical.cpp > 5ef29f26ec8071f79c2f4f78dbe2bb0a613cc92d > src/tests/hierarchical_allocator_tests.cpp > 5f771f02db9bd098f3cd36730cd84bf2f5e87a33 > > 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 > >
