Browse Source

Disable file log since file paths may conflict with the OS environment

on stand-alone Tomcat server installations
Signed-off-by: Pekka Helenius <fincer89@hotmail.com>
v0.0.1-alpha
Pekka Helenius 4 years ago
parent
commit
4fef3aa30d
1 changed files with 10 additions and 6 deletions
  1. +10
    -6
      bookstore/src/main/resources/logback.xml

+ 10
- 6
bookstore/src/main/resources/logback.xml View File

@ -1,9 +1,9 @@
<?xml version="1.0" encoding="UTF-8" ?> <?xml version="1.0" encoding="UTF-8" ?>
<Configuration> <Configuration>
<!--
<property name="LOG_FILE" value="logs/bookstore.log" /> <property name="LOG_FILE" value="logs/bookstore.log" />
-->
<Appender name="console" target="SYSTEM_OUT" class="ch.qos.logback.core.ConsoleAppender"> <Appender name="console" target="SYSTEM_OUT" class="ch.qos.logback.core.ConsoleAppender">
<Layout class="ch.qos.logback.classic.PatternLayout"> <Layout class="ch.qos.logback.classic.PatternLayout">
<Pattern> <Pattern>
@ -11,7 +11,7 @@
</Pattern> </Pattern>
</Layout> </Layout>
</Appender> </Appender>
<!--
<Appender name="file" class="ch.qos.logback.core.FileAppender"> <Appender name="file" class="ch.qos.logback.core.FileAppender">
<File>${LOG_FILE}</File> <File>${LOG_FILE}</File>
<Append>True</Append> <Append>True</Append>
@ -20,18 +20,22 @@
%d{yyyy-MM-dd HH:mm:ss.SSS} - [%thread] %-5level %logger{40} - %msg%n %d{yyyy-MM-dd HH:mm:ss.SSS} - [%thread] %-5level %logger{40} - %msg%n
</Pattern> </Pattern>
</Layout> </Layout>
<!--
-->
<!--
<RollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy"> <RollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy">
<fileNamePattern> <fileNamePattern>
${LOG_FILE}.%d{yyyy-MM-dd}.%i.log ${LOG_FILE}.%d{yyyy-MM-dd}.%i.log
</fileNamePattern> </fileNamePattern>
<MaxFileSize>2MB</MaxFileSize> <MaxFileSize>2MB</MaxFileSize>
</RollingPolicy> -->
</RollingPolicy>
-->
<!--
</Appender> </Appender>
-->
<Root level="info"> <Root level="info">
<Appender-Ref ref="console" /> <Appender-Ref ref="console" />
<Appender-Ref ref="file"/>
<!-- Appender-Ref ref="file"/> -->
</Root> </Root>
</Configuration> </Configuration>

Loading…
Cancel
Save