Re: Review Request 33935: Improved HTTP request logging for master/slave endpoints.

2015-05-07 Thread Mesos ReviewBot

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


Patch looks great!

Reviews applied: [33933, 33934, 33935]

All tests passed.

- Mesos ReviewBot


On May 7, 2015, 10 p.m., Ben Mahler wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/33935/
> ---
> 
> (Updated May 7, 2015, 10 p.m.)
> 
> 
> Review request for mesos, Jie Yu and Vinod Kone.
> 
> 
> Bugs: MESOS-2519
> https://issues.apache.org/jira/browse/MESOS-2519
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> This adds the client address, as well as user-agent and forwarding 
> information, if present.
> 
> 
> Diffs
> -
> 
>   src/master/http.cpp fb448256d7ced1f47ea48ccfca2ae267bc26ef94 
>   src/master/master.hpp 49ee050ca4d2b2c5f75ce864fcf6ae703dfdeadd 
>   src/master/master.cpp bee842557c8397428ca51e46faa182a391584be3 
>   src/slave/http.cpp f678aabdccd8c16e25c18ffb5075265ed8b76a70 
>   src/slave/slave.hpp 654a8698be88e0d0f588190775dc3eee6b36f92e 
>   src/slave/slave.cpp c78ee3c9e7fc38ad364e83f4abe267e86bfbbc13 
> 
> Diff: https://reviews.apache.org/r/33935/diff/
> 
> 
> Testing
> ---
> 
> Tested manually:
> 
> I0507 05:41:37.386196 28393 http.cpp:233] HTTP GET for /master/state.json 
> from 127.0.0.1:5050 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
> libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'
> 
> I0507 05:42:34.905570 31000 http.cpp:237] HTTP GET for /slave(1)/state.json 
> from 127.0.0.1:5051 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
> libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'
> 
> 
> Thanks,
> 
> Ben Mahler
> 
>



Re: Review Request 33935: Improved HTTP request logging for master/slave endpoints.

2015-05-07 Thread Ben Mahler

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

(Updated May 7, 2015, 10 p.m.)


Review request for mesos, Jie Yu and Vinod Kone.


Changes
---

Missed a bind conversion to a lambda.


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


Repository: mesos


Description
---

This adds the client address, as well as user-agent and forwarding information, 
if present.


Diffs (updated)
-

  src/master/http.cpp fb448256d7ced1f47ea48ccfca2ae267bc26ef94 
  src/master/master.hpp 49ee050ca4d2b2c5f75ce864fcf6ae703dfdeadd 
  src/master/master.cpp bee842557c8397428ca51e46faa182a391584be3 
  src/slave/http.cpp f678aabdccd8c16e25c18ffb5075265ed8b76a70 
  src/slave/slave.hpp 654a8698be88e0d0f588190775dc3eee6b36f92e 
  src/slave/slave.cpp c78ee3c9e7fc38ad364e83f4abe267e86bfbbc13 

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


Testing
---

Tested manually:

I0507 05:41:37.386196 28393 http.cpp:233] HTTP GET for /master/state.json from 
127.0.0.1:5050 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'

I0507 05:42:34.905570 31000 http.cpp:237] HTTP GET for /slave(1)/state.json 
from 127.0.0.1:5051 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'


Thanks,

Ben Mahler



Re: Review Request 33935: Improved HTTP request logging for master/slave endpoints.

2015-05-07 Thread Ben Mahler


> On May 7, 2015, 9:56 p.m., Jie Yu wrote:
> > src/master/master.cpp, lines 740-742
> > 
> >
> > Forgot this one?

Thanks for catching that!


- Ben


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


On May 7, 2015, 10 p.m., Ben Mahler wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/33935/
> ---
> 
> (Updated May 7, 2015, 10 p.m.)
> 
> 
> Review request for mesos, Jie Yu and Vinod Kone.
> 
> 
> Bugs: MESOS-2519
> https://issues.apache.org/jira/browse/MESOS-2519
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> This adds the client address, as well as user-agent and forwarding 
> information, if present.
> 
> 
> Diffs
> -
> 
>   src/master/http.cpp fb448256d7ced1f47ea48ccfca2ae267bc26ef94 
>   src/master/master.hpp 49ee050ca4d2b2c5f75ce864fcf6ae703dfdeadd 
>   src/master/master.cpp bee842557c8397428ca51e46faa182a391584be3 
>   src/slave/http.cpp f678aabdccd8c16e25c18ffb5075265ed8b76a70 
>   src/slave/slave.hpp 654a8698be88e0d0f588190775dc3eee6b36f92e 
>   src/slave/slave.cpp c78ee3c9e7fc38ad364e83f4abe267e86bfbbc13 
> 
> Diff: https://reviews.apache.org/r/33935/diff/
> 
> 
> Testing
> ---
> 
> Tested manually:
> 
> I0507 05:41:37.386196 28393 http.cpp:233] HTTP GET for /master/state.json 
> from 127.0.0.1:5050 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
> libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'
> 
> I0507 05:42:34.905570 31000 http.cpp:237] HTTP GET for /slave(1)/state.json 
> from 127.0.0.1:5051 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
> libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'
> 
> 
> Thanks,
> 
> Ben Mahler
> 
>



Re: Review Request 33935: Improved HTTP request logging for master/slave endpoints.

2015-05-07 Thread Jie Yu

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

Ship it!



src/master/master.cpp


Forgot this one?


- Jie Yu


On May 7, 2015, 9:53 p.m., Ben Mahler wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/33935/
> ---
> 
> (Updated May 7, 2015, 9:53 p.m.)
> 
> 
> Review request for mesos, Jie Yu and Vinod Kone.
> 
> 
> Bugs: MESOS-2519
> https://issues.apache.org/jira/browse/MESOS-2519
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> This adds the client address, as well as user-agent and forwarding 
> information, if present.
> 
> 
> Diffs
> -
> 
>   src/master/http.cpp fb448256d7ced1f47ea48ccfca2ae267bc26ef94 
>   src/master/master.hpp 49ee050ca4d2b2c5f75ce864fcf6ae703dfdeadd 
>   src/master/master.cpp bee842557c8397428ca51e46faa182a391584be3 
>   src/slave/http.cpp f678aabdccd8c16e25c18ffb5075265ed8b76a70 
>   src/slave/slave.hpp 654a8698be88e0d0f588190775dc3eee6b36f92e 
>   src/slave/slave.cpp c78ee3c9e7fc38ad364e83f4abe267e86bfbbc13 
> 
> Diff: https://reviews.apache.org/r/33935/diff/
> 
> 
> Testing
> ---
> 
> Tested manually:
> 
> I0507 05:41:37.386196 28393 http.cpp:233] HTTP GET for /master/state.json 
> from 127.0.0.1:5050 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
> libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'
> 
> I0507 05:42:34.905570 31000 http.cpp:237] HTTP GET for /slave(1)/state.json 
> from 127.0.0.1:5051 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
> libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'
> 
> 
> Thanks,
> 
> Ben Mahler
> 
>



Re: Review Request 33935: Improved HTTP request logging for master/slave endpoints.

2015-05-07 Thread Ben Mahler


> On May 7, 2015, 5:40 p.m., Jie Yu wrote:
> > src/master/master.cpp, lines 732-735
> > 
> >
> > Why do you need to capture `this`? Http::log is a static function, I 
> > don't think you need to capture `this`.
> > 
> > Capture `this` is in general dangeous because you want to make sure the 
> > callback is invoked before this object is destructured. It's not obviously 
> > here that this is the case.
> 
> Ben Mahler wrote:
> We need `http` which is a member variable. The last line is essentialy 
> `return this->http.observe(request);`. It's already being captured with the 
> bind approach as `http` contains the `Master*` pointer. Make sense? 
> Alternatives you'd prefer?
> 
> Jie Yu wrote:
> To match the previous semantics, you want to capture `http` object 
> (instead of `this`) by value since lambda::bind does a copy on `http` object. 
> I just thought capturing `this` in general is a bad practice.
> 
> I got confused initialy because I thought the callback of `route` will be 
> invoked at a different context. After checking the code, seems that the 
> callback (even if it's just a lambda function) will be invoked at Master 
> Process's context. It's not documented and quite confusing because we have an 
> overload version of `route` which takes a `T::*method`.

For posterity, you can't capture 'http' because it is outside the "reaching 
scope" of the lambda since it is a member variable (only 'this' is inside the 
reaching scope). So I've created a local Http variable, which works since the 
member was only needed for the route calls.


> On May 7, 2015, 5:40 p.m., Jie Yu wrote:
> > src/master/master.cpp, lines 728-729
> > 
> >
> > Just to be consistent, can you follow up with a patch to use lambda 
> > consistently here?
> 
> Ben Mahler wrote:
> Can you clarify this one? Are you saying don't use bind?

Added lambdas consistently.


- Ben


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


On May 7, 2015, 5:47 a.m., Ben Mahler wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/33935/
> ---
> 
> (Updated May 7, 2015, 5:47 a.m.)
> 
> 
> Review request for mesos, Jie Yu and Vinod Kone.
> 
> 
> Bugs: MESOS-2519
> https://issues.apache.org/jira/browse/MESOS-2519
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> This adds the client address, as well as user-agent and forwarding 
> information, if present.
> 
> 
> Diffs
> -
> 
>   src/master/http.cpp fb448256d7ced1f47ea48ccfca2ae267bc26ef94 
>   src/master/master.hpp 49ee050ca4d2b2c5f75ce864fcf6ae703dfdeadd 
>   src/master/master.cpp bee842557c8397428ca51e46faa182a391584be3 
>   src/slave/http.cpp f678aabdccd8c16e25c18ffb5075265ed8b76a70 
>   src/slave/slave.hpp 654a8698be88e0d0f588190775dc3eee6b36f92e 
>   src/slave/slave.cpp c78ee3c9e7fc38ad364e83f4abe267e86bfbbc13 
> 
> Diff: https://reviews.apache.org/r/33935/diff/
> 
> 
> Testing
> ---
> 
> Tested manually:
> 
> I0507 05:41:37.386196 28393 http.cpp:233] HTTP GET for /master/state.json 
> from 127.0.0.1:5050 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
> libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'
> 
> I0507 05:42:34.905570 31000 http.cpp:237] HTTP GET for /slave(1)/state.json 
> from 127.0.0.1:5051 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
> libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'
> 
> 
> Thanks,
> 
> Ben Mahler
> 
>



Re: Review Request 33935: Improved HTTP request logging for master/slave endpoints.

2015-05-07 Thread Ben Mahler

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

(Updated May 7, 2015, 9:53 p.m.)


Review request for mesos, Jie Yu and Vinod Kone.


Changes
---

Jie's feedback.


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


Repository: mesos


Description
---

This adds the client address, as well as user-agent and forwarding information, 
if present.


Diffs (updated)
-

  src/master/http.cpp fb448256d7ced1f47ea48ccfca2ae267bc26ef94 
  src/master/master.hpp 49ee050ca4d2b2c5f75ce864fcf6ae703dfdeadd 
  src/master/master.cpp bee842557c8397428ca51e46faa182a391584be3 
  src/slave/http.cpp f678aabdccd8c16e25c18ffb5075265ed8b76a70 
  src/slave/slave.hpp 654a8698be88e0d0f588190775dc3eee6b36f92e 
  src/slave/slave.cpp c78ee3c9e7fc38ad364e83f4abe267e86bfbbc13 

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


Testing
---

Tested manually:

I0507 05:41:37.386196 28393 http.cpp:233] HTTP GET for /master/state.json from 
127.0.0.1:5050 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'

I0507 05:42:34.905570 31000 http.cpp:237] HTTP GET for /slave(1)/state.json 
from 127.0.0.1:5051 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'


Thanks,

Ben Mahler



Re: Review Request 33935: Improved HTTP request logging for master/slave endpoints.

2015-05-07 Thread Jie Yu


> On May 7, 2015, 5:40 p.m., Jie Yu wrote:
> > src/master/master.cpp, lines 732-735
> > 
> >
> > Why do you need to capture `this`? Http::log is a static function, I 
> > don't think you need to capture `this`.
> > 
> > Capture `this` is in general dangeous because you want to make sure the 
> > callback is invoked before this object is destructured. It's not obviously 
> > here that this is the case.
> 
> Ben Mahler wrote:
> We need `http` which is a member variable. The last line is essentialy 
> `return this->http.observe(request);`. It's already being captured with the 
> bind approach as `http` contains the `Master*` pointer. Make sense? 
> Alternatives you'd prefer?

To match the previous semantics, you want to capture `http` object (instead of 
`this`) by value since lambda::bind does a copy on `http` object. I just 
thought capturing `this` in general is a bad practice.

I got confused initialy because I thought the callback of `route` will be 
invoked at a different context. After checking the code, seems that the 
callback (even if it's just a lambda function) will be invoked at Master 
Process's context. It's not documented and quite confusing because we have an 
overload version of `route` which takes a `T::*method`.


- Jie


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


On May 7, 2015, 5:47 a.m., Ben Mahler wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/33935/
> ---
> 
> (Updated May 7, 2015, 5:47 a.m.)
> 
> 
> Review request for mesos, Jie Yu and Vinod Kone.
> 
> 
> Bugs: MESOS-2519
> https://issues.apache.org/jira/browse/MESOS-2519
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> This adds the client address, as well as user-agent and forwarding 
> information, if present.
> 
> 
> Diffs
> -
> 
>   src/master/http.cpp fb448256d7ced1f47ea48ccfca2ae267bc26ef94 
>   src/master/master.hpp 49ee050ca4d2b2c5f75ce864fcf6ae703dfdeadd 
>   src/master/master.cpp bee842557c8397428ca51e46faa182a391584be3 
>   src/slave/http.cpp f678aabdccd8c16e25c18ffb5075265ed8b76a70 
>   src/slave/slave.hpp 654a8698be88e0d0f588190775dc3eee6b36f92e 
>   src/slave/slave.cpp c78ee3c9e7fc38ad364e83f4abe267e86bfbbc13 
> 
> Diff: https://reviews.apache.org/r/33935/diff/
> 
> 
> Testing
> ---
> 
> Tested manually:
> 
> I0507 05:41:37.386196 28393 http.cpp:233] HTTP GET for /master/state.json 
> from 127.0.0.1:5050 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
> libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'
> 
> I0507 05:42:34.905570 31000 http.cpp:237] HTTP GET for /slave(1)/state.json 
> from 127.0.0.1:5051 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
> libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'
> 
> 
> Thanks,
> 
> Ben Mahler
> 
>



Re: Review Request 33935: Improved HTTP request logging for master/slave endpoints.

2015-05-07 Thread Ben Mahler


> On May 7, 2015, 5:40 p.m., Jie Yu wrote:
> > src/slave/http.cpp, lines 239-241
> > 
> >
> > I think we usually put `?` and `:` in the end (similar to what we put 
> > `=` in the end):
> > 
> > ```
> > << (userAgent.isSome() ?
> >  " with User-Agent='" + userAgent.get() + "'" :
> >  "")
> > << (...)
> >  
> > ```
> > 
> > (BTW, I think you don't need `string(...)` above)

Really? I see a lot more cases of using it at the beginning, which I think is 
more readable as well, fortunately :)
Also, I don't think it's similar to '=', since that only occurs once. This 
seems similar to a conditional, which you're right, tends to go on the end. I 
had a comment about this here: https://reviews.apache.org/r/23542/

Odd, I could have sworn it complained without string(), I'll remove it.


> On May 7, 2015, 5:40 p.m., Jie Yu wrote:
> > src/master/master.cpp, lines 732-735
> > 
> >
> > Why do you need to capture `this`? Http::log is a static function, I 
> > don't think you need to capture `this`.
> > 
> > Capture `this` is in general dangeous because you want to make sure the 
> > callback is invoked before this object is destructured. It's not obviously 
> > here that this is the case.

We need `http` which is a member variable. The last line is essentialy `return 
this->http.observe(request);`. It's already being captured with the bind 
approach as `http` contains the `Master*` pointer. Make sense? Alternatives 
you'd prefer?


> On May 7, 2015, 5:40 p.m., Jie Yu wrote:
> > src/master/master.cpp, lines 728-729
> > 
> >
> > Just to be consistent, can you follow up with a patch to use lambda 
> > consistently here?

Can you clarify this one? Are you saying don't use bind?


- Ben


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


On May 7, 2015, 5:47 a.m., Ben Mahler wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/33935/
> ---
> 
> (Updated May 7, 2015, 5:47 a.m.)
> 
> 
> Review request for mesos, Jie Yu and Vinod Kone.
> 
> 
> Bugs: MESOS-2519
> https://issues.apache.org/jira/browse/MESOS-2519
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> This adds the client address, as well as user-agent and forwarding 
> information, if present.
> 
> 
> Diffs
> -
> 
>   src/master/http.cpp fb448256d7ced1f47ea48ccfca2ae267bc26ef94 
>   src/master/master.hpp 49ee050ca4d2b2c5f75ce864fcf6ae703dfdeadd 
>   src/master/master.cpp bee842557c8397428ca51e46faa182a391584be3 
>   src/slave/http.cpp f678aabdccd8c16e25c18ffb5075265ed8b76a70 
>   src/slave/slave.hpp 654a8698be88e0d0f588190775dc3eee6b36f92e 
>   src/slave/slave.cpp c78ee3c9e7fc38ad364e83f4abe267e86bfbbc13 
> 
> Diff: https://reviews.apache.org/r/33935/diff/
> 
> 
> Testing
> ---
> 
> Tested manually:
> 
> I0507 05:41:37.386196 28393 http.cpp:233] HTTP GET for /master/state.json 
> from 127.0.0.1:5050 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
> libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'
> 
> I0507 05:42:34.905570 31000 http.cpp:237] HTTP GET for /slave(1)/state.json 
> from 127.0.0.1:5051 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
> libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'
> 
> 
> Thanks,
> 
> Ben Mahler
> 
>



Re: Review Request 33935: Improved HTTP request logging for master/slave endpoints.

2015-05-07 Thread Jie Yu

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



src/master/master.cpp


Just to be consistent, can you follow up with a patch to use lambda 
consistently here?



src/master/master.cpp


Why do you need to capture `this`? Http::log is a static function, I don't 
think you need to capture `this`.

Capture `this` is in general dangeous because you want to make sure the 
callback is invoked before this object is destructured. It's not obviously here 
that this is the case.



src/slave/http.cpp


I think we usually put `?` and `:` in the end (similar to what we put `=` 
in the end):

```
<< (userAgent.isSome() ?
 " with User-Agent='" + userAgent.get() + "'" :
 "")
<< (...)
 
```

(BTW, I think you don't need `string(...)` above)


- Jie Yu


On May 7, 2015, 5:47 a.m., Ben Mahler wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/33935/
> ---
> 
> (Updated May 7, 2015, 5:47 a.m.)
> 
> 
> Review request for mesos, Jie Yu and Vinod Kone.
> 
> 
> Bugs: MESOS-2519
> https://issues.apache.org/jira/browse/MESOS-2519
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> This adds the client address, as well as user-agent and forwarding 
> information, if present.
> 
> 
> Diffs
> -
> 
>   src/master/http.cpp fb448256d7ced1f47ea48ccfca2ae267bc26ef94 
>   src/master/master.hpp 49ee050ca4d2b2c5f75ce864fcf6ae703dfdeadd 
>   src/master/master.cpp bee842557c8397428ca51e46faa182a391584be3 
>   src/slave/http.cpp f678aabdccd8c16e25c18ffb5075265ed8b76a70 
>   src/slave/slave.hpp 654a8698be88e0d0f588190775dc3eee6b36f92e 
>   src/slave/slave.cpp c78ee3c9e7fc38ad364e83f4abe267e86bfbbc13 
> 
> Diff: https://reviews.apache.org/r/33935/diff/
> 
> 
> Testing
> ---
> 
> Tested manually:
> 
> I0507 05:41:37.386196 28393 http.cpp:233] HTTP GET for /master/state.json 
> from 127.0.0.1:5050 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
> libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'
> 
> I0507 05:42:34.905570 31000 http.cpp:237] HTTP GET for /slave(1)/state.json 
> from 127.0.0.1:5051 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
> libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'
> 
> 
> Thanks,
> 
> Ben Mahler
> 
>



Re: Review Request 33935: Improved HTTP request logging for master/slave endpoints.

2015-05-06 Thread Mesos ReviewBot

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


Patch looks great!

Reviews applied: [33933, 33934, 33935]

All tests passed.

- Mesos ReviewBot


On May 7, 2015, 5:47 a.m., Ben Mahler wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/33935/
> ---
> 
> (Updated May 7, 2015, 5:47 a.m.)
> 
> 
> Review request for mesos, Jie Yu and Vinod Kone.
> 
> 
> Bugs: MESOS-2519
> https://issues.apache.org/jira/browse/MESOS-2519
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> This adds the client address, as well as user-agent and forwarding 
> information, if present.
> 
> 
> Diffs
> -
> 
>   src/master/http.cpp fb448256d7ced1f47ea48ccfca2ae267bc26ef94 
>   src/master/master.hpp 49ee050ca4d2b2c5f75ce864fcf6ae703dfdeadd 
>   src/master/master.cpp bee842557c8397428ca51e46faa182a391584be3 
>   src/slave/http.cpp f678aabdccd8c16e25c18ffb5075265ed8b76a70 
>   src/slave/slave.hpp 654a8698be88e0d0f588190775dc3eee6b36f92e 
>   src/slave/slave.cpp c78ee3c9e7fc38ad364e83f4abe267e86bfbbc13 
> 
> Diff: https://reviews.apache.org/r/33935/diff/
> 
> 
> Testing
> ---
> 
> Tested manually:
> 
> I0507 05:41:37.386196 28393 http.cpp:233] HTTP GET for /master/state.json 
> from 127.0.0.1:5050 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
> libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'
> 
> I0507 05:42:34.905570 31000 http.cpp:237] HTTP GET for /slave(1)/state.json 
> from 127.0.0.1:5051 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
> libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'
> 
> 
> Thanks,
> 
> Ben Mahler
> 
>



Review Request 33935: Improved HTTP request logging for master/slave endpoints.

2015-05-06 Thread Ben Mahler

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

Review request for mesos, Jie Yu and Vinod Kone.


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


Repository: mesos


Description
---

This adds the client address, as well as user-agent and forwarding information, 
if present.


Diffs
-

  src/master/http.cpp fb448256d7ced1f47ea48ccfca2ae267bc26ef94 
  src/master/master.hpp 49ee050ca4d2b2c5f75ce864fcf6ae703dfdeadd 
  src/master/master.cpp bee842557c8397428ca51e46faa182a391584be3 
  src/slave/http.cpp f678aabdccd8c16e25c18ffb5075265ed8b76a70 
  src/slave/slave.hpp 654a8698be88e0d0f588190775dc3eee6b36f92e 
  src/slave/slave.cpp c78ee3c9e7fc38ad364e83f4abe267e86bfbbc13 

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


Testing
---

Tested manually:

I0507 05:41:37.386196 28393 http.cpp:233] HTTP GET for /master/state.json from 
127.0.0.1:5050 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'

I0507 05:42:34.905570 31000 http.cpp:237] HTTP GET for /slave(1)/state.json 
from 127.0.0.1:5051 with User-Agent='curl/7.15.5 (x86_64-redhat-linux-gnu) 
libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5'


Thanks,

Ben Mahler