Download the PHP package net_bazzline/component_proxy_logger without Composer
On this page you can find all versions of the php package net_bazzline/component_proxy_logger. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download net_bazzline/component_proxy_logger
More information about net_bazzline/component_proxy_logger
Files in net_bazzline/component_proxy_logger
Package component_proxy_logger
Short Description php component proxy logger
License LGPLv3
Homepage https://github.com/stevleibelt/php_component_proxy_logger
Informations about the package component_proxy_logger
Logger Proxy Component
This component ships a collection of enhanced proxy logger handling tools.
Current stable version is 1.2.0.
The build status of the current master branch is tracked by Travis CI:
The main idea is to use a proxy with a buffer for one or a collection of PSR-3 logger to add freedom and silence back to your log files.
Features
- full PSR-3 Logger Interface compatibility
- allows you define when log messages are pushed to your loggers
- only logs if configured log level is reached
- regains freedom and silence in your log files
- use the proxy logger component to combine management of multiple loggers
Licence
This software is licenced under GNU LESSER GENERAL PUBLIC LICENSE. The full licence text is shipped within this component package.
Links
Documentation
Common Terms
PSR-3 Logger
Following an uncompleted list of available PSR3-Logger components.
Reason To Use This Component
Comparison Between Normal Logger And Trigger Flush Buffer Logger
Taken from the example upward flush buffer trigger versus normal logger.
This example shows a process that is working on a collection of items.
The first run is simple logging all information's. This fills up your logs pretty fast.
Since the second run has a logger, that only displays log levels of warning and above, you do not fill up your logs with unnecessary log requests.
But too bad, when something happens you are loosing information's.
The third run is logging everything without any restriction only, if and for the area where something happens.
You are not loosing information and don't fill up your log with not needed log requests.
As you can see, only the third run logs all the information you need to debug your code and fix possible bugs.
Using Two Trigger Flush Buffer Logger As A Collection In One Buffer Logger
This example shows how you can use two trigger flush buffer logger as a collection.
The example is using two manipulate buffer loggers injected in an buffer logger. The first manipulate buffer logger is flushing the buffer via a trigger on the log level alert. The second one triggers the buffer flush on log level critical.
Furthermore, three runs are simulated in the example. The first run only adds log levels below critical or alert, meaning no buffer flush is triggered.
The second run adds log levels up to critical, meaning the buffer flush for the first logger is triggered.
Finally, the third run is adding log levels up to alert, meaning a buffer flush is triggered for both loggers.
What is this example all about? As the names of the logger requests are anticipating, you can implement this by sending an email if log level critical is reached and sending a wake up call if log level alert is reached.
All versions of component_proxy_logger with dependencies
psr/log Version 1.0.0
net_bazzline/component_requirement Version 1.0.4
symfony/event-dispatcher Version v2.3.5