Timbre middleware configuring log levels per namespace pattern.
In project.clj:
[timbre-ns-pattern-level "0.1.2"]
require:
[taoensso.timbre :as timbre]
[timbre-ns-pattern-level]
Configure timbre with the middleware:
(timbre/merge-config!
{:middleware [(timbre-ns-pattern-level/middleware {"datomic.process-monitor" :warn
"com.mchange.v2.c3p0.*" :warn
"ring.logger.timbre" :debug ;; to log request body
:all :info})]})
Copied with minor changes from a timbre issue comment by vandr0iy.
Copyright © 2017 Yonatan Elhanan
Distributed under the MIT License.