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

Remove redundant prometheus data points #5934

Merged
merged 1 commit into from May 15, 2018
Merged

Conversation

nitisht
Copy link
Contributor

@nitisht nitisht commented May 15, 2018

Description

Removed field minio_http_requests_total as it was redundant with
minio_http_requests_duration_seconds_count

Also removed field minio_server_start_time_seconds as it was
redundant with process_start_time_seconds

Motivation and Context

This PR removes couple of redundant fields in Prometheus data exported by Minio server.

How Has This Been Tested?

Manually

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added unit tests to cover my changes.
  • I have added/updated functional tests in mint. (If yes, add mint PR # here: )
  • All new and existing tests passed.

Removed field minio_http_requests_total as it was redundant with
minio_http_requests_duration_seconds_count

Also removed field minio_server_start_time_seconds as it was
redundant with process_start_time_seconds
@codecov
Copy link

codecov bot commented May 15, 2018

Codecov Report

Merging #5934 into master will increase coverage by 0.03%.
The diff coverage is 50%.

Impacted file tree graph

@@            Coverage Diff            @@
##           master   #5934      +/-   ##
=========================================
+ Coverage   59.57%   59.6%   +0.03%     
=========================================
  Files         214     214              
  Lines       30786   30772      -14     
=========================================
+ Hits        18342   18343       +1     
+ Misses      10899   10881      -18     
- Partials     1545    1548       +3
Impacted Files Coverage Δ
cmd/http-stats.go 96.11% <ø> (-0.08%) ⬇️
cmd/metrics.go 29.7% <50%> (-0.39%) ⬇️
cmd/fs-v1-rwpool.go 65.48% <0%> (-2.66%) ⬇️
cmd/xl-sets.go 58.6% <0%> (-0.22%) ⬇️
cmd/update-notifier.go 81.66% <0%> (+19.99%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 5c21e89...4f0b539. Read the comment docs.

@@ -190,8 +190,6 @@ func (st *HTTPStats) updateStats(r *http.Request, w *httpResponseRecorder, durat
st.successDELETEs.Duration.Add(durationSecs)
}
}
// Increment the prometheus http request count with appropriate label
httpRequests.With(prometheus.Labels{"request_type": r.Method}).Inc()
Copy link
Member

Choose a reason for hiding this comment

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

@nitisht I am not sure how number of requests count is redundant with requests duration, can you elaborate ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@vadmeste the field minio_http_requests_duration_seconds (basename) is a histogram so it has basename_bucket , basename_sum and basename_count fields, where basename_count is number of events that have been observed.

The minio_http_requests_total also had the same data

Copy link
Member

@vadmeste vadmeste left a comment

Choose a reason for hiding this comment

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

LGTM & works as expected

@deekoder deekoder merged commit e6ebcc4 into minio:master May 15, 2018
@nitisht nitisht deleted the prom-rem branch May 16, 2018 00:46
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.

None yet

4 participants