Skip to content

Commit b8e2760

Browse files
committed
rm metricsAscend flag
1 parent ed5895f commit b8e2760

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

pkg/controller/priorityqueue/priorityqueue.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,6 @@ func (w *priorityqueue[T]) spin() {
239239
}
240240

241241
for {
242-
metricsAscend := false
243242
pivotChange := false
244243

245244
w.queue.AscendGreaterOrEqual(&pivot, func(item *item[T]) bool {
@@ -265,8 +264,7 @@ func (w *priorityqueue[T]) spin() {
265264
}
266265
}
267266

268-
if w.waiters.Load() == 0 || metricsAscend {
269-
metricsAscend = true
267+
if w.waiters.Load() == 0 {
270268
// Have to keep iterating here to ensure we update metrics
271269
// for further items that became ready and set nextReady.
272270
return true

0 commit comments

Comments
 (0)