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

refactor: duplicate utility to get server ID from ProviderID #532

Merged
merged 2 commits into from
Oct 6, 2023

Conversation

apricote
Copy link
Member

@apricote apricote commented Oct 6, 2023

This utility function was duplicated with nearly the exact same functionality. This commit cleans it up by extracting to a new package (to avoid cyclic imports).

These two methods are about to get more complicated with #523, better to clean it up now than to make changes to both locations in the future.

This utility function was duplicated with nearly the exact same
functionality. This commit cleans it up by extracting to a new package
(to avoid cyclic imports).
@apricote apricote self-assigned this Oct 6, 2023
@apricote apricote requested a review from a team as a code owner October 6, 2023 13:23
@apricote apricote requested a review from jooola October 6, 2023 13:27
Copy link
Member

@jooola jooola left a comment

Choose a reason for hiding this comment

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

This removes themetrics.OperationCalled.WithLabelValues(op).Inc() metrics, is that intended?

@apricote
Copy link
Member Author

apricote commented Oct 6, 2023

This removes themetrics.OperationCalled.WithLabelValues(op).Inc() metrics, is that intended?

This is intended. I do not think this metrics provides any value for this particular operation, as its just string parsing.

@apricote apricote merged commit 6f4b4a6 into main Oct 6, 2023
7 of 8 checks passed
@apricote apricote deleted the refactor-providerid-util branch October 6, 2023 13:43
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.

2 participants