This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2020-06-12
Channels
- # aleph (1)
- # aws (2)
- # babashka (44)
- # beginners (178)
- # biff (12)
- # calva (22)
- # chlorine-clover (60)
- # cider (1)
- # clj-kondo (9)
- # cljdoc (6)
- # cljs-dev (37)
- # cljss (2)
- # clojure (43)
- # clojure-europe (3)
- # clojure-finland (23)
- # clojure-italy (1)
- # clojure-nl (4)
- # clojure-norway (3)
- # clojure-spec (56)
- # clojure-uk (148)
- # clojuredesign-podcast (1)
- # clojurescript (11)
- # conjure (5)
- # core-async (22)
- # cursive (9)
- # datascript (5)
- # datomic (4)
- # duct (8)
- # emotion-cljs (2)
- # figwheel-main (15)
- # fulcro (53)
- # graalvm (68)
- # helix (2)
- # jackdaw (1)
- # kaocha (9)
- # lambdaisland (1)
- # malli (10)
- # meander (2)
- # news-and-articles (1)
- # observability (12)
- # off-topic (17)
- # pathom (1)
- # pedestal (25)
- # practicalli (1)
- # protojure (4)
- # re-frame (2)
- # reagent (57)
- # reitit (1)
- # releases (2)
- # shadow-cljs (69)
- # specter (6)
- # tools-deps (10)
- # vim (16)
- # vscode (4)
- # yada (3)
Do you have an example of what your deps.edn logging deps looks like, Sean? I’ve been setting up a new project and as plexus noted in his post, there are so many deps required to set everything up for logging its indeed confusing to know whats required. My current setup is based off stuart’s clojure.dev logging setup.
This is what I currently have, just two dependencies, although it's log4j 1: https://pastebin.com/sQbAHQne It logs into a file and the console.
Example of what's usually in my project.clj: https://gist.github.com/ataggart/ac208c289c5d01dacf3b4b341a1c37f0
@U04V70XH6 What's the use case for logged-future
? I didn't find any documentation, but I infer it's just wrapping future
around a logging call.
@U0677JTQX Since we were switching away from Timbre, we figured we might as well use the most modern logging library (2 over 1).
;; use log4j 2.x:
org.apache.logging.log4j/log4j-api {:mvn/version "2.13.3"}
;; bridge into log4j:
org.apache.logging.log4j/log4j-1.2-api {:mvn/version "2.13.3"}
org.apache.logging.log4j/log4j-jcl {:mvn/version "2.13.3"}
org.apache.logging.log4j/log4j-jul {:mvn/version "2.13.3"}
org.apache.logging.log4j/log4j-slf4j-impl {:mvn/version "2.13.3"}
@U5ZNLFCQ7 It means we can just replace future
with logged-future
everywhere and not have to worry about adding in code everywhere to get this:
(future
(try
,,, body ,,,
(catch Throwable t
(logger/error t))))
Thanks a lot everyone for contributing to the conversation. I learned a few things, and I'll be updating the post!
all of these https://landing.google.com/sre/books/
https://www.amazon.com/Phoenix-Project-DevOps-Helping-Business/dp/0988262592 is also good if you want something that covers more of the human side of things.