add `_local` to apache
paulfantom committed
Jul 14, 2016 at 14:26 UTC
aa1dbccd9c604366d79f83e802eaf8b4ac2b2a72
1 file changed
+16
-16
charts.d/apache.chart.sh
+16
-16
@@ -165,27 +165,27 @@ apache_check() {
165
# _create is called once, to create the charts
166
apache_create() {
167
cat <<EOF
168
-CHART apache.bytesperreq '' "apache Lifetime Avg. Response Size" "bytes/request" statistics apache.bytesperreq area $((apache_priority + 8)) $apache_update_every
168
+CHART apache_local.bytesperreq '' "apache Lifetime Avg. Response Size" "bytes/request" statistics apache.bytesperreq area $((apache_priority + 8)) $apache_update_every
169
DIMENSION size '' absolute 1 ${apache_decimal_detail}
170
-CHART apache.workers '' "apache Workers" "workers" workers apache.workers stacked $((apache_priority + 5)) $apache_update_every
170
+CHART apache_local.workers '' "apache Workers" "workers" workers apache.workers stacked $((apache_priority + 5)) $apache_update_every
171
DIMENSION idle '' absolute 1 1
172
DIMENSION busy '' absolute 1 1
173
-CHART apache.reqpersec '' "apache Lifetime Avg. Requests/s" "requests/s" statistics apache.reqpersec line $((apache_priority + 6)) $apache_update_every
173
+CHART apache_local.reqpersec '' "apache Lifetime Avg. Requests/s" "requests/s" statistics apache.reqpersec line $((apache_priority + 6)) $apache_update_every
174
DIMENSION requests '' absolute 1 ${apache_decimal_detail}
175
-CHART apache.bytespersec '' "apache Lifetime Avg. Bandwidth/s" "kilobits/s" statistics apache.bytespersec area $((apache_priority + 7)) $apache_update_every
175
+CHART apache_local.bytespersec '' "apache Lifetime Avg. Bandwidth/s" "kilobits/s" statistics apache.bytespersec area $((apache_priority + 7)) $apache_update_every
176
DIMENSION sent '' absolute 8 $((apache_decimal_detail * 1000))
177
-CHART apache.requests '' "apache Requests" "requests/s" requests apache.requests line $((apache_priority + 1)) $apache_update_every
177
+CHART apache_local.requests '' "apache Requests" "requests/s" requests apache.requests line $((apache_priority + 1)) $apache_update_every
178
DIMENSION requests '' incremental 1 1
179
-CHART apache.net '' "apache Bandwidth" "kilobits/s" bandwidth apache.net area $((apache_priority + 3)) $apache_update_every
179
+CHART apache_local.net '' "apache Bandwidth" "kilobits/s" bandwidth apache.net area $((apache_priority + 3)) $apache_update_every
180
DIMENSION sent '' incremental 8 1
181
EOF
182
183
if [ ${apache_has_conns} -eq 1 ]
184
then
185
cat <<EOF2
186
-CHART apache.connections '' "apache Connections" "connections" connections apache.connections line $((apache_priority + 2)) $apache_update_every
186
+CHART apache_local.connections '' "apache Connections" "connections" connections apache.connections line $((apache_priority + 2)) $apache_update_every
187
DIMENSION connections '' absolute 1 1
188
-CHART apache.conns_async '' "apache Async Connections" "connections" connections apache.conns_async stacked $((apache_priority + 4)) $apache_update_every
188
+CHART apache_local.conns_async '' "apache Async Connections" "connections" connections apache.conns_async stacked $((apache_priority + 4)) $apache_update_every
189
DIMENSION keepalive '' absolute 1 1
190
DIMENSION closing '' absolute 1 1
191
DIMENSION writing '' absolute 1 1
@@ -209,22 +209,22 @@ apache_update() {
209
210
# write the result of the work.
211
cat <<VALUESEOF
212
-BEGIN apache.requests $1
212
+BEGIN apache_local.requests $1
213
SET requests = $((apache_accesses))
214
END
215
-BEGIN apache.net $1
215
+BEGIN apache_local.net $1
216
SET sent = $((apache_kbytes))
217
END
218
-BEGIN apache.reqpersec $1
218
+BEGIN apache_local.reqpersec $1
219
SET requests = $((apache_reqpersec))
220
END
221
-BEGIN apache.bytespersec $1
221
+BEGIN apache_local.bytespersec $1
222
SET sent = $((apache_bytespersec))
223
END
224
-BEGIN apache.bytesperreq $1
224
+BEGIN apache_local.bytesperreq $1
225
SET size = $((apache_bytesperreq))
226
END
227
-BEGIN apache.workers $1
227
+BEGIN apache_local.workers $1
228
SET idle = $((apache_idleworkers))
229
SET busy = $((apache_busyworkers))
230
END
@@ -233,10 +233,10 @@ VALUESEOF
233
if [ ${apache_has_conns} -eq 1 ]
234
then
235
cat <<VALUESEOF2
236
-BEGIN apache.connections $1
236
+BEGIN apache_local.connections $1
237
SET connections = $((apache_connstotal))
238
END
239
-BEGIN apache.conns_async $1
239
+BEGIN apache_local.conns_async $1
240
SET keepalive = $((apache_connsasynckeepalive))
241
SET closing = $((apache_connsasyncclosing))
242
SET writing = $((apache_connsasyncwriting))