Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/tkyshm/efluentc
efluentc is the Client OTP application for Fluentd
https://github.com/tkyshm/efluentc
erlang fluentd fluentd-logger
Last synced: about 1 month ago
JSON representation
efluentc is the Client OTP application for Fluentd
- Host: GitHub
- URL: https://github.com/tkyshm/efluentc
- Owner: tkyshm
- License: apache-2.0
- Created: 2017-11-04T06:12:51.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2018-07-08T08:42:00.000Z (over 6 years ago)
- Last Synced: 2023-09-16T23:10:43.653Z (about 1 year ago)
- Topics: erlang, fluentd, fluentd-logger
- Language: Erlang
- Size: 18.6 KB
- Stars: 6
- Watchers: 2
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
[![hex.pm version](https://img.shields.io/hexpm/v/ltsv.svg)](https://hex.pm/packages/efluentc)
[![Build Status](https://travis-ci.org/tkyshm/efluentc.svg?branch=master)](https://travis-ci.org/tkyshm/efluentc)[efluentc](https://hex.pm/packages/efluentc)
=====efluentc is the Client OTP application for Fluentd.
efluentc design is to make it more faster to send some messages which are buffered at a time, and reduce count of transmission.
If you can see performance degration that is casued by burst traffic,
I'd recommend increasing concurrency of fluent clients.efluentc has interval to flush messages and buffer size, and you can adjust theses.
It is recommeneded that theses parameters are set appropriate value according to your application flow rate.Available parameters below:
name | default | description
------------- | --------- | ----------------------------------------------------------
worker_size | 2 | send of concurrency
flush_timeout | 50 | interval of flushing buffered data (msec)
buffer_size | 10KB | if over buffer size, flush all buffered data
host | localhost | fluentd host name
port | 24224 | fluentd port numbersample(app.config):
```erlang
[
{efluentc, [{worker_size, 10}, % 10 workers
{fluesh_timeout, 500}, % 500msec
{buffer_size, 1048576}, % 1MiB
{host, localhost},
{port, 24224}]}
]```
Usage
====add rebar.config:
```
{efluentc, "0.1.0"}
```efluentc api:
```
> efluentc:post(<<"test.tag">>, <<"message">>).
ok> efluentc:post('test.tag', <<"message">>).
ok> efluentc:post('test.tag', "message").
ok> efluentc:post('test.tag', #{<<"key">> => <<"value">>}).
ok
```