template: last_collected_secs
on: web_log.response_codes
+families: *
calc: $now - $last_collected_t
units: seconds ago
every: 10s
template: 1m_2xx
on: web_log.response_codes
+families: *
lookup: sum -1m unaligned of 2xx
calc: ($this == 0)?(1):($this)
units: requests
template: 1m_redirects
on: web_log.response_codes
+families: *
lookup: sum -1m unaligned of 3xx
calc: $this * 100 / ( $1m_2xx + $this )
units: %
template: 1m_bad_requests
on: web_log.response_codes
+families: *
lookup: sum -1m unaligned of 4xx
calc: $this * 100 / ( $1m_2xx + $this )
units: %
template: 1m_internal_errors
on: web_log.response_codes
+families: *
lookup: sum -1m unaligned of 5xx
calc: $this * 100 / ( $1m_2xx + $this )
units: %
template: 10m_response_time
on: web_log.response_time
+families: *
lookup: average -10m unaligned of avg
units: ms
every: 30s
template: web_slow
on: web_log.response_time
- lookup: sum -1m unaligned of avg
+families: *
+ lookup: average -1m unaligned of avg
units: ms
every: 10s
green: 500
template: 5m_2xx_last
on: web_log.response_codes
+families: *
lookup: average -5m at -5m unaligned of 2xx
units: requests
every: 30s
template: 5m_2xx_now
on: web_log.response_codes
+families: *
lookup: average -5m unaligned of 2xx
units: requests
every: 30s
template: 5m_requests_ratio
on: web_log.response_codes
+families: *
calc: ($5m_2xx_last > 0)?($5m_2xx_now * 100 / $5m_2xx_last):(100)
units: %
every: 30s
job_name = find_job_name(self.override_name, self.name)
self.detailed_chart = 'CHART %s.detailed_response_codes ""' \
' "Response Codes" requests/s responses' \
- ' web_log.detailed_resp stacked 1 %s\n' % (job_name, self.update_every)
+ ' web_log.detailed_response_codes stacked 1 %s\n' % (job_name, self.update_every)
self.http_method_chart = 'CHART %s.http_method' \
- ' "" "HTTP Methods" requests/s requests' \
+ ' "" "Requests Per HTTP Method" requests/s requests' \
' web_log.http_method stacked 2 %s\n' % (job_name, self.update_every)
if regex_name == 'access_apache_ext':