Example #1
0
 /**
  * @inheritdoc
  */
 public function gauge($key, $value)
 {
     $this->client->gauge($key, $value);
 }
Example #2
0
 /**
  * Creates a gauge in statsd.
  *
  * @static
  *
  * @param string $name the name of the key
  * @param string|int $amount the amount the gauge is increased
  */
 public function gauge($name, $amount)
 {
     $this->statsd->gauge($name, $amount);
 }
Example #3
0
 /**
  * Gauge metric
  *
  * @param string $key   Something like: 'foo.bar'
  * @param mixed  $value Absolute values, e.g.: 3, or delta values e.g.: '-11', '+14'
  */
 private function gauge($key, $value)
 {
     $this->client->gauge($key, $value);
 }
Example #4
0
 public function testGaugeCanReceiveFormattedNumber()
 {
     $this->client->gauge('foobar', '+11');
     $message = $this->connection->getLastMessage();
     $this->assertEquals('test.foobar:+11|g', $message);
 }