Repository navigation
feat(jackson3): add jackson3 support for Java Client generator - WebClient - #23031
Merged
wing328 merged 5 commits intoMar 9, 2026
Merged
Conversation
Contributor
There was a problem hiding this comment.
6 issues found across 860 files
Note: This PR contains a large number of files. cubic only reviews up to 75 files per PR, so some files may not have been reviewed.
Prompt for AI agents (all issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="samples/client/petstore/java/restclient-springBoot4-jackson2/docs/FakeApi.md">
<violation number="1" location="samples/client/petstore/java/restclient-springBoot4-jackson2/docs/FakeApi.md:1007">
P2: The generated example uses `Arrays.asList(-efg)`, which is invalid Java syntax. The enum value "-efg" maps to `EnumClass._EFG`, so the example should reference the enum constant instead of the raw token.</violation>
</file>
<file name="modules/openapi-generator/src/main/resources/Java/libraries/restclient/pom.mustache">
<violation number="1" location="modules/openapi-generator/src/main/resources/Java/libraries/restclient/pom.mustache:351">
P2: When useJackson3 is enabled, the template still includes jackson-databind-nullable, which depends on Jackson 2 (com.fasterxml.jackson.*). This will conflict with Jackson 3’s tools.jackson.* packages and can cause compilation/runtime failures. Guard this dependency for Jackson 3 or provide a compatible alternative.</violation>
</file>
<file name="samples/client/petstore/java/restclient-springBoot4-jackson2/README.md">
<violation number="1" location="samples/client/petstore/java/restclient-springBoot4-jackson2/README.md:100">
P2: README example uses `HttpStatusCodeException` without importing it, so the snippet won’t compile when copied.</violation>
</file>
<file name="samples/client/petstore/java/restclient-springBoot4-jackson2/build.sbt">
<violation number="1" location="samples/client/petstore/java/restclient-springBoot4-jackson2/build.sbt:1">
P2: Invalid comment syntax in build.sbt; '#' is not a Scala comment and will cause sbt parsing to fail.</violation>
</file>
<file name="modules/openapi-generator/src/main/resources/Java/libraries/webclient/ApiClient.mustache">
<violation number="1" location="modules/openapi-generator/src/main/resources/Java/libraries/webclient/ApiClient.mustache:169">
P2: Jackson 3 createDefaultMapper omits JsonNullableModule registration, so openApiNullable types won’t serialize/deserialize correctly.</violation>
</file>
<file name="modules/openapi-generator/src/main/resources/Java/libraries/restclient/ApiClient.mustache">
<violation number="1" location="modules/openapi-generator/src/main/resources/Java/libraries/restclient/ApiClient.mustache:195">
P2: Jackson3 createDefaultMapper builds a JsonMapper without registering JsonNullableModule when openApiNullable is enabled, unlike the Jackson2 branch. JsonNullable requires its module to be registered to serialize/deserialize nullable fields, so Jackson3-generated clients will mishandle JsonNullable values.</violation>
</file>
Since this is your first cubic review, here's how it works:
- cubic automatically reviews your code and comments on bugs and improvements
- Teach cubic by replying to its comments. cubic learns from your replies and gets better over time
- Add one-off context when rerunning by tagging
@cubic-dev-aiwith guidance or docs links (includingllms.txt) - Ask questions if you need clarification on any suggestion
Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.
phoval
force-pushed
the
feature/java_jackson3_webclient
branch
2 times, most recently
from
March 6, 2026 07:36
4b3e61f to
3cdbb71
Compare
wing328
reviewed
Mar 6, 2026
phoval
force-pushed
the
feature/java_jackson3_webclient
branch
5 times, most recently
from
March 7, 2026 07:56
7fea6c1 to
22e948f
Compare
phoval
force-pushed
the
feature/java_jackson3_webclient
branch
from
March 7, 2026 19:06
2d6a1df to
f03bda6
Compare
phoval
force-pushed
the
feature/java_jackson3_webclient
branch
from
March 7, 2026 19:16
f03bda6 to
726f6c6
Compare
6 tasks
6 tasks done
davidricodias
pushed a commit
to davidricodias/openapi-generator
that referenced
this pull request
Mar 11, 2026
…lient (OpenAPITools#23031) * feat(jackson3): add jackson3 support for Java Client generator - WebClient * chore: generate bin/generate-samples.sh bin/configs/java-* * fix: add back FindBugs JSR 305 dependency * chore: generate bin/generate-samples.sh bin/configs/java-* * chore: generate bin/generate-samples.sh bin/configs/java-*
4 of 6 tasks
3 tasks done
3 tasks done
wing328
pushed a commit
that referenced
this pull request
Oct 23, 2026
…rix entries (#25378) Several samples-*.yaml workflows had path filters that did not line up with the sample directories their matrix builds. Each line was traced in git history; none of them was deliberate. - samples-kotlin-client.yaml: the push trigger has used `branches:` instead of `paths:` since the file was created in #11619, so the workflow never ran on push (noted but left alone in #23007). Also add filters for the kotlin-jvm-okhttp-path-comments (#20767) and echo_api kotlin-jvm-spring-3-* (#17664) samples that are already in the matrix. - samples-spring.yaml: samples/openapi3/client/petstore/spring* has been in the matrix since #11441 but was never in the filter, so changes to those seven samples did not trigger the workflow. - samples-java-client-jdk17.yaml: add filters for the plain restclient sample (#18522, not matched by restclient-*) and webclient-springBoot4-* (#23031), both of which are in the matrix. - samples-java-client-jdk11.yaml: drop two filters for samples/client/others/java/{resteasy,apache-httpclient}, which do not exist (#22003 meant samples/client/petstore/java/..., already covered by samples/client/petstore/java/**), and add the missing filter for echo_api/java/okhttp-gson-user-defined-templates (#18423). - samples-java-client-echo-api-jdk8.yaml: restore resttemplate in the pull_request filter; #17473 replaced that line instead of adding to it. - samples-kotlin-server-jdk17.yaml, samples-kotlin-server-jdk21.yaml: add the kotlin-misk filter for the matrix entry added in #20885. - samples-protobuf.yaml: add the protobuf-schema-config-complex filter for the matrix entry added in #20915. - samples-rust-client.yaml: the push filter pointed at the nonexistent samples/client/petstore/rust-server (typo introduced in #16143); use samples/client/petstore/rust like the pull_request filter and the matrix. - samples-dotnet8.yaml: drop filters for csharp/httpclient/net8 and csharp/unityWebRequest/net8, directories that have never existed (#20270). - samples-typescript-nestjs-server.yaml: drop the reference to a workflow file that does not exist (#22960); the sample it was meant for lives under typescript-nestjs-server/builds/parameters and is already covered.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PR checklist
Commit all changed files.
This is important, as CI jobs will verify all generator outputs of your HEAD commit as it would merge with master.
These must match the expectations made by your contribution.
You may regenerate an individual generator by passing the relevant config(s) as an argument to the script, for example
./bin/generate-samples.sh bin/configs/java*.IMPORTANT: Do NOT purge/delete any folders/files (e.g. tests) when regenerating the samples as manually written tests may be removed.
master(upcoming7.x.0minor release - breaking changes with fallbacks),8.0.x(breaking changes without fallbacks)"fixes #22294"present in the PR description)Summary by cubic
Adds Jackson 3 support to the Java WebClient generator with Spring Boot 4, using Spring’s Jackson 3 codecs and Jakarta EE. Includes a new Petstore sample with Maven CI (Java 17/21) and adds it to the JDK17 samples workflow.
New Features
Bug Fixes
Written for commit 726f6c6. Summary will update on new commits.