WW-2963 default-action-ref fails to find wildcard named actions#1614
Open
lukaszlenart wants to merge 2 commits intomainfrom
Open
WW-2963 default-action-ref fails to find wildcard named actions#1614lukaszlenart wants to merge 2 commits intomainfrom
lukaszlenart wants to merge 2 commits intomainfrom
Conversation
When default-action-ref names an action that only exists as a wildcard pattern (e.g., "movie-list" matching "movie-*"), the fallback now tries wildcard matching after the exact map lookup fails. This mirrors the exact→wildcard resolution already used for request action names. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
…igInNamespace Extract default-action-ref resolution into findDefaultActionConfig() and replace the deeply nested if-pyramid with early returns, reducing the nesting depth from 5 to 1 to satisfy Sonar's complexity threshold. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com> Made-with: Cursor
|
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
Fixes WW-2963
default-action-reffallback now resolves via wildcard matching when the exact action map lookup failsRoot Cause
In
DefaultConfiguration.RuntimeConfigurationImpl.findActionConfigInNamespace(), the default-action-ref fallback only didactions.get(defaultActionRef)— an exact key lookup. If the default ref name (e.g.,"movie-input") only matched a wildcard pattern (e.g.,"movie-*"), the lookup returnednulland the request failed with a 404.Fix
After the exact lookup fails for the default action ref, also try the wildcard matcher:
Test plan
ConfigurationTest#testDefaultActionRefWithWildcard— default-action-ref resolves via wildcard matchingConfigurationTest#testDefaultActionRefWithExactMatch— default-action-ref resolves via exact match (pre-existing behavior)ConfigurationTest#testDefaultActionRefWithWildcardNoMatch— returns null when default-action-ref matches neitherConfigurationTestsuite passes with no regressions🤖 Generated with Claude Code