Output is correct as per your config. Probably you are not understanding the log back pattern. Go through [0] to understand better. Let me try to explain & then answer your query. Still did not understand plan to play with logback locally to get familiar.
- Out of the box pattern is [2] that means it always logs date, debug level, thread name , logger name and actual message added with new line.
- The number in the config you specified at org.apache.sling.commons.log.pattern like *{4}* [{2}] {3} {5} is conversion word length . explained where well at [1].
- You are looking for [3], to do that create a file such that logger configured to set as [3] and place at crx-quickstart & then at property org.apache.sling.commons.log.configurationFile specify your file name and changes should get reflected to meet your need.
[0] http://logback.qos.ch/manual/
[1] http://logback.qos.ch/manual/layouts.html
[2] %d{dd.MM.yyyy HH:mm:ss.SSS} *%level* [%thread] %logger %msg%n
[3] %d{dd.MM.yyyy HH:mm:ss.SSS} *%level* %msg%n