Conversation
…p cleanup Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…e saving
Empty collections ([] and {}) were persisting in the workflow definition
when parameters were deleted or never configured, causing them to appear
in both the workflow editor and action perform method.
- Add removeEmptyCollections() that recursively strips empty maps/lists
from the parameter map before persisting the workflow definition
- Make removeParameter() self-cleaning by cascading empty-map removal
through its existing recursion
- Called in all four save paths: delete/update for both workflow nodes
and cluster elements
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…eEmptyCollections Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
Pull request overview
This PR prevents empty maps/lists ({} / []) from being persisted in workflow node (and cluster element) parameter maps by stripping empty collections before saving workflow definitions, so deleted/unconfigured parameters don’t reappear in the editor or action execution.
Changes:
- Added
removeEmptyCollections()and invoked it in all update/delete save paths (workflow nodes + cluster elements). - Enhanced
removeParameter()to cascade-remove now-empty parent maps during its recursion. - Extended/adjusted facade tests to cover empty-collection cleanup scenarios.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
.../WorkflowNodeParameterFacadeTest.java |
Adds tests verifying empty parent maps/lists are removed after parameter deletion and that non-empty collections are preserved. |
.../WorkflowNodeParameterFacadeImpl.java |
Adds removeEmptyCollections() and calls it before persisting; updates removeParameter() to remove empty parent maps. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
...rc/main/java/com/bytechef/platform/configuration/facade/WorkflowNodeParameterFacadeImpl.java
Show resolved
Hide resolved
...rc/main/java/com/bytechef/platform/configuration/facade/WorkflowNodeParameterFacadeImpl.java
Show resolved
Hide resolved
|
marko-kriskovic
approved these changes
Feb 20, 2026
marko-kriskovic
approved these changes
Feb 20, 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.



Empty collections ([] and {}) were persisting in the workflow definition
when parameters were deleted or never configured, causing them to appear
in both the workflow editor and action perform method.
from the parameter map before persisting the workflow definition
through its existing recursion
and cluster elements
Co-Authored-By: Claude Opus 4.6 noreply@anthropic.com