Skip to content

Conversation

scrye
Copy link
Contributor

@scrye scrye commented Oct 24, 2019

This adds the following metrics:

# HELP lib_infra_messenger_read_sizes_bytes Size of successful reads.
# TYPE lib_infra_messenger_read_sizes_bytes histogram
lib_infra_messenger_read_sizes_bytes_bucket{le="32"} 0
lib_infra_messenger_read_sizes_bytes_bucket{le="64"} 0
lib_infra_messenger_read_sizes_bytes_bucket{le="128"} 3
lib_infra_messenger_read_sizes_bytes_bucket{le="256"} 3
lib_infra_messenger_read_sizes_bytes_bucket{le="512"} 52
lib_infra_messenger_read_sizes_bytes_bucket{le="1024"} 177
lib_infra_messenger_read_sizes_bytes_bucket{le="2048"} 177
lib_infra_messenger_read_sizes_bytes_bucket{le="4096"} 177
lib_infra_messenger_read_sizes_bytes_bucket{le="8192"} 177
lib_infra_messenger_read_sizes_bytes_bucket{le="16384"} 177
lib_infra_messenger_read_sizes_bytes_bucket{le="+Inf"} 177
lib_infra_messenger_read_sizes_bytes_sum 114298
lib_infra_messenger_read_sizes_bytes_count 177
# HELP lib_infra_messenger_reads_total Total number of Read calls.
# TYPE lib_infra_messenger_reads_total counter
lib_infra_messenger_reads_total{result="err_invalid_request"} 26
lib_infra_messenger_reads_total{result="ok_success"} 177

Fixes #3187.


This change is Reviewable

@scrye scrye added feature New feature or request c/observability Metrics, logging, tracing labels Oct 24, 2019
@scrye scrye requested a review from lukedirtwalker October 24, 2019 08:44
@scrye scrye self-assigned this Oct 24, 2019
Copy link
Collaborator

@lukedirtwalker lukedirtwalker left a comment

Choose a reason for hiding this comment

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

Reviewed 9 of 9 files at r1.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @scrye)


go/protobuf/BUILD.bazel, line 1 at r1 (raw file):

load("@io_bazel_rules_go//go:def.bzl", "go_library")

Remove this 🙈

Copy link
Collaborator

@lukedirtwalker lukedirtwalker left a comment

Choose a reason for hiding this comment

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

Reviewed 2 of 2 files at r2.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @scrye)

Copy link
Collaborator

@lukedirtwalker lukedirtwalker left a comment

Choose a reason for hiding this comment

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

:lgtm:

Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @scrye)

Copy link
Contributor Author

@scrye scrye left a comment

Choose a reason for hiding this comment

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

Reviewable status: :shipit: complete! all files reviewed, all discussions resolved


go/protobuf/BUILD.bazel, line 1 at r1 (raw file):

Previously, lukedirtwalker (Lukas Vogel) wrote…

Remove this 🙈

Done.

scrye added 2 commits October 24, 2019 15:12
This adds the following metrics:
```
# HELP lib_infra_messenger_read_sizes_bytes Size of successful reads.
# TYPE lib_infra_messenger_read_sizes_bytes histogram
lib_infra_messenger_read_sizes_bytes_bucket{le="32"} 0
lib_infra_messenger_read_sizes_bytes_bucket{le="64"} 0
lib_infra_messenger_read_sizes_bytes_bucket{le="128"} 3
lib_infra_messenger_read_sizes_bytes_bucket{le="256"} 3
lib_infra_messenger_read_sizes_bytes_bucket{le="512"} 52
lib_infra_messenger_read_sizes_bytes_bucket{le="1024"} 177
lib_infra_messenger_read_sizes_bytes_bucket{le="2048"} 177
lib_infra_messenger_read_sizes_bytes_bucket{le="4096"} 177
lib_infra_messenger_read_sizes_bytes_bucket{le="8192"} 177
lib_infra_messenger_read_sizes_bytes_bucket{le="16384"} 177
lib_infra_messenger_read_sizes_bytes_bucket{le="+Inf"} 177
lib_infra_messenger_read_sizes_bytes_sum 114298
lib_infra_messenger_read_sizes_bytes_count 177
# HELP lib_infra_messenger_reads_total Total number of Read calls.
# TYPE lib_infra_messenger_reads_total counter
lib_infra_messenger_reads_total{result="err_invalid_request"} 26
lib_infra_messenger_reads_total{result="ok_success"} 177
```

Fixes #3187.

# Please enter the commit message for your changes. Lines starting
# with '#' will be kept; you may remove them yourself if you want to.
# An empty message aborts the commit.
#
# Date:      Thu Oct 24 10:37:21 2019 +0200
#
# On branch pubpr-fix-3187
# Your branch is up-to-date with 'puborig/pubpr-fix-3187'.
#
# Changes to be committed:
#	modified:   go/lib/infra/disp/disp.go
#	modified:   go/lib/infra/disp/disp_test.go
#	modified:   go/lib/infra/messenger/BUILD.bazel
#	modified:   go/lib/infra/messenger/adapter.go
#	new file:   go/lib/infra/messenger/internal/metrics/BUILD.bazel
#	new file:   go/lib/infra/messenger/internal/metrics/metrics.go
#	modified:   go/lib/infra/messenger/messenger.go
#	modified:   go/lib/prom/prom.go
#	new file:   go/protobuf/BUILD.bazel
#
# Untracked files:
#	go/lib/infra/messenger/internal/metrics/metrics_test.go
#	msger.metrics
#
Copy link
Collaborator

@lukedirtwalker lukedirtwalker left a comment

Choose a reason for hiding this comment

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

Reviewed 1 of 1 files at r3.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved

@scrye scrye merged commit a9de604 into scionproto:master Oct 24, 2019
@scrye scrye deleted the pubpr-fix-3187 branch October 24, 2019 14:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c/observability Metrics, logging, tracing feature New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

lib/infra/messenger: improve metrics
2 participants