chore: add SonarCloud CPD exclusions for unavoidable duplication#22479
Open
gnodet wants to merge 1 commit intoapache:mainfrom
Open
chore: add SonarCloud CPD exclusions for unavoidable duplication#22479gnodet wants to merge 1 commit intoapache:mainfrom
gnodet wants to merge 1 commit intoapache:mainfrom
Conversation
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Contributor
|
🌟 Thank you for your contribution to the Apache Camel project! 🌟 🐫 Apache Camel Committers, please review the following items:
|
davsclaus
approved these changes
Apr 8, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds
sonar.cpd.exclusionsto the rootpom.xmlto exclude modules with unavoidable code duplication from SonarCloud Copy-Paste Detection (CPD).Excluded modules:
camel-jackson3/camel-jackson3xml(~2,200 lines): These are forks of the Jackson v2 modules (camel-jackson/camel-jacksonxml) adapted for the Jackson 3.x API. The duplication between v2 and v3 variants is unavoidable since they target different major versions of Jackson with incompatible APIs.camel-test-junit6(~4,000 lines): This is a copy ofcamel-test-junit5with package renames for the JUnit 6 migration. The duplication is intentional and temporary until JUnit 5 support is eventually removed.These exclusions should bring the new code duplication metric below the 3% quality gate threshold (currently at 5.58%).
Test plan
Claude Code on behalf of Guillaume Nodet