Sentry component and log route for Yii framework.
- Yii Framework > 1.1.15 (Have not test any other frameworks)
- Sentry Account or Your own Sentry server
composer require intersvyaz/yii-sentry
main.php:
...
'preload' => [
...
'sentry',
],
...
'components' => [
'sentry' => [
'class' => Skillshare\YiiSentry\SentryComponent::class,
'dsn' => 'https://X1:X2@host.com/2',
'useRavenJs' => true,
'ravenJsPlugins' => ['jquery'],
'enabled' => !YII_DEBUG,
],
...
'log' => [
'class' => 'CLogRouter',
'routes' => [
...
[
'class' => Skillshare\YiiSentry\SentryLogRoute::class,
'levels' => 'error, warning',
'except' => 'exception.CHttpException.404, exception.CHttpException.400, exception.CHttpException.403',
],
],
],
],
...