Skip to content
This repository has been archived by the owner on Nov 9, 2022. It is now read-only.

fossamagna/logback-idobata

Repository files navigation

Logback appender for Idobata Build Status Maven Central Coverage Status

logback-idobata is simple logback appender for Idobata.

Including it in your project

Maven

Add logback-idobata to dependencies in your pom.xml file.

<dependencies>
  <dependency>
    <groupId>com.github.fossamagna</groupId>
    <artifactId>logback-idobata</artifactId>
    <version>0.1.0</version>
  </dependency>
</dependencies>

Gradle

Add logback-idobata to dependencies in your build.gradle file.

dependencies {
  compile 'com.github.fossamagna:logback-idobata:0.1.0'
}

Usage

Add IdobataAppender configuration to logback.groovy file.

import static ch.qos.logback.classic.Level.*

import com.github.fossamagna.logback.idobata.IdobataAppender

def webHookUrl = System.getenv("IDOBATA_NOTIFICATION_URL")
if (webHookUrl) {
  appender("Idobata", IdobataAppender) {
    endpointUrl = new URL(webHookUrl)
  }
  root(ERROR, ["Idobata"])
}

License

logback-idobata is Open Source software released under the Apache 2.0 license.