Fork me on GitHub

Good Morning!


Morning friends




I have to say ive really liked the early hour for the elderly and vunerable at the supermarkets


I was waiting for the shops to open to general public today and was impressed that people werent kicking up a fuss


Its just nice to see something good happen haha


Anyone have much experience with sente? Trying to work out why it keeps not working with mount


What are people using for logging? Timbre?

ataggart14:03:41 delegating to log4j2 configured with a file.


🙂 Hi Alex!


I use that, but with logback


logback is configured with xml, right?


but the configuration is very minimal


as it should be


some folks dislike xml


timbre has worked out pretty well for us


I'm in the dislike with a passon xml


but I tolerate a few things. I moved from log4j (when it was a 1 release) to logback years and years ago and had a good experience, inertia has prevented me from looking elsewhere


This is all I have.


yeah, I looked around when starting a new system, and the performance of log4j2 over everything else (and the non-xml option) sold me.


<?xml version="1.0" encoding="UTF-8"?>
<configuration scan="true" scanPeriod="10 seconds">

    <statusListener class="ch.qos.logback.core.status.NopStatusListener"/>

    <variable name="ROOT_LOG_LEVEL" value="${ROOT_LOG_LEVEL:-info}"/>

    <appender name="CONSOLE" class="ch.qos.logback.core.ConsoleAppender">
            <Pattern>[%boldWhite(%d)] --- [%boldBlue(%-5level)][%boldGreen(%-40.40logger{40})][%boldMagenta(%-4.4L)] - %msg%n%rEx</Pattern>

    <root level="${ROOT_LOG_LEVEL}">
        <appender-ref ref="CONSOLE"/>



That covers nearly 100% of all the projects I work in


heh, basically the same


Is log4j2 faster than logback thesedays?


they claim it is


It was one of the reasons I moved to logback, since log4j1 was very slow

Ben Hammond15:03:24

rescan config file at runtime is the killer feature

👍 8
Ben Hammond15:03:37

would never want to be without that again


Yes, that has come in very very handy lots of times


and also the jmx configurator as well

rickmoynihan15:03:28 here with slf4j/log4j2. I personally really don’t get on with timbre — but depends on what you want from logging.


> some folks dislike xml I dislike it too; and all things being equal I should prefer timbre with edn config… however the truth is that slf4j/log4j2 via are just far more mature, ship with better defaults, and give you better capabilities such as capturing logging with java libraries such as apache http-client which have been invaluable to us. Yeah you could do this with timbre too; but then you have your backends logging configuration and timbre’s too — it’s just redundant. Plus I found timbres defaults (at least via duct) in prod were horrible; e.g. the syntax colouring by default means tailing logs over ssh the logs are full of gunk… so I had to switch stuff like that off. Plus I ran into a few bugs back in the day; that are probably all fixed now but it felt it was just adding complexity for me. Especially given the log4j configs we need are typically pretty minimal.

Wes Hall15:03:10

I actually use slf4j-simple for most stuff. You can do the basic config with system properties, and it just works. Logging is by far the most over-engineered thing in the whole JVM ecosystem.

☝️ 8

@U06HHF230 we ended up using a timbre appender - just one lot of EDN config for all our clj + java logging


@U0524B4UW yeah and that’s great — but if you want to log stuff in java libraries you’re using; and one library uses log4j and the other java.util.logging; you really don’t want to add timbre too.


oh, i think we intermediate with slf - so our clj timbre client uses an slf backend, and our slf uses a timbre appender. it's been a while since i looked at the details, so i'm a bit hazy tbh, but we successfully capture logging from lots of java libs without having to make any code changes


I've made some regretable technical decisions in my career, but keeping as an abstraction and away from being a logging implementation is not one of them. 🙂

☝️ 4

@U9HA101PY I don’t think java logging is particularly over engineered. Yeah nobody likes how the ecosystem is; and if sun had just include java.util.logging before log4j etc and it had been established; things would be fine… but given we have multiple frameworks now… I think it’s engineered to the right level… it’s just now a complicated problem 😞


Yeah I’ve used that too

Wes Hall15:03:30

@U06HHF230 Yeah, I don't really mean that anybody set out to over engineer it, and you're quite right it was the intro of JUL that really started the whole mess. Whatever you call it though, over-engineered, over-complex etc... this is now a near 40 post thread while we discuss the ways we write lines of text to a file... something perhaps of a case-in-point 🙂


Yeah I don’t disagree with that


@U5ZNLFCQ7 With your setup, are you able to dynamically change logging levels in production?


@UQXS91RT7 Yes, insofar as changes to the file will be reloaded if given a monitorInterval. There might be a way to do it via JMX, but I haven't had to look into it yet.


With JMX yes, I do it in production by exposing the JMX port


(internal only)


so I can adjust if required.


that's what I do


Still deciding between frameworks though. @U5ZNLFCQ7 is your properties file external to the uberjar? @U11EL3P9U interesting, might look at that


Yes, all configuration is external (not just logging), and their locations specified at runtime via system properties.


Though for production use of mucking about with logging config, I'd go with the JMX approach.


How do you specifically specify the location?


Clojure Tools Logging

Ben Hammond14:03:58

Miaow > Apache Log4j 2 is an upgrade to Log4j that provides significant improvements over its predecessor, Log4j 1.x, and provides many of the improvements available in Logback while fixing some inherent problems in Logback’s architecture.

Ben Hammond14:03:24

I've not tried log4j2, must be time to check it out


We were using Timbre for years, but a while back we switched everything over to log4j2, with


(we weened ourselves off all of the taoensso libraries over a period of several months -- just seemed like a lot of code for stuff that didn't really need all that configurability/customization)


I use the taoensso library for i18n - tempura - works well. That's the only one I use 🙂


How's everyone doing with working from home? So far so okay for moi 🙂 Although with a young kid, it's going to be an endurance if this stretches out for months...


i work from home anyway, so plus ça change


Good at the minute — but wfh’d a lot anyway, though I am missing going in to the office. Not sure how it’ll be with nurseries when my wifes mat leave ends; in a few weeks still not heard what they’re planning; whether we’re obliged to still pay them to hold a place etc… She’s a probation officer and should be classed as a key worker though, so maybe places will be available but not sure I want to be mixing large groups of children right now anyway.

👍 4

I've been working remotely for 3 years, no biggie for me really

😄 4

I've been working from home for thirteen years now (with about 18 months in there where I had to go into a local office a few days a week). My wife's climbing the walls a bit tho'... her routine was an hour or two down the gym every morning and of course... no more of that...


I just spoke to my mum and she says the UK has said restrictions will be in place for twelve weeks? (at least)


That's what I've heard

Eamonn Sullivan18:03:48

I've never worked from home for longer than 2-3 days in a row, but in a previous career as a journalists I had to work outside of the office for long stretches. This wasn't home-working, though, it was working in coffee shops, libraries, or whatever. Having a home office where I go every day is quite a different experience for me. I'm on week two. Still doing OK. Haven't gone nuts yet.


Yeah, Boris is holding an unscheduled conference at 20:30 this evening


I strongly suspect lockdown.


I think there may be a rush on the supermarkets


Last time I worked from home was a few years ago, for a full year. This is the first time since then for an extended duration with a 3 year old in tow too!


interesting times!


about f**n' time

truestory 8
Ben Hammond20:03:13

you get out once a day to take your constitutional


Police will have powers to stop and ask, I'm sure the details will come out in a bit (including the full terms, i.e., fines etc..)


NL hasn't gone into complete lockdown yet.


but all larger gathering are banned etc.


Damn. I need to get ginger for dinner tomorrow.v they were out today!


Can deliveroo do supermarkets yet?


in some areas of the uk, deliveroo will shop certain items from yr local coop


or at least they did when I was there


Ive seen that as well in london. They can go buy you some beers from your local offy

Ben Hammond21:03:29

I think you can go out to get food


Yeah, but everyone else will be doing that!


My wife is of the opinion there will be a massive baby boom in 9 months. After all, once you've both binge watched all of netflix, amazon, hulu, disney+, apple tv...what then??...what then??


nah, in 18 mths as pregnant women are higher risk. I reck people will wait til corona is past


(but there will be a boom for sure)


Facebook is full of that


Good time to invest in a condom company?


does anyone here have any experience with K8S/EKS auto-scaling ?


I misread entirely 😂


in some areas of the uk, deliveroo will shop certain items from yr local coop


How do you specifically specify the location?