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

APP-2747 Add hostname to metric #230

Merged
merged 6 commits into from
Jan 9, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions rpc/wrtc_call_queue_mongodb.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,12 @@ var (
},
})

callAnswererTooBusy = statz.NewCounter1[string]("rpc.webrtc/call_answerer_too_busy", statz.MetricConfig{
callAnswererTooBusy = statz.NewCounter2[string, string]("rpc.webrtc/call_answerer_too_busy", statz.MetricConfig{
Description: "The number of times all answerers were too busy to handle a new call.",
Unit: units.Dimensionless,
Labels: []statz.Label{
{Name: "operator_id", Description: "The queue operator ID."},
{Name: "hostname", Description: "The robot being requested"},
},
})

Expand Down Expand Up @@ -630,8 +631,8 @@ func (queue *mongoDBWebRTCCallQueue) processNextSubscriptionEvent(next mongoutil
return
}
}
callAnswererTooBusy.Inc(queue.operatorID, callResp.Host)
// if we get there its because none of the answer channels were able to send on the event
callAnswererTooBusy.Inc(queue.operatorID)
queue.logger.Warnw(
"all answerers for host too busy to answer call",
"id", callResp.ID,
Expand Down
Loading