Monolog\Handler\BufferHandler
Buffers all records until closing the handler and then pass them as batch.
This is useful for a MailHandler to send only one mail per request instead of
sending one per log message.
- Author: Christophe Coevoet <stof@notk.org>
Synopsis
class BufferHandler
extends AbstractHandler
{
- // members
- protected $handler;
- protected integer $bufferSize;
- protected $bufferLimit;
- protected $flushOnOverflow;
- protected array $buffer;
- // Inherited members from AbstractHandler
- protected $level;
- protected $bubble;
- protected FormatterInterface $formatter;
- protected array $processors;
- // methods
- public void __construct()
- public void handle()
- public void flush()
- public void close()
- // Inherited methods from AbstractHandler
- public void __construct()
- public void isHandling()
- public void handleBatch()
- public void close()
- public void pushProcessor()
- public void popProcessor()
- public void setFormatter()
- public void getFormatter()
- public void setLevel()
- public integer getLevel()
- public void setBubble()
- public Boolean getBubble()
- public void __destruct()
- protected FormatterInterface getDefaultFormatter()
Hierarchy
Extends
Members
protected
- $bubble
- $buffer
- $bufferLimit
- $bufferSize
- $flushOnOverflow
- $formatter — Monolog\Formatter\FormatterInterface
- $handler
- $level
- $processors
Methods
public
- __construct()
- close() — {@inheritdoc}
- flush()
- handle() — {@inheritdoc}
Inherited from Monolog\Handler\AbstractHandler
protected
- getDefaultFormatter() — Gets the default formatter.
public
- close() — Closes the handler.
- getBubble() — Gets the bubbling behavior.
- getFormatter() — {@inheritdoc}
- getLevel() — Gets minimum logging level at which this handler will be triggered.
- handleBatch() — {@inheritdoc}
- isHandling() — {@inheritdoc}
- popProcessor() — {@inheritdoc}
- pushProcessor() — {@inheritdoc}
- setBubble() — Sets the bubbling behavior.
- setFormatter() — {@inheritdoc}
- setLevel() — Sets minimum logging level at which this handler will be triggered.