vod_live_window_duration
The `vod_live_window_duration` directive defines the duration of the live window for video on demand (VOD) streaming in NGINX-based VOD Packager.
Description
The vod_live_window_duration directive is utilized within the NGINX-based video on demand (VOD) module to configure the length of the live streaming window. This parameter allows users to specify how much of the ongoing video stream should be made available to clients. By setting this duration, content providers can manage the viewing experience and control the delay on live streams, effectively determining how much past content is accessible to users.
The directive accepts a single argument, which should be specified in a time format (e.g., '10s', '1m'). When the duration is defined, the VOD module will allow clients to access video segments that fall within this specified time frame. For instance, if the vod_live_window_duration is set to '10s', clients will be able to request segments from the last 10 seconds of the live streaming content. This behavior is crucial for live events where timely content delivery is vital to maintain viewer engagement.
The configuration of this directive can be placed at different levels in the NGINX configuration hierarchy, including http, server, and location contexts, granting flexibility in how it is applied. It is typically used in conjunction with other directives that handle media streaming and buffering, ensuring smooth transitions between live and on-demand content.
Config Example
server {
listen 80;
location /live {
vod_live_window_duration 30s;
}
}Setting a very long duration can lead to outdated content being served, which may not be ideal for live events.
Make sure to test the performance when using this directive, as a larger live window may result in increased resource consumption.