Skip to content

fix(engine): CollectEntriesDecisionResultMapper#mapDecisionResult must always return immutable list - #3741

Merged
kthoms merged 1 commit into
mainfrom
issues/3713-immutable-collection
Sep 25, 2026
Merged

kthoms merged 1 commit into
mainfrom
issues/3713-immutable-collection

Conversation

@kthoms

@kthoms kthoms commented Sep 25, 2026

Copy link
Copy Markdown
Contributor

fixes #3713

@kthoms kthoms added this to the 2.1.6 milestone Sep 25, 2026
Copilot AI lite review requested due to automatic review settings September 25, 2026 05:56
@kthoms kthoms added the noteworthy Should be documented in the release notes label Sep 25, 2026
@github-actions github-actions Bot added documentation Improvements or additions to documentation lang:java Pull requests that update Java code scope:core-api Changes to the core API: engine, dmn-engine, feel-engine, REST API, OpenAPI scope:tests Changes affecting only test code labels Sep 25, 2026

Copilot AI 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.

Copilot review overview

🔵 Needs a closer look

Add an UnsupportedOperationException assertion for mutation of the empty result.

Review effort: Lite
Findings: None

What changed in this PR

Updates DMN collectEntries mapping to return immutable lists.

Changes:

  • Makes mapped results unmodifiable.
  • Adds mapper behavior and immutability tests.
  • Documents license-header guidance.
File Summary
engine/​src/​test/​java/​org/​operaton/​bpm/​engine/​impl/​dmn/​result/​CollectEntriesDecisionResultMapperTest.java Tests mapping and immutability; the empty-result case still needs a mutation rejection assertion.
engine/​src/​main/​java/​org/​operaton/​bpm/​engine/​impl/​dmn/​result/​CollectEntriesDecisionResultMapper.java Enforces immutable mapped results.
AGENTS.md Adds license-header guidance.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@sonarqubecloud

Copy link
Copy Markdown

@kthoms
kthoms merged commit d0db75f into main Sep 25, 2026
17 checks passed
@kthoms
kthoms deleted the issues/3713-immutable-collection branch September 25, 2026 19:32
kthoms added a commit that referenced this pull request Sep 25, 2026
…t always return immutable list (#3741)

(cherry picked from commit d0db75f)
@kthoms

kthoms commented Sep 25, 2026

Copy link
Copy Markdown
Contributor Author

Cherry-picked for 2.1.6

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

Labels

documentation Improvements or additions to documentation lang:java Pull requests that update Java code noteworthy Should be documented in the release notes scope:core-api Changes to the core API: engine, dmn-engine, feel-engine, REST API, OpenAPI scope:tests Changes affecting only test code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Behaviour of list of collected DMN results is inconsistent

2 participants