Tools.logging is an interface. You need to decide on a logging engine too.
In effect it means Tools.logging can not log things on its own. It delegates to another library for that. So think of it as a wrapper around other logging libraries.
I personally recommend going with LogBack.
LogBack is SLF4J’s default logging engine. SLF4J is also an interface that wraps other logging engines.
It helps to think of history.
First there was java.utils.logging. It had a particular API and could log to files. Being both and interface and engine. Some people felt it didn’t have enough features. So Apache commons-log appeared. It had a different interfaxe and its own logging engine. People felt it was too slow, so log4j 1 came out. Again it wad a different interface and engine. Finally, someone thought, damn its annoying having all these different interfaces for logging and engines. So SLF4J came out to try and create a unified interface over all logging engines. It also created its own logging engine called LogBack. Finally, clojure.tools.logging came out as a common Clojure interface wrapper over all Java logging libraries, interfaces or engine.
But clojure.tools.logging has no logging engine. Its only an empty shell. So you need to add a dependency on a supported Java logging engine it knows how to use for it to actually log anything. Also, it does not wrap over the configuration for the engines, since that would be too hard to unify config over all logging engines as they vary too much.
Alright, so, how do you pick an underlying logging engine?
Basically, you just add them as a dependency to your project. If your project depends on more then one supported logging engine, clojure.tools.logging will use in priority the first one it finds using the order you quoted.
So, go look at your dependencies and see if you depend on a logging engine that clojure.tools.logging supports. Check all the ones there are, there could be more then one. Specifically, you have to look at transitive dependencies too, so you need to run
lein deps :tree
If you find some engines as part of transitive dependencies, exclude them. You don’t want a dependency bringing in a logging engine that suddenly takes priority on yours.
If you have more then one direct depency to some engines, pick one, and remove the others.
I’ll assume you had none. In this case, if you look at the quoted order, java.utils.logging is the last supported engine. And this one comes bundled with Java itself. So if you have no dependencies on any other, that’s the one clojure.tools.logging will use.
Now, I’d recommend LogBack for production uses. In which case, I’d recommend you start getting familiar with it right away. Its fast, doesn’t have any known deadlocks. Is stable. Has great documentation. Is relatively simple to configure. And has a good set of advanced features.
Anyways, at this point, you have to go read the documentation of the logging engine you chose. Each one will have a different way of setting the log level of the default logger.
Or just use Timbre which is a pure Clojure/Script logging interface which comes with its own engine.