Skip to content

Commit

Permalink
add true name to acknowledged
Browse files Browse the repository at this point in the history
  • Loading branch information
Axel Chauvin authored and achauvin-wish committed Sep 22, 2021
1 parent 43c6dc9 commit ac81e2a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion metrics/metrics.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ func NewQProxyMetrics() (QProxyMetrics, error) {
Namespace: "qproxy",
Name: "acknowledged",
},
[]string{"namespace", "name"},
[]string{"namespace", "name", "true_name"},
)
if err := prometheus.Register(m.Acknowledged); err != nil {
return m, err
Expand Down
2 changes: 1 addition & 1 deletion server.go
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ func (s *QProxyServer) AckMessages(ctx context.Context, in *rpc.AckMessagesReque
s.m.APIErrors.WithLabelValues("AckMessages", in.QueueId.Namespace, in.QueueId.Name, s.ParseError(err)).Inc()
log.Println("Error AckMessages: ", err)
} else {
s.m.Acknowledged.WithLabelValues(in.QueueId.Namespace, in.QueueId.Name).Add(float64(len(in.Receipts) - len(resp.Failed)))
s.m.Acknowledged.WithLabelValues(in.QueueId.Namespace, in.QueueId.Name,*sqs.QueueIdToName(in.QueueId)).Add(float64(len(in.Receipts) - len(resp.Failed)))
}
}()
ctx = s.setContextTimeout(ctx, in.RPCTimeout)
Expand Down

0 comments on commit ac81e2a

Please sign in to comment.