Module logstasher

Behaviours: gen_server.

Function Index

handle_call/3
handle_cast/2
init/1
send/1Send an encoded JSON message to logstash.
send_message/2Send a custom message with fields to logstash.
start_link/0
terminate/2

Function Details

handle_call/3

handle_call(X1::{send, binary()}, X2::any(), State::maps:map()) -> {reply, ok | {error, atom() | {timeout, binary()}}, maps:map()}

handle_cast/2

handle_cast(X1::term(), State::maps:map()) -> {noreply, maps:map()}

init/1

init(X1::term()) -> {ok, maps:map()} | {stop, maps:map()}

send/1

send(Data::binary()) -> ok | {error, atom()}

Send an encoded JSON message to logstash.

send_message/2

send_message(Message::binary(), Fields::map()) -> ok | {error, atom()}

Send a custom message with fields to logstash. The fields must be valid input for the json encoder.

start_link/0

start_link() -> {ok, pid()} | {error, term()}

terminate/2

terminate(X1::term(), X2::maps:map()) -> ok


Generated by EDoc