Add segmentation commodity for the node_group entity. Each node_group entity should sell the segmentation commodity if there is any workload that has an anti-affinity term with the topologyKey as the node_group id
Do a rediscovery and broadcast, dump the topology from TP
Search the keywords zone1, there should be a Node_Group entity whose name contains the zone1. Check its sold commodity list, there should be a segmentation commodity that has the name of the workload controller as the key
These are the items that must be done by the developer and by reviewers before the change is ready to merge. Please strikeout any items that are not applicable, but don't delete them
[ ] Developer Checks
[ ] Full build with unit tests and fmt and vet checks
[ ] Unit tests added / updated
[ ] No unlicensed images, no third-party code (such as from StackOverflow)
[ ] Integration tests added / updated
[x] Manual testing done (and described)
[ ] Product sweep run and passed
[ ] Developer wiki updated (and linked to this description)
[ ] Reviewer Checks
[ ] Merge request description clear and understandable
[ ] Developer checklist items complete
[ ] Functional code review (how is the code written)
[ ] Architectural review (does the code try to do the right thing, in the right way)
Intent
Add segmentation commodity for the node_group entity. Each node_group entity should sell the segmentation commodity if there is any workload that has an anti-affinity term with the
topologyKey
as the node_group idBackground
https://jsw.ibm.com/browse/TRB-44268
Testing
Pre-setup:
Label the worker nodes with
kubernetes.io/zone=zone1
orkubernetes.io/zone=zone2
in a K8s clusterCreate a deployment with anti-affinity and the
topologyKey
askubernetes.io/zone
Expected to see
Do a rediscovery and broadcast, dump the topology from TP
Search the keywords
zone1
, there should be a Node_Group entity whose name contains thezone1
. Check its sold commodity list, there should be a segmentation commodity that has the name of the workload controller as the keySearch another node_group entity with the keyword
zone2
, there should be similar output as the previous oneChecklist
These are the items that must be done by the developer and by reviewers before the change is ready to merge. Please
strikeoutany items that are not applicable, but don't delete themAudience
(@ mention any
review/...
groups or people that should be aware of this merge request)