You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by vi...@apache.org on 2016/08/05 23:42:00 UTC
[2/5] mesos git commit: Added more assertions to master code.
Added more assertions to master code.
Review: https://reviews.apache.org/r/50416/
Project: http://git-wip-us.apache.org/repos/asf/mesos/repo
Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/60dbd347
Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/60dbd347
Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/60dbd347
Branch: refs/heads/master
Commit: 60dbd347b409c788776760a8270965d943b6806e
Parents: 2992565
Author: Neil Conway <ne...@gmail.com>
Authored: Fri Aug 5 16:41:18 2016 -0700
Committer: Vinod Kone <vi...@gmail.com>
Committed: Fri Aug 5 16:41:18 2016 -0700
----------------------------------------------------------------------
src/master/master.cpp | 4 ++++
1 file changed, 4 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/mesos/blob/60dbd347/src/master/master.cpp
----------------------------------------------------------------------
diff --git a/src/master/master.cpp b/src/master/master.cpp
index 9259509..0bd1a34 100644
--- a/src/master/master.cpp
+++ b/src/master/master.cpp
@@ -4572,6 +4572,7 @@ void Master::_registerSlave(
const string& version,
const Future<bool>& admit)
{
+ CHECK(slaves.registering.contains(pid));
slaves.registering.erase(pid);
CHECK(!admit.isDiscarded());
@@ -4822,6 +4823,7 @@ void Master::_reregisterSlave(
const string& version,
const Future<bool>& readmit)
{
+ CHECK(slaves.reregistering.contains(slaveInfo.id()));
slaves.reregistering.erase(slaveInfo.id());
CHECK(!readmit.isDiscarded());
@@ -5933,6 +5935,7 @@ void Master::_authenticate(
authenticated.put(pid, future.get().get());
}
+ CHECK(authenticating.contains(pid));
authenticating.erase(pid);
}
@@ -6720,6 +6723,7 @@ void Master::_removeSlave(
const string& message,
Option<Counter> reason)
{
+ CHECK(slaves.removing.contains(slaveInfo.id()));
slaves.removing.erase(slaveInfo.id());
CHECK(!removed.isDiscarded());