From 9340bca14e7d57f5856fd3f9c04c7d44ebff2723 Mon Sep 17 00:00:00 2001 From: Wojciech Tyczynski Date: Fri, 29 Jun 2018 11:33:14 +0200 Subject: [PATCH] Revert "Make no. of services in load test configurable" --- test/e2e/scalability/load.go | 18 ++---------------- 1 file changed, 2 insertions(+), 16 deletions(-) diff --git a/test/e2e/scalability/load.go b/test/e2e/scalability/load.go index 135ff48975f..cd977c628d4 100644 --- a/test/e2e/scalability/load.go +++ b/test/e2e/scalability/load.go @@ -492,17 +492,6 @@ func GenerateConfigsForGroup( secretConfigs := make([]*testutils.SecretConfig, 0, count*secretsPerPod) configMapConfigs := make([]*testutils.ConfigMapConfig, 0, count*configMapsPerPod) savedKind := kind - - // We assume by default that every RC is part of its own service. - // However, you can override it using SERVICE_TO_RC_RATIO env var. - serviceToRCRatio := 1.0 - if serviceToRCRatioEnv := os.Getenv("SERVICE_TO_RC_RATIO"); serviceToRCRatioEnv != "" { - if value, err := strconv.ParseFloat(serviceToRCRatioEnv, 64); err == nil { - serviceToRCRatio = value - } - } - numServices := int(float64(count) * serviceToRCRatio) - for i := 1; i <= count; i++ { kind = savedKind namespace := nss[i%len(nss)].Name @@ -546,11 +535,8 @@ func GenerateConfigsForGroup( MemRequest: 26214400, // 25MB SecretNames: secretNames, ConfigMapNames: configMapNames, - } - - // Add a label to first 'numServices' RCs (to include them in services). - if i <= numServices { - baseConfig.Labels = map[string]string{svcLabelKey: groupName + "-" + strconv.Itoa(i)} + // Define a label to group every 2 RCs into one service. + Labels: map[string]string{svcLabelKey: groupName + "-" + strconv.Itoa((i+1)/2)}, } if kind == randomKind {