Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feature #27801 [MonologBridge] Add ProcessorInterface, enabling autoc…
…onfiguration of monolog processors (nicolas-grekas) This PR was merged into the 4.2-dev branch. Discussion ---------- [MonologBridge] Add ProcessorInterface, enabling autoconfiguration of monolog processors | Q | A | ------------- | --- | Branch? | master | Bug fix? | no | New feature? | yes | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | - | License | MIT | Doc PR | symfony/symfony-docs#9996 Using this, enabling e.g. TokenProcessor or WebProcessor just needs one line in `services.yaml`: ```yaml services: Symfony\Bridge\Monolog\Processor\TokenProcessor: ~ Symfony\Bridge\Monolog\Processor\WebProcessor: ~ ``` Commits ------- 28a4912 [MonologBridge] Add ProcessorInterface, enabling autoconfiguration of monolog processors
- Loading branch information
Showing
5 changed files
with
35 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
25 changes: 25 additions & 0 deletions
25
src/Symfony/Bridge/Monolog/Processor/ProcessorInterface.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of the Symfony package. | ||
* | ||
* (c) Fabien Potencier <fabien@symfony.com> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
namespace Symfony\Bridge\Monolog\Processor; | ||
|
||
/** | ||
* An optional interface to allow autoconfiguration of Monolog processors. | ||
* | ||
* @author Nicolas Grekas <p@tchwork.com> | ||
*/ | ||
interface ProcessorInterface | ||
{ | ||
/** | ||
* @return array The processed records | ||
*/ | ||
public function __invoke(array $records); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters