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




src/master/master.cpp
Line 7295 (original), 7329 (patched)
<https://reviews.apache.org/r/65591/#comment277558>

    This should be `!contains`, right?



src/master/master.cpp
Lines 7334-7336 (patched)
<https://reviews.apache.org/r/65591/#comment277560>

    You compare operations here for resource providers. This isn't done in the 
code above for agent operations. Please add a comment, why this is necessary 
here but not for agent operations.



src/master/master.cpp
Line 7392 (original), 7351 (patched)
<https://reviews.apache.org/r/65591/#comment277562>

    Name this `resourceProvider` to be consistent with the code above (or use 
`provider` in the code above). Here and below when iterating over 
`message.resource_providers().providers()`.



src/master/master.cpp
Lines 7546-7547 (original), 7437-7438 (patched)
<https://reviews.apache.org/r/65591/#comment277564>

    This makes no sense, slave operations are tracked separately from resource 
provider operations. Please remove.



src/master/master.cpp
Lines 7448 (patched)
<https://reviews.apache.org/r/65591/#comment277565>

    This doesn't feel right. We don't want to add an operation to the agent 
here, only to the respective resource provider -- but might want to update used 
resources of the agent.



src/master/master.cpp
Lines 7516 (patched)
<https://reviews.apache.org/r/65591/#comment277566>

    This is redundant, as we're iterating over `oldProvider.operations` here.



src/master/master.cpp
Lines 7517-7518 (patched)
<https://reviews.apache.org/r/65591/#comment277567>

    Could iterate using `foreachpair` instead.



src/master/master.cpp
Lines 7520 (patched)
<https://reviews.apache.org/r/65591/#comment277568>

    Also redundant, as that guaranteed by the `else` case we're currently in.



src/master/master.cpp
Line 7616 (original), 7527 (patched)
<https://reviews.apache.org/r/65591/#comment277569>

    Agent shouldn't keep track of resource provider operations.



src/master/master.cpp
Lines 7626-7627 (original), 7537-7538 (patched)
<https://reviews.apache.org/r/65591/#comment277570>

    Probably needs to be updated to handle resource provider operations.


- Jan Schlicht


On Feb. 9, 2018, 6:27 p.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/65591/
> -----------------------------------------------------------
> 
> (Updated Feb. 9, 2018, 6:27 p.m.)
> 
> 
> Review request for mesos, Jie Yu and Jan Schlicht.
> 
> 
> Bugs: MESOS-8382
>     https://issues.apache.org/jira/browse/MESOS-8382
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> This patch adds explicit tracking of resource providers to the master
> process. While we already had explicitly send resource provider
> information in e.g., `UpdateSlaveMessage`, we only stored that
> information aggregated over the full agent in the master up to now.
> 
> 
> Diffs
> -----
> 
>   src/common/protobuf_utils.cpp b5c2997ada8362e42150fa3cfd762120e5ea715f 
>   src/master/master.hpp b434d2398b8815811345b6586ca586d2025cb2a2 
>   src/master/master.cpp d7d22866f7a4eb87bd8949efafc97e828e7d4b94 
> 
> 
> Diff: https://reviews.apache.org/r/65591/diff/1/
> 
> 
> Testing
> -------
> 
> `make check`
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>

Reply via email to