> On June 6, 2016, 4:30 p.m., Vinod Kone wrote: > > src/master/http.cpp, line 2951 > > <https://reviews.apache.org/r/48116/diff/1/?file=1406733#file1406733line2951> > > > > why want this function to return `v1::master::Response` instead of > > `http::Response` to be consistent with how we did for others. since this > > response doesn't have a body, this could be an empty `v1::master::Response`. > > haosdent huang wrote: > Hi, @vinodkone, thank you very much for your review. According to the > design document, seems we need return `Accepted` here? > > ``` > Example #2: Call with parameters but no return. > > TEARDOWN_FRAMEWORK HTTP Request (JSON): > POST /api/v1/ HTTP/1.1 > > Host: masterhost:5050 > Content-Type: application/json > > { > “type” : “TEARDOWN_FRAMEWORK”, > > “teardown_network” : { > > “framework_id” : “1242352-1235235-1235235-235235” > > } > } > > TEARDOWN_FRAMEWORK HTTP Response: > HTTP/1.1 202 Accepted > ```
teardown happens asynchronously, so we send 202. afaict, updating of maintenance schedule is done before we return a response? if yes, that should be a 200? not sure why the original maintenance handler returned 202 in the first place. @kaysoky? - Vinod ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/48116/#review136286 ----------------------------------------------------------- On June 5, 2016, 6 p.m., haosdent huang wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/48116/ > ----------------------------------------------------------- > > (Updated June 5, 2016, 6 p.m.) > > > Review request for mesos and Vinod Kone. > > > Bugs: MESOS-5505 > https://issues.apache.org/jira/browse/MESOS-5505 > > > Repository: mesos > > > Description > ------- > > Implemented UPDATE_MAINTENANCE_SCHEDULE Call in v1 master API. > > > Diffs > ----- > > src/internal/devolve.hpp 00842bb0de1dd587f2b47c79f17c0e7bd7f51189 > src/internal/devolve.cpp 4233246c6838f85189f1b4c7e66d2bc0a3bf5408 > src/master/http.cpp 4fbf5638fb9ae8e7b28c21529d15735e46a85ffb > src/master/master.hpp 790da3ce686401c378ad9c62d497d60893c4ce41 > > Diff: https://reviews.apache.org/r/48116/diff/ > > > Testing > ------- > > > Thanks, > > haosdent huang > >
