davsclaus opened a new pull request, #29779:
URL: https://github.com/apache/camel/pull/29779
This takes the Jackson 2 part of the dependabot group update #29601 and
keeps Jackson 3 at 3.2.4.
## Changes
- `jackson2-version` goes from 2.22.4 to 2.23.0 and
`jackson-annotations-version` from 2.22 to 2.23.
- `jackson3-version` stays at 3.2.4.
- `.github/dependabot.yml` ignores `tools.jackson` 3.3.0 and later, with a
comment saying when to revisit.
## Why Jackson 3 stays at 3.2.x
#29601 fails on Java 21: 26 of 27 tests of `camel-toon` fail with
`NoClassDefFoundError: Could not initialize class
dev.toonformat.jtoon.decoder.ValueDecoder` (and
`...normalizer.JsonNormalizer`). The root cause:
```
java.lang.IllegalStateException: Cannot register BlackbirdModule: it
requires Java 25 or later, and this runtime is Java 21.0.13+9-LTS.
at
tools.jackson.module.blackbird.BlackbirdModule.setupModule(BlackbirdModule.java:151)
...
at
dev.toonformat.jtoon.util.ObjectMapperSingleton.getInstance(ObjectMapperSingleton.java:42)
at
dev.toonformat.jtoon.decoder.ValueDecoder.<clinit>(ValueDecoder.java:35)
```
- **Jackson 3.3.0 needs Java 25 for Blackbird.** Its new code generator uses
the ClassFile API ([release notes,
#359](https://github.com/FasterXML/jackson-modules-base/blob/jackson-modules-base-3.3.0/release-notes/VERSION)).
On Java 17–24, an explicit `addModule(new BlackbirdModule())` throws
`IllegalStateException`.
- **jtoon 3.0.0 registers it.** jtoon 3.0.0 is the latest release, and its
`ObjectMapperSingleton` registers Blackbird explicitly. It is built for Java 21
against Jackson 3.2.3.
- **Camel still supports Java 21.** Every TOON encode and decode would fail
there.
Camel itself does not use Blackbird. The #29601 build stopped at
`camel-toon`, so other Jackson 3 users may have problems with 3.3.0 that the
build never reached.
The ignore can be removed once jtoon stops registering Blackbird below Java
25, or once Camel's minimum Java is 25.
## Tests
On Java 21, with this branch:
- `camel-toon` on Java 21 (Zulu 21.0.5): 27/27 pass. The same module with
`-Djackson3-version=3.3.0` on Java 21 reproduces the failure (26 run, 7
failures, 19 errors, `Cannot register BlackbirdModule: it requires Java 25 or
later`).
- On Java 25: `camel-toon` 27/27, `camel-jackson` 116/116,
`camel-jacksonxml` 42/42, `camel-jackson-avro` 34/34, `camel-jackson3` 126/126.
_Claude Code on behalf of davsclaus_
🤖 Generated with [Claude Code](https://claude.com/claude-code)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]