Use the Instant TV feature
Dynamically create a manifest that points to segments of a live stream.
The Instant TV feature allows your stream viewers to request a clip at a specified start time during a live event. If they join the event at a point in the stream after the start time, they can jump back to the beginning and watch from there. You can use this feature without changing the manifest published on the encoder or restarting the encoder.
-
startTime
: Time in epoch format that the event begins or where you want to start the program from. -
endTime
: You can define a specific time in epoch format, but this is optional. If theendTime
is not defined, MSL4 will generate a live event manifest for the stream.
You should give a startTime
within 12 hours of the current time. Otherwise, the start of the event will be trimmed to 12 hours and the streaming edge servers will continue to serve the content but only for the last 12 hours.
URL syntax
If the event has not ended or the endTime
isn't defined, use this URL syntax:
http://CDN_HOSTNAME/master-archive.m3u8?startTime=$startTime
http://CDN_HOSTNAME/master-archive.mpd?startTime=$startTime
HLS examples:
http://testing.com.akamaized.net/hls/live/2020842/instant_tv_hls_jul10_test1/master-archive.m3u8?startTime=1594425896
http://testing.com.akamaized.net/hls/live/2020842/instant_tv_hls_jul10_test2/master-archive.m3u8?startTime=1594427399
DASH examples:
http://cpcode.akamaized.net/dash/live/2020326/instant_tv_dash_jul10_test1/dash-archive.mpd?startTime=1594428064
http://cpcode.akamaized.net/dash/live/2020326/instant_tv_dash_jul10_test2/dash-archive.mpd?startTime=1594428219
If the event has already ended, use this URL syntax:
http://CDN_HOSTNAME/master-archive.m3u8?startTime=$startTime&endTime=$endTime
http://CDN_HOSTNAME/master-archive.mpd?startTime=$startTime&endTime=$endTime
To enable this feature, choose the Advanced Archive option.
Update your Adaptive Media Delivery property
In order to apply this feature, you need to change a few settings in your Adaptive Media Delivery property configuration.
-
In Property Manager, set the match criteria to match on archive manifest file extensions
.m3u8
or.mpd
with properly formatted Query String Parameters in the request URLs.This example also shows
endTime
, but that's optional. -
Add a Cache Key Query Parameters behavior to include
startTime
as an exact match (endTime
is optional). -
Add a Caching behavior to Force revalidation of stale objects with origin.
-
If you're using token authentication with Instant TV, you need to need to enable Token in URI and add
master-archive.m3u8
in the Master Manifest Files list.
You can also include a Filename match criteria to match on
-archive
. This prevents requests for other manifest files that includestartTime
andendTime
as query string parameters from being interpreted as Instant TV requests.
Updated about 3 years ago