-
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
Enhance StoragePerf #721
Enhance StoragePerf #721
Conversation
Not only value size. Currently, one thread could sent at most 1000 requests. We should break the limit. One task could sent N requests each time. |
Can someone explain what's the purpose of this PR? |
In this PR I have support two features:
Maybe I should update it's title. @sherman-the-tank |
CHECK_GT(interval, 0) << "qpsPerThread should not large than 1000, interval " << interval; | ||
int32_t radix = qpsPerThread / 1000; | ||
int32_t slotSize = sizeof(slots_) / sizeof(int32_t); | ||
if (qpsPerThread >= 1000) { |
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.
Maybe we don't need this if statement?
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.
Good catch & fixed :)
@@ -51,6 +82,7 @@ class Perf { | |||
CHECK(mClient_->waitForMetadReady()); | |||
client_ = std::make_unique<StorageClient>(threadPool_, mClient_.get()); | |||
time::Duration duration; | |||
static uint32_t interval = 1; |
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.
I guess you mean 100ms here? According to my understanding, you split 1 second to 10 * 100ms, and set corresponding qps of each slot.
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.
Ah, I got it.
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.
10 ms is a cycle. slots_
is the sending plan for a cycle. So it should sleep 1 ms.
Unit testing passed. |
Unit testing passed. |
1 similar comment
Unit testing passed. |
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.
Excellent!
@@ -0,0 +1,28 @@ | |||
### Storage Perf Tool | |||
|
|||
`_build/storage_perf` is the performance tool to test the storage service. |
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.
Well done
Unit testing passed. |
1 similar comment
Unit testing passed. |
* data's size per request and multi message per request * append random message * fix dangleptr's comment
#### What type of PR is this? - [ ] bug - [x] feature - [ ] enhancement #### What does this PR do? #### Which issue(s)/PR(s) this PR relates to? close vesoft-inc#3448 #### Special notes for your reviewer, ex. impact of this fix, etc: #### Additional context: #### Checklist: - [x] Documentation affected (Please add the label if documentation needs to be modified.) - [ ] Incompatible (If it is incompatible, please describe it and add corresponding label.) - [ ] Need to cherry-pick (If need to cherry-pick to some branches, please label the destination version(s).) - [x] Performance impacted: Consumes more CPU/Memory #### Release notes: Please confirm whether to reflect in release notes and how to describe: > Support segment auto-increasing id ` Migrated from vesoft-inc#3550 Co-authored-by: jakevin <30525741+jackwener@users.noreply.github.com>
In this PR, support config data's size per message and multi message per request.