Giter VIP home page Giter VIP logo

lager_amqp_backend's Introduction

Lager AMQP Backend

This is a backend for the Lager Erlang logging framework.

https://github.com/basho/lager

It will send all of your logging messages to the exchange you specify and use the logging level as the routing key. It uses a smart connection pool to your broker. If the connection drops or becomes unusable, the backend will reconnect.

Usage

Include this backend into your project using rebar:

{lager_amqp_backend, ".*", {git, "https://github.com/jbrisbin/lager_amqp_backend.git", "master"}}

Configuration

You can pass the backend the following configuration (shown are the defaults):

{lager, [
  {handlers, [
    {lager_amqp_backend, [
      {name,        "lager_amqp_backend"},
      {level,       debug},
      {exchange,    <<"lager_amqp_backend">>},
      {amqp_user,   <<"guest">>},
      {amqp_pass,   <<"guest">>},
      {amqp_vhost,  <<"/">>},
      {amqp_host,   "localhost"},
      {amqp_port,   5672},
      {formatter, lager_default_formatter},  % optional, this is the default
      {format_config, [date," ",time," ", message]}, % optional, this is the default
      {content_type, <<"text/plain">>} % optional, this is the default
    ]}
  ]}
]}

License

Apache 2.0, just like everything else I do. :)

lager_amqp_backend's People

Contributors

jbrisbin avatar nialscorva avatar

Watchers

 avatar James Cloos avatar Trevor Alpeter avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.