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

Boltdb shipper metrics changes #2790

Merged
merged 3 commits into from
Oct 25, 2020

Conversation

sandeepsukhani
Copy link
Contributor

What this PR does / why we need it:

  1. Renamed some of the metrics to have table in their names instead of files.
  2. Increments tables_sync_operation_total metric during periodic sync operations to be able to detect problems and write alerts on it.

@@ -163,10 +163,20 @@ func (tm *TableManager) getOrCreateTable(spanCtx context.Context, tableName stri
return table
}

func (tm *TableManager) syncTables(ctx context.Context) error {
func (tm *TableManager) syncTables(ctx context.Context) (err error) {
Copy link
Collaborator

Choose a reason for hiding this comment

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

I prefer the other style of not defining the variable name in the method.

This is usually how we do it and I like that return nil at the end is a little more explicit.

Copy link
Collaborator

@slim-bean slim-bean left a comment

Choose a reason for hiding this comment

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

one nit but LGTM

Copy link
Member

@owen-d owen-d left a comment

Choose a reason for hiding this comment

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

lgtm

@codecov-io
Copy link

Codecov Report

Merging #2790 into master will decrease coverage by 0.04%.
The diff coverage is 58.82%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2790      +/-   ##
==========================================
- Coverage   61.35%   61.30%   -0.05%     
==========================================
  Files         177      177              
  Lines       14378    14387       +9     
==========================================
- Hits         8821     8820       -1     
- Misses       4748     4755       +7     
- Partials      809      812       +3     
Impacted Files Coverage Δ
.../storage/stores/shipper/downloads/table_manager.go 60.43% <0.00%> (-4.27%) ⬇️
pkg/storage/stores/shipper/downloads/metrics.go 100.00% <100.00%> (ø)
pkg/storage/stores/shipper/downloads/table.go 65.11% <100.00%> (ø)
pkg/storage/stores/shipper/uploads/table.go 68.66% <0.00%> (-1.85%) ⬇️
...kg/storage/stores/shipper/uploads/table_manager.go 65.78% <0.00%> (-1.76%) ⬇️
pkg/querier/queryrange/downstreamer.go 97.64% <0.00%> (+2.35%) ⬆️

@slim-bean slim-bean merged commit 2793499 into grafana:master Oct 25, 2020
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.

None yet

4 participants