Upgrade to Pro — share decks privately, control downloads, hide ads and more …

The Road to Ultra Low Latency

The Road to Ultra Low Latency

Delivering "better than broadcast" live streams presents a number of technical challenges, and achieving ultra-low latency is certainly near the top of the list. But "challenging" doesn't mean impossible -- and Akamai can help. Join this session to learn how you can leverage the latest features of the Common Media Application Format (CMAF) with Akamai Media Services Live to create live streams with ultra-low latency for amazing video experiences.

Akamai Developer

October 11, 2017
Tweet

More Decks by Akamai Developer

Other Decks in Technology

Transcript

  1. © AKAMAI - EDGE 2017 The Road to Ultra Low

    Latency Streaming Phillip Harrison, Enterprise Media Architect
  2. © AKAMAI - EDGE 2017 What we’ll cover q Where

    latency stands today q Where the road diverges q What technology is coming next q Demo
  3. © AKAMAI - EDGE 2017 1. Start up time does

    not impact latency and vice versa. 2. Hand wave latency is the sum total of many delays in the live workflow chain. 3. The player chooses the start position and then builds the buffer to the live edge. 4. Multicast, WebRTC, UDP technologies complement low latency. 5. Low latency is always a trade-off between quality and latency. But first some definitions…
  4. © AKAMAI - EDGE 2017 Other areas to Optimise… Encoding

    Shift encoder priority to from quality to latency optimisation Packaging Use smaller segment sizes Ingest Ensure ingest server is close to encoding facility CDN Optimise CDN mid-tier for fast transfers Last Mile Ensure server close to end users for short round trip time Player Optimise start-up buffer logic to be as close to live as possible
  5. © AKAMAI - EDGE 2017 IPP Encoding • Encoding with

    zero input buffering: • I-Frame and P-frames only (No B-Frames) • Encoder should output frame as soon as CPU has encoded • Higher input framerates will lead to lower encoding latency. Use 50/60p if possible.
  6. © AKAMAI - EDGE 2017 Encoding delay First-mile upload CDN

    propagation Last mile delivery Player buffer D = Segment duration Min(1xD, 5) 0.25xD 1xD 0.25xD 3xD Total 5.5xD 5 2.5 10 2.5 30 10s 50s 2 0.5 2 0.5 6 2s 11s Why use short segments?
  7. © AKAMAI - EDGE 2017 2 Second Segment sizes 10

    Second Segment sizes 1 Second Segment sizes? Graphic Credit: Wowza
  8. © AKAMAI - EDGE 2017 • Future Proof • Described

    my m3u8 or MPD • Sub Segment Feature • Efficient • High compatibility • Generally only m3u8 • No Sub segment • Redundant data
  9. © AKAMAI - EDGE 2017 CMAF Sub Segment moof mdat

    Encoder output timestamp mdat moof moof moof moof moof Encoder output timestamp Encoder output timestamp Encoder output timestamp Encoder output timestamp Encoder output timestamp 6 Second Segment with 1 Fragment (1 moof + 1 mdat) 6 Second Segment with 6 Fragments (6 moof + 6 mdat)
  10. © AKAMAI - EDGE 2017 HTTP/1.1 200 OK Content-Type: video/mp4

    Transfer-Encoding: chunked 4C4B4 ��X�SS�����X�ST0����ґm��1^#ů��� U�)�p��sj!�)CN|,R*��w�KO|�Z*� 4C4B4 �������X�US�����X�UT0����ґm�� 1^#ů�鲧U�)�p�� ��X�SS�� U�)�p� �� 1^#ů 4C4B4 ��X�SS�����X�ST0����ґm��1^#ů��� U�)�p��sj!�)CN|,R*��w�KO|�Z*� 4C4B4 �������X�US�����X�UT0����ґm�� 1^#ů�鲧U�)�p�� 4C4B4 ��X�SS�����X�ST0����ґm��1^#ů��� U�)�p��sj!�)CN|,R*��w�KO|�Z*� ��X�SS�� U�)�p� GET /ull/v_0_640x360-1507596336.m4s HTTP/1.1 User-Agent: curl/7.37. Host: pharriso.akamaized.net Accept: */* HTTP Chunked Transfer Encoding
  11. © AKAMAI - EDGE 2017 HTTP Chunked Transfer Encoding Upload

    SubSegments to CDN while Segment is still being created ENCODER INGEST ORIGN CDN PLAYER Creates 1s segments with 500ms SubSegments (Fragments) and uploads via HTTP Chunked Transfer Encoding Bytes streamed to multiple Live Origins Player requests segment that is still being encoded Request goes forward to Origin Origin streams bytes to Edge Bytes streamed to client and object stored in cache once complete
  12. © AKAMAI - EDGE 2017 Seconds in the buffer 0

    1 2 3 4 5 6 7 QUIC+H2+Fetch API Standard
  13. © AKAMAI - EDGE 2017 Summary q Fragmented MP4 (CMAF)

    q Chunked Transfer Encoding q Fetch API, H2, QUIC q MPEG-DASH
  14. © AKAMAI - EDGE 2017 Manifest at the Edge #EXTM3U

    #EXT-X-TARGETDURATION:1 #EXT-X-VERSION:7 #EXT-X-MEDIA-SEQUENCE:1503290621 #EXT-X-INDEPENDENT-SEGMENTS #EXT-X-MAP:URI="v_0_640x360-init.mp4” #EXTINF:1, #EXT-X-PROGRAM-DATE-TIME:2017-08-21T04:43:40.00+0000 v_0_640x360-1503290620.m4s #EXTINF:1, #EXT-X-PROGRAM-DATE-TIME:2017-08-21T04:43:41.00+0000 v_0_640x360-1503290621.m4s #EXTINF:1, #EXT-X-PROGRAM-DATE-TIME:2017-08-21T04:43:42.00+0000 v_0_640x360-1503290622.m4s Now Now Now -1 Now +1