Serverless APIs should have AWS X-Ray tracing enabled to capture distributed traces for requests, which helps diagnose performance issues and investigate security incidents or anomalous application behavior. The TracingEnabled property on AWS::Serverless::Api resources must be defined and set to true. Resources with TracingEnabled missing, null, or set to false will be flagged.
AWSTemplateFormatVersion:'2010-09-09'Transform:AWS::Serverless-2016-10-31Description:AWS SAM template with a simple API definitionResources:ApiGatewayApi3:Type:AWS::Serverless::ApiProperties:StageName:prodTracingEnabled:true
Non-Compliant Code Examples
AWSTemplateFormatVersion:'2010-09-09'Transform:AWS::Serverless-2016-10-31Description:AWS SAM template with a simple API definitionResources:ApiGatewayApi:Type:AWS::Serverless::ApiProperties:StageName:prod
AWSTemplateFormatVersion:'2010-09-09'Transform:AWS::Serverless-2016-10-31Description:AWS SAM template with a simple API definitionResources:ApiGatewayApi2:Type:AWS::Serverless::ApiProperties:StageName:prodTracingEnabled:false
1
2
rulesets:- CloudFormation / AWS # Rules to enforce / AWS.
맞춤형 데모 요청
Datadog 시작하기
Ask AI
AI-generated responses may be inaccurate. Verify important info.