Configuring Circuit Breaking and Outlier Detection
Outlier detection in SCP tracks the status of each individual endpoint of the producer NFs/NF Services. Upstream producer EndPoints that continually returns 5xx errors for service requests are ejected from the routing pool for a pre-defined period of time.
Outlier detection is a form of passive health checking of producer NFs. Outlier detection is per endpoint (of producer NF instance) and triggers when SCP receives consecutively 5xx error response and exceeds the configurable number of consecutive 5XX errors.
Circuit breaking is triggered on a per FQDN basis when its outstanding transactions exceeds a configurable value. When circuit breaking is activated, requests are alternate routed if possible or rejected otherwise.
Operator configuration:
- Enable/Disable the circuit breaking on a per NF or FQDN basis.
- Outstanding Transactions Threshold beyond which Circuit breaking shall be invoked on a per NF or FQDN basis.
- Error code to be sent if the Request cannot be alternate routed also on a per NF service basis.
Table 3-10 provides information about the configuring parameters for outlier detection.
Note:
Circuit Breaking and Outlier Detection are global or system wide options.Table 3-10 Outlier Detection Parameters
Parameter | Value | Description | Example |
---|---|---|---|
instanceId | String | Unique Id that represents systemOption record |
Set the value of field instanceId in the curl command below: curl -X PUT \ http://<Soothsayerfqdn>:8081/soothsayer/v1/systemoptions \ -H 'Content-Type: application/json' \ -d '{ "instanceId": "e33ac015-081a-4e25-99c1-d1d6c332246e", "cb_and_od_enabled": true, "trafficPolicy": { "connectionPool": { "http": { "http2MaxRequests": 1000 } }, "outlierDetection": { "consecutiveErrors": 5, "interval": "10s", "baseEjectionTime": "30s", "maxEjectionPercent": 100 } } }' |
cb_and_od_enabled | Boolean | This tells whether Circuit-Breaking and Outlier-Detection is enabled or not. |
Set the value of field cb_and_od_enabled in the curl command below: curl -X PUT \ http://<Soothsayerfqdn>:8081/soothsayer/v1/systemoptions \ -H 'Content-Type: application/json' \ -d '{ "instanceId": "e33ac015-081a-4e25-99c1-d1d6c332246e", "cb_and_od_enabled": true, "trafficPolicy": { "connectionPool": { "http": { "http2MaxRequests": 1000 } }, "outlierDetection": { "consecutiveErrors": 5, "interval": "10s", "baseEjectionTime": "30s", "maxEjectionPercent": 100 } } }' |
trafficPolicy.connectionPool.http.http2MaxRequests | Integer | Maximum number of requests to a backend. Default 1024. | Set the value of field
http2MaxRequests under
trafficPolicy.connectionPool.http
in the curl command below:
curl -X PUT \ http://<Soothsayerfqdn>:8081/soothsayer/v1/systemoptions \ -H 'Content-Type: application/json' \ -d '{ "instanceId": "e33ac015-081a-4e25-99c1-d1d6c332246e", "cb_and_od_enabled": true, "trafficPolicy": { "connectionPool": { "http": { "http2MaxRequests": 1000 } }, "outlierDetection": { "consecutiveErrors": 5, "interval": "10s", "baseEjectionTime": "30s", "maxEjectionPercent": 100 } } }' |
outlierDetection.consecutiveErrors | Integer | 5G defined NF Type. For example, BSF, UDR, UDSF, etc., | Set the value of
ConsecutiveErrors field
under outlierDetection in the curl command below
consecutiveErrors
UPDATE Command
curl -X PUT \ http://<Soothsayerfqdn>:8081/soothsayer/v1/systemoptions \ -H 'Content-Type: application/json' \ -d '{ "instanceId": "e33ac015-081a-4e25-99c1-d1d6c332246e", "cb_and_od_enabled": true, "trafficPolicy": { "connectionPool": { "http": { "http2MaxRequests": 1000 } }, "outlierDetection": { "consecutiveErrors": 5, "interval": "10s", "baseEjectionTime": "30s", "maxEjectionPercent": 100 } } }' |
outlierDetection.interval | String | Time interval between ejection sweep analysis.
Format: 1h/1m/1s/1ms. MUST BE >=1ms. Default is 10s |
Set the value of
interval field
under outlierDetection in the curl command below
interval UPDATE
Command
curl -X PUT \ http://<Soothsayerfqdn>:8081/soothsayer/v1/systemoptions \ -H 'Content-Type: application/json' \ -d '{ "instanceId": "e33ac015-081a-4e25-99c1-d1d6c332246e", "cb_and_od_enabled": true, "trafficPolicy": { "connectionPool": { "http": { "http2MaxRequests": 1000 } }, "outlierDetection": { "consecutiveErrors": 5, "interval": "10s", "baseEjectionTime": "30s", "maxEjectionPercent": 100 } } }' |
outlierDetection.baseEjectionTime | String | Minimum ejection duration.
Format: 1h/1m/1s/1ms. MUST BE >=1ms. Default is 30s. |
Set the value of field baseEjectionTime under
outlierDetection in the curl command below
baseEjectionTime
UPDATE Command
curl -X PUT \ http://<Soothsayerfqdn>:8081/soothsayer/v1/systemoptions \ -H 'Content-Type: application/json' \ -d '{ "instanceId": "e33ac015-081a-4e25-99c1-d1d6c332246e", "cb_and_od_enabled": true, "trafficPolicy": { "connectionPool": { "http": { "http2MaxRequests": 1000 } }, "outlierDetection": { "consecutiveErrors": 5, "interval": "10s", "baseEjectionTime": "30s", "maxEjectionPercent": 100 } } }' |
outlierDetection.maxEjectionPercent | Integer | Maximum percentage of hosts in the load balancing pool for the upstream service that can be ejected. | Set the value of field maxEjectionPercent under
outlierDetection in the curl command below
maxEjectionPercent
UPDATE Command
curl -X PUT \ http://<Soothsayerfqdn>:8081/soothsayer/v1/systemoptions \ -H 'Content-Type: application/json' \ -d '{ "instanceId": "e33ac015-081a-4e25-99c1-d1d6c332246e", "cb_and_od_enabled": true, "trafficPolicy": { "connectionPool": { "http": { "http2MaxRequests": 1000 } }, "outlierDetection": { "consecutiveErrors": 5, "interval": "10s", "baseEjectionTime": "30s", "maxEjectionPercent": 100 } } }' |