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 60015: Resources: Introduced `currentRole` and `currentPrincipal`.
Date Tue, 13 Jun 2017 18:15:10 GMT

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




include/mesos/resources.hpp
Lines 307-309 (patched)
<https://reviews.apache.org/r/60015/#comment251477>

    How about:
    
    ```
    reservationRole
    reservationPrincipal
    ```
    
    And noting that this is how people should get the role going forward, instead of accessing
Resource.role directly.



src/common/resources.cpp
Lines 974-976 (original), 972-974 (patched)
<https://reviews.apache.org/r/60015/#comment251478>

    Can you avoid the perfomance loss here? The code within Resources is performance sensitive.
If I don't provide a role, no need to copy out the reservation role (i.e. the old logic was
more efficient).



src/common/resources.cpp
Lines 986-988 (original), 982-985 (patched)
<https://reviews.apache.org/r/60015/#comment251479>

    currentRole in this context seems less readable, how about `reservationRole` and the following:
    
    I guess this function will be changing based on earlier feedback, so I won't leave more
detailed feedback but note the roles::isSubRole I mentioned from the previous patch could
be used here.


- Benjamin Mahler


On June 13, 2017, 8:34 a.m., Michael Park wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/60015/
> -----------------------------------------------------------
> 
> (Updated June 13, 2017, 8:34 a.m.)
> 
> 
> Review request for mesos and Benjamin Mahler.
> 
> 
> Bugs: MESOS-7655
>     https://issues.apache.org/jira/browse/MESOS-7655
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Resources: Introduced `currentRole` and `currentPrincipal`.
> 
> 
> Diffs
> -----
> 
>   include/mesos/resources.hpp 451b0cef6f84743e3d630104ba6f55665793f2bc 
>   include/mesos/v1/resources.hpp c790927353122a4eb2bbbee31c6df57d97f3994b 
>   src/common/resources.cpp f89f1aae7845f1e93dd5947de2e7a8e2bfce8bc4 
>   src/v1/resources.cpp 24240eedc4b2747ca02998534437318c3396db4d 
> 
> 
> Diff: https://reviews.apache.org/r/60015/diff/2/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Michael Park
> 
>


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