Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

longRunningTransactionsQuery counts all running queries #1066

Open
grzn opened this issue Sep 8, 2024 · 0 comments
Open

longRunningTransactionsQuery counts all running queries #1066

grzn opened this issue Sep 8, 2024 · 0 comments

Comments

@grzn
Copy link

grzn commented Sep 8, 2024

https://github.com/prometheus-community/postgres_exporter/blob/98f75c7e7ea3a02b974cfeda736cf7dbc091b18e/collector/pg_long_running_transactions.go#L52C2-L52C30

Its missing a condition on the duration of the query, as seen in https://github.com/prometheus-community/postgres_exporter/pull/819/files, e.g.

AND (now() - xact_start) > '1 minutes'::interval 

CleanShot 2024-09-09 at 01 15 42

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant