mirror of
https://github.com/floci-io/floci.git
synced 2026-11-23 22:11:36 -05:00
AWS documents StackId in every Create, Update and Delete request as the ARN of the stack that contains the custom resource, and handlers rely on it. #4973 now passes the engine's stack id and stashes it for Delete, but an engine with no stack ARN still leaks a non-ARN: Cloud Control's standalone engine uses the stack name as its id, so its custom resources got StackId "cloudcontrol". A stack id is now minted when there is no stack ARN to send. A resource created through Cloud Control has its minted id stashed at Create, so its Delete repeats it. A resource stashed by an earlier release with no __FlociStackId, or with a non-ARN one, gets a freshly minted ARN on Delete, because the delete path does not reach the stack. An integration test drives Create, Update and Delete through a mocked handler and checks the event's StackId against Ref AWS::StackId and DescribeStacks, including a nested stack's own id, and the docs say so.