-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Feat fixed unit basic #1640
Feat fixed unit basic #1640
Changes from 2 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -71,3 +71,4 @@ deps | |
# include codis fe javascript lib files | ||
!codis/cmd/fe/assets/** | ||
|
||
tests/tmp | ||
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2032,6 +2032,7 @@ void DbsizeCmd::Do(std::shared_ptr<Slot> slot) { | |
if (!db) { | ||
res_.SetRes(CmdRes::kInvalidDB); | ||
} else { | ||
db->RunKeyScan(); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. pika 设计并不支持实时统计,因为扫描有锁且耗时,最好还是在后台起线程做。可以参考 docs/ops/bestPractice.md pika最佳实践之十六. 针对测试修复,可以在 tcl 脚本的 dbsize 前添加 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ok There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. update |
||
KeyScanInfo key_scan_info = db->GetKeyScanInfo(); | ||
std::vector<storage::KeyInfo> key_infos = key_scan_info.key_infos; | ||
if (key_infos.size() != 5) { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The code patch seems to add a call to As for improvement suggestions, it would be good to replace the hard-coded value |
||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 非差异化命令的错误信息应与 redis 对齐,因为客户端可能会依赖错误信息进行进一步的处理。 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ok |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -211,7 +211,7 @@ start_server {tags {"basic"}} { | |
# p.s. no way I can force NaN to test it from the API because | ||
# there is no way to increment / decrement by infinity nor to | ||
# perform divisions. | ||
} {ERR*would produce*} | ||
} {ERR*increment or decrement would overflow*} | ||
|
||
test {INCRBYFLOAT decrement} { | ||
r set foo 1 | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The code patch only includes one modification, changing an error message string from "ERRwould produce" to "ERRincrement or decrement would overflow". This change is reasonable and seems to be well-focused on a specific issue. However, it's hard to tell whether there are other bugs or improvement suggestions without more context about the surrounding code. |
||
|
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.
The provided code patch only adds a new line to the file, which includes the path "tests/tmp". It is difficult to provide any insights regarding potential bugs or improvements without more context about the purpose and functionality of this file.