-
Notifications
You must be signed in to change notification settings - Fork 4k
mmaprototype: add tracing to testing for rebalanceStores #157133
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
Conversation
af0a3a3 to
b852857
Compare
sumeerbhola
left a comment
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 reviewed 3 of 3 files at r2, all commit messages.
Reviewable status:complete! 1 of 0 LGTMs obtained (waiting on @aa-joshi, @Abhinav1299, @arjunmahishi, @jasonlmfong, and @wenyihu6)
wenyihu6
left a comment
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.
mod the comment
Reviewable status:
complete! 1 of 0 LGTMs obtained (waiting on @aa-joshi, @Abhinav1299, @arjunmahishi, and @jasonlmfong)
pkg/kv/kvserver/allocator/mmaprototype/cluster_state_test.go line 524 at r2 (raw file):
rng := rand.New(rand.NewSource(0)) dsm := newDiversityScoringMemo() tr := tracing.NewTracer()
do we need to call tr.Close in the end like this
| defer e.close() |
b852857 to
0c5fa80
Compare
tbg
left a comment
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 (and 1 stale) (waiting on @aa-joshi, @Abhinav1299, @arjunmahishi, @jasonlmfong, @sumeerbhola, and @wenyihu6)
pkg/kv/kvserver/allocator/mmaprototype/cluster_state_test.go line 524 at r2 (raw file):
Previously, wenyihu6 (Wenyi Hu) wrote…
do we need to call tr.Close in the end like this
?
defer e.close()
We should, thanks. Added.
I'd like to make the trace events emitted from deterministic multi-metric allocator tests part of the expected test outputs. I realized there wasn't a standardized deterministic and barebones output format, so I added one. Epic: none
close tracer, ./dev gen bazel, set tracer redactable (make sure we get good debug output in production)
0c5fa80 to
754bacd
Compare
wenyihu6
left a comment
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! 1 of 0 LGTMs obtained (and 1 stale) (waiting on @aa-joshi, @Abhinav1299, @arjunmahishi, @jasonlmfong, and @sumeerbhola)
157132: tracing: add minimal format suitable for datadriven tests r=wenyihu6 a=tbg I'd like to make the trace events emitted from deterministic multi-metric allocator tests part of the expected test outputs. I realized there wasn't a standardized deterministic and barebones output format, so I added one. In the test I have in mind I'll probably condense the file:line prefix further, but it seemed unsavory to slap regexp transformations into the tracing packages, and unfortunately that is required to solve the problem if we want to avoid changing the `log` package. Related to #157133. Epic: none 157150: cloud/azure: add optional azure client caching r=dt a=dt This adds a signle-slot, process-wide in-memory cache of the most recently used azure SDK storage client allowing subsequent attempts to open clients with the same configuration to reuse the already open client. This can allow the SDK's internal caching of things like IMDS tokens to be used across separate CRDB operations on separate files which currently each open their own client. This can be particularly impactful for avoiding hitting the IMDS rate limit. Release note: none. Epic: none. 157217: mmaprototype: move rebalanceStores to its own file r=wenyihu6 a=tbg Epic: CRDB-55052 Co-authored-by: Tobias Grieger <[email protected]> Co-authored-by: David Taylor <[email protected]>
|
TFTR! bors r+ |
|
Ugh, wanted to unstack this before merging and squash the fixup commit. Making a mental note to add do-not-merge label when in that state. |
This PR adds the basic capability to exercise rebalanceStores through
TestClusterState. It does this by moving rebalanceStores from allocatorState to
clusterState, which is a small and mostly mechanical refactor.
The immediate motivation behind this change is being able to exercise
the functionality for #156776 while it is being added, while being able
to see the internal tracepoints as well.
Informs #156776.
Epic: CRDB-55052