> On Dec. 1, 2016, 3:22 a.m., Vinod Kone wrote: > > src/slave/http.cpp, line 2231 > > <https://reviews.apache.org/r/54221/diff/2/?file=1573319#file1573319line2231> > > > > This is different from how we prolong the lifetime of `connection` in > > `attachContainerOutput`. can we make them consistent? > > Anand Mazumdar wrote: > hmm, the scenarios looked pretty different and hence I did not make them > consistent. In the previous scenario, we had already received the `response` > from the `Connection` object and were streaming it back to the client. Hence, > it was fine to just capture it in `transform()` to prolong the life time. > However, here, the switch board would only _start_ streaming the response > after it has received the streaming request fully. > > Vinod Kone wrote: > I see the difference between the 2 scenarios, but I don't completely get > why `connection` cannot be captured in the `transform` lambda here too? Are > you saying that doesn't work? > > Anand Mazumdar wrote: > Yes, it won't work in this case. `transform()` would complete as soon as > we have completed streaming the `Request` to the switch board but before > waiting for the response. Hence, we need this alternate way to prolong its > lifetime.
aha. makes sense. thanks. - Vinod ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/54221/#review157518 ----------------------------------------------------------- On Dec. 1, 2016, 5:43 a.m., Anand Mazumdar wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/54221/ > ----------------------------------------------------------- > > (Updated Dec. 1, 2016, 5:43 a.m.) > > > Review request for mesos, Kevin Klues and Vinod Kone. > > > Bugs: MESOS-6472 > https://issues.apache.org/jira/browse/MESOS-6472 > > > Repository: mesos > > > Description > ------- > > Added the v1 `ATTACH_CONTAINER_INPUT` call handler on the agent. > > > Diffs > ----- > > src/slave/http.cpp 87189dd6e2e099cb74faabd3ad26aaca11e5cef2 > src/slave/slave.hpp 05865a09724f7a46e9c06b02e59779513fc532aa > > Diff: https://reviews.apache.org/r/54221/diff/ > > > Testing > ------- > > make check (tests would be added soon and can't be committed without them) > > > Thanks, > > Anand Mazumdar > >
