Skip to main content

Monitoring Stream

Using the Built-In Heartbeat Server

Health Score

You can check on Stream through the built-in Heartbeat Server:

  • Start Stream with docker run ... -p 8001:8001 ... to enable access to the Server
  • Send a GET request to the following endpoint: curl -i http://localhost:8001/status/
  • The Server will return a status code 200 if all cameras are still functional, 500 otherwise
  • The attached JSON response contains the current status of each camera:
{
"version": "1.51.0",
"cameras": {
"camera-1": {
"health": -1,
"status": "starting",
"last_checked": "2024-05-13 11:21:44.904403+00:00",
"received_fps": -1.0, // starting from version 1.58.0
"buffered_frames": 0, // starting from version 1.58.0
"file_processing": {
// starting from version 1.56.0
"processed_seconds": -1.0,
"total_seconds": -1.0
}
},
"camera-2": {
"health": 95,
"status": "running",
"last_checked": "2024-05-13 11:21:44.904623+00:00",
"received_fps": 24.5,
"buffered_frames": 3,
"file_processing": {
"processed_seconds": -1.0,
"total_seconds": -1.0
}
},
"camera-3": {
"health": 0,
"status": "stopped",
"last_checked": "2024-05-13 11:21:44.904623+00:00",
"received_fps": 0.1,
"buffered_frames": 90,
"file_processing": {
"processed_seconds": -1.0,
"total_seconds": -1.0
}
}
}
}

All last_checked timestamps are using timezone parameter configurable per camera.

New in version 1.51.0.

File processing

For files, you will be able to see current progress as well:

{
"...",
"cameras": {
"...",
"file-1": {
"health": 95,
"status": "running",
"last_checked": "2024-05-13 11:21:44.904623+00:00",
"received_fps": 0.1, // starting from version 1.58.0
"buffered_frames": 90, // starting from version 1.58.0
"file_processing": { // starting from version 1.56.0
"processed_seconds": 10,
"total_seconds": 100
}
},
"..."
}
}

New in version 1.56.0.

Network

Heartbeat also provides useful information about network connection through received_fps and buffered_frames fields.

The first one, received_fps, indicates how many frames of the original footage Stream is fetching per second. This value is not affected by the sample parameter and should be close to the actual FPS output of the camera. If not, it could indicate network problems.

The second one, buffered_frames, is the percentage of the received frames that were buffered by the video backend before being processed. Some buffering is acceptable, but 25% or more could indicate bandwidth or processing bottlenecks. Note that this value could be unreliable for Variable Bitrate videos.

New in version 1.58.0.

Using the Built-In Web Dashboard

You can check on Stream through the built-in web dashboard:

  • Start Stream with docker run ... -p 8001:8001 ... to enable access to the server
  • Open http://localhost:8001/ in your web browser

Mouse hovering underlined items, the status dot, and some links in the dashboard will show a tooltip with more information.

The top navigation bar shows at a glance the running Stream version and status dot, as well as the following links:

Web Dashboard

New in version 1.61.0.

Cameras

The Cameras page shows the IDs of cameras configured in Stream, their status, health, last result time and image (see note), camera's webhooks status, source URL and the last error message if any.

Clicking on any camera ID will open the Results page for that camera.

The page is refreshed every 10 seconds, unless paused by the user by clicking the icon.

note

Last result time and image are only available if the jsonlines_file config parameter is set for the camera.

Results

The Results page shows the latest results, up to a maximum of 100 per camera, in sortable chronological order. 20 results are shown per page, with pagination controls.

The page is refreshed every 10 seconds, unless paused by the user by clicking the icon, or by using the pagination controls.

Clicking on a camera ID (here or in the Cameras page) will filter the results for that camera only.

Each result shows the camera ID, timestamp, image, and, if any, the recognized license plates, regions, makes and models (if MMC available) and vehicle types.

Precise confidence scores are shown by hovering over items. They are also shown at a glance by the items' varying opacity.

The rightmost button (⎘) permits copying the full result in JSON format to the clipboard.

note

Results are only available if the jsonlines_file config parameter is set for the camera. Results images are only available if images have not been disabled by setting an empty image_format= config parameter for the camera.

System

The System page shows the running Stream version, video time used (for file processing), and the number of webhooks in cache.

The Check API Connectivity button allows you to check if Stream can connect to the snapshot cloud API.

The Restart Stream button allows you to restart Stream from the web interface.

note

The Stream container will only restart if the Docker container restart policy is set to always or unless-stopped. If not, you will need to manually restart the container via your Docker management tool.

Web-config

Opens the Platerecognizer web configuration page in a new tab.

Guide

Opens this site in a new tab.

Using Our Online Dashboard

Activity Status

The Stream Activity Status feature provides users with a visual representation of the activity status of their stream licenses. The following symbols and colors are used to indicate the status of each stream:

  • All Active: ✅
  • Partially Active: ⚠️
  • Inactive: ❌
  • Not Installed: ✘

Users can click on the activity status to view more detailed information about the activity status of each stream license. Activity Detail

Setting Up Inactivity Notifications

Users can also set up inactivity notifications for their stream licenses. This will notify user via email if there's no activity on the license for a defined period of time. This can be done through the "Setup Notification" dropdown located in the manage section of the license settings.

Notification

  1. Navigate to the "Manage" section of your license settings.
  2. Locate the "Setup Notification" dropdown.
  3. Choose your desired notification settings.
  4. Ensure that the notification interval is set to more than 8 hours to avoid unnecessary notifications.

Notification Settings

By utilizing the Stream Activity Monitor feature and setting up inactivity notifications, users can effectively monitor the status of their streams and stay informed about any potential issues.

Using Our Monitoring Script

Stream Monitor checks Stream status through its logs. It exposes a single API endpoint that returns the status of each camera (running or offline). The command python stream_monitor.py starts a web server that returns the status of each camera. For example:

{
"active": true,
"cameras": {
"camera-1": {
"status": "running"
}
}
}

See instructions and examples on our GitHub.