You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@mesos.apache.org by Timothy Chen <tn...@apache.org> on 2015/09/16 03:03:46 UTC

Review Request 38416: Allow HTTP response codes to be checked with code.

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

Review request for mesos, Anand Mazumdar, Jie Yu, Jojy Varghese, and Jiang Yan Xu.


Bugs: MESOS-3429
    https://issues.apache.org/jira/browse/MESOS-3429


Repository: mesos


Description
-------

Allow HTTP response codes to be checked with code.


Diffs
-----

  3rdparty/libprocess/include/process/http.hpp fbd6cf7967173495875a8ea90ed28ade88b982a2 

Diff: https://reviews.apache.org/r/38416/diff/


Testing
-------

make


Thanks,

Timothy Chen


Re: Review Request 38416: Allow HTTP response codes to be checked with code.

Posted by Joseph Wu <jo...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/38416/#review99304
-----------------------------------------------------------

Ship it!


Ship It!

- Joseph Wu


On Sept. 15, 2015, 6:03 p.m., Timothy Chen wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/38416/
> -----------------------------------------------------------
> 
> (Updated Sept. 15, 2015, 6:03 p.m.)
> 
> 
> Review request for mesos, Anand Mazumdar, Jie Yu, Jojy Varghese, and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-3429
>     https://issues.apache.org/jira/browse/MESOS-3429
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Allow HTTP response codes to be checked with code.
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/include/process/http.hpp fbd6cf7967173495875a8ea90ed28ade88b982a2 
> 
> Diff: https://reviews.apache.org/r/38416/diff/
> 
> 
> Testing
> -------
> 
> make
> 
> 
> Thanks,
> 
> Timothy Chen
> 
>


Re: Review Request 38416: Allow HTTP response codes to be checked with code.

Posted by Gilbert Song <gi...@mesoshere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/38416/#review99319
-----------------------------------------------------------

Ship it!


This improvement brings convenience.

- Gilbert Song


On Sept. 16, 2015, 1:03 a.m., Timothy Chen wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/38416/
> -----------------------------------------------------------
> 
> (Updated Sept. 16, 2015, 1:03 a.m.)
> 
> 
> Review request for mesos, Anand Mazumdar, Jie Yu, Jojy Varghese, and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-3429
>     https://issues.apache.org/jira/browse/MESOS-3429
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Allow HTTP response codes to be checked with code.
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/include/process/http.hpp fbd6cf7967173495875a8ea90ed28ade88b982a2 
> 
> Diff: https://reviews.apache.org/r/38416/diff/
> 
> 
> Testing
> -------
> 
> make
> 
> 
> Thanks,
> 
> Timothy Chen
> 
>


Re: Review Request 38416: Allow HTTP response codes to be checked with code.

Posted by Ben Mahler <be...@gmail.com>.

> On Sept. 16, 2015, 10:42 p.m., Ben Mahler wrote:
> > Looks like you're missing the change to decoder. On that note, what happens when we receive a response with a code that we haven't added to our enum?
> 
> Timothy Chen wrote:
>     You're right I missed the decoding part! Let me populate all the codes in the enum and set it correctly.

Keep in mind that we still have to handle codes we don't have in our enum (some are non-standard, we might receive something random, etc).


- Ben


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


On Sept. 16, 2015, 1:03 a.m., Timothy Chen wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/38416/
> -----------------------------------------------------------
> 
> (Updated Sept. 16, 2015, 1:03 a.m.)
> 
> 
> Review request for mesos, Anand Mazumdar, Jie Yu, Jojy Varghese, and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-3429
>     https://issues.apache.org/jira/browse/MESOS-3429
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Allow HTTP response codes to be checked with code.
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/include/process/http.hpp fbd6cf7967173495875a8ea90ed28ade88b982a2 
> 
> Diff: https://reviews.apache.org/r/38416/diff/
> 
> 
> Testing
> -------
> 
> make
> 
> 
> Thanks,
> 
> Timothy Chen
> 
>


Re: Review Request 38416: Allow HTTP response codes to be checked with code.

Posted by Timothy Chen <tn...@apache.org>.

> On Sept. 16, 2015, 10:42 p.m., Ben Mahler wrote:
> > Looks like you're missing the change to decoder. On that note, what happens when we receive a response with a code that we haven't added to our enum?
> 
> Timothy Chen wrote:
>     You're right I missed the decoding part! Let me populate all the codes in the enum and set it correctly.
> 
> Ben Mahler wrote:
>     Keep in mind that we still have to handle codes we don't have in our enum (some are non-standard, we might receive something random, etc).

definitely, the existing code that checks the http map will still exist.


- Timothy


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


On Sept. 16, 2015, 1:03 a.m., Timothy Chen wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/38416/
> -----------------------------------------------------------
> 
> (Updated Sept. 16, 2015, 1:03 a.m.)
> 
> 
> Review request for mesos, Anand Mazumdar, Jie Yu, Jojy Varghese, and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-3429
>     https://issues.apache.org/jira/browse/MESOS-3429
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Allow HTTP response codes to be checked with code.
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/include/process/http.hpp fbd6cf7967173495875a8ea90ed28ade88b982a2 
> 
> Diff: https://reviews.apache.org/r/38416/diff/
> 
> 
> Testing
> -------
> 
> make
> 
> 
> Thanks,
> 
> Timothy Chen
> 
>


Re: Review Request 38416: Allow HTTP response codes to be checked with code.

Posted by Timothy Chen <tn...@apache.org>.

> On Sept. 16, 2015, 10:42 p.m., Ben Mahler wrote:
> > Looks like you're missing the change to decoder. On that note, what happens when we receive a response with a code that we haven't added to our enum?

You're right I missed the decoding part! Let me populate all the codes in the enum and set it correctly.


- Timothy


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


On Sept. 16, 2015, 1:03 a.m., Timothy Chen wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/38416/
> -----------------------------------------------------------
> 
> (Updated Sept. 16, 2015, 1:03 a.m.)
> 
> 
> Review request for mesos, Anand Mazumdar, Jie Yu, Jojy Varghese, and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-3429
>     https://issues.apache.org/jira/browse/MESOS-3429
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Allow HTTP response codes to be checked with code.
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/include/process/http.hpp fbd6cf7967173495875a8ea90ed28ade88b982a2 
> 
> Diff: https://reviews.apache.org/r/38416/diff/
> 
> 
> Testing
> -------
> 
> make
> 
> 
> Thanks,
> 
> Timothy Chen
> 
>


Re: Review Request 38416: Allow HTTP response codes to be checked with code.

Posted by Ben Mahler <be...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/38416/#review99324
-----------------------------------------------------------


Looks like you're missing the change to decoder. On that note, what happens when we receive a response with a code that we haven't added to our enum?

- Ben Mahler


On Sept. 16, 2015, 1:03 a.m., Timothy Chen wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/38416/
> -----------------------------------------------------------
> 
> (Updated Sept. 16, 2015, 1:03 a.m.)
> 
> 
> Review request for mesos, Anand Mazumdar, Jie Yu, Jojy Varghese, and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-3429
>     https://issues.apache.org/jira/browse/MESOS-3429
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Allow HTTP response codes to be checked with code.
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/include/process/http.hpp fbd6cf7967173495875a8ea90ed28ade88b982a2 
> 
> Diff: https://reviews.apache.org/r/38416/diff/
> 
> 
> Testing
> -------
> 
> make
> 
> 
> Thanks,
> 
> Timothy Chen
> 
>


Re: Review Request 38416: Allow HTTP response codes to be checked with code.

Posted by Isabel Jimenez <co...@isabeljimenez.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/38416/#review99193
-----------------------------------------------------------

Ship it!


Ship It!

- Isabel Jimenez


On Sept. 16, 2015, 1:03 a.m., Timothy Chen wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/38416/
> -----------------------------------------------------------
> 
> (Updated Sept. 16, 2015, 1:03 a.m.)
> 
> 
> Review request for mesos, Anand Mazumdar, Jie Yu, Jojy Varghese, and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-3429
>     https://issues.apache.org/jira/browse/MESOS-3429
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Allow HTTP response codes to be checked with code.
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/include/process/http.hpp fbd6cf7967173495875a8ea90ed28ade88b982a2 
> 
> Diff: https://reviews.apache.org/r/38416/diff/
> 
> 
> Testing
> -------
> 
> make
> 
> 
> Thanks,
> 
> Timothy Chen
> 
>


Re: Review Request 38416: Allow HTTP response codes to be checked with code.

Posted by Ben Mahler <be...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/38416/#review100260
-----------------------------------------------------------



3rdparty/libprocess/include/process/http.hpp (lines 657 - 658)
<https://reviews.apache.org/r/38416/#comment157419>

    It seems odd to have the code duplicated above, can you set the status using the code?
    
    E.g.
    
    ```
        code = Status::SERVICE_UNAVAILABLE;
        status = stringify(code)+ " Service Unavailable";
    ```
    
    Or why don't we leverage the statuses map here? We have redundant information =/


- Ben Mahler


On Sept. 23, 2015, 7:59 a.m., Timothy Chen wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/38416/
> -----------------------------------------------------------
> 
> (Updated Sept. 23, 2015, 7:59 a.m.)
> 
> 
> Review request for mesos, Anand Mazumdar, Jie Yu, Jojy Varghese, and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-3429
>     https://issues.apache.org/jira/browse/MESOS-3429
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Allow HTTP response codes to be checked with code.
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/include/process/http.hpp fbd6cf7967173495875a8ea90ed28ade88b982a2 
>   3rdparty/libprocess/src/decoder.hpp 67a5135f302153e376e8dfe8db82aa0b15449389 
>   3rdparty/libprocess/src/http.cpp 9ad613a16c379b6d76a9a0f8d6160fe23a182fd4 
> 
> Diff: https://reviews.apache.org/r/38416/diff/
> 
> 
> Testing
> -------
> 
> make
> 
> 
> Thanks,
> 
> Timothy Chen
> 
>


Re: Review Request 38416: Allow HTTP response codes to be checked with code.

Posted by Mesos ReviewBot <re...@mesos.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/38416/#review100169
-----------------------------------------------------------


Patch looks great!

Reviews applied: [38416]

All tests passed.

- Mesos ReviewBot


On Sept. 23, 2015, 7:59 a.m., Timothy Chen wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/38416/
> -----------------------------------------------------------
> 
> (Updated Sept. 23, 2015, 7:59 a.m.)
> 
> 
> Review request for mesos, Anand Mazumdar, Jie Yu, Jojy Varghese, and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-3429
>     https://issues.apache.org/jira/browse/MESOS-3429
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Allow HTTP response codes to be checked with code.
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/include/process/http.hpp fbd6cf7967173495875a8ea90ed28ade88b982a2 
>   3rdparty/libprocess/src/decoder.hpp 67a5135f302153e376e8dfe8db82aa0b15449389 
>   3rdparty/libprocess/src/http.cpp 9ad613a16c379b6d76a9a0f8d6160fe23a182fd4 
> 
> Diff: https://reviews.apache.org/r/38416/diff/
> 
> 
> Testing
> -------
> 
> make
> 
> 
> Thanks,
> 
> Timothy Chen
> 
>


Re: Review Request 38416: Allow HTTP response codes to be checked with code.

Posted by Timothy Chen <tn...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/38416/
-----------------------------------------------------------

(Updated Sept. 25, 2015, 4:50 p.m.)


Review request for mesos, Anand Mazumdar, Jie Yu, Jojy Varghese, and Jiang Yan Xu.


Bugs: MESOS-3429
    https://issues.apache.org/jira/browse/MESOS-3429


Repository: mesos


Description
-------

Allow HTTP response codes to be checked with code.


Diffs (updated)
-----

  3rdparty/libprocess/include/process/http.hpp fbd6cf7967173495875a8ea90ed28ade88b982a2 
  3rdparty/libprocess/src/decoder.hpp 67a5135f302153e376e8dfe8db82aa0b15449389 
  3rdparty/libprocess/src/http.cpp 9ad613a16c379b6d76a9a0f8d6160fe23a182fd4 
  3rdparty/libprocess/src/process.cpp 4afa30569b4d235637b49a624602e6b199c32e0e 
  3rdparty/libprocess/src/tests/benchmarks.cpp 97c81b8e61a75771e5bf7d46505cec4e0c0f404a 
  3rdparty/libprocess/src/tests/http_tests.cpp d0b9399d38fa284466a012a21080b1d9007af98b 
  3rdparty/libprocess/src/tests/process_tests.cpp 1023500ac2e3c55be955c4686e7f720eba6b4cc9 
  src/scheduler/scheduler.cpp ee146eb81a8ad72bc04c62d1e223de6aa27b351d 

Diff: https://reviews.apache.org/r/38416/diff/


Testing
-------

make


Thanks,

Timothy Chen


Re: Review Request 38416: Allow HTTP response codes to be checked with code.

Posted by Timothy Chen <tn...@apache.org>.

> On Sept. 23, 2015, 4:58 p.m., Anand Mazumdar wrote:
> > 3rdparty/libprocess/src/http.cpp, line 77
> > <https://reviews.apache.org/r/38416/diff/2/?file=1082227#file1082227line77>
> >
> >     Why not implement a `stringify(...)` for the newly created enum and make the `statuses[]` use it ? This would allow us to now keep two things at sync at once unless I am missing something ?
> 
> Anand Mazumdar wrote:
>     Thinking about this again let's scope this patch to not cleaning up statuses for now. We can take it up as a separate issue. I am dropping this issue. Let me know if you feel otherwise.

This is fixed in this patch now as well.


- Timothy


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


On Sept. 25, 2015, 4:50 p.m., Timothy Chen wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/38416/
> -----------------------------------------------------------
> 
> (Updated Sept. 25, 2015, 4:50 p.m.)
> 
> 
> Review request for mesos, Anand Mazumdar, Ben Mahler, Jie Yu, Jojy Varghese, and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-3429
>     https://issues.apache.org/jira/browse/MESOS-3429
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Allow HTTP response codes to be checked with code.
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/include/process/http.hpp fbd6cf7967173495875a8ea90ed28ade88b982a2 
>   3rdparty/libprocess/src/decoder.hpp 67a5135f302153e376e8dfe8db82aa0b15449389 
>   3rdparty/libprocess/src/http.cpp 9ad613a16c379b6d76a9a0f8d6160fe23a182fd4 
>   3rdparty/libprocess/src/process.cpp 4afa30569b4d235637b49a624602e6b199c32e0e 
>   3rdparty/libprocess/src/tests/benchmarks.cpp 97c81b8e61a75771e5bf7d46505cec4e0c0f404a 
>   3rdparty/libprocess/src/tests/http_tests.cpp d0b9399d38fa284466a012a21080b1d9007af98b 
>   3rdparty/libprocess/src/tests/process_tests.cpp 1023500ac2e3c55be955c4686e7f720eba6b4cc9 
>   src/scheduler/scheduler.cpp ee146eb81a8ad72bc04c62d1e223de6aa27b351d 
> 
> Diff: https://reviews.apache.org/r/38416/diff/
> 
> 
> Testing
> -------
> 
> make
> 
> 
> Thanks,
> 
> Timothy Chen
> 
>


Re: Review Request 38416: Allow HTTP response codes to be checked with code.

Posted by Anand Mazumdar <ma...@gmail.com>.

> On Sept. 23, 2015, 4:58 p.m., Anand Mazumdar wrote:
> > 3rdparty/libprocess/src/http.cpp, line 77
> > <https://reviews.apache.org/r/38416/diff/2/?file=1082227#file1082227line77>
> >
> >     Why not implement a `stringify(...)` for the newly created enum and make the `statuses[]` use it ? This would allow us to now keep two things at sync at once unless I am missing something ?

Thinking about this again let's scope this patch to not cleaning up statuses for now. We can take it up as a separate issue. I am dropping this issue. Let me know if you feel otherwise.


- Anand


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


On Sept. 23, 2015, 7:59 a.m., Timothy Chen wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/38416/
> -----------------------------------------------------------
> 
> (Updated Sept. 23, 2015, 7:59 a.m.)
> 
> 
> Review request for mesos, Anand Mazumdar, Jie Yu, Jojy Varghese, and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-3429
>     https://issues.apache.org/jira/browse/MESOS-3429
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Allow HTTP response codes to be checked with code.
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/include/process/http.hpp fbd6cf7967173495875a8ea90ed28ade88b982a2 
>   3rdparty/libprocess/src/decoder.hpp 67a5135f302153e376e8dfe8db82aa0b15449389 
>   3rdparty/libprocess/src/http.cpp 9ad613a16c379b6d76a9a0f8d6160fe23a182fd4 
> 
> Diff: https://reviews.apache.org/r/38416/diff/
> 
> 
> Testing
> -------
> 
> make
> 
> 
> Thanks,
> 
> Timothy Chen
> 
>


Re: Review Request 38416: Allow HTTP response codes to be checked with code.

Posted by Anand Mazumdar <ma...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/38416/#review100211
-----------------------------------------------------------


LGTM , just some comments (see inline) around the `struct Status` being an `enum` directly and `int code` being an `Status code` too. We can do a `static_cast` in the decoder for converting the `int` status code to `enum` i.e. `decoder->response->code = static_cast<Status>(decoder->parser.status_code);` What do you think ?


3rdparty/libprocess/include/process/http.hpp (line 94)
<https://reviews.apache.org/r/38416/#comment157369>

    Why not `enum class Status` directly from C++11 ?



3rdparty/libprocess/include/process/http.hpp (line 391)
<https://reviews.apache.org/r/38416/#comment157370>

    Read my earlier comment about `struct Status` being `enum class Status` and this can be changed to `Status code` ?
    
    I hate `enum to int` conversions anyways :(



3rdparty/libprocess/src/http.cpp (line 77)
<https://reviews.apache.org/r/38416/#comment157368>

    Why not implement a `stringify(...)` for the newly created enum and make the `statuses[]` use it ? This would allow us to now keep two things at sync at once unless I am missing something ?


- Anand Mazumdar


On Sept. 23, 2015, 7:59 a.m., Timothy Chen wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/38416/
> -----------------------------------------------------------
> 
> (Updated Sept. 23, 2015, 7:59 a.m.)
> 
> 
> Review request for mesos, Anand Mazumdar, Jie Yu, Jojy Varghese, and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-3429
>     https://issues.apache.org/jira/browse/MESOS-3429
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Allow HTTP response codes to be checked with code.
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/include/process/http.hpp fbd6cf7967173495875a8ea90ed28ade88b982a2 
>   3rdparty/libprocess/src/decoder.hpp 67a5135f302153e376e8dfe8db82aa0b15449389 
>   3rdparty/libprocess/src/http.cpp 9ad613a16c379b6d76a9a0f8d6160fe23a182fd4 
> 
> Diff: https://reviews.apache.org/r/38416/diff/
> 
> 
> Testing
> -------
> 
> make
> 
> 
> Thanks,
> 
> Timothy Chen
> 
>


Re: Review Request 38416: Allow HTTP response codes to be checked with code.

Posted by Timothy Chen <tn...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/38416/
-----------------------------------------------------------

(Updated Sept. 23, 2015, 7:59 a.m.)


Review request for mesos, Anand Mazumdar, Jie Yu, Jojy Varghese, and Jiang Yan Xu.


Bugs: MESOS-3429
    https://issues.apache.org/jira/browse/MESOS-3429


Repository: mesos


Description
-------

Allow HTTP response codes to be checked with code.


Diffs (updated)
-----

  3rdparty/libprocess/include/process/http.hpp fbd6cf7967173495875a8ea90ed28ade88b982a2 
  3rdparty/libprocess/src/decoder.hpp 67a5135f302153e376e8dfe8db82aa0b15449389 
  3rdparty/libprocess/src/http.cpp 9ad613a16c379b6d76a9a0f8d6160fe23a182fd4 

Diff: https://reviews.apache.org/r/38416/diff/


Testing
-------

make


Thanks,

Timothy Chen


Re: Review Request 38416: Allow HTTP response codes to be checked with code.

Posted by Timothy Chen <tn...@apache.org>.

> On Sept. 16, 2015, 1:43 a.m., Guangya Liu wrote:
> >

it looks like the structs are ordered by response code, so just moving this to the right place assuming so


- Timothy


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


On Sept. 16, 2015, 1:03 a.m., Timothy Chen wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/38416/
> -----------------------------------------------------------
> 
> (Updated Sept. 16, 2015, 1:03 a.m.)
> 
> 
> Review request for mesos, Anand Mazumdar, Jie Yu, Jojy Varghese, and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-3429
>     https://issues.apache.org/jira/browse/MESOS-3429
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Allow HTTP response codes to be checked with code.
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/include/process/http.hpp fbd6cf7967173495875a8ea90ed28ade88b982a2 
> 
> Diff: https://reviews.apache.org/r/38416/diff/
> 
> 
> Testing
> -------
> 
> make
> 
> 
> Thanks,
> 
> Timothy Chen
> 
>


Re: Review Request 38416: Allow HTTP response codes to be checked with code.

Posted by Guangya Liu <gy...@gmail.com>.

> On Sept. 16, 2015, 1:43 a.m., Guangya Liu wrote:
> >
> 
> Timothy Chen wrote:
>     it looks like the structs are ordered by response code, so just moving this to the right place assuming so

Got it, this can make the code clear. Thanks.


- Guangya


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


On Sept. 16, 2015, 1:03 a.m., Timothy Chen wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/38416/
> -----------------------------------------------------------
> 
> (Updated Sept. 16, 2015, 1:03 a.m.)
> 
> 
> Review request for mesos, Anand Mazumdar, Jie Yu, Jojy Varghese, and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-3429
>     https://issues.apache.org/jira/browse/MESOS-3429
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Allow HTTP response codes to be checked with code.
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/include/process/http.hpp fbd6cf7967173495875a8ea90ed28ade88b982a2 
> 
> Diff: https://reviews.apache.org/r/38416/diff/
> 
> 
> Testing
> -------
> 
> make
> 
> 
> Thanks,
> 
> Timothy Chen
> 
>


Re: Review Request 38416: Allow HTTP response codes to be checked with code.

Posted by Guangya Liu <gy...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/38416/#review99147
-----------------------------------------------------------



3rdparty/libprocess/include/process/http.hpp (lines 559 - 584)
<https://reviews.apache.org/r/38416/#comment156036>

    Just curious why the order of the response are changed?


- Guangya Liu


On 九月 16, 2015, 1:03 a.m., Timothy Chen wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/38416/
> -----------------------------------------------------------
> 
> (Updated 九月 16, 2015, 1:03 a.m.)
> 
> 
> Review request for mesos, Anand Mazumdar, Jie Yu, Jojy Varghese, and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-3429
>     https://issues.apache.org/jira/browse/MESOS-3429
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Allow HTTP response codes to be checked with code.
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/include/process/http.hpp fbd6cf7967173495875a8ea90ed28ade88b982a2 
> 
> Diff: https://reviews.apache.org/r/38416/diff/
> 
> 
> Testing
> -------
> 
> make
> 
> 
> Thanks,
> 
> Timothy Chen
> 
>


Re: Review Request 38416: Allow HTTP response codes to be checked with code.

Posted by Mesos ReviewBot <re...@mesos.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/38416/#review99171
-----------------------------------------------------------


Patch looks great!

Reviews applied: [38416]

All tests passed.

- Mesos ReviewBot


On Sept. 16, 2015, 1:03 a.m., Timothy Chen wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/38416/
> -----------------------------------------------------------
> 
> (Updated Sept. 16, 2015, 1:03 a.m.)
> 
> 
> Review request for mesos, Anand Mazumdar, Jie Yu, Jojy Varghese, and Jiang Yan Xu.
> 
> 
> Bugs: MESOS-3429
>     https://issues.apache.org/jira/browse/MESOS-3429
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Allow HTTP response codes to be checked with code.
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/include/process/http.hpp fbd6cf7967173495875a8ea90ed28ade88b982a2 
> 
> Diff: https://reviews.apache.org/r/38416/diff/
> 
> 
> Testing
> -------
> 
> make
> 
> 
> Thanks,
> 
> Timothy Chen
> 
>