mesos-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From haosdent huang <haosd...@gmail.com>
Subject Re: Review Request 49243: Create readFile method in FilesProcess.
Date Mon, 27 Jun 2016 14:43:01 GMT

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




src/files/files.hpp (lines 64 - 67)
<https://reviews.apache.org/r/49243/#comment204831>

    These codes look more like http error codes. XD



src/files/files.hpp (lines 70 - 73)
<https://reviews.apache.org/r/49243/#comment204830>

    Refert to
    ```
    class ErrnoError : public Error
    {
    public:
      ErrnoError() : Error(os::strerror(errno)), code(errno) {}
    
      ErrnoError(const std::string& message)
        : Error(message + ": " + os::strerror(errno)), code(errno) {}
    
      const int code;
    };
    ```
    
    Maybe we coud use `FilesError(Type _type)` and `FilesError(Type _type, std::string _message)`?



src/files/files.cpp (lines 83 - 85)
<https://reviews.apache.org/r/49243/#comment204825>

    Why move these lines?



src/files/files.cpp (lines 485 - 495)
<https://reviews.apache.org/r/49243/#comment204827>

    Indent 2 spaces for case/default keyword.



src/files/files.cpp (line 527)
<https://reviews.apache.org/r/49243/#comment204832>

    Looks like we always add `\n`, is it possible to move it to `FilesError`?


- haosdent huang


On June 27, 2016, 9:11 a.m., zhou xing wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/49243/
> -----------------------------------------------------------
> 
> (Updated June 27, 2016, 9:11 a.m.)
> 
> 
> Review request for mesos, Anand Mazumdar, haosdent huang, and Vinod Kone.
> 
> 
> Bugs: mesos-5515
>     https://issues.apache.org/jira/browse/mesos-5515
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> This method helps to readFiles based on offset, length
> and path, which can be used for implementing master/agent's
> READ_FILE operator v1 API.
> 
> 
> Diffs
> -----
> 
>   src/files/files.hpp b767d5bc5bee16e3bd98199773a6bc7d30c1c32d 
>   src/files/files.cpp a5a1b86e14f63e5e3834a2900270252fbe16f586 
> 
> Diff: https://reviews.apache.org/r/49243/diff/
> 
> 
> Testing
> -------
> 
> make
> make check
> 
> 
> Thanks,
> 
> zhou xing
> 
>


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