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

compactor: Consider incrementing either ...group_compactions_total or ...group_vertical_compactions_total not both. #2469

Closed
bwplotka opened this issue Apr 20, 2020 · 8 comments

Comments

@bwplotka
Copy link
Member

This is why metric testing and e2e tests are awesome! I found some unexpected cases that were surprising. One of them is that on vertical compaction we increment both vertical and normal compaction, which is confusing as it looks like in total we had 2 compactions, not one.

I think we should increment just either normal or vertical or just add a label to this metric (better).

Marking as bug, let's fix it.

@bwplotka
Copy link
Member Author

bwplotka commented Apr 20, 2020

Related TODO:

// TODO(bwplotka): This is confusing, should be either normal compaction or vertical not both (?)

and discussion: #2462 (review)

@brancz
Copy link
Member

brancz commented Apr 20, 2020

I personally think this is the right behavior. Along the lines of total and corresponding error metric where total always includes errors.

@bwplotka
Copy link
Member Author

Thanks. In this case, maybe we should rename / clarify this in HELP (:

@brancz
Copy link
Member

brancz commented Apr 20, 2020

Agreed!

@pracucci
Copy link
Contributor

I personally think this is the right behavior. Along the lines of total and corresponding error metric where total always includes errors.

Agree. It's also who TSDB metrics work:

  • prometheus_tsdb_compactions_total (always increased)
  • prometheus_tsdb_vertical_compactions_total (increased if the overlapping blocks are found during compaction)

@darshanime
Copy link
Contributor

The TODO is already removed in 2654a10

The HELP text is currently:

		Name: "thanos_compact_group_compactions_total",
		Help: "Total number of group compaction attempts that resulted in a new block.",


		Name: "thanos_compact_group_vertical_compactions_total",
		Help: "Total number of group compaction attempts that resulted in a new block based on overlapping blocks.",

Any ideas on whether it change it? One possible alternative can be:

		Name: "thanos_compact_group_compactions_total",
		Help: "Total number of group compaction attempts that resulted in a new block regardless of cause.",


		Name: "thanos_compact_group_vertical_compactions_total",
		Help: "Total number of group compaction attempts that resulted in a new block based on overlapping blocks.",

@stale
Copy link

stale bot commented Jun 9, 2020

Hello 👋 Looks like there was no activity on this issue for last 30 days.
Do you mind updating us on the status? Is this still reproducible or needed? If yes, just comment on this PR or push a commit. Thanks! 🤗
If there will be no activity for next week, this issue will be closed (we can always reopen an issue if we need!). Alternatively, use remind command if you wish to be reminded at some point in future.

@stale stale bot added the stale label Jun 9, 2020
@bwplotka
Copy link
Member Author

bwplotka commented Jun 9, 2020

Looks like this is done after all, thanks all for discussion (:

@stale stale bot removed the stale label Jun 9, 2020
@brancz brancz closed this as completed Jun 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants