----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/36720/#review94496 -----------------------------------------------------------
Ship it! I left some comments here so you could see the issues I noticed as I went over this, mostly around upgrading and downgrading across pid and http. I've applied fixes for all of these to avoid more round-trips and will get this committed shortly, nice work! src/master/master.cpp (line 4950) <https://reviews.apache.org/r/36720/#comment149133> Much like when we remove a pid-based framework, we need to wipe the authentication related data here. src/master/master.cpp (lines 4963 - 4968) <https://reviews.apache.org/r/36720/#comment149135> Perhaps we should just push the unsetting of the other connection into updateConnection and have one for both http and pid. src/master/master.cpp (line 4967) <https://reviews.apache.org/r/36720/#comment149136> We need to remove the old one from `authenticated` and `principals` here when updrading to http, much like we do when a pid based framework is removed. Yes.. this stuff is a nasty mess, we need to make failover as simple as the composition of: disconnect -> reconnect! src/master/master.cpp (line 4983) <https://reviews.apache.org/r/36720/#comment149129> This check will crash when an http scheduler is downgrading to a pid framework. src/master/master.cpp (lines 5010 - 5015) <https://reviews.apache.org/r/36720/#comment149132> This won't work for downgrades from http to pid, since there was no principal in the map yet. src/master/master.cpp (lines 5039 - 5040) <https://reviews.apache.org/r/36720/#comment149138> Could we do this before reactivating? Note that your comment seems to hint that it must come after for some reason, but it doesn't need to. - Ben Mahler On Aug. 7, 2015, 2:27 a.m., Anand Mazumdar wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/36720/ > ----------------------------------------------------------- > > (Updated Aug. 7, 2015, 2:27 a.m.) > > > Review request for mesos, Ben Mahler and Vinod Kone. > > > Bugs: MESOS-2294 > https://issues.apache.org/jira/browse/MESOS-2294 > > > Repository: mesos > > > Description > ------- > > Split review out of r36318. This change adds the functionality of making a > http call for subscribe and the master responding with a subscribed event on > the persistent stream. > > Also added functionality for framework failover equivalent of re-register. It > should now be possible to merge the subscribed(...) introduced in this review > and the re-factor that happened in MESOS-3182. > > - Made a new function for exited()/failoverFramework for http frameworks that > invoke into the common continuation function for pid/http frameworks > thereafter. > - The re-register functionality equivalent goes in _subscribe(...) > > > Diffs > ----- > > src/master/http.cpp 76e70801925041f08bc94f0ca18c86f1a573b2b3 > src/master/master.hpp 53420ca7d503296fbe11b1ea0795afe2ebf86255 > src/master/master.cpp d699e4bc3cf734a516a6baf329919e04744b5702 > > Diff: https://reviews.apache.org/r/36720/diff/ > > > Testing > ------- > > make check + adding tests in a different patch. > > > Thanks, > > Anand Mazumdar > >