Skip to content

Commit

Permalink
enable grpc latency measurement with prometheus (#19)
Browse files Browse the repository at this point in the history
Signed-off-by: Kenny Leung <kleung@chainguard.dev>

Signed-off-by: Kenny Leung <kleung@chainguard.dev>
  • Loading branch information
k4leung4 authored Aug 11, 2022
1 parent ea396cd commit 404cfab
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions pkg/duplex/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ func (d *Duplex) ListenAndServe(ctx context.Context) error {
// Call this *after* all services have been registered.
func (d *Duplex) RegisterListenAndServeMetrics(port int, enablePprof bool) {
grpc_prometheus.Register(d.Server)
grpc_prometheus.EnableHandlingTimeHistogram()

go func(mport int) {
mux := http.NewServeMux()
Expand Down

0 comments on commit 404cfab

Please sign in to comment.