projects
/
collectd.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
src/libcollectdclient/client.c: Fix "Dead assignment" warning.
[collectd.git]
/
src
/
nginx.c
diff --git
a/src/nginx.c
b/src/nginx.c
index
7568a2c
..
de52262
100644
(file)
--- a/
src/nginx.c
+++ b/
src/nginx.c
@@
-181,6
+181,8
@@
static void submit (char *type, char *inst, long long value)
values[0].gauge = value;
else if (strcmp (type, "nginx_requests") == 0)
values[0].derive = value;
values[0].gauge = value;
else if (strcmp (type, "nginx_requests") == 0)
values[0].derive = value;
+ else if (strcmp (type, "connections") == 0)
+ values[0].derive = value;
else
return;
else
return;
@@
-254,6
+256,8
@@
static int nginx_read (void)
&& (atoll (fields[1]) != 0)
&& (atoll (fields[2]) != 0))
{
&& (atoll (fields[1]) != 0)
&& (atoll (fields[2]) != 0))
{
+ submit ("connections", "accepted", atoll (fields[0]));
+ submit ("connections", "handled", atoll (fields[1]));
submit ("nginx_requests", NULL, atoll (fields[2]));
}
}
submit ("nginx_requests", NULL, atoll (fields[2]));
}
}