Skip to content

Add opt-in Jackson Blackbird optimization to ObjectMappers#3534

Open
parker89 wants to merge 1 commit into
developfrom
pw/blackbird-opt-in
Open

Add opt-in Jackson Blackbird optimization to ObjectMappers#3534
parker89 wants to merge 1 commit into
developfrom
pw/blackbird-opt-in

Conversation

@parker89

@parker89 parker89 commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

Adds opt-in Jackson Blackbird support to ObjectMappers (off by default). ObjectMapperOptimizations.createModules(boolean) plus new server/client mapper overloads register BlackbirdModule only when explicitly requested.

@changelog-app

changelog-app Bot commented Jul 9, 2026

Copy link
Copy Markdown

Generate changelog in changelog/@unreleased

Type (Select exactly one)

  • Feature (Adding new functionality)
  • Improvement (Improving existing functionality)
  • Fix (Fixing an issue with existing functionality)
  • Break (Creating a new major version by breaking public APIs)
  • Deprecation (Removing functionality in a non-breaking way)
  • Migration (Automatically moving data/functionality to a new system)

Description

Add opt-in Jackson Blackbird optimization to ObjectMappers

Check the box to generate changelog(s)

  • Generate changelog entry

}

/** Like {@link #newServerSmileMapper()}, optionally enabling Jackson optimization modules (Blackbird). */
public static SmileMapper newServerSmileMapper(boolean useOptimizations) {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Did you have other optimizations in mind down the line?

I wonder if we should name this something like "newSingleInstantiatedServerSmileMapper" or something to make it clear that this should not be called multiple times, and then enable blackbird by default for this case.

Maybe we can write an errorprone check(? e.g. only created in a final variable in a class - though this is a bit restrictive)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants