2017 © Pedro Peláez
 

library laravel-statsd

Send to Statsd server from Laravel

image

rcrowe/laravel-statsd

Send to Statsd server from Laravel

  • Wednesday, November 19, 2014
  • by rcrowe
  • Repository
  • 2 Watchers
  • 20 Stars
  • 33,215 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 2 Forks
  • 2 Open issues
  • 6 Versions
  • 3 % Grown

The README.md

Allows you to seamlessly send data to a Statsd server from within your Laravel application., (*1)

Build Status, (*2)

Installation

Add rcrowe\laravel-statsd as a requirement to composer.json:, (*3)

{
    "require": {
        "rcrowe/laravel-statsd": "0.5.*"
    }
}

Update your packages with composer update or install with composer install., (*4)

Once Composer has installed or updated your packages you need to register Statsd with Laravel itself. Open up app/config/app.php and find the providers key towards the bottom and add:, (*5)

'rcrowe\Statsd\StatsdServiceProvider'

You will also need to register the facade so that you can access it within your application. To do this add the following to your aliases in app/config/app.php:, (*6)

'Statsd' => 'rcrowe\Statsd\Facades\Statsd'

Configuration

Statsd configuration file can be extended by creating app/config/packages/rcrowe/laravel-statsd/config.php. You can find the default configuration file at vendor/rcrowe/laravel-statsd/src/config/config.php., (*7)

You can quickly publish a configuration file by running the following Artisan command., (*8)

$ php artisan config:publish rcrowe/laravel-statsd

Usage

Laravel-Statsd exposes the following functions to send data to Statsd:, (*9)

Statsd::timing($key, $time);
Statsd::gauge($key, $value);
Statsd::set($key, $value);
Statsd::increment($key);
Statsd::decrement($key);
Statsd::updateCount($key, $delta);

The data is automatically sent to Statsd at the end of Laravels life-cycle, but you can force data to be sent with:, (*10)

Statsd::send()

Note: Data will only be sent to Statsd if your environment matches the environments defined in the config file., (*11)

The Versions

19/11 2014

dev-master

9999999-dev

Send to Statsd server from Laravel

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel statsd

13/11 2013

v0.5.2

0.5.2.0

Send to Statsd server from Laravel

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel statsd

17/07 2013

v0.5.1

0.5.1.0

Send to Statsd server from Laravel

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel statsd

20/06 2013

v0.5.0

0.5.0.0

Send to Statsd server from Laravel

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel statsd

19/03 2013

v0.0.2

0.0.2.0

Send to Statsd server from Laravel

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel statsd

24/01 2013

v0.0.1

0.0.1.0

Send to Statsd server from Laravel

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel statsd