Skip to content
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

Migration to dskit/ring #336

Merged
merged 18 commits into from
Oct 18, 2021
Merged

Migration to dskit/ring #336

merged 18 commits into from
Oct 18, 2021

Conversation

treid314
Copy link
Contributor

@treid314 treid314 commented Oct 11, 2021

What this PR does: With including the ring package in dskit we want to migrate mimir and other users to the dskit.

Remaining work

  • Fix import formatting
  • Fix TestStoreGateway_BlocksSyncWithDefaultSharding_RingTopologyChangedAfterScaleUp not able to find ring members metric
  • integration tests using ring metrics timing issues

Which issue(s) this PR fixes:

Fixes #

Checklist

  • Tests updated
  • [-] Documentation added
  • [-] CHANGELOG.md updated - the order of entries should be [CHANGE], [FEATURE], [ENHANCEMENT], [BUGFIX]

@treid314 treid314 requested a review from aknuds1 October 11, 2021 13:29
@treid314
Copy link
Contributor Author

treid314 commented Oct 11, 2021

As a side note, in dskit we should update metrics in the start fn and then start the ticker rather than do our first collect in 10 seconds, I'll create a PR for this tomorrow. grafana/dskit#61

@pstibrany
Copy link
Member

pstibrany commented Oct 11, 2021

Is this duplicate of #333?

@aknuds1
Copy link
Contributor

aknuds1 commented Oct 11, 2021

Is this duplicate of #333?

@pstibrany no, I think Tyler's PR is preferable :)

@pstibrany
Copy link
Member

Is this duplicate of #333?

@pstibrany no, I think Tyler's PR is preferable :)

Oh, that's too bad... you won the PR number lottery here :)

Copy link
Collaborator

@pracucci pracucci left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I will find many "Remove this newline, please." comments (at some point I've stopped reporting it, but please fix it everywhere). I would suggest you to check your goformat/goimports settings. Your IDE should do it for you.

Could you also rebase main please?

pkg/alertmanager/alertmanager_client.go Show resolved Hide resolved
pkg/alertmanager/alertmanager_ring.go Outdated Show resolved Hide resolved
pkg/alertmanager/alertmanager_ring.go Outdated Show resolved Hide resolved
pkg/alertmanager/alertmanager_ring_test.go Outdated Show resolved Hide resolved
pkg/alertmanager/distributor_test.go Show resolved Hide resolved
pkg/ruler/ruler_ring.go Outdated Show resolved Hide resolved
pkg/storegateway/gateway_ring.go Outdated Show resolved Hide resolved
pkg/storegateway/gateway_test.go Outdated Show resolved Hide resolved
pkg/storegateway/gateway_test.go Outdated Show resolved Hide resolved
pkg/util/test/leak.go Outdated Show resolved Hide resolved
Copy link
Contributor

@aknuds1 aknuds1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Generally looks good to me, but see comments please.

pkg/ingester/lifecycle_test.go Outdated Show resolved Hide resolved
pkg/ingester/lifecycle_test.go Outdated Show resolved Hide resolved
pkg/ruler/lifecycle_test.go Outdated Show resolved Hide resolved
pkg/storegateway/gateway_test.go Outdated Show resolved Hide resolved
pkg/storegateway/gateway_test.go Outdated Show resolved Hide resolved
@treid314 treid314 changed the title WIP migration to dskit/ring Migration to dskit/ring Oct 15, 2021
@treid314 treid314 marked this pull request as ready for review October 15, 2021 18:00
Copy link
Collaborator

@pracucci pracucci left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good job! I think I've just noticed an issue: could you take a look, please?

pkg/ruler/ruler.go Show resolved Hide resolved
Copy link
Collaborator

@pracucci pracucci left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@pracucci pracucci enabled auto-merge (squash) October 18, 2021 16:54
@pracucci pracucci merged commit 18a5e2d into main Oct 18, 2021
@pracucci pracucci deleted the dskit-ring branch October 18, 2021 19:15
// metrics := initialRegistries.BuildMetricFamiliesPerUser()
// return metrics.GetSumOfGauges("cortex_ring_members")
// })
dstest.Poll(t, 11*time.Second, float64(numAllGateways*numInitialGateways), func() interface{} {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change from 5 seconds to 11 is worth calling out in the commit message.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And should be rendered unnecessary by grafana/dskit#107, I think.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants