This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2019-12-25
Channels
- # adventofcode (5)
- # announcements (2)
- # babashka (10)
- # beginners (25)
- # calva (2)
- # clojure (23)
- # clojure-europe (1)
- # clojure-nl (3)
- # clojure-uk (5)
- # clojurescript (6)
- # community-development (5)
- # core-async (16)
- # core-logic (17)
- # datomic (9)
- # defnpodcast (1)
- # duct (6)
- # emacs (4)
- # leiningen (3)
- # off-topic (99)
- # planck (1)
- # shadow-cljs (3)
- # sql (1)
- # tools-deps (6)
- # vrac (2)
Thursday next week 🙂
I wanted something similar too (using tools.logging->slf4j->logback in my case). As you've probably ascertained, the duct default logger (`:duct/logger`) uses timbre. So you need to rewire :duct/logger
to use something else - which means implementing the duct.logger/Logger
protocol: https://github.com/duct-framework/logger/blob/master/src/duct/logger.clj#L4
E.g.:
(ns duct.logger.tools-logging
(:require [clojure.tools.logging :as log]
[duct.logger]
[integrant.core :as ig]))
(defrecord ClojureLogger []
duct.logger/Logger
...)
(defmethod ig/init-key :duct.logger/tools-logging [_ _]
(->ClojureLogger))
And then you need a line in your duct_hierarchy.edn: :duct.logger/tools-logging [:duct/logger]
Now if you add :duct.logger/tools-logging {}
to your app's duct config file it should all wire up to use Clojure's tools.logging (which you can then wire up to logback using slf4j).Thanks!