[
https://issues.apache.org/jira/browse/CAMEL-27952?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Claus Ibsen resolved CAMEL-27952.
---------------------------------
Resolution: Fixed
Fixed by https://github.com/apache/camel/pull/31194 (merged as ccc58a150a4f on
main, 4.25.0).
> camel-infinispan: remove the unused infinispan-query dependency (pulls
> Hibernate Search and Lucene into Hot Rod users)
> ----------------------------------------------------------------------------------------------------------------------
>
> Key: CAMEL-27952
> URL: https://issues.apache.org/jira/browse/CAMEL-27952
> Project: Camel
> Issue Type: Improvement
> Components: camel-infinispan
> Affects Versions: 4.17.0, 4.23.0
> Reporter: Federico Mariani
> Assignee: Federico Mariani
> Priority: Minor
> Fix For: 4.25.0
>
>
> When camel-infinispan was upgraded to Infinispan 16 (CAMEL-22692), Infinispan
> 16 had removed {{infinispan-query-dsl}} (used by camel-infinispan-common) and
> {{infinispan-remote-query-client}} (used by camel-infinispan). Both were
> replaced by {{org.infinispan:infinispan-query}}.
> {{infinispan-query}} is Infinispan's *embedded* query engine, and Hot Rod
> clients don't need it:
> * the query API now lives in {{infinispan-commons}}
> ({{org.infinispan.commons.api.query.*}});
> * remote query is implemented in {{infinispan-client-hotrod}}.
> Neither camel-infinispan-common nor camel-infinispan references a class from
> {{infinispan-query}} in its main code. The only related test import,
> {{org.infinispan.query.remote.client.impl.MarshallerRegistration}}, ships in
> {{infinispan-commons}}.
> As a result, every application using the remote component gets 20 extra
> runtime jars (~24.3 MB, measured on a consumer project on main: 101 -> 81
> jars, ~43.9 MB -> ~19.6 MB) that the component never uses. Through
> {{infinispan-query}} this includes {{infinispan-core}} and JGroups. The
> module's own dependency tree under-reports it, because camel-infinispan
> declares {{infinispan-core}} with test scope:
> {noformat}
> org.infinispan:infinispan-query:16.3.1
> org.infinispan:infinispan-core:16.3.1
> org.jgroups:jgroups:5.5.7.Final
> org.jboss.threads:jboss-threads:3.11.0
> org.hibernate.search:hibernate-search-engine / -mapper-pojo-base /
> -backend-lucene / -util-common:8.4.0.Final
> org.apache.lucene:lucene-core / lucene-analysis-common / lucene-facet /
> lucene-highlighter / lucene-join /
> lucene-memory / lucene-queries / lucene-queryparser /
> lucene-sandbox:9.12.3
> org.hibernate.models:hibernate-models:1.3.4
> io.smallrye:jandex:3.3.2
> com.carrotsearch:hppc:0.10.0
> {noformat}
> Downstream runtimes inherit the same jars through camel-infinispan, including
> the Camel Spring Boot starter and the Camel Quarkus extension.
> *Proposal:* remove {{infinispan-query}} from camel-infinispan-common and
> camel-infinispan. camel-infinispan-embedded keeps its own declaration,
> because an embedded cache needs the query module at runtime to run queries.
> Because applications no longer get {{infinispan-core}}, JGroups or the
> embedded query engine through camel-infinispan, the change is documented in
> the 4.25 upgrade guide (use camel-infinispan-embedded, or add the
> dependencies explicitly).
> *Verification* on main (4.24.0-SNAPSHOT) against
> quay.io/infinispan/server:16.3:
> * camel-infinispan: 17 unit tests and 111 integration tests pass. This
> includes InfinispanRemoteQueryProducerIT and InfinispanRemoteQueryConsumerIT;
> the latter covers continuous query, the scenario behind CAMEL-9703.
> * camel-infinispan-embedded: its classpath is unchanged, and its tests
> (including the embedded query producer/consumer tests) pass.
> * Separately, a Camel Quarkus 3.40 application with the dependency excluded
> passes its Infinispan put/get round trip, with 16 fewer jars. That was JVM
> mode only; native mode was not tested.
--
This message was sent by Atlassian Jira
(v10.3.26#10030026)