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


Fix it, then Ship it!





src/master/allocator/mesos/sorter/sorter.hpp
Lines 132-137 (original), 132-137 (patched)
<https://reviews.apache.org/r/71672/#comment306114>

    I find the comments to be a little bit convoluted, don't think we need to 
mention shared, how about:
    
    ```
    // NOTE: Sorter provides no direct method to modify resource quantities on 
an
    // agent. Updating is done by first `removeSlave()` and then `addSlave()` 
with
    // new resource quantities.
    ```


- Meng Zhu


On Oct. 24, 2019, 10:05 a.m., Andrei Sekretenko wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/71672/
> -----------------------------------------------------------
> 
> (Updated Oct. 24, 2019, 10:05 a.m.)
> 
> 
> Review request for mesos, Benjamin Mahler and Meng Zhu.
> 
> 
> Bugs: MESOS-10015
>     https://issues.apache.org/jira/browse/MESOS-10015
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> This patch moves conversion of agent `Resources` into `ScalarQuantities`
> out of the Sorter. This results in performance improvement of
> allocator's `updateAllocation()` method.
> 
> Results of `*BENCHMARK_WithReservationParam.UpdateAllocation*`:
> 
> Master + previous patch:
> Agent resources size: 200 (50 frameworks)
> Made 20 reserve and unreserve operations in 471.781183ms
> Agent resources size: 400 (100 frameworks)
> Made 20 reserve and unreserve operations in 1.022879058secs
> Agent resources size: 800 (200 frameworks)
> Made 20 reserve and unreserve operations in 2.622324521secs
> ...
> Agent resources size: 6400 (1600 frameworks)
> Made 20 reserve and unreserve operations in 2.04261335795mins
> 
> Master + previous patch + this patch:
> Agent resources size: 200 (50 frameworks)
> Made 20 reserve and unreserve operations in 463.223084ms
> Agent resources size: 400 (100 frameworks)
> Made 20 reserve and unreserve operations in 930.097972ms
> Agent resources size: 800 (200 frameworks)
> Made 20 reserve and unreserve operations in 2.160506847secs
> ...
> Agent resources size: 6400 (1600 frameworks)
> Made 20 reserve and unreserve operations in 1.50729369885mins
> 
> 
> Diffs
> -----
> 
>   src/master/allocator/mesos/hierarchical.cpp 
> 21010de363f25c516bb031e4ae48888e53621128 
>   src/master/allocator/mesos/sorter/drf/sorter.hpp 
> 3f6c7413f1b76f3fa86388360983763c8b76079f 
>   src/master/allocator/mesos/sorter/drf/sorter.cpp 
> ef79083b710fba628b4a7e93f903883899f8a71b 
>   src/master/allocator/mesos/sorter/random/sorter.hpp 
> a3097be98d175d2b47714eb8b70b1ce8c5c2bba8 
>   src/master/allocator/mesos/sorter/random/sorter.cpp 
> 86aeb1b8136eaffd2d52d3b603636b01383a9024 
>   src/master/allocator/mesos/sorter/sorter.hpp 
> 6b6b4a1811ba36e0212de17b9a6e63a6f8678a7f 
>   src/tests/sorter_tests.cpp d7fdee8f2cab4c930230750f0bd1a55eb08f89bb 
> 
> 
> Diff: https://reviews.apache.org/r/71672/diff/1/
> 
> 
> Testing
> -------
> 
> make check
> 
> ran `*BENCHMARK_WithReservationParam.UpdateAllocation*`
> 
> 
> Thanks,
> 
> Andrei Sekretenko
> 
>

Reply via email to