Callback character encoding
You can use <charset>in your definition PatternLayoutEncoder, since this is a subclass LayoutWrappingEncoderthat the method provides setCharset. This is indicated in the class excerpt documentation, but no xml configuration is specified. For LayoutWrappingEncoder the answer was given here: [Logback-user]: how to use UTF-8 .
So, if you configure the code, you can call the method setCharsetusing UTF-8. Or, if you are configuring through xml, this is:
<encoder class="ch.qos.logback.classic.encoder.PatternLayoutEncoder">
<charset>UTF-8</charset>
<outputPatternAsHeader>true</outputPatternAsHeader>
<pattern>[%thread] %-5level %logger{35} - %msg%n</pattern>
</encoder>
Default File Encoding
, , . UTF-8 (, my windows-1252). , , logback UTF-8, . logback UTF-8 -, file.encoding - , , .
, Sun file.encoding, Oracle VM:
"file.encoding" J2SE; Sun . ; .
Eclipse Maven
maven eclipse UTF-8 / Run Configuration ( ), eclipse JVM UTF-8, file.encoding. : Eclipse