mesos-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Adam B <a...@mesosphere.io>
Subject Re: Review Request 54381: Adds authorization support when attaching containers input/output.
Date Wed, 07 Dec 2016 00:32:45 GMT


> On Dec. 6, 2016, 12:50 a.m., Adam B wrote:
> > src/slave/http.cpp, lines 2465-2468
> > <https://reviews.apache.org/r/54381/diff/1/?file=1576455#file1576455line2465>
> >
> >     Can you please comment on the need for std::move here?
> >     Why is decoder a `&&` in the first place? @vinodkone may be able to
comment

>From Anand: It’s passing ownership of the `decoder` to the `attachContainerInput` function.
It could have been a constant reference too based on how we use the `Owned` pointer in our
code but it would break when we move `Owned` to rely on move semantics ala `unique_ptr`.
Adam: So then it's ok for us to `return _attachContainerInput(call, std::move(decoder_), contentType,
acceptType);` to pass ownership of the `decoder` from `attachContainerInput()` to `_attachContainerInput()`?
Anand: yes

Sounds like a quick `Pass on ownership of decoder to the continuation.` comment would be sufficient
here.


- Adam


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


On Dec. 6, 2016, 6:15 a.m., Alexander Rojas wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/54381/
> -----------------------------------------------------------
> 
> (Updated Dec. 6, 2016, 6:15 a.m.)
> 
> 
> Review request for mesos, Adam B, Kevin Klues, and Vinod Kone.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Introduces authorization support for the newly introduced debug API
> calls: `AttachContainerInput` and `AttachContainerOutput`.
> 
> 
> Diffs
> -----
> 
>   src/slave/http.cpp 91eebe117d3dc86dd5b1fd47156c01e147165cef 
>   src/slave/slave.hpp 4b94dff9c1f9f212f84984674268ef38b43d93bd 
>   src/slave/slave.cpp 7eb45036f49289972c0b706c3c8e2ed96553d279 
>   src/tests/api_tests.cpp 7c70f284a9225ca23abc7049f48f3efba314b641 
> 
> Diff: https://reviews.apache.org/r/54381/diff/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Alexander Rojas
> 
>


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