persist_setup_timeout
The `persist_setup_timeout` directive sets the timeout duration for persistently setting up sessions in the Kaltura Media Framework.
Description
The persist_setup_timeout directive specifies how long the NGINX server will wait for a persistent session to be established with the Kaltura Media Framework. This timeout value is crucial for ensuring that sessions do not hang indefinitely and helps manage resources effectively. If the session setup exceeds this specified time, the request will be terminated, potentially reducing server load and avoiding long wait times for users.
This directive takes a single argument, which is intended to be a time duration. The format follows typical NGINX time specifications, allowing for various time units like seconds, minutes, or hours. When configuring persist_setup_timeout, it is essential to choose a timeout value that balances performance and user experience. A very short timeout may lead to frequent session failures, while an overly long timeout can result in delayed responses and resource allocation issues.
In practice, this directive should be set in the relevant NGINX configuration block that handles Kaltura API requests. It is particularly effective in high-traffic scenarios where multiple streaming sessions are being established concurrently, ensuring that resources are allocated efficiently and clients receive timely responses.
Config Example
persist_setup_timeout 30s;
Ensure the timeout value is appropriate for your application's expected latency.
Avoid setting an excessively long timeout to prevent resource exhaustion on the server.
Be aware of the impact on user experience when sessions timeout too quickly.