Package Data | |
---|---|
Maintainer Username: | utkarshx |
Package Create Date: | 2015-08-02 |
Package Last Update: | 2015-12-18 |
Language: | PHP |
License: | MIT |
Last Refreshed: | 2024-11-22 03:06:20 |
Package Statistics | |
---|---|
Total Downloads: | 19 |
Monthly Downloads: | 2 |
Daily Downloads: | 0 |
Total Stars: | 1 |
Total Watchers: | 3 |
Total Forks: | 0 |
Total Open Issues: | 1 |
Loggly logging and error integration for Laravel 5. Based on laravel-rollbar by jenssegers.
Install using composer:
composer require utkarshx/loggly-laravel
Add the service provider to the 'providers'
array in config/app.php
:
'Utkarshx\Loggly\LogglyServiceProvider',
This package supports configuration through the services configuration file located in app/config/services.php
. All configuration variables will be directly passed to Rollbar:
'loggly' => [
'key' => 'your-loggly-token',
'level' => 'debug',
'tags' => ['your-tokens]
],
The level variable defines the minimum log level at which log messages are sent to Loggly.
To automatically monitor exceptions, simply use the Log
facade in your error handler in app/Exceptions/Handler.php
:
public function report(Exception $e)
{
\Log::error($e);
return parent::report($e);
}
For Laravel 4 installations, this is located in app/start/global.php
:
App::error(function(Exception $exception, $code)
{
Log::error($exception);
});
Your other log messages will also be sent to Loggly:
\Log::debug('Here is some debug information');