zae/monolog-publish
最新稳定版本:0.0.2
Composer 安装命令:
composer require zae/monolog-publish
包简介
A publisher handler for monolog
README 文档
README
A simple Monolog handler that can be used to 'publish' the errors to a subscriber.
Publishers
Available publishers are:
- RedisPublisher
Install
Via Composer
$ composer require zae/monolog-publish
Usage
use Monolog\Logger; use Monolog\Handler\StreamHandler; use Zae\Monolog\Publish\Handler\PublishHandler; use Zae\Monolog\Publish\Publisher\RedisPublisher; // create a log channel $log = new Logger('name'); $log->pushHandler(new PublishHandler(new RedisPublisher('log', Logger::WARNING))); // add records to the log $log->addWarning('Foo'); $log->addError('Bar');
Testing
$ phpunit
Contributing
Contributions are welcome via pull requests on github.
Mostly new publishers are needed.
Credits
License
The MIT License (MIT). Please see License File for more information.
统计信息
- 总下载量: 37
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2015-05-14