-
Notifications
You must be signed in to change notification settings - Fork 72
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
Delayed Write: calculate delay based on current state #276
Comments
consider adding the option to the c- API and to the java |
Yuval-Ariel
added a commit
that referenced
this issue
Dec 14, 2022
Calculate the delayed write rate based on the current state of the CF based on the value of delayed_write_rate that the user initially set. The calculation reduces speed linearly with regards to how much the CF has exceeded the slowdown conditions (L0 files and pending bytes). The slowdown for writing to the last memtable (when theres more than 3) is 10 fold
Yuval-Ariel
added a commit
that referenced
this issue
Dec 14, 2022
Calculate the delayed write rate based on the current state of the CF based on the value of delayed_write_rate that the user initially set. The calculation reduces speed linearly with regards to how much the CF has exceeded the slowdown conditions (L0 files and pending bytes). The slowdown for writing to the last memtable (when theres more than 3) is 10 fold
QA passed on ffe9b9c |
@erez-speedb , regarding the 25% deterioration in the fillup of the small obj test: |
Yuval-Ariel
added a commit
that referenced
this issue
Dec 19, 2022
Calculate the delayed write rate based on the current state of the CF based on the value of delayed_write_rate that the user initially set. The calculation reduces speed linearly with regards to how much the CF has exceeded the slowdown conditions (L0 files and pending bytes). The slowdown for writing to the last memtable (when theres more than 3) is 10 fold
Yuval-Ariel
added a commit
that referenced
this issue
Dec 20, 2022
Calculate the delayed write rate based on the current state of the CF based on the value of delayed_write_rate that the user initially set. The calculation reduces speed linearly with regards to how much the CF has exceeded the slowdown conditions (L0 files and pending bytes). The slowdown for writing to the last memtable (when theres more than 3) is 10 fold
Yuval-Ariel
added a commit
that referenced
this issue
May 1, 2023
Calculate the delayed write rate based on the current state of the CF based on the value of delayed_write_rate that the user initially set. The calculation reduces speed linearly with regards to how much the CF has exceeded the slowdown conditions (L0 files and pending bytes). The slowdown for writing to the last memtable (when theres more than 3) is 10 fold
Yuval-Ariel
added a commit
that referenced
this issue
May 4, 2023
Calculate the delayed write rate based on the current state of the CF based on the value of delayed_write_rate that the user initially set. The calculation reduces speed linearly with regards to how much the CF has exceeded the slowdown conditions (L0 files and pending bytes). The slowdown for writing to the last memtable (when theres more than 3) is 10 fold
udi-speedb
pushed a commit
that referenced
this issue
Nov 13, 2023
Calculate the delayed write rate based on the current state of the CF based on the value of delayed_write_rate that the user initially set. The calculation reduces speed linearly with regards to how much the CF has exceeded the slowdown conditions (L0 files and pending bytes). The slowdown for writing to the last memtable (when theres more than 3) is 10 fold
udi-speedb
pushed a commit
that referenced
this issue
Nov 15, 2023
Calculate the delayed write rate based on the current state of the CF based on the value of delayed_write_rate that the user initially set. The calculation reduces speed linearly with regards to how much the CF has exceeded the slowdown conditions (L0 files and pending bytes). The slowdown for writing to the last memtable (when theres more than 3) is 10 fold
udi-speedb
pushed a commit
that referenced
this issue
Dec 3, 2023
Calculate the delayed write rate based on the current state of the CF based on the value of delayed_write_rate that the user initially set. The calculation reduces speed linearly with regards to how much the CF has exceeded the slowdown conditions (L0 files and pending bytes). The slowdown for writing to the last memtable (when theres more than 3) is 10 fold
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Owner: yuval
as can be seen in the analysis in #154 (comment) , the current mechanism which calculates the delayed write rate needs improvement.
the current delay rate is calculated in SetupDelay in db/column_family.cc. (called from RecalculateWriteStallConditions)
the problem with the current implementation is that the delayed write rate (DWR from now) is calculated based on the changes in compaction pending bytes between the current and previous call to RecalculateWriteStallConditions (which is called on every InstallSuperVersion ). If compaction pending bytes is less than the prev then it increases the current DWR by 25% and if equal or greater than the prev then it reduces the DWR by 20%.
so no matter by how much the state has changed, the DWR is always changed by the same amount.
furthermore, these changes are bigger the closer we are to the original (user) DWR, e.g. reduce by 20Mb/s from 100Mb/s versus reduce by 2 Mb/s from 10MB/s. so the closer we are to the stop limitation, the less we change the amount by which we delay which is not what we want. we'd like the delay to be small at small violations of the limitations (L0 files, compaction pending bytes, memory) and increase the delay by bigger quantities as we get closer to the stop limitations.
We propose to calculate the DWR based on by how much we're currently in a violation of the limitation and calculate according to the user DWR and not the previously calculated DWR. e.g. if the user DWR is 100MB/s, L0 slowdown is set to 10 and stop is set to 20 files, and there are 14 L0 files:
there are 10 steps until stop. so each step toward the stop is 10MB/s reduction from the delayed rate the user specified and the other way when increasing the write rate.
10 L0 files - 100 Mb/s
11 L0 files - 90 Mb/s
until total stop at 20 L0 files.
same solution for compaction pending bytes and memtables.
The text was updated successfully, but these errors were encountered: