Skip to content

Multi line sample in aws_rds_log_messages_total #2

Open
@vikranty123

Description

@vikranty123

Postgres logs the statement after the error

2023-03-02 07:12:56 UTC:IP_ADDRESS(35258):postgres@DB_NAME:[7317]:ERROR:  canceling statement due to statement timeout
2023-03-02 07:12:56 UTC:IP_ADDRESS(35258):postgres@DB_NAME:[7317]:STATEMENT:  select pg_sleep(20);

The series created in prometheus is

aws_rds_log_messages_total{instance="host.docker.internal:8014", job="aws_agent", level="error", pattern_hash="e4622f3614d87800cbe4608232f0c563", rds_instance_id="ap-south-1/DB_NAME", sample="UTC:IP_ADDRESS(35258):postgres@DB_NAME:[7317]:ERROR: canceling statement due to statement timeout"}

We've an immediate requirement to alert on the statements which are a) timed out or b) deadlocked. If we can add the statement to the sample, it will solve the problem. Do you've any plan to support this feature soon ?

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