-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
perf: redis block with keys command #1423
Conversation
Signed-off-by: rfyiamcool <[email protected]>
Apply Sweep Rules to your PR?
|
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## main #1423 +/- ##
========================================
+ Coverage 4.54% 4.98% +0.44%
========================================
Files 49 49
Lines 4140 4152 +12
========================================
+ Hits 188 207 +19
+ Misses 3940 3933 -7
Partials 12 12 ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When using the Keys command, be aware that it can cause performance problems in a database with a large number of keys because it requires scanning the entire key space to find a matching key. In a production environment, the SCAN command is recommended because it is designed to iterate over large databases more efficiently.
summary
pervent redis block when use
keys *
command to request redis.