Skip to content

build(engine): Use commons-collections4 in tests - #3103

Merged
kthoms merged 1 commit into
mainfrom
backport/fluxnova-484-commons-collections4
Jun 11, 2026
Merged

kthoms merged 1 commit into
mainfrom
backport/fluxnova-484-commons-collections4

Conversation

@hauptmedia

@hauptmedia hauptmedia commented Jun 9, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Backports Fluxnova change unit 484 to replace the legacy test-scope Apache Commons Collections 3.x dependency with Commons Collections 4 in the engine test setup.

The change updates Operaton's internal dependency management from commons-collections:commons-collections:3.2.2 to org.apache.commons:commons-collections4:4.4, switches the engine test dependency to the new artifact, and updates the two affected test imports from org.apache.commons.collections.map.HashedMap to org.apache.commons.collections4.map.HashedMap.

Reviewer notes

This is a test-scope dependency modernization. The direct engine dependency is declared with <scope>test</scope>, so the change affects the engine test classpath and the internal BOM entry, not Operaton runtime behavior.

The only Java code changes are import migrations in two History Cleanup test classes. The tests still exercise the same query/setup logic; the map implementation is the Commons Collections 4 equivalent of the previous Commons Collections 3 HashedMap type.

Repo-wide follow-up check: qa/test-old-engine/pom.xml still contains commons-collections:commons-collections inside the old-engine profile. That is intentionally left unchanged here because this profile imports the historical Operaton BOM 1.0.0-beta-5 and resolves commons-collections:3.2.2:test for old-engine compatibility testing. It is not using the engine test dependency changed by this PR. The remaining root pom.xml reference is only a versions-maven-plugin rule for the old coordinate.

Operaton adaptation:

  • Fluxnova's internal-dependencies/pom.xml maps to Operaton's bom/internal-dependencies/pom.xml.
  • Fluxnova package paths were adapted to Operaton package paths.
  • Operaton's tests are already JUnit 5, so no test framework migration was needed.

Attribution

Backported from Fluxnova:

Verification

./mvnw -pl engine -am -Dskip.frontend.build=true -DskipTests dependency:tree -Dincludes=commons-collections:commons-collections,org.apache.commons:commons-collections4 -DoutputType=text

Result: operaton-engine resolves org.apache.commons:commons-collections4:jar:4.4:test.

./mvnw -pl engine -am -DskipTests -Dskip.frontend.build=true install

Result: BUILD SUCCESS.

./mvnw -pl engine -Dskip.frontend.build=true -Dtest=HistoricInstanceForCleanupQueryTest,HistoricBatchManagerBatchesForCleanupTest -Dsurefire.failIfNoSpecifiedTests=false -DfailIfNoTests=false test

Result: 5 tests run, 0 failures, 0 errors, 0 skipped.

./mvnw -f qa/test-old-engine/pom.xml -Pold-engine -Dskip.frontend.build=true -DskipTests dependency:tree -Dincludes=commons-collections:commons-collections,org.apache.commons:commons-collections4 -DoutputType=text

Result: operaton-qa-old-engine intentionally still resolves commons-collections:commons-collections:jar:3.2.2:test from the historical old-engine BOM.

git diff --check

Result: no whitespace issues.

Backported commit 3fea119d15143c364c078ec3c5cc0ea6ed44a3a6 from repository https://github.com/finos/fluxnova-bpm-platform.

Original author: Sowmya, HL <[email protected]>

Operaton adaptation: Applied the test dependency modernization to Operaton's BOM and engine test dependency, and updated the equivalent Operaton test imports from org.apache.commons.collections.map.HashedMap to org.apache.commons.collections4.map.HashedMap. The source commit used Fluxnova package paths; Operaton tests are already JUnit 5.

Backport change unit: 484
@hauptmedia hauptmedia added dependencies Changes that update a dependency scope:build Changes affecting the build, e.g. Maven configuration, shell scripts. dependencies:maven Updates of Maven dependencies backport:fluxnova Changes backported from Fluxnova scope:tests Changes affecting only test code labels Jun 9, 2026
@github-actions github-actions Bot added lang:java Pull requests that update Java code scope:core-api Changes to the core API: engine, dmn-engine, feel-engine, REST API, OpenAPI labels Jun 9, 2026
@sonarqubecloud

sonarqubecloud Bot commented Jun 9, 2026

Copy link
Copy Markdown

@kthoms kthoms removed scope:core-api Changes to the core API: engine, dmn-engine, feel-engine, REST API, OpenAPI scope:build Changes affecting the build, e.g. Maven configuration, shell scripts. labels Jun 11, 2026
@kthoms kthoms added this to the 2.1.2 milestone Jun 11, 2026
@kthoms kthoms added the backport:patch-release Should be ported back to the latest feature release branch. label Jun 11, 2026
@kthoms
kthoms merged commit e9a4944 into main Jun 11, 2026
22 checks passed
@kthoms
kthoms deleted the backport/fluxnova-484-commons-collections4 branch June 11, 2026 15:25
kthoms pushed a commit that referenced this pull request Jun 11, 2026
Backported commit 3fea119d15143c364c078ec3c5cc0ea6ed44a3a6 from repository https://github.com/finos/fluxnova-bpm-platform.

Original author: Sowmya, HL <[email protected]>

Operaton adaptation: Applied the test dependency modernization to Operaton's BOM and engine test dependency, and updated the equivalent Operaton test imports from org.apache.commons.collections.map.HashedMap to org.apache.commons.collections4.map.HashedMap. The source commit used Fluxnova package paths; Operaton tests are already JUnit 5.

Backport change unit: 484

(cherry picked from commit e9a4944)
@kthoms

kthoms commented Jun 11, 2026

Copy link
Copy Markdown
Contributor

Cherry-picked for 2.1.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:fluxnova Changes backported from Fluxnova backport:patch-release Should be ported back to the latest feature release branch. dependencies:maven Updates of Maven dependencies dependencies Changes that update a dependency lang:java Pull requests that update Java code scope:tests Changes affecting only test code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants