[ 
https://issues.apache.org/jira/browse/SOLR-18325?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18108711#comment-18108711
 ] 

Bernd Wahlen edited comment on SOLR-18325 at 8/27/26 8:20 AM:
--------------------------------------------------------------

Concrete downstream case: a Spring Boot 4 service on solr-solrj 10.0.0 ships 
both
tools.jackson.core:jackson-databind:3.1.5 and 
com.fasterxml.jackson.core:jackson-databind:2.21.5
(~2.4MB duplicated runtime), and can't drop the latter


was (Author: bwahlen):
Concrete downstream case: a Spring Boot 4 service on solr-solrj 10.0.0 ships 
both
tools.jackson.core:jackson-databind:3.1.5 and 
com.fasterxml.jackson.core:jackson-databind:2.21.5
(~2.4MB duplicated runtime), and can't drop the latter — a bytecode scan of 
solr-solrj-10.0.0 finds
only 5 of 778 classes referencing com/fasterxml/jackson (Utils, 
JacksonContentWriter,
JacksonDataBindResponseParser, CoreAdminResponse), but Utils sits on 
error-response paths, so even a
javabin-only client risks NoClassDefFoundError exactly when Solr returns an 
error.

>  Upgrade Jackson from 2.x to 3.x (tools.jackson)
> ------------------------------------------------
>
>                 Key: SOLR-18325
>                 URL: https://issues.apache.org/jira/browse/SOLR-18325
>             Project: Solr
>          Issue Type: Improvement
>          Components: SolrJ
>    Affects Versions: 10.0
>            Reporter: Bernd Wahlen
>            Priority: Minor
>
> SolrJ (and Solr generally) depends on Jackson 2.x (com.fasterxml.jackson.*); 
> solr-solrj:10.0.0 pulls jackson-databind:2.20. Jackson 3 is released, with 
> 3.1 as the recommended stable line.
> Because Jackson 3 changed its Maven coordinates and packages 
> (com.fasterxml.jackson.core/databind → 
> tools.jackson.core/tools.jackson.databind), it can coexist with Jackson 2 on 
> a classpath — but that's the problem downstream: applications that have moved 
> to Jackson 3 (e.g. anything on Spring Boot 4, which now defaults to Jackson 
> 3) and also use SolrJ are forced to ship both Jackson runtimes, since SolrJ 
> keeps Jackson 2. Filing this to track the upgrade for a major release where 
> the coordinate/package change is acceptable.
> Motivation
> - Align with the current Jackson line (3.1 stable); Jackson 2 will eventually 
> EOL.
> - Let Jackson-3 downstreams avoid bundling two Jackson runtimes when they use 
> SolrJ.
> Scope / considerations
> - Package/coordinate change across the codebase: 
> com.fasterxml.jackson.{databind,core} → tools.jackson.{databind,core}. 
> Annotations are unaffected — they stay com.fasterxml.jackson.annotation 
> (Jackson 3 depends on jackson-annotations 2.20+ by design), so @JsonProperty 
> etc. don't change.
> - API changes: ObjectMapper is immutable/builder-based 
> (JsonMapper.builder()…build()); exceptions are unchecked now 
> (tools.jackson.core.JacksonException replaces JsonProcessingException).
> - Jackson 3.0 is not LTS — target 3.1.x.
> - Needs alignment across all Solr modules (server, solrj, contribs).
> - Breaking coordinate change → natural fit for the next major (11.0, already 
> in dev per SOLR-18003).



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to