Alert
Overview
Alert is a module that can detect anomalies and patterns of interest in a stream or system and send notifications to users. Anomalies and patterns of interest can be set through predefined , and when detected, the module sends an HTTP(S) request to the user's notification server.
Configuration
Alert can be set up on <Server>, as shown below.
Key | Description |
---|---|
Url | The HTTP Server to receive the notification. HTTP and HTTPS are available. |
Secretkey | The secret key used when encrypting with HMAC-SHA1 For more information, see Security. |
Timeout | Time to wait for a response after request. (in milliseconds) |
Rules | Anomalies and patterns of interest to be detected. |
Rules
Type | Key | Description |
---|---|---|
Ingress | MinBitrate | Detects when the input stream's bitrate is lower than the set value. |
MaxBitrate | Detects when the input stream's bitrate is greater than the set value. | |
MinFramerate | Detects when the input stream's framerate is lower than the set value. | |
MaxFramerate | Detects when the input stream's framerate is greater than the set value. | |
MinWidth | Detects when the input stream's width is lower than the set value. | |
MaxWidth | Detects when the input stream's width is greater than the set value. | |
MinHeight | Detects when the input stream's height is lower than the set value. | |
MaxHeight | Detects when the input stream's height is greater than the set value. | |
MinSamplerate | Detects when the input stream's samplerate is lower than the set value. | |
MaxSamplerate | Detects when the input stream's samplerate is greater than the set value. | |
LongKeyFrameInterval | Detects when the input stream's keyframe interval is too long (exceeds 4 seconds). | |
HasBFrame | Detects when there are B-frames in the input stream. |
Notification
Request
Format
Here is a detailed explanation of each element of Json payload:
Element | Description |
---|---|
sourceUri | URI information of the detected source. It consists of #<vhost>#<application>/<stream>. |
messages | List of messages detected by the Rules. |
sourceInfo | Detailed information about the source at the time of detection. It is identical to the response of the REST API's source information query for the detected source. |
Messages
Code | Description |
---|---|
INGRESS_BITRATE_LOW | The ingress stream's current bitrate ( |
INGRESS_BITRATE_HIGH | The ingress stream's current bitrate ( |
INGRESS_FRAMERATE_LOW | The ingress stream's current framerate ( |
INGRESS_FRAMERATE_HIGH | The ingress stream's current framerate ( |
INGRESS_WIDTH_SMALL | The ingress stream's width ( |
INGRESS_WIDTH_LARGE | The ingress stream's width ( |
INGRESS_HEIGHT_SMALL | The ingress stream's height ( |
INGRESS_HEIGHT_LARGE | The ingress stream's height ( |
INGRESS_SAMPLERATE_LOW | The ingress stream's current samplerate ( |
INGRESS_SAMPLERATE_HIGH | The ingress stream's current samplerate ( |
INGRESS_LONG_KEY_FRAME_INTERVAL | The ingress stream's current keyframe interval ( |
INGRESS_HAS_BFRAME | There are B-Frames in the ingress stream. |
Security
The control server may need to validate incoming http requests for security reasons. To do this, the AdmissionWebhooks module puts the X-OME-Signature
value in the HTTP request header. X-OME-Signature
is a base64 url safe encoded value obtained by encrypting the payload of an HTTP request with the HMAC-SHA1 algorithm using the secret key set in <Alert><SecretKey>
of the configuration.
Response
The engine in the closing state does not need any parameter in response. To the query just answer with empty json object.
Last updated