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

Is this an error in the template or did I miss something? #157

Open
osborm opened this issue Mar 25, 2020 · 0 comments
Open

Is this an error in the template or did I miss something? #157

osborm opened this issue Mar 25, 2020 · 0 comments

Comments

@osborm
Copy link

osborm commented Mar 25, 2020

The Discover PostgreSQL Databases discovery rule contains three item prototypes that I don't understand. They also share the same item name with some other item prototypes which is confusing me.

The following three item prototypes are defined twice in the Discover PostgreSQL Databases LLD rule:

PostgreSQL Database rows deleted/sec on {#PATH}
PostgreSQL Database rows inserted/sec on {#PATH}
PostgreSQL Database rows updated/sec on {#PATH}

The keys are different for each multiply defined item name, so we have:

PostgreSQL Database rows deleted/sec on {#PATH}
pg.db.tup_deleted[{$PG_CONN},{$PG_DB},{#DATABASE}]
pg.table.n_tup_del[{$PG_CONN},{#DATABASE}]

PostgreSQL Database rows inserted/sec on {#PATH}
pg.db.tup_inserted[{$PG_CONN},{$PG_DB},{#DATABASE}]
pg.table.n_tup_ins[{$PG_CONN},{#DATABASE}]

PostgreSQL Database rows updated/sec on {#PATH}
pg.db.tup_updated[{$PG_CONN},{$PG_DB},{#DATABASE}]
pg.table.n_tup_upd[{$PG_CONN},{#DATABASE}]

the difference seems to be whether the item pulls data from pg_stat_database or pg_stat_all_tables

From what I can figure out from looking at the source code, it doesn't make sense to use pg.table.n_tup_ins, pg.table.n_tup_del or pg.table.n_tup_upd without supplying a table name which these prototypes do not.

However I am seeing values even when a table name is not supplied.

Can anyone explain this? Or should I just remove the three item prototypes in question?

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