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

Migrating from go-kit/kit/log to the slimmer go-kit/log #4421

Merged
merged 3 commits into from
Sep 29, 2021

Conversation

dannykopping
Copy link
Contributor

@dannykopping dannykopping commented Aug 13, 2021

What this PR does:
This PR aims to align Cortex with Prometheus (see prometheus/prometheus#8927) in its use of go-kit's logger. go-kit/kit/log was split out into go-kit/log, and that's all we use of go-kit ostensibly.

Note: I had to update some tests since logs get produced with labels in a different order. I think these logs are coming from the vendored Thanos code in the compactor, which may explain why they're ordered differently.

Which issue(s) this PR fixes:
N/A

Checklist

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

@dannykopping dannykopping marked this pull request as ready for review September 14, 2021 09:30
Copy link
Contributor

@bboreham bboreham left a comment

Choose a reason for hiding this comment

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

lgtm

Copy link
Contributor

@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.

LGTM, thanks!

@@ -107,3 +107,20 @@ func CheckFatal(location string, err error) {
os.Exit(1)
}
}

// TODO(dannyk): remove once weaveworks/common updates to go-kit/log
Copy link
Contributor

Choose a reason for hiding this comment

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

Could you open a PR there too, please?

@pracucci pracucci merged commit 34bb142 into cortexproject:master Sep 29, 2021
cristiangreco added a commit to grafana/cortex-tools that referenced this pull request Nov 3, 2021
srijan55 pushed a commit to srijan55/cortex that referenced this pull request Nov 26, 2021
…t#4421)

* Migrating from go-kit/kit/log to the slimmer go-kit/log

Signed-off-by: Danny Kopping <[email protected]>

* Appeasing the linter

Signed-off-by: Danny Kopping <[email protected]>

* Fixing tests where log lines are produced with different label orders

Signed-off-by: Danny Kopping <[email protected]>
Signed-off-by: Manish Kumar Gupta <[email protected]>
simonswine pushed a commit to grafana/e2e that referenced this pull request Jan 13, 2022
…t/cortex#4421)

* Migrating from go-kit/kit/log to the slimmer go-kit/log

Signed-off-by: Danny Kopping <[email protected]>

* Appeasing the linter

Signed-off-by: Danny Kopping <[email protected]>

* Fixing tests where log lines are produced with different label orders

Signed-off-by: Danny Kopping <[email protected]>
alvinlin123 pushed a commit to ac1214/cortex that referenced this pull request Jan 14, 2022
…t#4421)

* Migrating from go-kit/kit/log to the slimmer go-kit/log

Signed-off-by: Danny Kopping <[email protected]>

* Appeasing the linter

Signed-off-by: Danny Kopping <[email protected]>

* Fixing tests where log lines are produced with different label orders

Signed-off-by: Danny Kopping <[email protected]>
Signed-off-by: Alvin Lin <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants