-
Notifications
You must be signed in to change notification settings - Fork 34
calling addForwarderToNonLambdaLogGroups via Aspects results in unstable LogicalIds #247
Copy link
Copy link
Open
Labels
enhancementNew feature or requestNew feature or request
Description
Expected Behavior
Given an aspect:
export class DatadogAspect implements IAspect {
constructor(private props: {
datadog: Datadog;
}) {
}
visit(node: IConstruct): void {
if (
node instanceof Function ||
node instanceof NodejsFunction ||
node instanceof PythonFunction
) {
this.props.datadog.addLambdaFunctions([node]);
}
if (node instanceof DockerImageFunction) {
this.props.datadog.addForwarderToNonLambdaLogGroups([(node as DockerImageFunction).logGroup]);
}
}
}
Synthesizing the app should result in a stable SubscriptionFilter resource
Actual Behavior
Each synth results in a different LogicalId of the subscription resource.
Steps to Reproduce the Problem
- Create a stack with a DockerImageFunction resource.
- Use the above aspect like:
const datadog = new Datadog(...);
Aspects.of(this).add(new DatadogAspect({ datadog: datadog }));
Synthesize the stack and note the LogicalId of the SubscriptionFilter resource
Synthesize again and notice the LogicalId has changed.
Specifications
- Datadog Lambda Layer version:
extensionLayerVersion: 43, - Node version: 20.9.0
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request