<? xml version="1.0" encoding="UTF-8"? >

<configuration scan="true">
	<property name="APP" value="${project.artifactId}" />
	<property name="LOG_HOME" value="/data/www/log/${APP}" />
	<appender name="CONSOLE" class="ch.qos.logback.core. ConsoleAppender">
		<encoder>
			<pattern>%d{yy-MM-dd. HH:mm:ss. SSS} [%-16t] %-5p %-22c{0} %X{ServiceId} - %m%n</pattern>
		</encoder>
	</appender>
	<appender name="DETAIL"
		class="ch.qos.logback.core.rolling. RollingFileAppender" additivity="false">
		<File>${LOG_HOME}/${APP}_detail.log</File>
		<encoder>
			<pattern>%d{yy-MM-dd. HH:mm:ss. SSS} [%-16t] %-5p %-22c{0} %X{ServiceId} - %m%n</pattern>
		</encoder>
		<rollingPolicy class="ch.qos.logback.core.rolling. TimeBasedRollingPolicy">
			<fileNamePattern>${LOG_HOME}/${APP}_detail.log.%d{yyyyMMdd}</fileNamePattern>
		</rollingPolicy>
	</appender>
	<appender name="ACCESS"
		class="ch.qos.logback.core.rolling. RollingFileAppender" additivity="false">
		<File>${LOG_HOME}/${APP}_access.log</File>
		<encoder>
			<pattern>%d{yy-MM-dd. HH:mm:ss. SSS};%X{ServiceId};%m%n</pattern>
		</encoder>
		<rollingPolicy class="ch.qos.logback.core.rolling. TimeBasedRollingPolicy">
			<fileNamePattern>${LOG_HOME}/${APP}_access.log.%d{yyyyMMdd}</fileNamePattern>
		</rollingPolicy>
	</appender>


	<logger name="ACCESS">
		<appender-ref ref="ACCESS" />
	</logger>
	<logger name="druid.sql. Statement" level="DEBUG" />
	<logger name="cn.mldn.microboot.dao" level="TRACE" />

	<root level="INFO">
		<appender-ref ref="DETAIL" />
		<appender-ref ref="CONSOLE" />
	</root>
</configuration>