Rename DefaultPodTopologySpread plugin #91994

This commit is contained in:
RAKESH REDDY BANDI
2020-06-25 04:50:53 -04:00
parent ad29e168dc
commit d44a20f9ca
18 changed files with 99 additions and 99 deletions

View File

@@ -136,11 +136,11 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
{Name: "NodeLabel"},
{Name: "ServiceAffinity"},
},
"PreScorePlugin": {{Name: "DefaultPodTopologySpread"}},
"PreScorePlugin": {{Name: "SelectorSpread"}},
"ScorePlugin": {
{Name: "NodeResourcesLeastAllocated", Weight: 1},
{Name: "NodeLabel", Weight: 4},
{Name: "DefaultPodTopologySpread", Weight: 2},
{Name: "SelectorSpread", Weight: 2},
{Name: "ServiceAffinity", Weight: 3},
},
"BindPlugin": {{Name: "DefaultBinder"}},
@@ -191,12 +191,12 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
{Name: "NodeLabel"},
{Name: "ServiceAffinity"},
},
"PreScorePlugin": {{Name: "DefaultPodTopologySpread"}},
"PreScorePlugin": {{Name: "SelectorSpread"}},
"ScorePlugin": {
{Name: "NodeResourcesBalancedAllocation", Weight: 2},
{Name: "NodeResourcesLeastAllocated", Weight: 2},
{Name: "NodeLabel", Weight: 8}, // Weight is 4 * number of LabelPreference priorities
{Name: "DefaultPodTopologySpread", Weight: 2},
{Name: "SelectorSpread", Weight: 2},
{Name: "ServiceAffinity", Weight: 6}, // Weight is the 3 * number of custom ServiceAntiAffinity priorities
},
"BindPlugin": {{Name: "DefaultBinder"}},
@@ -254,14 +254,14 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
{Name: "AzureDiskLimits"},
{Name: "VolumeZone"},
},
"PreScorePlugin": {{Name: "DefaultPodTopologySpread"}},
"PreScorePlugin": {{Name: "SelectorSpread"}},
"ScorePlugin": {
{Name: "NodeResourcesBalancedAllocation", Weight: 2},
{Name: "ImageLocality", Weight: 2},
{Name: "NodeResourcesLeastAllocated", Weight: 2},
{Name: "NodeAffinity", Weight: 2},
{Name: "NodeLabel", Weight: 4},
{Name: "DefaultPodTopologySpread", Weight: 2},
{Name: "SelectorSpread", Weight: 2},
{Name: "ServiceAffinity", Weight: 3},
},
"BindPlugin": {{Name: "DefaultBinder"}},
@@ -326,7 +326,7 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
},
"PreScorePlugin": {
{Name: "InterPodAffinity"},
{Name: "DefaultPodTopologySpread"},
{Name: "SelectorSpread"},
{Name: "TaintToleration"},
},
"ScorePlugin": {
@@ -335,7 +335,7 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
{Name: "InterPodAffinity", Weight: 2},
{Name: "NodeResourcesLeastAllocated", Weight: 2},
{Name: "NodeAffinity", Weight: 2},
{Name: "DefaultPodTopologySpread", Weight: 2},
{Name: "SelectorSpread", Weight: 2},
{Name: "TaintToleration", Weight: 2},
},
"BindPlugin": {{Name: "DefaultBinder"}},
@@ -402,7 +402,7 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
},
"PreScorePlugin": {
{Name: "InterPodAffinity"},
{Name: "DefaultPodTopologySpread"},
{Name: "SelectorSpread"},
{Name: "TaintToleration"},
},
"ScorePlugin": {
@@ -413,7 +413,7 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
{Name: "NodeResourcesMostAllocated", Weight: 2},
{Name: "NodeAffinity", Weight: 2},
{Name: "NodePreferAvoidPods", Weight: 2},
{Name: "DefaultPodTopologySpread", Weight: 2},
{Name: "SelectorSpread", Weight: 2},
{Name: "TaintToleration", Weight: 2},
},
"BindPlugin": {{Name: "DefaultBinder"}},
@@ -489,7 +489,7 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
},
"PreScorePlugin": {
{Name: "InterPodAffinity"},
{Name: "DefaultPodTopologySpread"},
{Name: "SelectorSpread"},
{Name: "TaintToleration"},
},
"ScorePlugin": {
@@ -500,7 +500,7 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
{Name: "NodeResourcesMostAllocated", Weight: 2},
{Name: "NodeAffinity", Weight: 2},
{Name: "NodePreferAvoidPods", Weight: 2},
{Name: "DefaultPodTopologySpread", Weight: 2},
{Name: "SelectorSpread", Weight: 2},
{Name: "TaintToleration", Weight: 2},
},
"BindPlugin": {{Name: "DefaultBinder"}},
@@ -587,7 +587,7 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
},
"PreScorePlugin": {
{Name: "InterPodAffinity"},
{Name: "DefaultPodTopologySpread"},
{Name: "SelectorSpread"},
{Name: "TaintToleration"},
},
"ScorePlugin": {
@@ -598,7 +598,7 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
{Name: "NodeResourcesMostAllocated", Weight: 2},
{Name: "NodeAffinity", Weight: 2},
{Name: "NodePreferAvoidPods", Weight: 2},
{Name: "DefaultPodTopologySpread", Weight: 2},
{Name: "SelectorSpread", Weight: 2},
{Name: "TaintToleration", Weight: 2},
},
"BindPlugin": {{Name: "DefaultBinder"}},
@@ -688,7 +688,7 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
},
"PreScorePlugin": {
{Name: "InterPodAffinity"},
{Name: "DefaultPodTopologySpread"},
{Name: "SelectorSpread"},
{Name: "TaintToleration"},
},
"ScorePlugin": {
@@ -699,7 +699,7 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
{Name: "NodeResourcesMostAllocated", Weight: 2},
{Name: "NodeAffinity", Weight: 2},
{Name: "NodePreferAvoidPods", Weight: 2},
{Name: "DefaultPodTopologySpread", Weight: 2},
{Name: "SelectorSpread", Weight: 2},
{Name: "TaintToleration", Weight: 2},
},
"BindPlugin": {{Name: "DefaultBinder"}},
@@ -794,7 +794,7 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
},
"PreScorePlugin": {
{Name: "InterPodAffinity"},
{Name: "DefaultPodTopologySpread"},
{Name: "SelectorSpread"},
{Name: "TaintToleration"},
},
"ScorePlugin": {
@@ -805,7 +805,7 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
{Name: "NodeResourcesMostAllocated", Weight: 2},
{Name: "NodeAffinity", Weight: 2},
{Name: "NodePreferAvoidPods", Weight: 2},
{Name: "DefaultPodTopologySpread", Weight: 2},
{Name: "SelectorSpread", Weight: 2},
{Name: "TaintToleration", Weight: 2},
},
"BindPlugin": {{Name: "DefaultBinder"}},
@@ -912,7 +912,7 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
},
"PreScorePlugin": {
{Name: "InterPodAffinity"},
{Name: "DefaultPodTopologySpread"},
{Name: "SelectorSpread"},
{Name: "TaintToleration"},
},
"ScorePlugin": {
@@ -924,7 +924,7 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
{Name: "NodeAffinity", Weight: 2},
{Name: "NodePreferAvoidPods", Weight: 2},
{Name: "RequestedToCapacityRatio", Weight: 2},
{Name: "DefaultPodTopologySpread", Weight: 2},
{Name: "SelectorSpread", Weight: 2},
{Name: "TaintToleration", Weight: 2},
},
"BindPlugin": {{Name: "DefaultBinder"}},
@@ -1033,7 +1033,7 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
},
"PreScorePlugin": {
{Name: "InterPodAffinity"},
{Name: "DefaultPodTopologySpread"},
{Name: "SelectorSpread"},
{Name: "TaintToleration"},
},
"ScorePlugin": {
@@ -1045,7 +1045,7 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
{Name: "NodeAffinity", Weight: 2},
{Name: "NodePreferAvoidPods", Weight: 2},
{Name: "RequestedToCapacityRatio", Weight: 2},
{Name: "DefaultPodTopologySpread", Weight: 2},
{Name: "SelectorSpread", Weight: 2},
{Name: "TaintToleration", Weight: 2},
},
"BindPlugin": {{Name: "DefaultBinder"}},
@@ -1154,7 +1154,7 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
},
"PreScorePlugin": {
{Name: "InterPodAffinity"},
{Name: "DefaultPodTopologySpread"},
{Name: "SelectorSpread"},
{Name: "TaintToleration"},
},
"ScorePlugin": {
@@ -1166,7 +1166,7 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
{Name: "NodeAffinity", Weight: 2},
{Name: "NodePreferAvoidPods", Weight: 2},
{Name: "RequestedToCapacityRatio", Weight: 2},
{Name: "DefaultPodTopologySpread", Weight: 2},
{Name: "SelectorSpread", Weight: 2},
{Name: "TaintToleration", Weight: 2},
},
"BindPlugin": {{Name: "DefaultBinder"}},
@@ -1279,7 +1279,7 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
},
"PreScorePlugin": {
{Name: "InterPodAffinity"},
{Name: "DefaultPodTopologySpread"},
{Name: "SelectorSpread"},
{Name: "TaintToleration"},
},
"ScorePlugin": {
@@ -1291,7 +1291,7 @@ func TestCompatibility_v1_Scheduler(t *testing.T) {
{Name: "NodeAffinity", Weight: 2},
{Name: "NodePreferAvoidPods", Weight: 2},
{Name: "RequestedToCapacityRatio", Weight: 2},
{Name: "DefaultPodTopologySpread", Weight: 2},
{Name: "SelectorSpread", Weight: 2},
{Name: "TaintToleration", Weight: 2},
},
"BindPlugin": {{Name: "DefaultBinder"}},
@@ -1409,7 +1409,7 @@ func TestAlgorithmProviderCompatibility(t *testing.T) {
{Name: "InterPodAffinity"},
{Name: "PodTopologySpread"},
{Name: "TaintToleration"},
{Name: "DefaultPodTopologySpread"},
{Name: "SelectorSpread"},
},
"ScorePlugin": {
{Name: "NodeResourcesBalancedAllocation", Weight: 1},
@@ -1420,7 +1420,7 @@ func TestAlgorithmProviderCompatibility(t *testing.T) {
{Name: "NodePreferAvoidPods", Weight: 10000},
{Name: "PodTopologySpread", Weight: 2},
{Name: "TaintToleration", Weight: 1},
{Name: "DefaultPodTopologySpread", Weight: 1},
{Name: "SelectorSpread", Weight: 1},
},
"BindPlugin": {{Name: "DefaultBinder"}},
"ReservePlugin": {{Name: "VolumeBinding"}},
@@ -1479,7 +1479,7 @@ func TestAlgorithmProviderCompatibility(t *testing.T) {
{Name: "InterPodAffinity"},
{Name: "PodTopologySpread"},
{Name: "TaintToleration"},
{Name: "DefaultPodTopologySpread"},
{Name: "SelectorSpread"},
},
"ScorePlugin": {
{Name: "NodeResourcesBalancedAllocation", Weight: 1},
@@ -1490,7 +1490,7 @@ func TestAlgorithmProviderCompatibility(t *testing.T) {
{Name: "NodePreferAvoidPods", Weight: 10000},
{Name: "PodTopologySpread", Weight: 2},
{Name: "TaintToleration", Weight: 1},
{Name: "DefaultPodTopologySpread", Weight: 1},
{Name: "SelectorSpread", Weight: 1},
},
"ReservePlugin": {{Name: "VolumeBinding"}},
"PreBindPlugin": {{Name: "VolumeBinding"}},
@@ -1569,7 +1569,7 @@ func TestPluginsConfigurationCompatibility(t *testing.T) {
{Name: "InterPodAffinity"},
{Name: "PodTopologySpread"},
{Name: "TaintToleration"},
{Name: "DefaultPodTopologySpread"},
{Name: "SelectorSpread"},
},
"ScorePlugin": {
{Name: "NodeResourcesBalancedAllocation", Weight: 1},
@@ -1580,7 +1580,7 @@ func TestPluginsConfigurationCompatibility(t *testing.T) {
{Name: "NodePreferAvoidPods", Weight: 10000},
{Name: "PodTopologySpread", Weight: 2},
{Name: "TaintToleration", Weight: 1},
{Name: "DefaultPodTopologySpread", Weight: 1},
{Name: "SelectorSpread", Weight: 1},
},
"ReservePlugin": {{Name: "VolumeBinding"}},
"PreBindPlugin": {{Name: "VolumeBinding"}},
@@ -1770,7 +1770,7 @@ func TestPluginsConfigurationCompatibility(t *testing.T) {
PreScore: &config.PluginSet{
Disabled: []config.Plugin{
{Name: "InterPodAffinity"},
{Name: "DefaultPodTopologySpread"},
{Name: "SelectorSpread"},
{Name: "TaintToleration"},
{Name: "PodTopologySpread"},
},
@@ -1783,7 +1783,7 @@ func TestPluginsConfigurationCompatibility(t *testing.T) {
{Name: "NodeResourcesLeastAllocated"},
{Name: "NodeAffinity"},
{Name: "NodePreferAvoidPods"},
{Name: "DefaultPodTopologySpread"},
{Name: "SelectorSpread"},
{Name: "TaintToleration"},
{Name: "PodTopologySpread"},
},
@@ -1856,7 +1856,7 @@ func TestPluginsConfigurationCompatibility(t *testing.T) {
PreScore: &config.PluginSet{
Enabled: []config.Plugin{
{Name: "TaintToleration"},
{Name: "DefaultPodTopologySpread"},
{Name: "SelectorSpread"},
{Name: "InterPodAffinity"},
},
Disabled: []config.Plugin{
@@ -1866,7 +1866,7 @@ func TestPluginsConfigurationCompatibility(t *testing.T) {
Score: &config.PluginSet{
Enabled: []config.Plugin{
{Name: "TaintToleration", Weight: 24},
{Name: "DefaultPodTopologySpread", Weight: 24},
{Name: "SelectorSpread", Weight: 24},
{Name: "NodePreferAvoidPods", Weight: 24},
{Name: "NodeAffinity", Weight: 24},
{Name: "NodeResourcesLeastAllocated", Weight: 24},
@@ -1913,12 +1913,12 @@ func TestPluginsConfigurationCompatibility(t *testing.T) {
},
"PreScorePlugin": {
{Name: "TaintToleration"},
{Name: "DefaultPodTopologySpread"},
{Name: "SelectorSpread"},
{Name: "InterPodAffinity"},
},
"ScorePlugin": {
{Name: "TaintToleration", Weight: 24},
{Name: "DefaultPodTopologySpread", Weight: 24},
{Name: "SelectorSpread", Weight: 24},
{Name: "NodePreferAvoidPods", Weight: 24},
{Name: "NodeAffinity", Weight: 24},
{Name: "NodeResourcesLeastAllocated", Weight: 24},