Wowza media streaming engine delete files while streaming
I'm working on an application and used this library to do RTMP live streaming toward a wowza streaming engine. If your setup archives the live stream as progressive mp4s, consider delivering them using Fastly's OTFP service.I really appreciate your work on this library, especially maintenance and support you do here! If your VOD manifest has the same URL as the live one, purge the live stream video manifest or wait for the caches to invalidate (as they will be set with low TTLs). Most encoders generate a separate video manifest when making the same live stream available for VOD. Take advantage of surrogate key purgingĪll video segments and the manifest for a live stream can be purged using a single API call by using Fastly's surrogate key feature. These metrics can help you analyze throughput and may help you determine reasons a video player might switch quality levels during ABR playback. -length and resp.body_bytes_written (actual bytes sent to client compared to what was expected to be sent).server.datacenter (the Fastly POP that served the request).req.restarts (number of request restarts typically indicates retry attempts).(network path Fastly is sending the client response).client.requests (number of requests on a connection so far)._snd_mss (maximum segment size used to send responses to client)._delta_retrans (number of packets re-transmitted to the client).client.as.number and client.as.name ( autonomous system number and name associated with client IP).time.elapsed (time since the request started, which can be used to calculate response time or time-to-last-byte for both origin and clients).time.to_first_byte (time from client request to the first byte being received).fastly_info.state (cache hits or misses).Configure real-time log streamingįor troubleshooting and debugging live streaming delivery issues, configure real-time log streaming and include TCP connection, caching, and different time-related metrics in vcl_log. Consider setting up failover (fallback) originsĬonsider configuring your VCL to allow your origins to failover from high-profile primary streams to alternate streams in case of encoder failures or other issues (e.g., high resource utilization). Typically, these values should be configured such that Fastly can also retry another origin (if configured) before sending the appropriate response on client requests. For example, for a live stream with 5s video segments, set the Origin Connect value to 1s and the First Byte and Between Bytes timeout values to 2s. Set appropriate origin timeouts to ensure new live stream segments are downloaded from origin in a timely manner. For example, enable BBR only for clients within a specific ASN or ISP network like a mobile or wireless network. TCP optimizations can be applied conditionally rather than applying them to all clients. Unlike the default CUBIC congestion control algorithm, which is packet-loss-based and latency-insensitive, BBR is designed to maximize bandwidth while controlling latency. The BBR TCP congestion control algorithm is an optional, TCP-related configuration that can help improve a client's experience. Enable the experimental BBR congestion algorithm Sub vcl_fetch Ĭonfigure automatic gzipping for manifest files based on their file extension or content-type using the following table as a guide: HTTP streaming formatĪpplication/x-mpegurl, application/Īpplication/f4m (for manifest), application/octet-stream (for bootstrap)Ĭonfigure a CORS header on your service to play audio or video content on a different domain. It can also be added to your service using VCL Snippets: The following VCL sample may help you implement different TTLs for video manifest and segments. For long DVRs and live-to-VOD transitions, set segment TTLs longer on shields and shorter on edge POPs such that they are served from memory (that is, less than 3600s). We recommend setting manifest file TTLs to less than half of the video segment duration, typically 1-2 seconds for 5-second video segments. In live streams, video manifests are periodically refreshed when new segments become available, specially for HLS. Configure video manifest and segment caching TTLs If your setup includes primary and alternate origins (e.g., for high profile live streams), be sure to select a shield POP close to each origin, one for each origin you define. Configure shieldingĬonfigure shielding by designating a specific shield POP for your origin to ensure live streams remain highly available within the Fastly network. When configuring VCL to deliver live streams, we recommend following these guidelines, which Customer Support can help you with. The Fastly network can deliver live streams for any HTTP streaming technology, archived or recorded, on any public or private cloud storage service.