-
Notifications
You must be signed in to change notification settings - Fork 3.9k
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
do not send diagnostics if organization is cockroach labs #20790
do not send diagnostics if organization is cockroach labs #20790
Conversation
51ba537
to
1500675
Compare
I think we might actually want to report from our own clusters but just want to indicate that they are ours, so we can filter them server-side. That way we can validate that our reporting is working as expected? |
Well, the reason I didn't go with that approach was because then we would have to send everyone's organization with each update? If that's not a big deal, I guess we could just send it and then filter on the server side? In that case, we might even want to add a column or something to mark if a cluster is Cockroach or not? That seems heavy handed. |
discussed offline and think sending a |
Cool, also going to do a schema change on the reg cluster by adding in a testing column in both the clusters and updates table. |
small nit, any reason not to call this |
Correction, I don't think we need to also include this in updates, since if at any point, a cluster becomes a CRL cluster, we should just omit it. Okay on calling this column internal. |
c9422c2
to
e2443fd
Compare
last commit is badly named and superfluous? Review status: 0 of 2 files reviewed at latest revision, all discussions resolved. Comments from Reviewable |
@andreimatei I'll fix and squash that last commit with a better message once this passes tests - I botched a rebase and pulled a hail mary to get rid of a bunch of random commits. |
3ccf11f
to
04ac51a
Compare
@dt could I get a review on this? thank you! |
@@ -224,6 +233,9 @@ func TestReportUsage(t *testing.T) { | |||
if minExpected, actual := len(params.StoreSpecs), len(r.last.Stores); minExpected > actual { | |||
return errors.Errorf("expected at least %v stores got %v", minExpected, actual) | |||
} | |||
if expected, actual := "true", r.last.internal; expected != actual { |
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.
probably want to have a test case where this is false
Review status: 0 of 2 files reviewed at latest revision, 1 unresolved discussion, all commit checks successful. pkg/server/updates_test.go, line 236 at r1 (raw file): Previously, couchand (Andrew Couch) wrote…
So the reason why I do it this way is that in this TestReportUsage function, I actually set the organization to Cockroach Labs, and once that's done, it can't go back to false anymore. I do test whether or not things are initialized as false in the test case above under TestCheckVersion? Is that adequate? Comments from Reviewable |
Review status: 0 of 2 files reviewed at latest revision, 1 unresolved discussion, all commit checks successful. pkg/server/updates_test.go, line 236 at r1 (raw file): Previously, dianasaur323 (Diana Hsieh) wrote…
Oh, I had missed that. Thanks! Comments from Reviewable |
ok for me to merge? Could I get an LGTM from someone? thanks! Review status: 0 of 2 files reviewed at latest revision, 1 unresolved discussion, all commit checks successful. Comments from Reviewable |
, although this starts the long process of updating all our tools that create clusters to set this setting. Review status: 0 of 2 files reviewed at latest revision, 1 unresolved discussion, all commit checks successful. Comments from Reviewable |
Awesome, thanks! I'm going to go ahead and merge this, and perhaps we can start that process after code freeze. |
This broke master, looking into it |
- server: fix TestReportUsage (broken by cockroachdb#20790) - cli/interactive_tests: do not check for proper termination by `cockroach quit` until cockroachdb#22536 is fixed. Release note: none
thanks, @knz! |
Not too sure if this is the right approach, but basically adding logic where we check for whether or not a user has enabled diagnostics to also check for if the user has an organization that contains Cockroach Labs. This way, we can stop counting backup / restores that are related to internal work.
Fixes https://github.com/cockroachlabs/registration/issues/91