-
Notifications
You must be signed in to change notification settings - Fork 40.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Migrate Logback configuration class to use suppliers #43588
Comments
@philwebb Please note that the use of suppliers for specifying converter classes is optional. Logback 1.5.14 and later will transparently adapt any converters specified as strings. |
@ceki I am a bit confused about the change. How is the use of suppliers optional? Looking at the code, it looks like that the
What should we do if we want to migrate our code to use suppliers? |
@snicoll I only had 10 minutes to look into this issue this morning. Which version of logback are you using? I am asking because version logback 1.5.14 fixed a compatibility issue when accessing the pattern rule registry through the logging context. Are you using an earlier version of logback by any chance? The later versions of logback maintain two registries PATTERN_RULE_REGISTRY_FOR_SUPPLIERS and PATTERN_RULE_REGISTRY at the logger context level. When a PatternLayout instance is instantiated, entries from both maps are merged into an effective converter map. |
Nope, I am using the latest. But you answered my question. I should change the key to lookup the map. |
See qos-ch/logback@be0b5e0 (which triggered qos-ch/logback#885 in Boot 3.4). In 3.5 we could update our code to also use suppliers.
The text was updated successfully, but these errors were encountered: