Open thomasklinger1234 opened 3 years ago
This issue has not received any attention in 1 year. If you want to keep this issue open, please leave a comment below and auto-close will be canceled.
Bump. This would be nice to have.
Any updates or a work around on how to do it?
@verma-rajatk you can use the Level 1 constructs to enable x-ray tracing on a Canary:
const canary = new Canary(this, 'Canary', canaryProps);
// enable x-ray tracing for Canary
const cfnCanary = canary.node.defaultChild as CfnCanary;
cfnCanary.runConfig = {
...cfnCanary.runConfig,
activeTracing: true,
};
Can't remember if you need to add any extra permissions to allow that to work, you might need to tweak the role it runs under as well.
Enable active tracing (https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-synthetics-canary-runconfig.html#cfn-synthetics-canary-runconfig-activetracing) for a canary.
Use Case
End-to-end tracing from Canary to API Gateway to Lambda.
Proposed Solution
Add a new property to
synthetics.CanaryProps
:By default, it will be
false
. When set to true, it will also append XRay permissions to the IAM role (e.g. the managed policyarn:aws:iam::aws:policy/AWSXrayWriteOnlyAccess
).Other
Similar PR: https://github.com/aws/aws-cdk/pull/11865.
This is a :rocket: Feature Request