MCPcopy Create free account
hub / github.com/apache/mesos / lostSlave

Method lostSlave

src/sched/sched.cpp:1084–1119  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1082 }
1083
1084 void lostSlave(const UPID& from, const SlaveID& slaveId)
1085 {
1086 if (!running.load()) {
1087 VLOG(1) << "Ignoring lost agent message because the driver is not"
1088 << " running!";
1089 return;
1090 }
1091
1092 if (!connected) {
1093 VLOG(1) << "Ignoring lost agent message because the driver is "
1094 << "disconnected!";
1095 return;
1096 }
1097
1098 CHECK_SOME(master);
1099
1100 if (from != master->pid()) {
1101 VLOG(1) << "Ignoring lost agent message because it was sent "
1102 << "from '" << from << "' instead of the leading master '"
1103 << master->pid() << "'";
1104 return;
1105 }
1106
1107 VLOG(1) << "Lost agent " << slaveId;
1108
1109 savedSlavePids.erase(slaveId);
1110
1111 Stopwatch stopwatch;
1112 if (FLAGS_v >= 1) {
1113 stopwatch.start();
1114 }
1115
1116 scheduler->slaveLost(driver, slaveId);
1117
1118 VLOG(1) << "Scheduler::slaveLost took " << stopwatch.elapsed();
1119 }
1120
1121 void lostExecutor(
1122 const UPID& from,

Callers

nothing calls this directly

Calls 6

elapsedMethod · 0.80
startMethod · 0.65
slaveLostMethod · 0.65
loadMethod · 0.45
pidMethod · 0.45
eraseMethod · 0.45

Tested by

no test coverage detected