1
0
Fork 0
mirror of https://github.com/kubernetes-sigs/node-feature-discovery.git synced 2025-03-28 10:47:23 +00:00
node-feature-discovery/pkg
Markus Lehtonen 3b448ae623 apis/nfd: allow different types of features of the same name
This patch changes the handling of NodeFeatureRules so that one feature
name (say "cpu.cpuid") can hold different types of features (flags,
attributes and/or instances). Requiring features to choose one single
type has not been a limitation of the API itself (and there has been no
validation on this) but an implementation decision.

The new evalutation logic of match expressions is such that "flags" and
"attributes" are basically evaluated as an union - they are both maps
but "flags" just don't have any value associated with the key. However,
"instances" are handled separately as that is basically an array of
maps and needs to be evaluated in a different way (loop over the array
of instances and evaluate expressions against the attributes of each).
Because of this difference care must be taken if mixing "instance"
features with "flag" and/or "attribute" features.

Note that the API types or their validation is not changed - just the
implementation of how the NodeFeatureRules are evaluated.
2024-05-24 13:18:31 +03:00
..
apis/nfd apis/nfd: allow different types of features of the same name 2024-05-24 13:18:31 +03:00
cpuid pkg/cpuid: lint fixes 2020-05-20 21:48:06 +03:00
features Add FeatureGate framework to handle new features 2024-03-15 19:11:32 +01:00
kubectl-nfd Move NFD api to a separate go mod 2024-04-05 16:35:47 +02:00
labeler Fix update_codegen 2024-04-09 18:28:04 +02:00
nfd-gc Merge pull request #1600 from ArangoGutierrez/e2e-not-k8s 2024-04-09 02:06:06 -07:00
nfd-master chore/nfd-master: remove warnings in nfd-master unit tests file 2024-04-22 22:27:15 +02:00
nfd-topology-updater Tidy up usage of channels for signaling 2024-04-05 14:39:58 +03:00
nfd-worker Merge pull request #1600 from ArangoGutierrez/e2e-not-k8s 2024-04-09 02:06:06 -07:00
podres Update auto-generated code 2024-03-11 12:18:32 +02:00
resourcemonitor topology-updater: ditch apihelper 2024-01-25 22:15:20 +02:00
topologypolicy nrt-api: move from v1alpha1 to v1alpha2 2023-02-09 12:29:54 +01:00
utils nfd-master: prevent crash on empty config struct 2024-04-05 14:19:44 +03:00
version version: allow undefined version 2020-03-20 07:21:43 +02:00