Add nullChannel DSL element to Groovy DSL#10600
Merged
artembilan merged 3 commits intospring-projects:mainfrom Nov 20, 2025
Merged
Add nullChannel DSL element to Groovy DSL#10600artembilan merged 3 commits intospring-projects:mainfrom
artembilan merged 3 commits intospring-projects:mainfrom
Conversation
The Groovy DSL was missing support for the nullChannel, which is a special channel that discards messages (acts like /dev/null). This prevents users from using nullChannel in their Groovy integration flows. Add unit tests to verify: - nullChannel can be used at the end of a flow - nullChannel can be used after transform operations - Messages are properly discarded without exceptions
artembilan
requested changes
Nov 19, 2025
...ain/groovy/org/springframework/integration/groovy/dsl/GroovyIntegrationFlowDefinition.groovy
Show resolved
Hide resolved
...groovy/src/test/groovy/org/springframework/integration/groovy/dsl/test/GroovyDslTests.groovy
Outdated
Show resolved
Hide resolved
...groovy/src/test/groovy/org/springframework/integration/groovy/dsl/test/GroovyDslTests.groovy
Show resolved
Hide resolved
...groovy/src/test/groovy/org/springframework/integration/groovy/dsl/test/GroovyDslTests.groovy
Show resolved
Hide resolved
The original implementation had left the beans as dead code after initial tests were deemed to weak. However, the dynamic flow increased the amount of code to maintain. Changes include: - Replace dynamic flow creation with `@Bean` configuration methods - Add shared `nullCheckWireTapChannel` bean for message verification - Simplify test methods by using autowired channels - Add `@since 7.0.1` annotation to `nullChannel()` method documentation
artembilan
requested changes
Nov 19, 2025
...ain/groovy/org/springframework/integration/groovy/dsl/GroovyIntegrationFlowDefinition.groovy
Show resolved
Hide resolved
NullChannel for groovy DSL `see` and `since` annotation were moved to correct location
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.
The Groovy DSL was missing support for the nullChannel, which is a special channel that discards messages (acts like /dev/null). This prevents users from using nullChannel in their Groovy integration flows.
Add unit tests to verify: