projects
/
collectd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0eff2a8
)
Update postgresql.c
author
daniacs
<daniacs@gmail.com>
Fri, 20 Oct 2017 16:36:12 +0000
(14:36 -0200)
committer
GitHub
<noreply@github.com>
Fri, 20 Oct 2017 16:36:12 +0000
(14:36 -0200)
A simple way collectd to identify itself to pg_stat_activity view.
src/postgresql.c
patch
|
blob
|
history
diff --git
a/src/postgresql.c
b/src/postgresql.c
index
3b702ae
..
b122dfe
100644
(file)
--- a/
src/postgresql.c
+++ b/
src/postgresql.c
@@
-340,6
+340,7
@@
static int c_psql_connect(c_psql_database_t *db) {
C_PSQL_PAR_APPEND(buf, buf_len, "sslmode", db->sslmode);
C_PSQL_PAR_APPEND(buf, buf_len, "krbsrvname", db->krbsrvname);
C_PSQL_PAR_APPEND(buf, buf_len, "service", db->service);
+ C_PSQL_PAR_APPEND(buf, buf_len, "application_name", "collectd_postgresql");
db->conn = PQconnectdb(conninfo);
db->proto_version = PQprotocolVersion(db->conn);