Laravel5.4に、リアルタイムエラートラッキングの「Sentry(sentry-laravel)」を設定してみました。わざとエラーを起こしてみても、何も起こらないので、設定が間違っているのかも。信じて、しばらく様子を見ることにします(?)。
/config/app.php
参考サイト
The Exception Handler(Laravel)
sentry-laravel(GitHub)
イベントログ収集ツールの Sentry が凄そう(Memoさん)
/config/app.php
/app/Exceptions/Handler.php
'providers' => [
Sentry\SentryLaravel\SentryLaravelServiceProvider::class,
],
'aliases' => [
'Sentry' => Sentry\SentryLaravel\SentryFacade::class,
],
/config/sentry.php(設定ファイルの作成)
public function report(Exception $exception)
{
if ($this->shouldReport($exception)) {
app('sentry')->captureException($exception);
}
parent::report($exception);
}
/config/sentry.php
$ php artisan vendor:publish --provider="Sentry\SentryLaravel\SentryLaravelServiceProvider"
return array(
'dsn' => env('SENTRY_DSN'),
'breadcrumbs.sql_bindings' => true,
);
参考サイト
The Exception Handler(Laravel)
sentry-laravel(GitHub)
イベントログ収集ツールの Sentry が凄そう(Memoさん)