----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/51027/#review158818 -----------------------------------------------------------
This patch itself LGTM. Will give ship it once we confirm the flaky tests are fixed and we have at least minimal test for its efficacy. src/master/allocator/mesos/hierarchical.hpp (line 224) <https://reviews.apache.org/r/51027/#comment229654> To make it more clear to the reader, we can explain what the future means: ``` The returned future becomes ready when the latest allocation run which commences after this call has completed. NOTE: At any given moment there's at most one allocation run pending or being executed. ``` src/master/allocator/mesos/hierarchical.hpp (line 227) <https://reviews.apache.org/r/51027/#comment229655> The following should be sufficient. ``` // Method that performs the allocation work. ``` src/master/allocator/mesos/hierarchical.cpp (lines 1281 - 1282) <https://reviews.apache.org/r/51027/#comment229657> Does this work? ``` return allocate({slaveId}); ``` src/master/allocator/mesos/hierarchical.cpp (lines 1297 - 1298) <https://reviews.apache.org/r/51027/#comment229636> "allocation-triggering events" better than "events triggering allocations"? src/master/allocator/mesos/hierarchical.cpp (line 1299) <https://reviews.apache.org/r/51027/#comment229637> s/a single slaveId/a single `slaveId`/ to be consistent. src/master/allocator/mesos/hierarchical.cpp (lines 1334 - 1338) <https://reviews.apache.org/r/51027/#comment229638> Clear the candidates after the log line because you need `allocationCandidates.size()`? src/master/allocator/mesos/hierarchical.cpp (line 1347) <https://reviews.apache.org/r/51027/#comment229652> Move this to `run()`, above `Stopwatch stopwatch;`. - Jiang Yan Xu On Oct. 18, 2016, 9:14 a.m., Jacob Janco wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/51027/ > ----------------------------------------------------------- > > (Updated Oct. 18, 2016, 9:14 a.m.) > > > Review request for mesos, Benjamin Mahler, Guangya Liu, James Peach, Klaus > Ma, and Jiang Yan Xu. > > > Bugs: MESOS-3157 > https://issues.apache.org/jira/browse/MESOS-3157 > > > Repository: mesos > > > Description > ------- > > - Triggered allocations dispatch allocate() only > if there is no pending allocation in the queue. > - Allocation candidates are accumulated and only > cleared when enqueued allocations are processed. > > > Diffs > ----- > > src/master/allocator/mesos/hierarchical.hpp > 2c31471ee0f5d6836393bf87ff9ecfd8df835013 > src/master/allocator/mesos/hierarchical.cpp > c8f9492ee1b69e125a1e841116d22a578a9b524e > > Diff: https://reviews.apache.org/r/51027/diff/ > > > Testing > ------- > > make check > > note: check without filters depends on https://reviews.apache.org/r/51028 and > https://reviews.apache.org/r/52534 > > > Thanks, > > Jacob Janco > >
