Download the PHP package splash/sonata-admin-monolog-bundle without Composer
On this page you can find all versions of the php package splash/sonata-admin-monolog-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package sonata-admin-monolog-bundle
SonataAdaminMonologBundle
This Symfony bundle provides a Doctrine DBAL handler for Monolog Web UI to display log entries is integrated to Sonata Admin UI.
You can list, filter and paginate logs as you can see on the screenshot bellow:
As this bundle query your database on each raised log, it's relevant for small and medium projects, but if you have billion of logs consider using a specific log server.
This Bundle is inspired from LexikMonologBrowserBundle
Requirements:
- Symfony 3.4+ | 4.0+ | 4.2+
- Sonata-Project/AdminBundle
Installation
Installation with composer:
Next, be sure to enable these bundles in your Kernel.php
file:
Basic Configuration
Then, you can configure Monolog to use the Doctrine DBAL handler:
Advanced Configuration
If you don't want to use default Doctrine Entity Manager, you need to configure the Doctrine DBAL connection to use in the handler.
You have 2 ways to do that:
By using an existing Doctrine connection:
Note: we set the logging
and profiling
option to false to avoid DI circular reference.
By creating a custom Doctrine connection for the bundle:
Please refer to the Doctrine DBAL connection configuration for more details.
Now your database is configured, you can generate the schema for your log entry table by running the following command:
Translations
If you wish to use default translations provided in this bundle, make sure you have enabled the translator in your config:
Contributing
Any Pull requests are welcome!
This module is part of SplashSync project.
All versions of sonata-admin-monolog-bundle with dependencies
symfony/framework-bundle Version ~2.1
knplabs/knp-paginator-bundle Version >=2.3