mesos-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jie Yu" <yujie....@gmail.com>
Subject Re: Review Request 42505: Multiple Disk: Adjusted DiskInfo validation.
Date Thu, 21 Jan 2016 21:59:17 GMT

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



src/common/resources.cpp (lines 694 - 705)
<https://reviews.apache.org/r/42505/#comment176730>

    I would probably save the 'source' reference first to avoid calling `resource.disk().source()`
multiple times:
    ```
    const Resource::DiskInfo& disk = resource.disk();
    ...
    if (resource.disk().has_source()) {
      const Resource::DiskInfo::Source& source = resource.disk().source();
      
      if (source.type() == ... && !source.has_path()) {
        ...
      }
      
      ...
    }
    ```



src/master/validation.cpp (lines 180 - 184)
<https://reviews.apache.org/r/42505/#comment176732>

    This is not needed. This is already called in `resource::validate`.


- Jie Yu


On Jan. 21, 2016, 7:40 a.m., Joris Van Remoortere wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/42505/
> -----------------------------------------------------------
> 
> (Updated Jan. 21, 2016, 7:40 a.m.)
> 
> 
> Review request for mesos, Jie Yu and Michael Park.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Multiple Disk: Adjusted DiskInfo validation.
> 
> 
> Diffs
> -----
> 
>   src/common/resources.cpp 575d6651185d8431f01d589f4afc255cb751181a 
>   src/master/validation.cpp 98360b690382ed1912a868ac93b058cb28003a12 
>   src/v1/resources.cpp 8de6672ba9b34947db81c74b8e03e8965e8af5fc 
> 
> Diff: https://reviews.apache.org/r/42505/diff/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Joris Van Remoortere
> 
>


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