Skip to content

Quality-based routing

Quality-based routing takes a vendor connection out of the way when its calls go bad, without waiting for you to notice. The switch measures each monitored connection on its recent calls. When the quality falls below the thresholds you set, it moves the connection to the end of the routing list or blocks it, and later sends it a batch of test calls to see whether it has recovered.

Screenshot "concepts/connection-quality-monitoring" has not been generated yet — see scripts/screenshots/screens.yml.
  1. Measure. For every connection with at least one of Monitor ACD Quality, Monitor ASR Quality or Monitor PDD Quality checked, the switch keeps statistics over the last Statistics Window calls, 20 by default. The window slides: each new call pushes the oldest one out.
  2. Judge. The connection is bad as soon as one monitored metric crosses its threshold: ACD below ACD Threshold, sec, ASR below ASR Threshold, %, or PDD above PDD Threshold, sec. It is good while every monitored metric is on the right side.
  3. Act. When the connection turns bad, Bad Quality Action takes effect for new calls. Calls in progress are not touched.
  4. Retry. After Retry Interval, sec, 600 by default, the connection returns to its normal place for the next Retry Batch calls, 10 by default. The switch measures that batch. If it is good, the connection stays in place and a new statistics window starts from the batch. If not, the action is applied again for another retry interval.
Bad Quality Action Effect on new calls
Make Last In Routing (default) The connection moves to the end of the hunting list of every routing group. It still gets calls that all other routes failed
Block The connection is skipped
Notify Only Routing does not change; only the notification is sent

Notify On Status Change e-mails the root customer each time the connection really changes between good and bad. Temporary changes during a retry batch do not send mail.

The metrics are measured on the calls the switch sends to that connection:

  • ACD is the average duration of the connected calls, in seconds. Calls with zero duration are not counted.
  • ASR is the share of calls with a non-zero duration among all calls sent to the connection, in percent.
  • PDD is the average time from the INVITE to the first ringing response, in seconds.

Test Dialplan shows the current state of each monitored connection next to its route: Connection quality is good, Connection preference lowered due to bad quality or Connection blocked due to bad quality.

  • ASR — answer-seizure ratio: percentage of attempted calls that were answered.
  • ACD — average call duration of answered calls.
  • PDD — post-dial delay: time between sending INVITE and receiving ringing.
  • Connection — a route to a vendor (SIP host, port, protocol, codecs) used by routing to send calls.
  • Hunting — trying the next route after a failed attempt.

A vendor starts returning busy for every call

Section titled “A vendor starts returning busy for every call”

ASR of the connection collapses within one statistics window. With ASR Threshold, % set, the connection moves to the end of the list or is blocked, and the next vendors take the traffic. After the retry interval ten test calls show whether the vendor works again.

A demoted connection recovers before the retry interval ends

Section titled “A demoted connection recovers before the retry interval ends”

With Make Last In Routing the connection still carries calls that all better routes rejected. Once it has terminated a full retry batch this way, the switch re-evaluates it at once instead of waiting for the interval to expire. With Block it gets no calls, so the switch waits for the interval.

Quality monitoring never triggers on low-volume connections

Section titled “Quality monitoring never triggers on low-volume connections”

A statistics window of 20 calls fills slowly when a connection carries a few calls an hour, and the metrics react late. Lower Statistics Window for such connections, but not so far that a single failed call makes the connection bad.