Skip to content

chore: align example dependency versions with Camel and Spring Boot - #223

Merged
Croway merged 1 commit into
apache:mainfrom
Croway:align-dependency-versions
Nov 10, 2026
Merged

Croway merged 1 commit into
apache:mainfrom
Croway:align-dependency-versions

Conversation

@Croway

@Croway Croway commented Nov 10, 2026

Copy link
Copy Markdown
Contributor

Summary

Aligns the dependency and plugin versions declared by the examples with the ones managed by Camel (camel-dependencies), camel-spring-boot and the Spring Boot 4.1.2 BOM. Where none of them defines a version, the dependency is bumped to its latest release.

This also resolves the Dependabot alert for io.micrometer:micrometer-core (>= 1.10.0, <= 1.13.15), which was pinned to 1.13.15 in observation/loggingtracer.

Overrides that shadowed newer Camel / Spring Boot versions (removed)

Where Before Now (inherited)
root reactor-version (reactive-streams) 3.8.3 3.8.8
root testcontainers-version (azure-storage-blob, multi-datasource-2pc) 2.0.3 2.0.5
resilience4j log4j2-version 2.24.3 2.25.5
ai-agent spring-ai-version 2.0.0 2.0.2
genai-observability langchain4j starter 1.20.0 + hardcoded -beta30 ${langchain4j-beta-version} 1.23.0-beta33
observation/loggingtracer micrometer-core / brave 1.13.15 (via a property named micrometer-tracing.version) / 6.0.3 1.17.2 / 6.3.1 (Spring Boot BOM)

observation/loggingtracer had no <parent>, so it could not inherit any managed version (it was also compiled at the compiler plugin's default level instead of Java 21). It now uses the examples root as parent and imports the Spring Boot BOM. It does not use camel-example-spring-boot-observation as parent, because that would apply Spring Boot repackaging to a plain library.

Also removed the unused activemq-version (activemq) and kafka-avro-serializer-version (root) properties.

Hardcoded versions replaced with the Camel property

  • org.postgresql:postgresql 42.7.12 -> ${pgjdbc-driver-version} (42.7.14)
  • build-helper-maven-plugin 3.0.0 / 3.5.0 / unversioned -> ${build-helper-maven-plugin-version} (3.7.0)
  • agroal-spring-boot-starter 3.0 -> ${agroal-version} (3.2.1)
  • hapi-structures-v24 -> ${hapi-version} (unchanged 2.6.0, drops the duplicate root property)

Artemis groupId relocation

artemis and saga used org.apache.activemq:artemis-jakarta-*, which has been relocated to org.apache.artemis. The artemis example pinned 2.44.0, so the classpath mixed 2.44.0 jars with the 2.53.0 jars managed by Spring Boot. Both examples now use org.apache.artemis, with the version managed by the Spring Boot BOM.

Not managed by Camel / Spring Boot: bumped to latest

  • JKube kubernetes-maven-plugin 1.19.0 -> 1.20.0. openshift-maven-plugin in master and saga had no version at all; it now uses ${jkube-maven-plugin-version}
  • Strimzi kafka-oauth-* 0.15.0 -> 0.18.1. Renamed the property from strimzi.version to strimzi-kafka-oauth-version, since it versions the OAuth library and not the Strimzi operator
  • narayana-spring-boot-starter 4.0.0 -> 4.1.1 (built against Spring Boot 4.1)
  • swagger-codegen-maven-plugin 3.0.52 -> 3.0.85. Since swagger-codegen-generators 1.0.53, the spring generator defaults to validationMode=strict, which imports JsonNullable from org.openapitools:jackson-databind-nullable. openapi-contract-first now sets validationMode=legacy, so the generated models are the same as before (compared with the 3.0.52 output; only whitespace and line order differ) and no extra dependency is needed
  • opentelemetry-javaagent 2.19.0 -> 2.33.1. One root property, opentelemetry-javaagent-version, replaces the separate opentelemetry-agent.version / opentelemetry-javaagent.version properties in observability-services, opentelemetry and rest-cxf-opentelemetry

Unversioned plugins pinned

Without a version, Maven resolves whatever plugin release is newest, which may not match the Spring Boot version in use:

  • spring-boot-maven-plugin (opentelemetry/*, salesforce) -> ${spring-boot-version}
  • native-maven-plugin (aot-basic) -> 1.1.14, the version Spring Boot 4.1.2 uses

Cleanups

  • Removed org.jolokia:jolokia-core 1.7.1 from metrics and supervising-route-controller. Neither the code nor the configuration uses it, and Spring Boot 3+ no longer ships a Jolokia actuator endpoint (the jolokia example shows the supported camel-jolokia-starter setup)
  • Removed module properties that only repeated Camel's value: avro-version (kafka-avro), msal4j-version (mail-ms-exchange-oauth2), jakarta-servlet-api-version (saga)
  • resilience4j client2/service2 run on camel-main with SLF4J 2.x: switched log4j-slf4j-impl (SLF4J 1.x binding, ignored by SLF4J 2) to log4j-slf4j2-impl

Testing

  • ./mvnw -V clean install on the full reactor (Java 21, tests included): 86 tests run, 0 failures, 0 errors, 2 skipped
    • kamelet-chucknorris fails with NoClassDefFoundError: com/jayway/jsonpath/spi/json/Jackson3JsonProvider. It fails the same way on a clean main, so it is unrelated to this PR. Camel now uses json-path 3.0.0, but the Spring Boot 4.1.2 BOM manages 2.10.0
    • openapi-contract-first failed on the first run because of the swagger-codegen change above. After the validationMode fix it builds again
  • ./mvnw validate on the full reactor: no missing plugin version or groupId relocation warnings left
  • dependency:list checks:
    • artemis resolves only org.apache.artemis:*:2.53.0
    • observation/loggingtracer resolves micrometer-core 1.17.2 and brave 6.3.1
    • resilience4j client2/service2 resolve slf4j-api 2.0.20 with log4j-slf4j2-impl 2.25.5 as the only binding

Claude Code on behalf of Federico Mariani

Align the dependency and plugin versions declared by the examples with
the ones managed by Camel (camel-dependencies), camel-spring-boot and
the Spring Boot 4.1.2 BOM, and bump to the latest release where neither
defines a version.

- Drop module/root properties that shadowed newer Camel versions
  (reactor, testcontainers, log4j2, spring-ai, langchain4j) and unused
  ones (activemq-version, kafka-avro-serializer-version, jolokia).
- observation/loggingtracer: use the examples parent and the Spring
  Boot BOM instead of pinning micrometer-core 1.13.15 / brave 6.0.3
  (fixes the micrometer-core security alert).
- Use Camel properties for postgresql, build-helper-maven-plugin,
  agroal and hapi.
- Artemis: org.apache.activemq -> org.apache.artemis (relocated
  groupId), version managed by Spring Boot.
- Bump JKube, Strimzi kafka-oauth (property renamed to
  strimzi-kafka-oauth-version), narayana-spring-boot-starter,
  swagger-codegen-maven-plugin and the OpenTelemetry java agent (one
  shared opentelemetry-javaagent-version property).
- Pin unversioned spring-boot-maven-plugin, build-helper-maven-plugin,
  openshift-maven-plugin and native-maven-plugin.
- resilience4j client2/service2: log4j-slf4j-impl -> log4j-slf4j2-impl
  (SLF4J 2.x).
- openapi-contract-first: validationMode=legacy keeps the generated
  models unchanged with swagger-codegen 3.0.85.
@Croway
Croway requested review from davsclaus and oscerd November 10, 2026 14:06
@Croway
Croway merged commit b25dd19 into apache:main Nov 10, 2026
1 check passed
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.

2 participants