[BUG] <title> In rulesList, The un-matching request will cause normal requests to fail
- Dominant language
- Java
- Stars
- 8.8k
- Forks
- 3.1k
- Avg merge
- 7d 1h
- Merged PRs (30d)
- 85
Description
### Is there an existing issue for this?
- [X] I have searched the existing issues
### Current Behavior
this is my rule setting in modifyResponse plugin
this is matching case
this is un-matching case without add body info
but after un-matching case, the matching case become un-match
this operates in orders
### Expected Behavior
Whenever the request happens, the matching scene should be matched
### Steps To Reproduce
1. in shenyu-master branch
2. set matching rules
3. happen one un-matching case
4. matching case will dismatch
### Environment
```markdown
ShenYu version(s):
master
```
### Debug logs
this is the logs under matching case but un-matching and without modifyResponse rule success match info.
### Anything else?
i have debug in this case, find some questions in this line,
why caches an empty ruleData when not match rules.
`cacheRuleData(path, emptyRuleData);`
when i delete this line ,this bug will be fixed. but i am not sure this operate is correct.
Can u introduce the original intention of this line which cache empty ruleData?
Contributor guide
No contributing guide indexed for this repository
Research direction
Start at cacheRuleData(path, emptyRuleData) in the modifyResponse plugin and reproduce the matching, un-matching, then matching request sequence described in the issue. Determine the intended handling of an empty cached rule and verify that subsequent matching requests still match, adding or updating coverage if the relevant test location can be identified.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- api, backend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100