Skip to content

authMode parameter is not optional for Datadog scaler #6683

Open
@qlikcoe

Description

@qlikcoe

Report

The documentation for Datadog scaler mentions authMode: as an optional authentication parameter, where the default value is the only possible value for this scaler and it's bearer.

I couldn't make this scaler work until I manually set this parameter to authMode: bearer. Right away Keda was able to authenticate against datadog-cluster-agent-metrics-api.

Expected Behavior

Keda should be using bearer for the authMode by default when sending requests to Datadog's Cluster Agent (metrics endpoint on 8443)

Actual Behavior

Keda is not able to communicate with the Datadog's Cluster Agent.

Steps to Reproduce the Problem

  1. Create DatadogMetric resource with some query that is returning a valid value
  2. Create ScaledObject that is using Datadog trigger and Cluster Agent as proxy (useClusterAgentProxy: "true")
  3. Check the corresponding HPA and it's status, expect to see an error message, e.g:
unable to get external metric devops-internal/datadogmetric@devops-internal:test-dd-metric/&LabelSelector{MatchLabels:map[string]string{scaledobject.keda.sh/name: test-dd-metric,},MatchExpressions:[]LabelSelectorRequirement{},}: unable to fetch metrics from external metrics API: rpc error: code = Unknown desc = error when getting metric values metric:datadogmetric@devops-internal:test-dd-metric encountered error

Logs from KEDA operator

No response

KEDA Version

2.15.1

Kubernetes Version

1.30

Platform

Amazon Web Services

Scaler Details

Datadog

Anything else?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    Status

    To Triage

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions