iamgold / yii2fluentd
This is a lightweight client library of fluentd
Installs: 152
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Open Issues: 0
pkg:composer/iamgold/yii2fluentd
Requires
- php: >=5.4.0
- rmccue/requests: ^1.7
- yiisoft/yii2: ~2.0.0
This package is auto-updated.
Last update: 2025-09-13 06:32:44 UTC
README
This is a lightweight client library of fluentd. It be a component in Yii2.
Config setting
Injected the code belows into config file of web.php or console.php
'fluentd' => [ 'class' => 'iamgold\yii2fluentd\Fluentd', 'endpoint' => [endpoint of fluentd http server] ]
Usage
Yii::$app->fluentd->send($tag, $params);
Methods
/**
* send message
*
* @param string $tag
* @param array $params
* @return ResponseInterface
*/
public function send(string $tag, array $params)
ResponseInterface Methods
/** * is success * * @return bool */ public function isSuccess(); /** * get status code * * @return int */ public function getStatusCode(); /** * get error message * * @return string */ public function getErrorMessage();