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 65806: Fixed a bug where quota headroom is miscalculated.
Date Tue, 27 Feb 2018 04:32:41 GMT

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


Ship it!





src/master/allocator/mesos/hierarchical.cpp
Lines 1677-1678 (original), 1677-1679 (patched)
<https://reviews.apache.org/r/65806/#comment278431>

    Do we need the new variable? Looks like we just need to do the following in the equation
below:
    
    ```
    availableHeadroom -=
      Resources::sum(reservationScalarQuantities) -
      totalAllocatedReservationScalarQuantities;
    ```



src/master/allocator/mesos/hierarchical.cpp
Lines 1681-1688 (patched)
<https://reviews.apache.org/r/65806/#comment278432>

    How about:
    
      // Calculate total allocated reservations. Note that we need to ensure
      // we count a reservation for "a" being allocated to "a/b", therefore
      // we cannot simply loop over the reservations' roles.



src/master/allocator/mesos/hierarchical.cpp
Lines 1697-1698 (patched)
<https://reviews.apache.org/r/65806/#comment278433>

    We could inline this to make it a little more succinct:
    
    ```
          continue; // This role has no allocation.
    ```


- Benjamin Mahler


On Feb. 27, 2018, 2:46 a.m., Meng Zhu wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/65806/
> -----------------------------------------------------------
> 
> (Updated Feb. 27, 2018, 2:46 a.m.)
> 
> 
> Review request for mesos, Benjamin Mahler and Michael Park.
> 
> 
> Bugs: MESOS-8604
>     https://issues.apache.org/jira/browse/MESOS-8604
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> When calculating the quota headroom, we failed to consider
> ancestor's reservation allocated to the child. This leads
> to under-estimation of available headroom and excessive
> resources being set aside for headroom. See MESOS-8604.
> 
> This patches fixes this issue by counting ancestor's reservation
> allocated to the child as allocated-reservation even though
> the child itself has no reservation.
> 
> 
> Diffs
> -----
> 
>   src/master/allocator/mesos/hierarchical.cpp 80e0a347d6641c922cf7c62bef220ff5c8864597

> 
> 
> Diff: https://reviews.apache.org/r/65806/diff/1/
> 
> 
> Testing
> -------
> 
> make check
> Dedicated test in #65807
> 
> 
> Thanks,
> 
> Meng Zhu
> 
>


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