geode-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kirk Lund <>
Subject Fix for ClassCastException when using Logback for 1.10.0
Date Thu, 08 Aug 2019 18:24:51 GMT
This is the last logging related fix that I'd like to propose adding to
release branch.

Spring Boot adds Logback and log4j-to-slf4j to the classpath. This
results in ClassCastExceptions if log4j-core is not excluded.

This change prevents Geode from using Log4jAgent if Log4j Core is
present but not using Log4jProvider.

For example, Log4j uses SLF4JProvider instead of Log4jProvider when
log4j-to-slf4j is in the classpath.

By disabling Log4jAgent when other Log4j Providers are in use, this
prevents problems such as ClassCastExceptions when attempting to cast
loggers from org.apache.logging.slf4j.SLF4JLogger to
org.apache.logging.log4j.core.Logger to get the LoggerConfig or

GEODE-7050: Use Log4jAgent only if Log4j is using Log4jProvider

Kirk and Aaron

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message