mesos-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chun-Hung Hsiao <chhs...@apache.org>
Subject Re: Review Request 66050: Implemented grow and shrink of persistent volumes.
Date Thu, 26 Apr 2018 21:26:03 GMT

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




src/master/master.cpp
Line 4565 (original), 4563 (patched)
<https://reviews.apache.org/r/66050/#comment283689>

    As discussed, let's add the following variable:
    ```
    // TODO(zhitao): Remove this once `GROW_VOLUME` and `SHRINK_VOLUME` become
    // non-speculative.
    Resources resizedResources;
    ```



src/master/master.cpp
Lines 4947-4954 (patched)
<https://reviews.apache.org/r/66050/#comment283687>

    As discussed, let's do:
    ```
    CHECK_EQ(1u, _conversions->size());
    const Resources& consumed = _conversions->at(0).consumed;
    const Resources& converted = _conversinos->at(0).converted;
    
    if (!_offeredResources.contains(consumed)) {
      drop(...);
      continue;
    }
    
    _offeredResources -= consumed;
    resizedResources += converted;
    ```
    here and below. We can drop r/66568.



src/master/master.cpp
Lines 5503-5510 (original), 5636-5643 (patched)
<https://reviews.apache.org/r/66050/#comment283688>

    As discussed, let's do
    ```
    // TODO(zhitao): Remove `resizedResources` once `GROW_VOLUME` and
    // `SHRINK_VOLUME` become non-speculative.
    if (!_offeredResources.empty() || !resizedResources.empty()) {
      allocator->recoverResources(..., _offeredResources + resizedResources, ...);
    }
    ```


- Chun-Hung Hsiao


On April 24, 2018, 9:16 p.m., Zhitao Li wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/66050/
> -----------------------------------------------------------
> 
> (Updated April 24, 2018, 9:16 p.m.)
> 
> 
> Review request for mesos, Chun-Hung Hsiao, Gaston Kleiman, and Greg Mann.
> 
> 
> Bugs: MESOS-4965
>     https://issues.apache.org/jira/browse/MESOS-4965
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> The new offer operations are implemented as speculative operations, but
> we will use validation to make them non-speculative on API level so that
> we can transition later without a breaking change.
> 
> 
> Diffs
> -----
> 
>   src/common/protobuf_utils.cpp 78bffd8595f0e9f34e981548d8136ff94160573b 
>   src/common/resources_utils.cpp 9be01c1abd48264e308960f35cc7c2ee8a367518 
>   src/master/master.cpp c723a291ed8d219ced4492bc905ac6b52683ae47 
>   src/master/validation.hpp 7c129ceb929596acbb64d37025e055661277e6bf 
>   src/master/validation.cpp ac2e1bb8771841ec59b3bdcdeffb6c6230680d4d 
> 
> 
> Diff: https://reviews.apache.org/r/66050/diff/13/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Zhitao Li
> 
>


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