Skip to content

dev: improve readability and maintenance of internal/cache #5101

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

Merged
merged 18 commits into from
Nov 5, 2024

Conversation

ldez
Copy link
Member

@ldez ldez commented Nov 5, 2024

Before reviewing the content of this PR, and if you want, I propose a quick "game" to illustrate the goal of this PR:

  • Open the current version of internal/cache/cache.go locally
  • You have 10 seconds to read and explain what the method Get is doing
  • Now open my version of the method Get and do the same thing
  • Do you see the difference? 😸

Extends stopwatch to simplify the usage.

Isolates usage of iosem.

Factorizes methods to increase the readability.

Follows #5100

@ldez ldez added topic: cleanup Related to code, process, or doc cleanup area: cache labels Nov 5, 2024
@ldez ldez added this to the next milestone Nov 5, 2024
@ldez ldez force-pushed the feat/improve-readability branch 3 times, most recently from dd4b36c to cc9a461 Compare November 5, 2024 12:15
@ldez ldez force-pushed the feat/improve-readability branch from cc9a461 to 92fd8c8 Compare November 5, 2024 12:21
@ldez ldez merged commit e28ddc1 into golangci:master Nov 5, 2024
15 checks passed
@ldez ldez deleted the feat/improve-readability branch November 5, 2024 19:26
@ldez ldez changed the title Improve readability and maintenance of internal/cache dev: improve readability and maintenance of internal/cache Nov 5, 2024
@ldez ldez modified the milestones: next, v1.62 Nov 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: cache topic: cleanup Related to code, process, or doc cleanup
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants