symfony / monolog-bundle

Symfony Monolog Bundle
symfony.com
MIT License
2.9k stars 232 forks source link

Add enabled parameter in configuration #482

Open Arkalo2 opened 6 months ago

Arkalo2 commented 6 months ago

This feature aims to separate the enabling of handlers based on the environment.

Use Case :

You have 3 servers on your project : dev, staging, and prod

Currently, you can't disable handlers for a specific environment. For an instance, you can't disable logging only in your staging environment.

With the enabled parameter, you are able to disable logging only in the staging environment.