-
Notifications
You must be signed in to change notification settings - Fork 4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(imagebuilder): revert property field typings
Certain fields of the `ImageBuilder` service used to be typed as `Json` (i.e., arbitrary data). - In TypeScript, you would pass that data as an object literal with *capitalized* properties. - In Python, you would pass it as a `dict` - In Java, you would pass it as a `HashMap` - etc In the new CloudFormation spec, it is now typed as a struct. This adds type information that didn't use to be there. CDK now generates classes for it. - In TypeScript, you must now pass an object literal with *lowercased* properties. - In Python, you must now pass it as an instance of a class. - In Java, you must now use a builder to construct the object. Because of this, adding types to properties is a breaking change to the L1 layer. If you don't pass the information correctly, an empty object comes out the other end, probably not rendering what you expected. This is disastrous for construct libraries that are using L1s, as they are not in control when users upgrade their libraries but they may all of a sudden be broken with no recourse. Case in point: [ParallelCluster3](https://github.com/aws/aws-parallelcluster)
- Loading branch information
Showing
1 changed file
with
2 additions
and
69 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters