Keep track of the number of unsupported steps
This commit is contained in:
parent
f5cdbfe21d
commit
45ffe578b6
|
@ -328,6 +328,8 @@ void State::abortUnsupported()
|
|||
|
||||
std::unordered_set<Step::ptr> aborted;
|
||||
|
||||
size_t count = 0;
|
||||
|
||||
for (auto & wstep : runnable2) {
|
||||
auto step(wstep.lock());
|
||||
if (!step) continue;
|
||||
|
@ -341,6 +343,9 @@ void State::abortUnsupported()
|
|||
}
|
||||
}
|
||||
|
||||
if (!supported)
|
||||
count++;
|
||||
|
||||
if (!supported
|
||||
&& std::chrono::duration_cast<std::chrono::seconds>(now - step->state.lock()->lastSupported).count() >= maxUnsupportedTime)
|
||||
{
|
||||
|
@ -396,6 +401,8 @@ void State::abortUnsupported()
|
|||
++i;
|
||||
}
|
||||
}
|
||||
|
||||
nrUnsupportedSteps = count;
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -523,6 +523,7 @@ void State::dumpStatus(Connection & conn, bool log)
|
|||
root.attr("nrStepsCopyingTo", nrStepsCopyingTo);
|
||||
root.attr("nrStepsCopyingFrom", nrStepsCopyingFrom);
|
||||
root.attr("nrStepsWaiting", nrStepsWaiting);
|
||||
root.attr("nrUnsupportedSteps", nrUnsupportedSteps);
|
||||
root.attr("bytesSent", bytesSent);
|
||||
root.attr("bytesReceived", bytesReceived);
|
||||
root.attr("nrBuildsRead", nrBuildsRead);
|
||||
|
|
|
@ -355,6 +355,7 @@ private:
|
|||
counter nrStepsCopyingTo{0};
|
||||
counter nrStepsCopyingFrom{0};
|
||||
counter nrStepsWaiting{0};
|
||||
counter nrUnsupportedSteps{0};
|
||||
counter nrRetries{0};
|
||||
counter maxNrRetries{0};
|
||||
counter totalStepTime{0}; // total time for steps, including closure copying
|
||||
|
|
|
@ -34,6 +34,7 @@ sub sendQueueRunnerStats {
|
|||
gauge("hydra.queue.steps.unfinished", $json->{nrUnfinishedSteps});
|
||||
gauge("hydra.queue.steps.finished", $json->{nrStepsDone});
|
||||
gauge("hydra.queue.steps.retries", $json->{nrRetries});
|
||||
gauge("hydra.queue.steps.unsupported", $json->{nrUnsupportedSteps});
|
||||
gauge("hydra.queue.steps.max_retries", $json->{maxNrRetries});
|
||||
if ($json->{nrStepsDone}) {
|
||||
gauge("hydra.queue.steps.avg_total_time", $json->{avgStepTime});
|
||||
|
|
Loading…
Reference in a new issue