You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: keps/sig-scheduling/5142-pop-backoffq-when-activeq-empty/README.md
+3-2Lines changed: 3 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -179,7 +179,8 @@ Flushing from backoffQ to activeQ is done each second, taking all pods with back
179
179
It means that, when they come to activeQ, they are sorted by priority there and taken in this order from activeQ.
180
180
It is important, because preemption of a lower priority pod could happen if a higher priority pod is scheduled later.
181
181
182
-
To mitigate this, `lessFn` function of backoffQ's heap will be changed, quantifying the time to make one second windows in which pods will be sorted by priority.
182
+
To mitigate this, `lessFn` function of backoffQ's heap will be changed, splitting the time to make one second windows (by ignoring milliseconds)
183
+
in which pods will be sorted by priority.
183
184
Those whole windows will be eventually flushed to activeQ, making no change in current behavior.
184
185
185
186
## Design Details
@@ -218,7 +219,7 @@ At the moveToActiveQ level, these two paths could be distinguished by checking i
218
219
As [mentioned](#low-priority-pod-could-be-chosen-to-pop-even-if-high-priority-pod-has-a-slightly-later-backoff-expiration) in risks,
219
220
backoffQ's heap `lessFn` function has to be changed to apply priority within 1 second windows.
220
221
The actual implementation takes backoff expiration times of two pods and compares which is lower.
221
-
The new version will cut the milliseconds and use priorities to compare pods within those windows.
222
+
The new version will ignore the milliseconds and use priorities to compare pods within those windows.
222
223
To make ordering predictable, in case of equal priorities within the same window,
223
224
the whole backoff time expiration will be eventually compared. See the pseudocode:
0 commit comments