LighthouseGames / KmLogging

Kotlin multiplatform logging. High performance, composable and simple to use.
Apache License 2.0
84 stars 13 forks source link

Jvm/SLF4J uses class name instead of tag when logging #10

Closed Syer10 closed 2 years ago

Syer10 commented 2 years ago

I have a logger initialized like val log = logging("Server"), but it does not output using the Server tag, but the classname which is ServerService. Logs changed from 22:33:15.129 [DefaultDispatcher-worker-10 @coroutine#29] INFO/Server: to 22:33:15.129 [DefaultDispatcher-worker-10 @coroutine#29] INFO/ServerService$2$1$8: after switching my chosen kotlin multiplatform logging framework.

ellsworthrw commented 2 years ago

I have changed (in v1.2.0) to using the tag as the classname in SLF4J. If you are using a SLF4J config file you will want to also use the tag name in the config file as the class name.