Skip to content

Fix of tmp db size metric #465

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 3 commits into from
Jun 29, 2023
Merged

Fix of tmp db size metric #465

merged 3 commits into from
Jun 29, 2023

Conversation

rus-alex
Copy link
Contributor

@rus-alex rus-alex commented Jun 8, 2023

Replaces infinite number of metrics for each tmp DB with single generic metric for each kind of tmp DB.
Makes it easier to build a dashboard, prevents the leaks like #461

@rus-alex rus-alex requested a review from andrecronje as a code owner June 8, 2023 04:11
@rus-alex rus-alex requested review from hadv, thaarok and uprendis June 8, 2023 04:15
func genericNameOfTmpDB(name string) string {
match := tmpDbNameMask.FindStringSubmatch(name)
if len(match) == 3 {
return match[1] + "es"
Copy link
Contributor

Choose a reason for hiding this comment

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

Ending with "es" looks a bit strange for gossipes and epoches.

We might include all (gossip-, lachesis- and epoch-) into epochs like before?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

How about gossip-tmp, lachesis-tmp and epoch-tmp ?

Copy link
Contributor

Choose a reason for hiding this comment

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

@rus-alex I would say it is more like "gossip-epoch", "lachesis-epoch" and "epoch".
But I like the idea of one "epochs" generic name more.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@hkalina , but gossip-%d and lachesis-%d are not the same DB for "legacy-ldb" and "legacy-pbl" layouts. So we should have different metrics for each, not a common "epochs".
I agree that we mostly use "ldb-1" and "pbl-1" now. But it may be changed later.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Or, we may add a new kind of temporary db.

@uprendis uprendis merged commit b03d8bf into develop Jun 29, 2023
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.

4 participants