How to modify the hostname for publishing CloudWatch metrics from Synthetic Canary

0

There is a synthetics.afterCanary funtion in the BrokenLinkChecker blueprint synthetic canary that is sending CloudWatch latency and result metrics to CloudWatch but I am getting a timeout error because I have no route to that address. How can I repoint the hostname/ endpoint for that cloudwatch.PutMetricData api call from the private dns, monitoring.region.amazonaws.com, to the private link vpc endpoint, ...vpce.amazonaws.com?

I don't know how to change the properties of that CloudWatch object because the CloudWatch constructor is not a part of the canary/lambda blueprint code and I don't see any documentation on synthetics.afterCanary method here : https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/CloudWatch_Synthetics_Canaries_Library_Nodejs.html but maybe I am looking in the wrong place. (Nodejs and aws sdk javascript 2).

1개 답변
0

set environment variable AWS_ENDPOINT_URL_CLOUDWATCH=<vpc endpoint> in canary lambda function.

Refer for service specific endpoints.

https://docs.aws.amazon.com/sdkref/latest/guide/feature-ss-endpoints.html

https://docs.aws.amazon.com/sdkref/latest/guide/ss-endpoints-table.html

AWS
답변함 6달 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠