tinylog-org / tinylog

tinylog is a lightweight logging framework for Java, Kotlin, Scala, and Android
https://tinylog.org
Apache License 2.0
697 stars 82 forks source link

Can the log output of Logback and log4j2 be seamlessly migrated to tinylog for output? #748

Closed WenTao-Love closed 2 months ago

WenTao-Love commented 3 months ago

Thanks!

pmwmedia commented 3 months ago

Yes, tinylog can receive log entries via SLF4J.

If you use Logback, you properly use SLF4J as logging API. So, you just have to remove the logback JARs and use slf4j-tinylog instead.

For log4j2, you have to use slf4j-tinylog together with log4j-to-slf4.