Home Code Other Software

Table of Contents

This page has also been translated into Serbo-Croatian, by Anja Skrba.

Introduction

AVSL is a very simple logger, written in Scala. AVSL implements the Simple Logging Facade for Java (SLF4J) API, allowing applications to be written to the SLF4J API. (This, of course, includes Java applications.) Because it implements SLF4J, AVSL can easily be swapped for another SLF4J-compatible logging framework (or the other way around), without any changes to the calling application. Also, because it supports SLF4J, AVSL can be used in conjunction with Scala SLF4J wrappers, such as Grizzled-SLF4J.

“AVSL” stands for “A Very Simple Logger”, and AVSL strives for simplicity in several ways.

In short, AVSL is a perfectly serviceable, simple logging framework that can easily be swapped out for something with more features.

Installation

AVSL is published to my Bintray Maven repository, which is automatically linked to Bintray’s JCenter repository. (From JCenter, it’s eventually pushed to the Maven Central Repository.

sync’d with the Maven Central Repository.

Installing for Maven

If you’re using Maven, just give it the artifact, and Maven will do the rest:

For example:

<dependency>
  <groupId>org.clapper</groupId>
  <artifactId>avsl_2.11</artifactId>
  <version>1.0.2</version>
</dependency>

For more information on using Maven and Scala, see Josh Suereth’s Scala Maven Guide.

Using with SBT

0.7.x

If you’re using SBT 0.7.x to compile your code, you can place the following line in your project file (i.e., the Scala file in your project/build/ directory):

val javaNetRepo = "Java.net Maven 2 Repo" at
    "http://download.java.net/maven/2"
val avsl = "org.clapper" %% "avsl" % "0.4"

0.11.x/0.12.x/0.13.x

If you’re using SBT 0.11.x or better to compile your code, you can use the following line in your build.sbt file (for Quick Configuration). If you’re using an SBT 0.11.x Full Configuration, you’re obviously smart enough to figure out what to do, on your own.

If you’re using Scala 2.9.2 or earlier:

libraryDependencies += "org.clapper" %% "avsl" % "0.4"

If you’re using Scala 2.10 or Scala 2.11:

libraryDependencies += "org.clapper" %% "avsl" % "1.0.2"

AVSL is also registered with [Doug Tangren][]’s excellent ls.implicit.ly catalog. If you use the ls SBT plugin, you can install AVSL with

sbt> ls-install avsl

Source Code Repository

The source code for AVSL is maintained on GitHub. To clone the repository, run this command:

$ git clone git://github.com/bmc/avsl.git

Note: That gets you the trunk, which supports Scala 2.10 and later. If you want the code for Scala 2.9, switch to the pre-scala-2.10-fixes branch:

$ cd avsl
$ git co pre-scala-2.10-fixes

Building from Source

Building the library requires SBT 0.13.5 for Scala 2.10, and 0.11.x for Scala 2.9 or earlier. Install SBT, as described at the SBT web site. Then, assuming you have an sbt shell script (or .BAT file, for Windows), run:

sbt compile package

The resulting jar file will be in the top-level target directory.

Documentation

Please consult the User’s Guide for details on how to use and configure AVSL.

Change log

The change log for all releases is here.

Author

Brian M. Clapper, bmc@clapper.org

AVSL is copyright © 2010-2014 Brian M. Clapper and is released under a BSD License.

Patches

I gladly accept patches from their original authors. Feel free to email patches to me or to fork the GitHub repository and send me a pull request. Along with any patch you send: