diff --git a/mica-logging/src/main/java/net/dreamlu/mica/logging/appender/LoggingLokiAppender.java b/mica-logging/src/main/java/net/dreamlu/mica/logging/appender/LoggingLokiAppender.java index db848a5a5..19e8fa7f3 100644 --- a/mica-logging/src/main/java/net/dreamlu/mica/logging/appender/LoggingLokiAppender.java +++ b/mica-logging/src/main/java/net/dreamlu/mica/logging/appender/LoggingLokiAppender.java @@ -107,13 +107,6 @@ private Loki4jEncoder getFormat(LoggerContext context, labelCfg.setKeyValueSeparator(properties.getFormatLabelKeyValueSeparator()); labelCfg.setNopex(properties.isFormatLabelNoPex()); loki4jEncoder.setLabel(labelCfg); - // message config - AbstractLoki4jEncoder.MessageCfg messageCfg = new AbstractLoki4jEncoder.MessageCfg(); - String formatMessagePattern = properties.getFormatMessagePattern(); - if (StringUtil.isNotBlank(formatMessagePattern)) { - messageCfg.setPattern(formatMessagePattern); - } - loki4jEncoder.setMessage(messageCfg); // 其他配置 loki4jEncoder.setStaticLabels(properties.isFormatStaticLabels()); loki4jEncoder.setSortByTime(properties.isFormatSortByTime()); diff --git a/mica-logging/src/main/java/net/dreamlu/mica/logging/config/MicaLoggingProperties.java b/mica-logging/src/main/java/net/dreamlu/mica/logging/config/MicaLoggingProperties.java index 1673f1447..6216545ab 100644 --- a/mica-logging/src/main/java/net/dreamlu/mica/logging/config/MicaLoggingProperties.java +++ b/mica-logging/src/main/java/net/dreamlu/mica/logging/config/MicaLoggingProperties.java @@ -148,10 +148,6 @@ public static class Loki { */ private String formatLabelKeyValueSeparator = "="; private boolean formatLabelNoPex = true; - /** - * 消息体格式,默认为: l=%level c=%logger{20} t=%thread | %msg %ex - */ - private String formatMessagePattern; private boolean formatStaticLabels = false; private boolean formatSortByTime = false; }