mesos-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Benjamin Mahler <bmah...@apache.org>
Subject Re: Review Request 69603: Extended `min_allocatable_resources` flag to cover non-scalar resources.
Date Fri, 04 Jan 2019 22:33:47 GMT

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


Fix it, then Ship it!





src/master/allocator/mesos/hierarchical.cpp
Line 2435 (original), 2435 (patched)
<https://reviews.apache.org/r/69603/#comment297202>

    we should already be in mesos::internal here, did you find you needed to specify?



src/master/master.cpp
Line 742 (original), 734 (patched)
<https://reviews.apache.org/r/69603/#comment297199>

    not yours but looks like this colon should be removed



src/master/master.cpp
Lines 749-750 (original), 741-742 (patched)
<https://reviews.apache.org/r/69603/#comment297200>

    probably `resourceQuantities->begin()` / end() is more readable?



src/master/master.cpp
Line 752 (original), 744 (patched)
<https://reviews.apache.org/r/69603/#comment297201>

    Maybe we can declare first class resources down here where we use it, to make the code
more readable? we're not worried about the cost of re-constructing it in each loop iteration



src/master/master.cpp
Lines 750 (patched)
<https://reviews.apache.org/r/69603/#comment297203>

    Probably just want to use `*resourceQuantities` since we handle the error case above.


- Benjamin Mahler


On Jan. 4, 2019, 8:54 p.m., Meng Zhu wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/69603/
> -----------------------------------------------------------
> 
> (Updated Jan. 4, 2019, 8:54 p.m.)
> 
> 
> Review request for mesos and Benjamin Mahler.
> 
> 
> Bugs: MESOS-9324
>     https://issues.apache.org/jira/browse/MESOS-9324
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> The master flag min_allocatable_resources currently only supports
> scalar resources. Sometimes it is desirable to control the quantities
> of non-scalar resources in the offer as well, for example, to
> ensure offers always contain port resources.
> 
> This patch extended the flag to cover non-scalar resources.
> For RANGES and SET type resources, their quantities are the
> number of different instances in the range or set. For example,
> range:[1-5] has a quantity of 5 and set:{a,b} has a quantity of 2.
> 
> This patch also updated affected tests and modified the existing
> test for min_allocatable_resources to cover the updated use cases.
> 
> 
> Diffs
> -----
> 
>   docs/configuration/master.md 83b83b0b7a41f982c8680cee21f0971a0877e49e 
>   include/mesos/allocator/allocator.hpp 2a6849bf698f171fc31c84165bd574b8f4f846ea 
>   src/master/allocator/mesos/hierarchical.cpp cc8ab919aedb33cf424edfdb622ca13a2cc8ff0f

>   src/master/flags.cpp f9b68bcd5668160a7e90d6569f69f2713df802fe 
>   src/master/master.cpp b4faf2b077a0288ba36195b7a21402932489d316 
>   src/tests/hierarchical_allocator_benchmarks.cpp 527a25d1414882012f3906370bd1a2a7b40a92f2

>   src/tests/hierarchical_allocator_tests.cpp a3a6d7bb956a6d16f01e2c312d69f704fcbe9ddd

>   src/tests/master_allocator_tests.cpp 9dbab1822ea83ac912a56eb3196060c648a2a672 
> 
> 
> Diff: https://reviews.apache.org/r/69603/diff/2/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Meng Zhu
> 
>


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