-
-
Notifications
You must be signed in to change notification settings - Fork 808
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
Add JsonFactoryBuilder.configureForJackson2()
, JsonFactoryBuilder builderWithJackson2Defaults()
#1411
Add JsonFactoryBuilder.configureForJackson2()
, JsonFactoryBuilder builderWithJackson2Defaults()
#1411
Conversation
pjfanning
commented
Mar 5, 2025
•
edited
Loading
edited
- Relates to Add JsonMapper builder support in Jackson 3.0 for optionally creating mappers with Jackson2 config defaults jackson-databind#4986
Makes sense as a starting point, but if the idea is to add same functionality for other backends, should probably implement in a way that can share general (non-JSON-specific) settings. And in fact, instead of (or in addition to?) having all of these in Builder factory method, could perhaps have builder member method like |
I thought about having it on the builder but my worry is that users will then use annoying ordering in chaining their commands to configure the builder. Someone is bound to come along and create a build, set some config then call |
@pjfanning I still suggest adding configure method in Builder instance even if called from static factory method that creates Builders. That allows composition of Configure method can then be alternatively called by someone being only handed Builder, as opposed to only being available from Factory. |
I added configureForJackson2 in latest commit. |
setJackson2Defaults()
to JsonFactoryBuilder
setJackson2Defaults()
to JsonFactoryBuilder
JsonFactoryBuilder.configureForJackson2()
, JsonFactoryBuilder builderWithJackson2Defaults()