-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
backupccl: mark backup ExportRequests as Bulk priority #79086
Conversation
I'm dropping the AddSSTable part from this and addressing it in #79126. |
changed the source on the backup reqs to FROM_SQL while I'm here. RFAL. |
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.
Reviewed 1 of 2 files at r1, 2 of 2 files at r3.
Reviewable status: complete! 0 of 0 LGTMs obtained (waiting on @dt and @stevendanna)
pkg/ccl/backupccl/backup_processor.go, line 415 at r3 (raw file):
Priority: int32(admission.BulkNormalPri), CreateTime: timeutil.Now().UnixNano(), Source: roachpb.AdmissionHeader_FROM_SQL,
is this actually originating in SQL? That is, will there be distsql processing upstream of this?
pkg/util/admission/work_queue.go, line 157 at r3 (raw file):
// BulkNormalPri is bulk priority work from bulk jobs, which could be run due // to user submissions or be automatic. BulkNormalPri WorkPriority = -49
how about -25. Leaving gaps on both sides allows us to squeeze other things in there in the future.
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.
Reviewable status: complete! 0 of 0 LGTMs obtained (waiting on @dt, @stevendanna, and @sumeerbhola)
pkg/ccl/backupccl/backup_processor.go, line 415 at r3 (raw file):
Previously, sumeerbhola wrote…
is this actually originating in SQL? That is, will there be distsql processing upstream of this?
this is a distsql processor, if that's what you mean?
This is a distsql processor that is running in a distsql flow, which is launched by a job resumer from a job registry, which is something sql processes start at boot. The job is running because a sql query wrote it.
pkg/util/admission/work_queue.go, line 157 at r3 (raw file):
Previously, sumeerbhola wrote…
how about -25. Leaving gaps on both sides allows us to squeeze other things in there in the future.
ah, good call. How do you feel about -40 or -30?
Reelase note: none.
Marking this 22.1 backport, and I sorta think this should get a 21.2 backport as well (along with the col backfill and addstable enrollments in admission control, so that we can say all bulk work has the headers)? |
@sumeerbhola is it safe to backport new named priorities such as the one here? |
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.
@sumeerbhola is it safe to backport new named priorities such as the one here?
Not Sumeer, but I believe that should be fine -- the priority is an int32 field, not an enum, so arbitrary values will be handled correctly:
cockroach/pkg/roachpb/api.proto
Line 2485 in 5abeffa
int32 priority = 1; |
This is a distsql processor that is running in a distsql flow, which is launched by a job resumer from a job registry, which is something sql processes start at boot. The job is running because a sql query wrote it.
That's how I think about this too.
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 priority is an int32 field, not an enum, so arbitrary values will be handled correctly
correct.
Reviewed 1 of 1 files at r4.
Reviewable status: complete! 1 of 0 LGTMs obtained (waiting on @dt, @erikgrinaker, and @stevendanna)
pkg/ccl/backupccl/backup_processor.go, line 415 at r3 (raw file):
this is a distsql processor, if that's what you mean?
yep. thanks.
pkg/util/admission/work_queue.go, line 157 at r3 (raw file):
Previously, dt (David Taylor) wrote…
ah, good call. How do you feel about -40 or -30?
-30, that you have here is fine
TFTRs! bors r+ |
Build succeeded: |
Encountered an error creating backports. Some common things that can go wrong:
You might need to create your backport manually using the backport tool. error creating merge commit from ef29359 to blathers/backport-release-21.2-79086: POST https://api.github.com/repos/cockroachdb/cockroach/merges: 409 Merge conflict [] you may need to manually resolve merge conflicts with the backport tool. Backport to branch 21.2.x failed. See errors above. 🦉 Hoot! I am a Blathers, a bot for CockroachDB. My owner is otan. |
This adds a new "bulk normal" priority that is lower than normal user priority but higher than low user priority, and then assigns that priority on AddSSTable and Export requests.
Release note (bug fix): BACKUP read requests are now sent with lower admission control priority than normal traffic.
Jira issue: CRDB-14711
Epic CRDB-2264