DataDog / datadog-lambda-extension

Datadog Lambda Extension
Apache License 2.0
79 stars 4 forks source link

Noisy log "http: proxy error: context canceled" #383

Closed howdy10 closed 1 month ago

howdy10 commented 1 month ago

Set up:

Runtime: Node.js 20.x
Layer 1: Datadog-Node20-x - version 115 - arn:aws:lambda:us-east-1:464622532012:layer:Datadog-Node20-x:115
Layer 2: Datadog-Extension - 63 - arn:aws:lambda:us-east-1:464622532012:layer:Datadog-Extension:63

Cdk Version: 2.138 
datadog-cdk-constructs-v2: ^1.12.0

Problem is I'm getting a sea of "http: proxy error: context canceled"

I traced this down to this log shows whenever a cloudWatch log stread/log group ends. Each group starts with

{"DD_EXTENSION_FAILOVER_REASON":"appsec_enabled"}

Setting enableDatadogASM to false seemed to clear up that noisy log, but I would like to keep that enabled since it is for Threat Detection. I know it's just noise logs and can be ignored but it would be really nice to have them not show.

cdk:

this.datadog = new Datadog(this, 'Datadog', {
        nodeLayerVersion: 100,
        extensionLayerVersion: 55,
        site: 'datadoghq.com',
        apiKey: process.env.DD_API_KEY,
        enableDatadogTracing: true,
        enableDatadogASM: true,
        env: process.env.DD_ENV,
        service: process.env.DD_SERVICE,
        version: process.env.DD_VERSION
      });
      this.datadog.addLambdaFunctions([this]);

image

hghotra commented 1 month ago

Hi @howdy10, this was fixed in extension v64. Can you upgrade and let us know if it goes away.