-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
roachprod: changes in promhelper client for modify labels #124460
roachprod: changes in promhelper client for modify labels #124460
Conversation
e8b1b11
to
be97a53
Compare
e41e003
to
87646e9
Compare
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.
Can you explain to me why we need to update the config this way? By the time we call cluster.Start
the first time, we should already the test name and the run ID, is there a reason we can't add it all in one shot?
87646e9
to
2787ec1
Compare
When a test is run, a new label has to be added to prometheus. To do this, we need to first get the current config, add the new label and update the config. This change does that. Post this change, the label update will be integrated. The change also needs a change in httputil client GET function to support headers being passed. Fixes: cockroachdb#124319 Epic: none
2787ec1
to
2413158
Compare
If a cluster is reused, do we always stop the nodes and then add the tags and start? If that is the case, we should be good without this change. |
Yes, that's correct. If we reuse a cluster, we call cockroach/pkg/cmd/roachtest/test_runner.go Lines 636 to 637 in 99d7687
This eventually calls cockroach/pkg/roachprod/install/cluster_synced.go Lines 547 to 549 in 6918532
Same with removing labels. We call this at the end of cockroach/pkg/cmd/roachtest/test_runner.go Lines 1031 to 1033 in 99d7687
|
Thats great! Then we should be good without this change. I will close this PR! Thanks for pointing out!! |
When a test is run, a new label has to be added to prometheus. To do this, we need to first get the current config, add the new label and update the config. This change does that. Post this change, the label update will be integrated.
The change also needs a change in httputil client GET function to support headers being passed.
Fixes: #124319
Epic: none