Skip to content

Commit 6aa03e5

Browse files
feat(opensearchservice): add useLatestServiceSoftwareForBlueGreen support (#38499)
### Issue #38664 Closes #38664 . ### Issue Adds support for `UseLatestServiceSoftwareForBlueGreen` in the OpenSearch domain `SoftwareUpdateOptions`, aligning the L2 construct with the service API. ### Reason for this change The OpenSearch Service API supports `UseLatestServiceSoftwareForBlueGreen` in `SoftwareUpdateOptions`, which allows domains to automatically use the latest available service software when a blue/green deployment is triggered. This property is already in the CloudFormation resource schema (`AWS::OpenSearchService::Domain`) but was missing from the CDK L2 construct. ### Description of changes - Added `useLatestServiceSoftwareForBlueGreen` optional boolean prop to `DomainProps` - Updated L1 wiring to pass the property through to `softwareUpdateOptions` - Updated the `softwareUpdateOptions` condition to render when either `enableAutoSoftwareUpdate` or `useLatestServiceSoftwareForBlueGreen` is specified - Updated README with usage example - Added unit tests ### Description of how you validated changes Unit tests covering: - `useLatestServiceSoftwareForBlueGreen` set to `true` - `useLatestServiceSoftwareForBlueGreen` set to `false` - Both props used together - Existing tests still pass (absent when neither prop specified) ### Checklist - [x] My code adheres to the [CONTRIBUTING GUIDE](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md) - [x] Is this a breaking change (changing existing behavior or interface)? No - [x] Does this change require a documentation update? Yes (README updated) - [x] Does this change require an update to the integration tests? Not required (no new CFN resource type) --- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
1 parent 6ede006 commit 6aa03e5

16 files changed

Lines changed: 118808 additions & 2 deletions

‎packages/@aws-cdk-testing/framework-integ/test/aws-opensearchservice/test/integ.opensearch.software-update-options.js.snapshot/OpenSearchSoftwareUpdateOptionsIntegDefaultTestDeployAssert277CBA0D.assets.json‎

Lines changed: 33 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎packages/@aws-cdk-testing/framework-integ/test/aws-opensearchservice/test/integ.opensearch.software-update-options.js.snapshot/OpenSearchSoftwareUpdateOptionsIntegDefaultTestDeployAssert277CBA0D.metadata.json‎

Lines changed: 72 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎packages/@aws-cdk-testing/framework-integ/test/aws-opensearchservice/test/integ.opensearch.software-update-options.js.snapshot/OpenSearchSoftwareUpdateOptionsIntegDefaultTestDeployAssert277CBA0D.template.json‎

Lines changed: 145 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)