----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/39848/#review115154 -----------------------------------------------------------
src/slave/slave.cpp (lines 1485 - 1524) <https://reviews.apache.org/r/39848/#comment176044> +1 to Vinod's comment on 'validation.cpp'. Another suggestion which doesn't require a large refactor, could be to move some of the comparison code into the Resources class itself. That way, it could be something like: if(_resources_revocable_total < task.resources().revocable()) { ... } Also, any reason this need to happen in this continuation of runTask() and not the earlier one? - Niklas Nielsen On Jan. 19, 2016, 2:39 a.m., Guangya Liu wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/39848/ > ----------------------------------------------------------- > > (Updated Jan. 19, 2016, 2:39 a.m.) > > > Review request for mesos, Niklas Nielsen and Vinod Kone. > > > Bugs: MESOS-2647 > https://issues.apache.org/jira/browse/MESOS-2647 > > > Repository: mesos > > > Description > ------- > > Validates if there are enough revocable resources when launching > the task on slave. > > > Diffs > ----- > > src/slave/slave.cpp ddeece4334b13cf8b5ab7d87012bbf946640025b > > Diff: https://reviews.apache.org/r/39848/diff/ > > > Testing > ------- > > make > make check > > > Thanks, > > Guangya Liu > >
