Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jarppe/tukki
Simple clojure first logging library with SLF4J compatibility
https://github.com/jarppe/tukki
Last synced: 2 months ago
JSON representation
Simple clojure first logging library with SLF4J compatibility
- Host: GitHub
- URL: https://github.com/jarppe/tukki
- Owner: jarppe
- Created: 2024-10-05T09:47:54.000Z (4 months ago)
- Default Branch: main
- Last Pushed: 2024-11-15T12:14:57.000Z (2 months ago)
- Last Synced: 2024-11-15T13:20:26.868Z (2 months ago)
- Language: Clojure
- Size: 29.3 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# tukki - Simple clojure first logging library with SLF4J compatibility
Experimental library for handling logging in Clojure first way.
Most Clojure logging libraries are wrappers to an exiting Java libraries. I was
wondering what a Clojure first solution would look like.This library is Clojure logging library with SLF4J API for compatibility with
existing Java libraries.The major differences to existing solutions are:
- Clojure friendly output out of the box
- Write log output to `System/out` leaving REPL (that uses `*out*`) clean
- The main logging API is done with macros that do not emit any code if the
logging level is lower than configured level
- About 7x faster than logback## Clojure friendly output
The default appender function (you can make your own, it's just a function) aims for developer happiness.
It has following defaults:- Output is colored by log level, gray for debug, green for info, red for errors etc.
- Namespaces are truncated so that `foo.bar.boz` becomes `f.b.boz`
- Exceptions are printed with the root cause first
- Only the root cause stack trace is printed completely
- Stacktraces print clojure names as they are found in clojure files, so that function `hello!` is
printed as `hello!`, instead if `hello_BANG_`