Skip to content

Postgres agent integration forbidden tag error #20945

@markdjones82

Description

@markdjones82

Hi, we have a lambda postgres agent that was created a few years ago and since upgrading to python3.12 runtime environment. We are receiving the below error when trying to upload metrics. I am unsure what to modify to get this tag removed. Any help? Please let me know any info you need to help troubleshoot.

We are using these libraries:

from datadog_api_client.v1 import ApiClient, ApiException, Configuration
from datadog_api_client.v1.api import metrics_api
from datadog_api_client.v1.models import *

Series:
  formatted = Series(
                host = hostname,           
                interval = 1,
                metric = name,
                points = points,
                tags = tags,
                type = METRIC_TYPE_SUBMISSION_TO_BACKEND_MAP[metric_type]
            )

It seems to fail because of this:

checker = PostgreSql("Postgres", {}, [db_config])

the db_config requires a host entry which then gets a tag:
{ "host": db["Endpoint"], "port": db["Port"], "username": "datadog", "ssl": "require", "password": token, }

Caught error for cluster clustername.aws: Metric postgres.can_connect was submitted with a forbidden tag: host. Please rename this tag, or skip the tag validation with DDEV_SKIP_GENERIC_TAGS_CHECK environment variable.. Continuing with next cluster.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions