<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
goszowski / laravel-database-log-channel example snippets
return [
'channels' => [
'stack' => [
'driver' => 'stack',
'channels' => ['daily', 'database'], // Add "database" channel
'ignore_exceptions' => false,
],
// ...
'database' => [
'driver' => 'monolog',
'handler' => Goszowski\DatabaseLogChannel\Logging\DatabaseLogHandler::class,
'via' => Goszowski\DatabaseLogChannel\Logging\DatabaseLogger::class,
'alternative-log-channel' => 'daily', // Use an alternate channel when it is not possible to write to the database
'connection' => null, // Use default connection
'table' => 'logs',
'async' => true, // If true, will be sent to the queue
'queue' => 'default', // Define a queue for asynchronous logging
'level' => 'error',
],
],
];