BurstFilter logging with ClassNotFoundException:com.atlassian.confluence.impl.logging.filter.BurstFilter for Confluence Data Center 8.4.1 and later
プラットフォームについて: Data Center - この記事は、Data Center プラットフォームのアトラシアン製品に適用されます。
このナレッジベース記事は製品の Data Center バージョン用に作成されています。Data Center 固有ではない機能の Data Center ナレッジベースは、製品のサーバー バージョンでも動作する可能性はありますが、テストは行われていません。サーバー*製品のサポートは 2024 年 2 月 15 日に終了しました。サーバー製品を利用している場合は、アトラシアンのサーバー製品のサポート終了のお知らせページにて移行オプションをご確認ください。
*Fisheye および Crucible は除く
要約
For any fresh installations of Confluence of version 8.4.1 or above or after upgrading to 8.4.1 and later, BurstFilter logging in catalina.out file with ClassNotFoundException:com.atlassian.confluence.impl.logging.filter.BurstFilter errors. The system starts without any issues but the logging happens.
環境
Confluence 8.4.1 and later
診断
In catalina.out below error is seen.
2023-08-18 08:05:30,383 Catalina-utility-1 ERROR Unable to create Filter com.atlassian.confluence.impl.logging.filter.BurstFilter due to ClassNotFoundException:com.atlassian.confluence.impl.logging.filter.BurstFilter java.lang.ClassNotFoundException: com.atlassian.confluence.impl.logging.filter.BurstFilter
at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1412)
at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1220)
原因
- Since the release of Confluence 8, which comes bundled with Log4j 2.17, Confluence allows for burst limiting on loggers by using the log4j2 BurstFilter implementation. You can refer to the Log4j Filters for more details.
- The error message is a direct consequence of a recently fixed bug that was implemented in Confluence 8.4.1 as shown in the Issues Resolved in 8.4.1 page:
- CONFSERVER-45195: Analytics ProductEventListener Spamming Log
- The Burst Filter was used as part of the solution to the above bug, and below is the difference in the log4j.properties file when comparing 8.4.0 to 8.4.1 (or above):
##################################################### # Health check logging 8.4.0 ##################################################### log4j.appender.healthCheck=com.atlassian.confluence.logging.ConfluenceHomeLogAppender log4j.appender.healthCheck.LogFileName=atlassian-confluence-health-checks.log log4j.appender.healthCheck.layout=com.atlassian.confluence.util.PatternLayoutWithContext log4j.appender.healthCheck.layout.ConversionPattern=%d %p [%t] [%c{4}] %M %m%n log4j.logger.com.atlassian.confluence.impl.health=INFO, healthCheck
##################################################### # Health check logging 8.4.1 ##################################################### log4j.appender.healthCheck=com.atlassian.confluence.logging.ConfluenceHomeLogAppender log4j.appender.healthCheck.LogFileName=atlassian-confluence-health-checks.log log4j.appender.healthCheck.layout=com.atlassian.confluence.util.PatternLayoutWithContext log4j.appender.healthCheck.layout.ConversionPattern=%d %p [%t] [%c{4}] %M %m%n log4j.logger.com.atlassian.confluence.impl.health=INFO, healthCheck # Appender that burst limits log messages log4j.appender.burstFilterAppender=com.atlassian.confluence.logging.ConfluenceHomeLogAppender log4j.appender.burstFilterAppender.Threshold=ALL log4j.appender.burstFilterAppender.layout=com.atlassian.confluence.util.PatternLayoutWithContext log4j.appender.burstFilterAppender.layout.ConversionPattern=%d %p [%t] [%c\{4}] %M %m%n log4j.appender.burstFilterAppender.filter.1=com.atlassian.confluence.impl.logging.filter.BurstFilter log4j.appender.burstFilterAppender.filter.1.Level=WARN log4j.appender.burstFilterAppender.filter.1.Rate=0.5 log4j.appender.burstFilterAppender.filter.1.MaxBurst=5 log4j.logger.com.atlassian.analytics.client.listener.ProductEventListener=WARN, burstFilterAppender log4j.additivity.com.atlassian.analytics.client.listener.ProductEventListener=false
- The additional section at the bottom of the file was added on 8.4.1 and is responsible for the Burst filter error message.
ソリューション
- We can ignore those messages as this is a common invalid error for any fresh installation or upgrade for 8.4.1 and later.
- To get rid of these messages, comment out the respective section on the /opt/atlassian/confluence/confluence/WEB-INF/classes/log4j.properties file, as shown below.
# Appender that burst limits log messages
# log4j.appender.burstFilterAppender=com.atlassian.confluence.logging.ConfluenceHomeLogAppender
# log4j.appender.burstFilterAppender.Threshold=ALL
# log4j.appender.burstFilterAppender.layout=com.atlassian.confluence.util.PatternLayoutWithContext
# log4j.appender.burstFilterAppender.layout.ConversionPattern=%d %p [%t] [%c{4}] %M %m%n
# log4j.appender.burstFilterAppender.filter.1=com.atlassian.confluence.impl.logging.filter.BurstFilter
# log4j.appender.burstFilterAppender.filter.1.Level=WARN
# log4j.appender.burstFilterAppender.filter.1.Rate=0.5
# log4j.appender.burstFilterAppender.filter.1.MaxBurst=5
# log4j.logger.com.atlassian.analytics.client.listener.ProductEventListener=WARN, burstFilterAppender
# log4j.additivity.com.atlassian.analytics.client.listener.ProductEventListener=false