File tree Expand file tree Collapse file tree 1 file changed +7
-0
lines changed
Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -136,6 +136,7 @@ impl Profile {
136136 + self . idle_runner_count ( runners)
137137 + self . reserved_runner_count ( runners)
138138 + self . busy_runner_count ( runners)
139+ + self . done_or_unregistered_runner_count ( runners)
139140 }
140141
141142 pub fn started_or_crashed_runner_count ( & self , runners : & Runners ) -> usize {
@@ -162,6 +163,12 @@ impl Profile {
162163 . count ( )
163164 }
164165
166+ pub fn done_or_unregistered_runner_count ( & self , runners : & Runners ) -> usize {
167+ self . runners ( runners)
168+ . filter ( |( _id, runner) | runner. status ( ) == Status :: DoneOrUnregistered )
169+ . count ( )
170+ }
171+
165172 pub fn excess_idle_runner_count ( & self , runners : & Runners ) -> usize {
166173 // Healthy runners beyond the target count are excess runners.
167174 let excess = if self . healthy_runner_count ( runners) > self . target_runner_count ( ) {
You can’t perform that action at this time.
0 commit comments