mesos-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Adam B" <a...@mesosphere.io>
Subject Re: Review Request 41597: Extending allocator interface to support dynamic weights
Date Mon, 04 Jan 2016 10:23:38 GMT

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


Looks good. Nice, simple, and clean. Just a few suggestions, and we'll get this in.


include/mesos/mesos.proto (line 1669)
<https://reviews.apache.org/r/41597/#comment173017>

    Let's make it `optional`, in case we later want to add weights per principal, frameworkId,
etc. Experienced protobuffers say "`required` is forever" and usually only recommend one required
field per protobuf message. Since this is a WeightInfo, only `weight` needs to be required.



include/mesos/mesos.proto (lines 1676 - 1678)
<https://reviews.apache.org/r/41597/#comment173018>

    Do we really need this message? Can't we just use `repeated WeightInfo weightInfos` in
any other protobuf that needs this, or use `vector<WeightInfo>` in the allocator API?



src/master/allocator/mesos/hierarchical.cpp (line 1044)
<https://reviews.apache.org/r/41597/#comment173024>

    How about `updatingActiveRole`?



src/master/allocator/mesos/hierarchical.cpp (lines 1061 - 1063)
<https://reviews.apache.org/r/41597/#comment173025>

    Why not do this check up with line 1048 where you set the weight in the `weights[]` map?
Doesn't make sense to update the entry in the map and then erase it.



src/master/allocator/mesos/hierarchical.cpp (line 1066)
<https://reviews.apache.org/r/41597/#comment173023>

    "If at least one of the updated roles has registered frameworks, then trigger..."


- Adam B


On Jan. 4, 2016, 12:27 a.m., Yongqiao Wang wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/41597/
> -----------------------------------------------------------
> 
> (Updated Jan. 4, 2016, 12:27 a.m.)
> 
> 
> Review request for mesos, Adam B, Neil Conway, and Qian Zhang.
> 
> 
> Bugs: MESOS-3943
>     https://issues.apache.org/jira/browse/MESOS-3943
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Add the interface in allocator to support updating weight
> at runtime, and the allocator is invoked to allocate the
> resources based on the updated weights later.
> 
> 
> Diffs
> -----
> 
>   include/mesos/master/allocator.hpp f7ada68d7111486d264284990996413bb33333d6 
>   include/mesos/mesos.proto 158e08774c4a4fa5ec667388c61e55dbdafc7f67 
>   include/mesos/v1/mesos.proto c6c5a81eb9282d188d90fe395e1c16633a2a64cf 
>   src/master/allocator/mesos/allocator.hpp 50ef3b20f34bc6d87cbeccabcebec9a5031a6554 
>   src/master/allocator/mesos/hierarchical.hpp 86ea5a402ed67f8f22f11d5730147cd907d66a08

>   src/master/allocator/mesos/hierarchical.cpp 7f900c4e024485704d79e57ae22407557598fe6c

>   src/master/allocator/sorter/drf/sorter.hpp 050896e8b12cd4097ccd137d5284d6b39b0f06ab

>   src/master/allocator/sorter/drf/sorter.cpp 3a442f121f3a1505513877a5c78458a4b8d0a824

>   src/master/allocator/sorter/sorter.hpp 7be6b44a762fd62c2cd7f28b4dc4865a4587ed26 
>   src/tests/allocator.hpp 9bdfaecf1a148f113ad52956b50ed7cabe0902ef 
> 
> Diff: https://reviews.apache.org/r/41597/diff/
> 
> 
> Testing
> -------
> 
> Make & Make check successfully!
> 
> Test case: https://reviews.apache.org/r/41672/
> 
> 
> Thanks,
> 
> Yongqiao Wang
> 
>


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