Files
floci/docs
Alessandro Lattao fcb41966a8 fix(cloudformation): read an ECS task definition's properties as the ECS handler does (#6018)
Measured on CloudFormation (eu-west-1): an AWS::ECS::TaskDefinition gets
no template validation. CloudFormation hands the ECS handler every
scalar as text, and the handler converts each to the type the resource
schema declares: an integer is a sign and digits once trimmed, within
32 bits ("+128", " 128", "0128"), and a boolean is true or false in
lower, upper or title case once trimmed. A value it cannot convert
("abc", 4.5 or true for an integer, "yes", "tRuE" or "1" for a
boolean), and an object, a list and a scalar standing for one another,
fail the resource with every violation of the unconverted model, where
every scalar is a String, so a Memory of 128 is listed beside the value
that failed. At each object its missing required members come first,
then its members in the schema's order. When every value converts, the
required members the model lacks fail it alone, grouped where their
paths meet as the schema validator groups them.

Floci read the properties as plain JSON: a Memory of "abc" and a
container without an image were registered, and an Essential of
"False" registered an essential container.

AWS::ECS::TaskDefinition joins the generated cfn-property-types.json,
whose structures now carry the members the schema requires, read into
RequestShapeModel's shapes. CfnPropertyTypes' walk over the shapes is
shared by the template validation Reader and the new HandlerReader,
which differ in how a scalar converts and in what a mismatch does.
2026-10-19 16:15:05 -04:00
..
2026-03-15 17:43:56 -05:00