Properties

$processors

$processors : callable[]

Type

callable[]

$formatter

$formatter : ?\Monolog\Formatter\FormatterInterface

Type

FormatterInterface

$level

$level : int

Type

int

$bubble

$bubble : bool

Type

bool

$exchange

$exchange : \AMQPExchange|\PhpAmqpLib\Channel\AMQPChannel

Type

AMQPChannel

$exchangeName

$exchangeName : string

Type

string

$extraAttributes

$extraAttributes : array<string,mixed>

Type

array

Methods

handle()

handle(array  $record) : bool

{@inheritDoc}

Parameters

array $record

Returns

bool —

reset()

reset() : void

pushProcessor()

pushProcessor(callable  $callback) : \Monolog\Handler\HandlerInterface

{@inheritDoc}

Parameters

callable $callback

Returns

\Monolog\Handler\HandlerInterface —

popProcessor()

popProcessor() : callable

{@inheritDoc}

Returns

callable —

setFormatter()

setFormatter(\Monolog\Formatter\FormatterInterface  $formatter) : \Monolog\Handler\HandlerInterface

{@inheritDoc}

Parameters

\Monolog\Formatter\FormatterInterface $formatter

Returns

\Monolog\Handler\HandlerInterface —

getFormatter()

getFormatter() : \Monolog\Formatter\FormatterInterface

{@inheritDoc}

Returns

\Monolog\Formatter\FormatterInterface —

__construct()

__construct(\AMQPExchange|\PhpAmqpLib\Channel\AMQPChannel  $exchange, string|null  $exchangeName = null, mixed  $level = Logger::DEBUG, bool  $bubble = true) : mixed

Parameters

\AMQPExchange|\PhpAmqpLib\Channel\AMQPChannel $exchange

AMQPExchange (php AMQP ext) or PHP AMQP lib channel, ready for use

string|null $exchangeName

Optional exchange name, for AMQPChannel (PhpAmqpLib) only

mixed $level
bool $bubble

Returns

mixed —

isHandling()

isHandling(array  $record) : bool

{@inheritDoc}

Parameters

array $record

Returns

bool —

setLevel()

setLevel(mixed  $level) : self

Sets minimum logging level at which this handler will be triggered.

Parameters

mixed $level

Returns

self —

getLevel()

getLevel() : int

Gets minimum logging level at which this handler will be triggered.

Returns

int —

setBubble()

setBubble(bool  $bubble) : self

Sets the bubbling behavior.

Parameters

bool $bubble

true means that this handler allows bubbling. false means that bubbling is not permitted.

Returns

self —

getBubble()

getBubble() : bool

Gets the bubbling behavior.

Returns

bool —

true means that this handler allows bubbling. false means that bubbling is not permitted.

handleBatch()

handleBatch(array  $records) : void

{@inheritDoc}

Parameters

array $records

close()

close() : void

Closes the handler.

__destruct()

__destruct() : mixed

Returns

mixed —

__sleep()

__sleep() : mixed

Returns

mixed —

getExtraAttributes()

getExtraAttributes() : array<string,mixed>

Returns

array

setExtraAttributes()

setExtraAttributes(array<string,mixed>  $extraAttributes) : \Monolog\Handler\AmqpHandler

Configure extra attributes to pass to the AMQPExchange (if you are using the amqp extension)

Parameters

array $extraAttributes

One of content_type, content_encoding, message_id, user_id, app_id, delivery_mode, priority, timestamp, expiration, type or reply_to, headers.

Returns

\Monolog\Handler\AmqpHandler —

write()

write(array  $record) : void

Writes the record down to the log of the implementing handler

Parameters

array $record

processRecord()

processRecord(array  $record) : array

Processes a record.

Parameters

array $record

Returns

array —

resetProcessors()

resetProcessors() : void

getDefaultFormatter()

getDefaultFormatter() : \Monolog\Formatter\FormatterInterface

{@inheritDoc}

Returns

\Monolog\Formatter\FormatterInterface —

getRoutingKey()

getRoutingKey(array  $record) : string

Gets the routing key for the AMQP exchange

Parameters

array $record

Returns

string —

createAmqpMessage()

createAmqpMessage(string  $data) : \PhpAmqpLib\Message\AMQPMessage

Parameters

string $data

Returns

\PhpAmqpLib\Message\AMQPMessage —