Skip to content

CAMEL-23562: camel-xmpp - upgrade Smack from 4.3.5 to 4.4.8#24958

Merged
davsclaus merged 1 commit into
apache:mainfrom
oscerd:fix/CAMEL-23562
Jul 20, 2026
Merged

CAMEL-23562: camel-xmpp - upgrade Smack from 4.3.5 to 4.4.8#24958
davsclaus merged 1 commit into
apache:mainfrom
oscerd:fix/CAMEL-23562

Conversation

@oscerd

@oscerd oscerd commented Jul 20, 2026

Copy link
Copy Markdown
Contributor

Motivation

CAMEL-23562: upgrade Smack to the 4.4.x line (4.4.8 is the latest stable on Maven Central; 4.5 is still in beta). We were on 4.3.5, released in 2019.

Changes

  • smack-version 4.3.5 → 4.4.8; smack-java7 (gone in 4.4) replaced by smack-java8 in the camel-xmpp pom.
  • XmppBinding: DefaultExtensionElement was removed in Smack 4.4 — the fallback branch for an unparsed JiveProperties extension now uses its replacement StandardExtensionElement, mapping flat child elements to headers with the same header-filter application as before. (The primary JivePropertiesExtension path is unchanged.)
  • XmppLogger: stanza.toXML(null) is ambiguous against the 4.4 Element overloads (toXML(XmlEnvironment) vs toXML(String)) — switched to the no-arg toXML().
  • Upgrade-guide entry (4.22) noting the upgrade, the module rename, and linking the Smack 4.4 readme for library-level behavioral changes.

Testing

  • Unit tests: all pass.
  • The module's container-based integration tests (*IT, XMPP server via test-infra) fail in my environment with SSLHandshakeException: Remote host terminated the handshakeidentically on current main with Smack 4.3.5 (verified by running the baseline first: same 1 failure + 6 errors, same exception). So their outcome is unchanged by this upgrade; the pre-existing test-server TLS issue can be looked at separately.
  • Full reactor mvn clean install -DskipTests from root: success, no stale generated files.

No backport: dependency upgrade, main/4.22.0 only.

Claude Code on behalf of Andrea Cosentino (@oscerd).

🤖 Generated with Claude Code

The smack-java7 module no longer exists in Smack 4.4 and is replaced by
smack-java8. DefaultExtensionElement was removed: unparsed JiveProperties
extensions are now represented by StandardExtensionElement, with flat child
elements mapped to headers as before. Stanza logging uses the no-arg toXML()
since toXML(null) is ambiguous against the 4.4 Element overloads.

The camel-xmpp container integration tests fail identically on smack 4.3.5
in the same environment (TLS handshake against the test server), so their
outcome is unchanged by this upgrade; unit tests pass.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Signed-off-by: Andrea Cosentino <ancosen@gmail.com>
@oscerd
oscerd requested review from davsclaus and gnodet July 20, 2026 17:31

@gnodet gnodet left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Clean dependency upgrade — all changes are well-targeted and the API migration is correct.

Version bump: 4.3.5 → 4.4.8 ✅
Module rename: smack-java7smack-java8 (removed in Smack 4.4) ✅
XmppBinding: DefaultExtensionElementStandardExtensionElement with updated iteration pattern (getElements() + getElementName()/getText() instead of getNames() + getValue()) — semantically equivalent for flat child elements. ✅
XmppLogger: toXML(null)toXML() (no-arg form avoids ambiguity with the new Element overload in 4.4) ✅
Upgrade guide: Thorough entry documenting the module rename, the StandardExtensionElement replacement, and linking to the Smack 4.4 readme for further behavioral changes. ✅

LGTM.

Reviewed with Claude Code on behalf of gnodet. This review was generated by an AI agent and may contain inaccuracies; please verify all suggestions before applying.

@github-actions

Copy link
Copy Markdown
Contributor

🌟 Thank you for your contribution to the Apache Camel project! 🌟
🤖 CI automation will test this PR automatically.

🐫 Apache Camel Committers, please review the following items:

  • First-time contributors require MANUAL approval for the GitHub Actions to run
  • You can use the command /component-test (camel-)component-name1 (camel-)component-name2.. to request a test from the test bot although they are normally detected and executed by CI.
  • You can label PRs using skip-tests and test-dependents to fine-tune the checks executed by this PR.
  • Build and test logs are available in the summary page. Only Apache Camel committers have access to the summary.

⚠️ Be careful when sharing logs. Review their contents before sharing them publicly.

@github-actions

Copy link
Copy Markdown
Contributor

🧪 CI tested the following changed modules:

  • components/camel-xmpp
  • docs
  • parent

POM dependency changes: targeted tests included

Changed properties: smack-version

Modules affected by dependency changes (1)
  • :camel-xmpp

🔬 Scalpel shadow comparison — Scalpel: 10 tested, 28 compile-only — current: 9 all tested

Maveniverse Scalpel detected 38 affected modules (current approach: 9).

⚠️ Modules only in Scalpel (29)
  • apache-camel
  • camel-allcomponents
  • camel-catalog
  • camel-catalog-console
  • camel-catalog-lucene
  • camel-catalog-maven
  • camel-catalog-suggest
  • camel-componentdsl
  • camel-csimple-maven-plugin
  • camel-endpointdsl
  • camel-endpointdsl-support
  • camel-itest
  • camel-jbang-core
  • camel-jbang-it
  • camel-jbang-main
  • camel-jbang-plugin-edit
  • camel-jbang-plugin-generate
  • camel-jbang-plugin-kubernetes
  • camel-jbang-plugin-test
  • camel-kamelet-main
  • camel-launcher
  • camel-report-maven-plugin
  • camel-route-parser
  • camel-yaml-dsl
  • camel-yaml-dsl-deserializers
  • camel-yaml-dsl-maven-plugin
  • coverage
  • docs
  • dummy-component

Changed properties: smack-version

Skip-tests mode would test 10 modules (2 direct + 8 downstream), skip tests for 28 (generated code, meta-modules)

Modules Scalpel would test (10)
  • camel-jbang-mcp
  • camel-jbang-plugin-mcp
  • camel-jbang-plugin-route-parser
  • camel-jbang-plugin-tui
  • camel-jbang-plugin-validate
  • camel-launcher-container
  • camel-xmpp
  • camel-yaml-dsl-validator
  • camel-yaml-dsl-validator-maven-plugin
  • docs
Modules with tests skipped (28)
  • apache-camel
  • camel-allcomponents
  • camel-catalog
  • camel-catalog-console
  • camel-catalog-lucene
  • camel-catalog-maven
  • camel-catalog-suggest
  • camel-componentdsl
  • camel-csimple-maven-plugin
  • camel-endpointdsl
  • camel-endpointdsl-support
  • camel-itest
  • camel-jbang-core
  • camel-jbang-it
  • camel-jbang-main
  • camel-jbang-plugin-edit
  • camel-jbang-plugin-generate
  • camel-jbang-plugin-kubernetes
  • camel-jbang-plugin-test
  • camel-kamelet-main
  • camel-launcher
  • camel-report-maven-plugin
  • camel-route-parser
  • camel-yaml-dsl
  • camel-yaml-dsl-deserializers
  • camel-yaml-dsl-maven-plugin
  • coverage
  • dummy-component

ℹ️ Shadow mode — Scalpel observes but does not affect test execution. Learn more

⚠️ Some tests are disabled on GitHub Actions (@DisabledIfSystemProperty(named = "ci.env.name")) and require manual verification:

  • components/camel-xmpp: 6 test(s) disabled on GitHub Actions
All tested modules (38 modules)
  • Camel :: All Components Sync point
  • Camel :: Assembly
  • Camel :: Catalog :: CSimple Maven Plugin (deprecated)
  • Camel :: Catalog :: Camel Catalog
  • Camel :: Catalog :: Camel Report Maven Plugin
  • Camel :: Catalog :: Camel Route Parser
  • Camel :: Catalog :: Console
  • Camel :: Catalog :: Dummy Component
  • Camel :: Catalog :: Lucene (deprecated)
  • Camel :: Catalog :: Maven
  • Camel :: Catalog :: Suggest
  • Camel :: Component DSL
  • Camel :: Coverage
  • Camel :: Docs
  • Camel :: Endpoint DSL
  • Camel :: Endpoint DSL :: Support
  • Camel :: Integration Tests
  • Camel :: JBang :: Core
  • Camel :: JBang :: Integration tests
  • Camel :: JBang :: MCP
  • Camel :: JBang :: Main
  • Camel :: JBang :: Plugin :: Edit
  • Camel :: JBang :: Plugin :: Generate
  • Camel :: JBang :: Plugin :: Kubernetes
  • Camel :: JBang :: Plugin :: MCP
  • Camel :: JBang :: Plugin :: Route Parser
  • Camel :: JBang :: Plugin :: TUI
  • Camel :: JBang :: Plugin :: Testing
  • Camel :: JBang :: Plugin :: Validate
  • Camel :: Kamelet Main
  • Camel :: Launcher
  • Camel :: Launcher :: Container
  • Camel :: XMPP
  • Camel :: YAML DSL
  • Camel :: YAML DSL :: Deserializers
  • Camel :: YAML DSL :: Maven Plugins
  • Camel :: YAML DSL :: Validator
  • Camel :: YAML DSL :: Validator Maven Plugin

⚙️ View full build and test results

@davsclaus davsclaus added this to the 4.22.0 milestone Jul 20, 2026
@davsclaus
davsclaus merged commit 33d9cd1 into apache:main Jul 20, 2026
6 checks passed
@apupier

apupier commented Jul 21, 2026

Copy link
Copy Markdown
Contributor
  • The module's container-based integration tests (*IT, XMPP server via test-infra) fail in my environment with SSLHandshakeException: Remote host terminated the handshakeidentically on current main with Smack 4.3.5 (verified by running the baseline first: same 1 failure + 6 errors, same exception). So their outcome is unchanged by this upgrade; the pre-existing test-server TLS issue can be looked at separately.

there was a single test failure with previous version based on this comment for me #22867 (comment)

@oscerd
oscerd deleted the fix/CAMEL-23562 branch July 21, 2026 07:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants