프로퍼티 | 타입 | 설명 | |
---|---|---|---|
$cacheContext | If true, context message will cached once it's been created. Makes sense to use with [[includeContext]]. | ||
$db | the elasticsearch connection object or the application component ID of the elasticsearch connection. | ||
$includeContext | If true, context will be included in every message. This is convenient if you log application errors and analyze them with tools like Kibana. | ||
$index | Elasticsearch index name. | ||
$logContext | If true, context will be logged as a separate message after all other messages. | ||
$options | array | URL options. | |
$type | Elasticsearch type name. |
프로퍼티 | 타입 | 설명 | |
---|---|---|---|
$_contextMessage | Context message cache (can be used multiple times if context is appended to every message) |
메소드 | 설명 | |
---|---|---|
collect ( array $messages, boolean $final ) | Processes the given log messages. | |
export ( ) | ||
init ( ) | This method will initialize the [[elasticsearch]] property to make sure it refers to a valid Elasticsearch connection. | |
prepareMessage ( array $message ) : string | Prepares a log message. |
메소드 | 설명 | |
---|---|---|
getContextMessage ( ) : array | If [[includeContext]] property is false, returns context message normally. |
protected getContextMessage ( ) : array | ||
리턴 | array | the context information |
public init ( ) |
public prepareMessage ( array $message ) : string | ||
$message | array | The log message to be formatted. |
리턴 | string |
protected $_contextMessage |
public $cacheContext |
public $db |
public $includeContext |
public $logContext |