Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] <title> In rulesList, The un-matching request will cause normal requests to fail #5588

Open
1 task done
creabob opened this issue Jul 4, 2024 · 6 comments
Open
1 task done
Labels
type: bug Something isn't working

Comments

@creabob
Copy link

creabob commented Jul 4, 2024

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

this is my rule setting in modifyResponse plugin
image
this is matching case
image
this is un-matching case without add body info
image
but after un-matching case, the matching case become un-match
image
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

ShenYu version(s):
master

Debug logs

this is the logs under matching case but un-matching and without modifyResponse rule success match info.
image

Anything else?

i have debug in this case, find some questions in this line,
why caches an empty ruleData when not match rules.
image
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?

@creabob creabob added the type: bug Something isn't working label Jul 4, 2024
@creabob
Copy link
Author

creabob commented Jul 4, 2024

besides, This problem not only exists in this plugin

@moremind
Copy link
Member

moremind commented Jul 5, 2024

please close rule cache in shenyu-bootstrap.yml

@creabob
Copy link
Author

creabob commented Jul 5, 2024

please close rule cache in shenyu-bootstrap.yml

so, it is recommended to turn on this rule cache function?

@moremind
Copy link
Member

moremind commented Jul 6, 2024

please close rule cache in shenyu-bootstrap.yml

so, it is recommended to turn on this rule cache function?

if your rule just exist url condition, you can turn on

@creabob
Copy link
Author

creabob commented Jul 17, 2024

If I want to use the cache not only under the rules of the url condition, is it supported now?

@moremind
Copy link
Member

moremind commented Jul 19, 2024

If I want to use the cache not only under the rules of the url condition, is it supported now?
next version

@moremind moremind reopened this Jul 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants