Skip to content
This repository has been archived by the owner on May 23, 2024. It is now read-only.

Rename RPC metrics and use more tags #121

Merged
merged 2 commits into from
Mar 21, 2017
Merged

Conversation

yurishkuro
Copy link
Member

@yurishkuro yurishkuro commented Mar 21, 2017

Remove "_ms" suffix from request latency metric name

In practice, the precision of the recorded timing values
depends on the metrics backend and the client library.
Since we're using time.Duration based API, we cannot claim
the unit of measure in the metric name.

Rename all metrics to "request" and "http_request" and use tags for other dimensions

  • Success/failure are distinguished by error=true|false tag.
  • HTTP Requests are distinguished by status_code=2xx|3xx|... tag

In practice, the precision of the recorded timing values
depends on the metrics backend and the client library.
Since we're using time.Duration based API, we cannot claim
the unit of measure in the metric name.
@coveralls
Copy link

Coverage Status

Coverage remained the same at 83.297% when pulling b798182 on rpcmetrics-remove-ms-suffix into bcc8018 on master.

@yurishkuro yurishkuro changed the title Remove "_ms" suffix from request latency metric name Rename RPC metrics and use more tags Mar 21, 2017
@coveralls
Copy link

Coverage Status

Coverage decreased (-0.006%) to 83.291% when pulling f4d8ac9 on rpcmetrics-remove-ms-suffix into bcc8018 on master.

}

func endpointTags(endpoint string, kv ...string) map[string]string {
return tags(append([]string{"endpoint", endpoint}, kv...)...)
Copy link
Contributor

Choose a reason for hiding this comment

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

does tags("endpoint", endpoint, kv...) not work?

Copy link
Member Author

Choose a reason for hiding this comment

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

no

@mhamrah
Copy link

mhamrah commented Mar 21, 2017

+1

@yurishkuro yurishkuro merged commit 1669a1b into master Mar 21, 2017
@yurishkuro yurishkuro deleted the rpcmetrics-remove-ms-suffix branch May 5, 2021 21:57
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants