You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I find that the root logger's filter added by log4j2Metrics, reseted sometime after application started.
Since my applcation have multiple context, it will trigger ApplicationEnvironmentPreparedEvent multiple times, and with LoggingSystemShutdownListener and ConfigFileApplicationListener's mechanism, the configration instance in logContext will be replace multiple times, which will lose the filter add by log4j2Metrics.
For now I'm adding a SpringApplicationRunListener#start to rebind the log4j2Metrics, but since it's SpringApplicationRunListener it will also be triggered as many as context's amount. Want a good solution from team, thx!
The text was updated successfully, but these errors were encountered:
I find that the root logger's filter added by log4j2Metrics, reseted sometime after application started.
Since my applcation have multiple context, it will trigger ApplicationEnvironmentPreparedEvent multiple times, and with
LoggingSystemShutdownListener
andConfigFileApplicationListener
's mechanism, the configration instance in logContext will be replace multiple times, which will lose the filter add by log4j2Metrics.For now I'm adding a SpringApplicationRunListener#start to rebind the log4j2Metrics, but since it's SpringApplicationRunListener it will also be triggered as many as context's amount. Want a good solution from team, thx!
The text was updated successfully, but these errors were encountered: