You are here

public function StatsD::increment in StatsD 7.2

Same name and namespace in other branches
  1. 6 includes/statsd.inc \StatsD::increment()
  2. 7 includes/statsd.inc \StatsD::increment()

Increments one or more stats counters

Parameters

$stats: A string or an array of string representing the metric(s) to increment.

$sample_rate: A float between 0 and 1 representing the sampling rate.

Return value

boolean

File

includes/statsd.inc, line 94

Class

StatsD
Sends statistics to the stats daemon over UDP.

Code

public function increment($stats, $sample_rate = NULL) {
  $this
    ->updateStats($stats, 1, $sample_rate);
}