博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
RocketMQ logback使用实践
阅读量:5084 次
发布时间:2019-06-13

本文共 9432 字,大约阅读时间需要 31 分钟。

logback_broker.xml

${user.home}/logs/rocketmqlogs/broker_default.log
true
${user.home}/logs/rocketmqlogs/otherdays/broker_default.%i.log.gz
1
10
100MB
%d{yyy-MM-dd HH:mm:ss,GMT+8} %p %t - %m%n
UTF-8
${user.home}/logs/rocketmqlogs/broker.log
true
${user.home}/logs/rocketmqlogs/otherdays/broker.%i.log.gz
1
20
128MB
%d{yyy-MM-dd HH:mm:ss,GMT+8} %p %t - %m%n
UTF-8
${user.home}/logs/rocketmqlogs/protection.log
true
${user.home}/logs/rocketmqlogs/otherdays/protection.%i.log.gz
1
10
100MB
%d{yyy-MM-dd HH:mm:ss,GMT+8} - %m%n
UTF-8
${user.home}/logs/rocketmqlogs/watermark.log
true
${user.home}/logs/rocketmqlogs/otherdays/watermark.%i.log.gz
1
10
100MB
%d{yyy-MM-dd HH:mm:ss,GMT+8} - %m%n
UTF-8
${user.home}/logs/rocketmqlogs/store.log
true
${user.home}/logs/rocketmqlogs/otherdays/store.%i.log.gz
1
10
128MB
%d{yyy-MM-dd HH:mm:ss,GMT+8} %p %t - %m%n
UTF-8
${user.home}/logs/rocketmqlogs/remoting.log
true
${user.home}/logs/rocketmqlogs/otherdays/remoting.%i.log.gz
1
10
100MB
%d{yyy-MM-dd HH:mm:ss,GMT+8} %p %t - %m%n
UTF-8
${user.home}/logs/rocketmqlogs/storeerror.log
true
${user.home}/logs/rocketmqlogs/otherdays/storeerror.%i.log.gz
1
10
100MB
%d{yyy-MM-dd HH:mm:ss,GMT+8} %p %t - %m%n
UTF-8
${user.home}/logs/rocketmqlogs/transaction.log
true
${user.home}/logs/rocketmqlogs/otherdays/transaction.%i.log.gz
1
10
100MB
%d{yyy-MM-dd HH:mm:ss,GMT+8} %p %t - %m%n
UTF-8
${user.home}/logs/rocketmqlogs/lock.log
true
${user.home}/logs/rocketmqlogs/otherdays/lock.%i.log.gz
1
5
100MB
%d{yyy-MM-dd HH:mm:ss,GMT+8} %p %t - %m%n
UTF-8
${user.home}/logs/rocketmqlogs/filter.log
true
${user.home}/logs/rocketmqlogs/otherdays/filter.%i.log.gz
1
10
100MB
%d{yyy-MM-dd HH:mm:ss,GMT+8} %p %t - %m%n
UTF-8
${user.home}/logs/rocketmqlogs/stats.log
true
${user.home}/logs/rocketmqlogs/otherdays/stats.%i.log.gz
1
5
100MB
%d{yyy-MM-dd HH:mm:ss,GMT+8} %p - %m%n
UTF-8
${user.home}/logs/rocketmqlogs/commercial.log
true
${user.home}/logs/rocketmqlogs/otherdays/commercial.%i.log.gz
1
10
500MB
true
%d{yyy-MM-dd HH\:mm\:ss,GMT+8} %p %t - %m%n
UTF-8
LoggerName.java
public class LoggerName {    public static final String FILTERSRV_LOGGER_NAME = "RocketmqFiltersrv";    public static final String NAMESRV_LOGGER_NAME = "RocketmqNamesrv";    public static final String BROKER_LOGGER_NAME = "RocketmqBroker";    public static final String BROKER_CONSOLE_NAME = "RocketmqConsole";    public static final String CLIENT_LOGGER_NAME = "RocketmqClient";    public static final String TOOLS_LOGGER_NAME = "RocketmqTools";    public static final String COMMON_LOGGER_NAME = "RocketmqCommon";    public static final String STORE_LOGGER_NAME = "RocketmqStore";    public static final String STORE_ERROR_LOGGER_NAME = "RocketmqStoreError";    public static final String TRANSACTION_LOGGER_NAME = "RocketmqTransaction";    public static final String REBALANCE_LOCK_LOGGER_NAME = "RocketmqRebalanceLock";    public static final String ROCKETMQ_STATS_LOGGER_NAME = "RocketmqStats";    public static final String COMMERCIAL_LOGGER_NAME = "RocketmqCommercial";    public static final String FLOW_CONTROL_LOGGER_NAME = "RocketmqFlowControl";    public static final String ROCKETMQ_AUTHORIZE_LOGGER_NAME = "RocketmqAuthorize";    public static final String DUPLICATION_LOGGER_NAME = "RocketmqDuplication";    public static final String PROTECTION_LOGGER_NAME = "RocketmqProtection";    public static final String WATER_MARK_LOGGER_NAME = "RocketmqWaterMark";    public static final String FILTER_LOGGER_NAME = "RocketmqFilter";}

代码中的使用

private static final Logger log = LoggerFactory.getLogger(LoggerName.FILTERSRV_LOGGER_NAME);

转载于:https://www.cnblogs.com/winner-0715/p/9063553.html

你可能感兴趣的文章
android onClick onTouch事件
查看>>
android Activity launch mode 一个实例 singleTask
查看>>
调用淘宝订单接口想到的一个问题
查看>>
map的使用方法
查看>>
集合类--容器
查看>>
大话卷积神经网络(CNN)
查看>>
浅谈MySQL的优化
查看>>
git强制使用远程仓库代码覆盖本地仓库
查看>>
违章查询助手数据调用分享
查看>>
[PAT] 1148 Werewolf - Simple Version (20 分)Java
查看>>
C# Graphics中有关绘图质量的几个Mode
查看>>
利用IIdentify接口实现点选和矩形选择要素
查看>>
Kindeditor 结合easyui与strturs文件上传与实现
查看>>
MFC绘制棋盘格
查看>>
[转]Mac Appium环境安装
查看>>
使用memcache 存储session
查看>>
HDU 4857 逃生(反向拓扑排序+优先队列)
查看>>
求二叉树中第K层结点的个数
查看>>
Cursor对象的构造函数传递光标文件
查看>>
R,RJAVA 安装配置 详细版
查看>>