Guest Post: Lager-Airbrake Notifier

Apr 24, 2015 7:25:47 PM | Guest Post: Lager-Airbrake Notifier

Check the latest Airbrake notifiers; Lager-Airbrake

Airbrake Notifiers send exceptions from your applications to Airbrake. The Notifiers are created by the developer community. Having a wide variety of notifiers for different programming languages and frameworks enables users to keep track of exceptions from all kinds of applications.

This time we are featuringRoberto Ostinelli, who has written Lager-Airbrake notifier, a backend for Lager a logging framework for Erlang.


I have a great pleasure to announce that today I've released Lager-Airbrake notifier.

If you are already using the popular logging framework [Lager]( by Basho in your application, you might consider having an easy drop in component that will report the errors with the desired level of severity to AirBrake.

Lager-Airbrake works as a Lager backend, it is therefore fully integrated with it, and easy to setup.

In your project's rebar.config file, add lager_airbrake as a dependency:

{<span class="pl-c1">lager_airbrake</span>, <span class="pl-s"><span class="pl-pds">"</span>.*<span class="pl-pds">"</span></span>, {<span class="pl-c1">git</span>, <span class="pl-s"><span class="pl-pds">"</span>git://<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>master<span class="pl-pds">"</span></span>}}

Then include lager_airbrake_backend in your lager configuration:

%% Lager config
{lager, [
{handlers, [
%% Add Airbrake monitoring
{lager_airbrake_backend, [
{environment, "development"},
{api_key, "AIRBRAKE_API_KEY"},
{project_id, "AIRBRAKE_PROJECT_ID"},
{level, warning},
{ignore, [
{file, "my_app_ignored_file.erl"},
{message, "Ignore message"}



You’re done.

Lager-Airbrake will try to use some heuristics to optimize the notification sent to Airbrake, so that errors can be easily differentiated. As you may know, in Erlang it is sometimes difficult to separate the errors based on their Type so some attempts have been done to address this reporting issue.

You can check Lager-Aibrake here:

Written By: Morgan McDaris