-
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
roachpb: clarify ownership of BatchRequests #75452
Comments
yuzefovich
added
the
C-cleanup
Tech debt, refactors, loose ends, etc. Solution not expected to significantly change behavior.
label
Jan 24, 2022
yuzefovich
added a commit
to yuzefovich/cockroach
that referenced
this issue
Jun 30, 2022
Previously, for all incomplete requests in a batch we'd allocate new Get and Scan requests (since - due to a known issue cockroachdb#75452 - at the moment the lifecycle of the requests is not clearly defined, so we're not allowed to modify them). However, we can reuse the Get requests since they won't be ever modified (i.e. they are either complete or incomplete, and, unlike for Scan requests, the start key won't ever be shifted), so this commit takes advantage of this observation. Release note: None
yuzefovich
added a commit
to yuzefovich/cockroach
that referenced
this issue
Jul 6, 2022
Previously, for all incomplete requests in a batch we'd allocate new Get and Scan requests (since - due to a known issue cockroachdb#75452 - at the moment the lifecycle of the requests is not clearly defined, so we're not allowed to modify them). However, we can reuse the Get requests since they won't be ever modified (i.e. they are either complete or incomplete, and, unlike for Scan requests, the start key won't ever be shifted), so this commit takes advantage of this observation. Release note: None
craig bot
pushed a commit
that referenced
this issue
Jul 6, 2022
83684: kvstreamer: reuse incomplete Get requests on resume batches r=yuzefovich a=yuzefovich Previously, for all incomplete requests in a batch we'd allocate new Get and Scan requests (since - due to a known issue #75452 - at the moment the lifecycle of the requests is not clearly defined, so we're not allowed to modify them). However, we can reuse the Get requests since they won't be ever modified (i.e. they are either complete or incomplete, and, unlike for Scan requests, the start key won't ever be shifted), so this commit takes advantage of this observation. Release note: None 83709: pkg/util/tracing: Add hidden tag group, make server responsible for sorting. r=benbardin a=benbardin Release note: none This moves all tags marked as "hidden" into a single tag group at the UI layer. This declutters the trace page a little bit and makes it easier to pick out more important information. <img width="1620" alt="Screen Shot 2022-07-01 at 12 37 07 PM" src="https://user-images.githubusercontent.com/261508/176937757-bf8ac920-9e28-4908-8de4-1fbc077fd2c7.png"> 83834: outliers: extract a Registry interface. r=matthewtodd a=matthewtodd This is a pure mechanical refactoring, preparing us for #81021, where we'll move outlier processing off of the hot execution path. The idea is that the outside world will continue to talk to us as a Registry, but we'll now have a seam into which we can insert some asynchrony. Release note: None Co-authored-by: Yahor Yuzefovich <[email protected]> Co-authored-by: Ben Bardin <[email protected]> Co-authored-by: Matthew Todd <[email protected]>
We have marked this issue as stale because it has been inactive for |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
While working on the
Streamer
library, I assumed that it was ok to reuse the sameRequestUnion
,GetRequest
, andScanRequest
objects to issue a follow-up request with the ResumeSpans. However, gRPC race transport began complaining about data races. As it turns out at the moment neither the server nor the client is allowed to modifyBatchRequest
s. The comment suggests that it should be ok for the client to reuse the requests, so we should get there.Some commentary from Andrei:
roachpb.Keys
from requests, so they can't be mutated. It's kind of a mess.Clone
them. There's probably cloning that's both insufficient and unnecessary.Jira issue: CRDB-12678
The text was updated successfully, but these errors were encountered: