From b0e546934b4140a3118c7eec466f320a30feae75 Mon Sep 17 00:00:00 2001 From: Julio Chana Date: Fri, 29 Dec 2017 12:55:44 +0100 Subject: [PATCH] [DEVOPS-632] Change default exporter resources/limits --- pkg/failover/client.go | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/pkg/failover/client.go b/pkg/failover/client.go index 680c88de7..fafd440c5 100644 --- a/pkg/failover/client.go +++ b/pkg/failover/client.go @@ -21,9 +21,13 @@ import ( // variables refering to the redis exporter port const ( - exporterPort = 9121 - exporterPortName = "http-metrics" - exporterContainerName = "redis-exporter" + exporterPort = 9121 + exporterPortName = "http-metrics" + exporterContainerName = "redis-exporter" + exporterDefaultRequestCPU = "25m" + exporterDefaultLimitCPU = "50m" + exporterDefaultRequestMemory = "50Mi" + exporterDefaultLimitMemory = "100Mi" ) const ( @@ -961,12 +965,12 @@ func createRedisExporterContainer() v1.Container { }, Resources: v1.ResourceRequirements{ Limits: v1.ResourceList{ - v1.ResourceCPU: resource.MustParse("300m"), - v1.ResourceMemory: resource.MustParse("300Mi"), + v1.ResourceCPU: resource.MustParse(exporterDefaultLimitCPU), + v1.ResourceMemory: resource.MustParse(exporterDefaultLimitMemory), }, Requests: v1.ResourceList{ - v1.ResourceCPU: resource.MustParse("200m"), - v1.ResourceMemory: resource.MustParse("150Mi"), + v1.ResourceCPU: resource.MustParse(exporterDefaultRequestCPU), + v1.ResourceMemory: resource.MustParse(exporterDefaultRequestMemory), }, }, }