> On April 29, 2016, 11:20 a.m., Benjamin Bannier wrote:
> > src/master/http.cpp, line 868
> > <https://reviews.apache.org/r/46784/diff/1/?file=1364766#file1364766line868>
> >
> >     Could you make this capture list explicit (`[this, request]`)?

The style guide recommends to prefer default capture by value, that's why I'm 
doing it here. The case here is different from the one in `slave/http.cpp`. 
There we explicitly captured by value to be sure not to capture `this`, because 
that would lead to problems there. We don't have this problem here, hence the 
default capture by value.


> On April 29, 2016, 11:20 a.m., Benjamin Bannier wrote:
> > src/master/http.cpp, line 874
> > <https://reviews.apache.org/r/46784/diff/1/?file=1364766#file1364766line874>
> >
> >     Not your pattern and a general problem here, but this does not return 
> > any useful response should we fail to get an answer from the `authorizer` :(

It would return a failed future. Don't know what libprocess does with that, by 
I would expect that it would create a "server error" response.


> On April 29, 2016, 11:20 a.m., Benjamin Bannier wrote:
> > src/tests/master_authorization_tests.cpp, line 1024
> > <https://reviews.apache.org/r/46784/diff/1/?file=1364768#file1364768line1024>
> >
> >     This looks very similar to the `SlaveEndpointTest` suite ;) Should we 
> > just also make this parameterized from the start?

I would like to, but unfortunately a parameterized test in GTest needs at least 
two values, at this point we have only one. It doesn't compile with a single 
parameter.


- Jan


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


On April 28, 2016, 4:57 p.m., Jan Schlicht wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/46784/
> -----------------------------------------------------------
> 
> (Updated April 28, 2016, 4:57 p.m.)
> 
> 
> Review request for mesos, Alexander Rukletsov and Benjamin Bannier.
> 
> 
> Bugs: MESOS-5297
>     https://issues.apache.org/jira/browse/MESOS-5297
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Access to the '/flags' endpoint is authorized using
> the 'GET_ENDPOINT_WITH_PATH' action.
> 
> 
> Diffs
> -----
> 
>   src/master/http.cpp 4f489fb9e5bc77b839cc4a44d7ec36af06f73e4a 
>   src/master/master.hpp 3e55114ee7866e06513071e86e15608099dae052 
>   src/tests/master_authorization_tests.cpp 
> 804b39a269c09df9f6c0bbdf6f8b53921ac09ce8 
> 
> Diff: https://reviews.apache.org/r/46784/diff/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Jan Schlicht
> 
>

Reply via email to