Skip to content

(CfnInclude): CfnInclude omits aws_autoscaling. UpdatePolicy that dont exists in the CDK (MinActiveInstancesPercent) #33810

Closed
@NetaNir

Description

@NetaNir

Describe the bug

When CfnInclude references a template that has an UpdatePolicy for autoscaling groups it silently omits the MinActiveInstancesPercent property because the code in cfn-parse.ts does not include the property:



      return undefinedIfAllValuesAreEmpty({
        maxBatchSize: FromCloudFormation.getNumber(p.MaxBatchSize).value,
        minInstancesInService: FromCloudFormation.getNumber(p.MinInstancesInService).value,
        minSuccessfulInstancesPercent: FromCloudFormation.getNumber(p.MinSuccessfulInstancesPercent).value,
        pauseTime: FromCloudFormation.getString(p.PauseTime).value,
        suspendProcesses: FromCloudFormation.getStringArray(p.SuspendProcesses).value,
        waitOnResourceSignals: FromCloudFormation.getBoolean(p.WaitOnResourceSignals).value,
      });

source

The result is that the property is omitted completely and silently :(

Regression Issue

  • Select this option if this issue appears to be a regression.

Last Known Working CDK Version

No response

Expected Behavior

MinActiveInstancesPercent should be included in the output template

Current Behavior

The result is that the property is omitted completely and silently :(

Reproduction Steps

Create a CFN template with an autoscaling group and an update policy which includes MinActiveInstancesPercent, reference the template file using CfnInclude, the MinActiveInstancesPercent will not exist in the template in cdk.out

Possible Solution

No response

Additional Information/Context

No response

CDK CLI Version

2.1003.0

Framework Version

2.132.0

Node.js Version

18

OS

MacOs

Language

TypeScript

Language Version

No response

Other information

No response

Metadata

Metadata

Assignees

Labels

@aws-cdk/cloudformation-includeIssues related to the "CFN include v.20" packagebugThis issue is a bug.effort/mediumMedium work item – several days of effortp1

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions