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

Method processCheckResult

src/checks/checker.cpp:160–181  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

158
159
160void Checker::processCheckResult(const Try<CheckStatusInfo>& result) {
161 CheckStatusInfo checkStatusInfo;
162
163 if (result.isError()) {
164 LOG(WARNING) << name << " for task '" << taskId << "'"
165 << " failed: " << result.error();
166
167 checkStatusInfo = createEmptyCheckStatusInfo(check);
168 } else {
169 checkStatusInfo = result.get();
170 }
171
172 // Trigger the callback if check info changes.
173 if (checkStatusInfo != previousCheckStatus) {
174 // We assume this is a local send, i.e., the checker library is not used
175 // in a binary external to the executor and hence can not exit before
176 // the data is sent to the executor.
177 callback(checkStatusInfo);
178
179 previousCheckStatus = checkStatusInfo;
180 }
181}
182
183} // namespace checks {
184} // namespace internal {

Callers

nothing calls this directly

Calls 5

callbackFunction · 0.85
errorMethod · 0.65
isErrorMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected