> On 一月 19, 2016, 1:31 p.m., Niklas Nielsen wrote: > > src/slave/slave.cpp, lines 1485-1524 > > <https://reviews.apache.org/r/39848/diff/2/?file=1116597#file1116597line1485> > > > > +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?
Thanks Niklas, I will upload a new patch later and will use `contain` to check if the reources are available for the task. - Guangya ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/39848/#review115154 ----------------------------------------------------------- On 一月 19, 2016, 10:39 a.m., Guangya Liu wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/39848/ > ----------------------------------------------------------- > > (Updated 一月 19, 2016, 10: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 > >
