Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Redirect java.util.Logging messages to slf4j #1

Open
jarppe opened this issue Sep 16, 2016 · 0 comments
Open

Redirect java.util.Logging messages to slf4j #1

jarppe opened this issue Sep 16, 2016 · 0 comments

Comments

@jarppe
Copy link
Member

jarppe commented Sep 16, 2016

Messages logged via j.u.l are not redirected. See http://stackoverflow.com/a/9117188/210300 how to enable this, example:

(ns jul-log-bridge
  (:import (java.util.logging LogManager Logger Level)
           (org.slf4j.bridge SLF4JBridgeHandler)))

(defn init-jul-logging-bridge []
  (.reset (LogManager/getLogManager))
  (SLF4JBridgeHandler/removeHandlersForRootLogger)
  (SLF4JBridgeHandler/install)
  (.setLevel (Logger/getLogger "global") Level/INFO))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant