Elixir Network Logger

Network Logger is a logger backend that outputs elixir logs to tcp/udp

Most of it was shamelessly copied from json_logger.

Configuration

Network Logger currently provides very few options:

Example configuration:

config :logger, :network_logger,
level: :info,
format: "$time $metadata[$level] $message\n",
metadata: [:pid, :module],
output: {:udp, "localhost", 514}

TCP support is still experimental, please submit issues that you encounter.

Adding the logger backend

You need to add this backend to your Logger:

# in your config...
config :logger,
backends: [
Logger.Backends.Network,
]
# or, in your code...
Logger.add_backend Logger.Backends.Network