Skip to content

feat: improve error message when Jackson is missing from classpath#473

Merged
edeandrea merged 3 commits intodocling-project:mainfrom
edeandrea:fix/improve-jackson-missing-error-message
Apr 28, 2026
Merged

feat: improve error message when Jackson is missing from classpath#473
edeandrea merged 3 commits intodocling-project:mainfrom
edeandrea:fix/improve-jackson-missing-error-message

Conversation

@edeandrea
Copy link
Copy Markdown
Contributor

Summary

  • Improves the IllegalStateException message thrown when neither Jackson 2 nor Jackson 3 is on the classpath to include actionable Maven/Gradle dependency coordinates
  • Updates the corresponding test assertion to verify the new message content

Test plan

  • DoclingServeClientBuilderFactoryTests.noBuilderWhenNeitherArePresent() passes with updated assertion
  • All other DoclingServeClientBuilderFactoryTests remain green
  • spotlessCheck passes

Closes #470

Copilot AI review requested due to automatic review settings April 28, 2026 01:15
@edeandrea edeandrea changed the title Improve error message when Jackson is missing from classpath fix: improve error message when Jackson is missing from classpath Apr 28, 2026
@edeandrea edeandrea changed the title fix: improve error message when Jackson is missing from classpath feat: improve error message when Jackson is missing from classpath Apr 28, 2026
@edeandrea edeandrea force-pushed the fix/improve-jackson-missing-error-message branch from 8b78bd7 to 40fef86 Compare April 28, 2026 01:17
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR improves the developer experience when using docling-serve-client without a Jackson implementation on the classpath by making the thrown IllegalStateException more actionable, and updates docs/examples around client usage and downstream framework integrations.

Changes:

  • Expand the “missing Jackson” IllegalStateException message to include Maven/Gradle dependency coordinates for Jackson 2 and Jackson 3.
  • Update DoclingServeClientBuilderFactoryTests to assert the new message content.
  • Refresh docs to link to Quarkus/Spring Boot downstream implementations and adjust client usage examples.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.

File Description
docs/src/doc/docs/docling-serve/serve-client.md Adds references to downstream implementations and updates the quick-start snippet (including an apiKey example).
docs/src/doc/docs/docling-serve/serve-api.md Adds references to downstream implementations and improves readability with spacing.
docling-serve/docling-serve-client/src/test/java/ai/docling/serve/client/DoclingServeClientBuilderFactoryTests.java Updates assertions to validate the expanded exception message.
docling-serve/docling-serve-client/src/main/java/ai/docling/serve/client/DoclingServeClientBuilderFactory.java Updates the thrown exception message to include dependency guidance for Jackson 2/3.

Comment thread docs/src/doc/docs/docling-serve/serve-client.md Outdated
@edeandrea edeandrea enabled auto-merge (squash) April 28, 2026 01:21
Copilot AI review requested due to automatic review settings April 28, 2026 01:21
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

Comment thread docs/src/doc/docs/docling-serve/serve-client.md Outdated
@edeandrea edeandrea disabled auto-merge April 28, 2026 01:24
Include Maven and Gradle dependency coordinates in the error message
when neither Jackson 2 nor Jackson 3 is found on the classpath, so
users know exactly what dependency to add.

Closes docling-project#470

Assisted-By: Claude Code <noreply@anthropic.com>
Signed-off-by: Eric Deandrea <eric.deandrea@ibm.com>
The trailing \ triggered Java text-block line continuation, suppressing
the newline and pulling closing-delimiter indentation into the message.

Assisted-By: Claude Code <noreply@anthropic.com>
Signed-off-by: Eric Deandrea <eric.deandrea@ibm.com>
$version is not a Gradle-standard variable and makes the snippet
non-copy-pasteable. Use <version> which is a widely recognized
placeholder convention.

Assisted-By: Claude Code <noreply@anthropic.com>
Signed-off-by: Eric Deandrea <eric.deandrea@ibm.com>
@edeandrea edeandrea force-pushed the fix/improve-jackson-missing-error-message branch from 88f3e35 to 6c5c7fb Compare April 28, 2026 01:25
@github-actions
Copy link
Copy Markdown

:java_duke: JaCoCo coverage report

Overall Project 47.33% 🔴

There is no coverage information present for the Files changed

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 28, 2026

TestsPassed ✅SkippedFailed
Gradle Test Results (all modules & JDKs)1002 ran1002 passed0 skipped0 failed
TestResult
No test annotations available

@github-actions
Copy link
Copy Markdown

HTML test reports are available as workflow artifacts (zipped HTML).

• Download: Artifacts for this run

@edeandrea edeandrea enabled auto-merge (squash) April 28, 2026 01:26
@github-actions
Copy link
Copy Markdown

HTML test reports are available as workflow artifacts (zipped HTML).

• Download: Artifacts for this run

@edeandrea edeandrea merged commit d1d13be into docling-project:main Apr 28, 2026
21 checks passed
@github-actions
Copy link
Copy Markdown

HTML test reports are available as workflow artifacts (zipped HTML).

• Download: Artifacts for this run

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Exception using docling-serve-client

2 participants