agent_check v0.2.8 AgentCheck

Implementation of the Agent Check protocol for your Elixir/Phoenix app. Also see - https://cbonte.github.io/haproxy-dconv/1.8/configuration.html#5.2-agent-check

It allows for easy rolling restarts and dynamic backpressure to your loadbalancer.

Link to this section Summary

Functions

Starts accepting connections on the given port

Reformat the stats struct into a haproxy state format

Try to handle the received commandline

Wait for incomming socket connection (blocking) and spawn of a Task when one comes in

Read a single line from the connected socket

Connect the socket and wait for a command

Link to this section Functions

Starts accepting connections on the given port.

Link to this function format_haproxy_state(stats_struct)

Reformat the stats struct into a haproxy state format.

Link to this function handle_command(arg1)

Try to handle the received commandline.

Link to this function loop_acceptor(socket)

Wait for incomming socket connection (blocking) and spawn of a Task when one comes in.

Link to this function read_line(socket)

Read a single line from the connected socket.

Connect the socket and wait for a command.