Skip to content

Commit 9c0e02b

Browse files
committed
nrt: doc: document the new attributes format
Since we are moving to a more structured format, let's document the expectations. Signed-off-by: Francesco Romani <[email protected]>
1 parent aff6bdd commit 9c0e02b

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

pkg/noderesourcetopology/README.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -155,6 +155,27 @@ Should the cluster need to have different settings (e.g. topology manager) or NU
155155
using [affinity](https://kubernetes.io/docs/user-guide/node-selection/#node-affinity-beta-feature) or also
156156
[taints](https://kubernetes.io/docs/user-guide/node-selection/#taints-and-toleations-beta-feature).
157157

158+
#### Topology Manager configuration
159+
160+
***Target audience: developers and operators of topology updaters (NodeResourceTopology producers)***
161+
162+
In addition to logically partitioning a cluster like explained above, the topology-aware scheduler needs to know key node-specific configuration settings like Topology manager policy and scope.
163+
This data is expected to be provided as top-level `Attributes` of the NodeResourceTopology objects:
164+
165+
NodeResourceTopology producers should add top-level `Attributes` in the following format
166+
- For `Name` and `Value` of attributes, words should be `snakeCase`
167+
- The `Name` of each attribute should be **the same of the corresponding kubelet configuration option**.
168+
- example: `--topology-manager-scope` becomes `topologyManagerScope`
169+
- example: `topologyManagerPolicy` becomes `topologyManagerPolicy`
170+
- The `Value` of each attribute should be **one of the value of the corresponding kubelet configuration option, VERBATIM**.
171+
- example: `single-numa-node` becomes `single-numa-node`
172+
- Should `topologyManagerOptions` be exposed:
173+
- they should be expanded in key-value pairs, using the `String()` representation
174+
- each key-value pair should be preceded by the `topologyManagerOption` prefix
175+
- every other provision described above applies
176+
- example: the `prefer-closest-numa-nodes` option becomes `topologyManagerOptionPreferClosestNumaNodes`, accepting exactly one of either `true` and `false`.
177+
- **RATIONALE**: this representation wants to guarantee all the Attribute Names are unique (no aliasing). It must be noted this is a stricter requirement with respect to the Attribute representation
178+
in NRT objects, and this requirement could be lifted in the future (an upgrade path will be provided).
158179

159180
### Demo
160181

0 commit comments

Comments
 (0)