Skip to content

Commit

Permalink
JAV-329 configured async logger
Browse files Browse the repository at this point in the history
  • Loading branch information
seanyinx committed Sep 3, 2017
1 parent 8bc0c5e commit e2e739b
Show file tree
Hide file tree
Showing 6 changed files with 29 additions and 8 deletions.
4 changes: 4 additions & 0 deletions beekeeper/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,10 @@
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-web</artifactId>
</dependency>
<dependency>
<groupId>com.lmax</groupId>
<artifactId>disruptor</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
Expand Down
4 changes: 4 additions & 0 deletions doorman/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,10 @@
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-web</artifactId>
</dependency>
<dependency>
<groupId>com.lmax</groupId>
<artifactId>disruptor</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
Expand Down
16 changes: 8 additions & 8 deletions etc/log/log4j2.xml
Original file line number Diff line number Diff line change
Expand Up @@ -35,33 +35,33 @@
</RollingFile>
<RollingFile name="sla" filename="${cse_dir}/@project_name@_metrics.dat"
filePattern="${cse_dir}/@project_name@/metrics-%d{MM-dd-yyyy}-%i.gz"
append="true" bufferedIO="false" bufferSize="0" immediateFlush="true">
append="true" bufferedIO="false" bufferSize="0" immediateFlush="false">
<PatternLayout pattern="%m%n"/>
<Policies>
<SizeBasedTriggeringPolicy size="20 MB" />
</Policies>
</RollingFile>
<RollingFile name="talc" filename="${cse_dir}/@project_name@_talc.dat"
filePattern="${cse_dir}/@project_name@/talc-%d{MM-dd-yyyy}-%i.gz"
append="true" bufferedIO="false" bufferSize="0" immediateFlush="true">
append="true" bufferedIO="false" bufferSize="0" immediateFlush="false">
<PatternLayout pattern="%m%n"/>
<Policies>
<SizeBasedTriggeringPolicy size="20 MB" />
</Policies>
</RollingFile>
</Appenders>
<Loggers>
<Root level="info">
<asyncRoot level="info">
<AppenderRef ref="stdout"/>
<AppenderRef ref="paas"/>
</Root>
<Logger name="com.huawei.paas.cse.sla.fileslasender"
</asyncRoot>
<AsyncLogger name="com.huawei.paas.cse.sla.fileslasender"
level="error" additivity="false">
<AppenderRef ref="sla"/>
</Logger>
<Logger name="com.huawei.paas.cse.tracing.filespansender"
</AsyncLogger>
<AsyncLogger name="com.huawei.paas.cse.tracing.filespansender"
level="error" additivity="false">
<AppenderRef ref="talc"/>
</Logger>
</AsyncLogger>
</Loggers>
</Configuration>
4 changes: 4 additions & 0 deletions manager/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,10 @@
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-web</artifactId>
</dependency>
<dependency>
<groupId>com.lmax</groupId>
<artifactId>disruptor</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
Expand Down
5 changes: 5 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,11 @@
<artifactId>log4j-web</artifactId>
<version>2.8.2</version>
</dependency>
<dependency>
<groupId>com.lmax</groupId>
<artifactId>disruptor</artifactId>
<version>3.3.6</version>
</dependency>
</dependencies>
</dependencyManagement>

Expand Down
4 changes: 4 additions & 0 deletions worker/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,10 @@
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-web</artifactId>
</dependency>
<dependency>
<groupId>com.lmax</groupId>
<artifactId>disruptor</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
Expand Down

0 comments on commit e2e739b

Please sign in to comment.