From b923512980dccb7d462df08c6a1f692d6dfe84d1 Mon Sep 17 00:00:00 2001 From: Asher Feldman Date: Tue, 12 Nov 2019 20:20:17 -0800 Subject: [PATCH] fix(monitoreddeploy): unset pinMinimumCapacity when scaling to 100% (#3294) --- .../servergroup/strategies/MonitoredDeployStrategy.groovy | 1 + .../servergroup/strategies/RollingRedBlackStrategy.groovy | 1 + 2 files changed, 2 insertions(+) diff --git a/orca-clouddriver/src/main/groovy/com/netflix/spinnaker/orca/clouddriver/pipeline/servergroup/strategies/MonitoredDeployStrategy.groovy b/orca-clouddriver/src/main/groovy/com/netflix/spinnaker/orca/clouddriver/pipeline/servergroup/strategies/MonitoredDeployStrategy.groovy index f5b78bc947..0232d7883c 100644 --- a/orca-clouddriver/src/main/groovy/com/netflix/spinnaker/orca/clouddriver/pipeline/servergroup/strategies/MonitoredDeployStrategy.groovy +++ b/orca-clouddriver/src/main/groovy/com/netflix/spinnaker/orca/clouddriver/pipeline/servergroup/strategies/MonitoredDeployStrategy.groovy @@ -194,6 +194,7 @@ class MonitoredDeployStrategy implements Strategy { scalePct : p, pinCapacity : p < 100, // if p < 100, capacity should be pinned (min == max == desired) unpinMinimumCapacity : p == 100, // if p == 100, min capacity should be restored to the original unpinned value from source + pinMinimumCapacity : p < 100, // pinMinimumCapacity should be false when unpinMinimumCapacity is true useNameAsLabel : true, // hint to deck that it should _not_ override the name targetHealthyDeployPercentage: stage.context.targetHealthyDeployPercentage ] diff --git a/orca-clouddriver/src/main/groovy/com/netflix/spinnaker/orca/clouddriver/pipeline/servergroup/strategies/RollingRedBlackStrategy.groovy b/orca-clouddriver/src/main/groovy/com/netflix/spinnaker/orca/clouddriver/pipeline/servergroup/strategies/RollingRedBlackStrategy.groovy index ffb369ccbd..effc213f31 100644 --- a/orca-clouddriver/src/main/groovy/com/netflix/spinnaker/orca/clouddriver/pipeline/servergroup/strategies/RollingRedBlackStrategy.groovy +++ b/orca-clouddriver/src/main/groovy/com/netflix/spinnaker/orca/clouddriver/pipeline/servergroup/strategies/RollingRedBlackStrategy.groovy @@ -170,6 +170,7 @@ class RollingRedBlackStrategy implements Strategy, ApplicationContextAware { scalePct : p, pinCapacity : p < 100, // if p < 100, capacity should be pinned (min == max == desired) unpinMinimumCapacity: p == 100, // if p == 100, min capacity should be restored to the original unpinned value from source + pinMinimumCapacity : p < 100, // pinMinimumCapacity should be false when unpinMinimumCapacity is true useNameAsLabel : true, // hint to deck that it should _not_ override the name targetHealthyDeployPercentage: stage.context.targetHealthyDeployPercentage ]