Hi Matt, On Wed, 17 Jul 2024 at 19:03, Matt Sicker <m...@musigma.org> wrote: > I’ll note one design constraint behind property sources and lookups. Property > sources are defined in the API while lookups are defined in Core.
Since Log4j Core 3 has a different properties system, property sources are technically defined in the API, but are almost unused in the API. They are only used: 1. For the `log4j.provider` property[1], 2. For the `SimpleLoggerContext` and related classes[2]. Status logger since 2.23.0 does not depend on `PropertiesUtil`[3]. The remaining properties (including the configuration of `ThreadContextMap`) are used in Log4j Core. In this way Log4j Core 3 can have its own properties system. > Besides that, property sources are intended for use with configuration > (either for components outside the config file or for reuse in a config file) > while lookups are intended for use with log events, though the ability to use > properties in log events makes this confusing. Most lookups don't really profit from the `LogEvent` parameter[4] and those that do, have a corresponding `PatternConverter`. Piotr [1] https://logging.staged.apache.org/log4j/2.x/manual/systemproperties.html#properties-log4j-api [2] https://logging.staged.apache.org/log4j/2.x/manual/simple-logger.html#config [3] https://logging.staged.apache.org/log4j/2.x/manual/status-logger.html#properties [4] https://logging.staged.apache.org/log4j/2.x/manual/lookups.html#collection