@@ -43,15 +43,18 @@ A scheduling or binding cycle can be aborted if the Pod is determined to
43
43
be unschedulable or if there is an internal error. The Pod will be returned to
44
44
the queue and retried.
45
45
46
- ## Extension points
46
+ ## Interfaces
47
47
48
- The following picture shows the scheduling context of a Pod and the extension
49
- points that the scheduling framework exposes. In this picture "Filter" is
48
+ The following picture shows the scheduling context of a Pod and the interfaces
49
+ that the scheduling framework exposes. In this picture "Filter" is
50
50
equivalent to "Predicate" and "Scoring" is equivalent to "Priority function".
51
51
52
- One plugin may register at multiple extension points to perform more complex or
52
+ One plugin may implement multiple interfaces to perform more complex or
53
53
stateful tasks.
54
54
55
+ Some interfaces are called as extension points which can be controled through
56
+ [ Scheduler Configuration] ( /docs/reference/scheduling/config/#extension-points ) .
57
+
55
58
{{< figure src="/images/docs/scheduling-framework-extensions.png" title="Scheduling framework extension points" class="diagram-large">}}
56
59
57
60
### PreEnqueue {#pre-enqueue}
@@ -65,6 +68,28 @@ Otherwise, it's placed in the internal unschedulable Pods list, and doesn't get
65
68
For more details about how internal scheduler queues work, read
66
69
[ Scheduling queue in kube-scheduler] ( https://github.com/kubernetes/community/blob/f03b6d5692bd979f07dd472e7b6836b2dad0fd9b/contributors/devel/sig-scheduling/scheduler_queues.md ) .
67
70
71
+ ### EnqueueExtension
72
+
73
+ EnqueueExtension is the interface where the plugin can control
74
+ whether to retry scheduling of Pods rejected by this plugin, based on changes in the cluster.
75
+ Plugins that implement PreEnqueue, PreFilter, Filter, Reserve or Permit should implement this interface.
76
+
77
+ #### QueueingHint
78
+
79
+ {{< feature-state for_k8s_version="v1.28" state="beta" >}}
80
+
81
+ QueueingHint is a callback function for deciding whether a Pod can be requeued to the active queue or backoff queue.
82
+ It's executed every time a certain kind of events happen,
83
+ and when the QueueingHint finds that the event might make the Pod schedulable,
84
+ the Pod is put into the active queue or the backoff queue
85
+ so that the scheduler will retry the scheduling of the Pod.
86
+
87
+ {{< note >}}
88
+ QueueingHint is a beta-level field and is enabled by default in 1.28.
89
+ You can disable it via the
90
+ ` SchedulerQueueingHints ` [ feature gate] ( /docs/reference/command-line-tools-reference/feature-gates/ ) .
91
+ {{< /note >}}
92
+
68
93
### QueueSort {#queue-sort}
69
94
70
95
These plugins are used to sort Pods in the scheduling queue. A queue sort plugin
@@ -148,7 +173,7 @@ NormalizeScore extension point.
148
173
149
174
### Reserve {#reserve}
150
175
151
- A plugin that implements the Reserve extension has two methods, namely ` Reserve `
176
+ A plugin that implements the Reserve interface has two methods, namely ` Reserve `
152
177
and ` Unreserve ` , that back two informational scheduling phases called Reserve
153
178
and Unreserve, respectively. Plugins which maintain runtime state (aka "stateful
154
179
plugins") should use these phases to be notified by the scheduler when resources
@@ -218,30 +243,10 @@ skipped**.
218
243
219
244
### PostBind {#post-bind}
220
245
221
- This is an informational extension point . Post-bind plugins are called after a
246
+ This is an informational interface . Post-bind plugins are called after a
222
247
Pod is successfully bound. This is the end of a binding cycle, and can be used
223
248
to clean up associated resources.
224
249
225
- ### EnqueueExtension
226
-
227
- EnqueueExtension is the interface where the plugin can have control how the scheduling of Pods rejected by this plugin are retried.
228
- PreEnqueue, PreFilter, Filter, Reserve and Permit plugins are supposed to implement this interface.
229
-
230
- {{< feature-state for_k8s_version="v1.28" state="beta" >}}
231
-
232
- QueueingHint is a part of EnqueueExtension.
233
- It's a callback function for deciding whether a Pod can be requeued to the active queue or backoff queue.
234
- It's executed every time a certain kind of events happen,
235
- and when the QueueingHint finds that the event might make the Pod schedulable,
236
- the Pod is put into the active queue or the backoff queue
237
- so that the scheduler will retry the scheduling of the Pod.
238
-
239
- {{< note >}}
240
- QueueingHint is a beta-level field and is enabled by default in 1.28.
241
- You can disable it via the
242
- ` SchedulerQueueingHints ` [ feature gate] ( /docs/reference/command-line-tools-reference/feature-gates/ ) .
243
- {{< /note >}}
244
-
245
250
## Plugin API
246
251
247
252
There are two steps to the plugin API. First, plugins must register and get
0 commit comments