Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
Company Confidential: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED.
Server-side WebRTC
Infrastructure
Chad Hart
Dire...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 2
About Me
Sr. Director, Product Marketing Blogg...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 3
Dialogic Overview
Experienced
Over 25 years co...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 4
WebRTC Server Considerations
Signaling
NAT
Tra...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 5
WebRTC is not 100% Peer-to-Peer
Server
client ...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 6
WebRTC Signaling Servers Relay SDP between Cli...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 7
Signaling Considerations Outside of WebRTC
Use...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 8
The NAT Traversal Problem
Image source: webrtc...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 9
How does WebRTC Traverse Firewalls & NATs?
med...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 10
Interactive Connectivity Establishment (ICE)
...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 11
STUN – What is my external IP address?
Signal...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 12
TURN will relay your media
media
client
Signa...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 13
Comparing STUN vs. TURN
STUN Server TURN Serv...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 14
Peer-to-Peer vs. Peer-to-Server
Server
client...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 15
Many Reasons for a Media Server
Conferencing ...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 16
Who do You Care About More?
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 17
Bandwidth is not Always Ubiquitous or Free
Cl...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 18
CPU & Processing Power is Expensive
Client vi...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 19
Multi-PARTY! Video Conferencing
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 20
Easy & Cheap Approach to Multi-party: Mesh
20...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 21
Mesh does not Scale for Many Video Conferees
...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 22
Traditional Telephony Approach: MCU
22
Multip...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 23
Traditional MCU Resource Usage
23
Worst-case ...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 24
Efficient MCU Resource Usage
24
Efficient pro...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 25
Resource Efficient MCU with Encoder Sharing
3...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 26
Newer Approach: SFU
26
SFU
Selective Forwardi...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 27
Newer Approach: SFU
27
SFU
Selective Forwardi...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 28
New WebRTC Approach: Simulcast
28
SFU
High bi...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 29
A look at Google Hangouts with Simulcast
http...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 30
Future Approach with VP9 – SVC?
30
SFU
Medium...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 31
Multi-party video summary comparison
http://n...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 32
Many Reasons for a Media Server
Conferencing ...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 33
Case Study: Video Recording Service
Applicati...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 34
Core WebRTC Gateway & Peripheral Functions
HT...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 35
WebRTC Gateways Come in Many Packages
API Gat...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 36
Example: Large, Web-Centric Network Architect...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 37
WebRTC Servers Summary
Server Type Why/when y...
COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 38
Questions?
Upcoming SlideShare
Loading in …5
×

Server-side WebRTC Infrastructure

10,270 views

Published on

Mid-level review of server infrastructure that is required and often used with WebRTC, including signaling servers, NAT traversal servers (STUN and TURN), media servers, and WebRTC Gateways.

Presented at the WebRTC Japan Conference in Tokyo.

Published in: Technology
  • Be the first to comment

Server-side WebRTC Infrastructure

  1. 1. Company Confidential: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. Server-side WebRTC Infrastructure Chad Hart Director, Product Marketing WebRTC Japan Conference 5 Feb 2015
  2. 2. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 2 About Me Sr. Director, Product Marketing Blogger & Chief Editor
  3. 3. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 3 Dialogic Overview Experienced Over 25 years connecting and adding value to Enterprise and Service Provider Networks Global presence US HQ (New Jersey) / 20+ Regional offices Strengths Products are widely deployed Impacting 4+ billion mobile subscribers 15+ Billion VoIP minutes / month Excellent Support Customers include 48 of top 50 mobile carriers and 80% of the Fortune 1000 Approximately 200 patents issued or pending Key Product & Services Rich Media Processing PowerMedia: Media Server / IMS MRF / SR140 Class 4 Softswitch / IMS MGCF and VoIP Gateways Mobile Signaling / Diameter Signaling Controllers
  4. 4. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 4 WebRTC Server Considerations Signaling NAT Traversal Media Gateway
  5. 5. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 5 WebRTC is not 100% Peer-to-Peer Server client client media
  6. 6. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 6 WebRTC Signaling Servers Relay SDP between Clients Real WebRTC Session Description Protocol (SDP) example (partial) Source: webrtchacks.com/sdp-anatomy
  7. 7. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 7 Signaling Considerations Outside of WebRTC User authentication Security & access controls Mobile push services Federation The rest of your application
  8. 8. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 8 The NAT Traversal Problem Image source: webrtcHacks - https://webrtchacks.com/stun-helps-webrtc-traverse-nats/
  9. 9. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 9 How does WebRTC Traverse Firewalls & NATs? media FW & NAT FW & NAT client client 10.10.1.1 192.168.10.1200.2.20.2 2 100.1.10.1 1 Signaling Server
  10. 10. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 10 Interactive Connectivity Establishment (ICE) A protocol for establishing a peer-to-peer media connection between peers behind NAT and firewall devices. ICE requires 2 kinds of servers: 1. STUN 2. TURN
  11. 11. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 11 STUN – What is my external IP address? Signaling Server media client 10.10.1.1 200.2.20.2 2 What is my external IP address? FW & NAT STUN Server Your IP address is 200.2.20.22
  12. 12. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 12 TURN will relay your media media client Signaling Server TURN Server STUN Server client
  13. 13. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 13 Comparing STUN vs. TURN STUN Server TURN Server What it does? Returns an external IP address Relays media When is it needed? Almost always Rarely How much does it cost to operate? Inexpensive Expensive Does it affect voice quality? No Possible
  14. 14. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 14 Peer-to-Peer vs. Peer-to-Server Server client client media Peer-to-Peer client client Media Server Signaling Server Peer-to-Server
  15. 15. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 15 Many Reasons for a Media Server Conferencing InterworkingTranscoding Stream processingRecording Person-to-machine
  16. 16. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 16 Who do You Care About More?
  17. 17. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 17 Bandwidth is not Always Ubiquitous or Free Client-side Server-side
  18. 18. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 18 CPU & Processing Power is Expensive Client view Provider View
  19. 19. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 19 Multi-PARTY! Video Conferencing
  20. 20. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 20 Easy & Cheap Approach to Multi-party: Mesh 20 Full Mesh Works for a few parties No server cost Lowest latency
  21. 21. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 21 Mesh does not Scale for Many Video Conferees 21 Full Mesh Clients get overloaded Encode costs more than decode Limited uplink bandwidth Inconsistent performance across participants
  22. 22. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 22 Traditional Telephony Approach: MCU 22 Multipoint Control Unit (MCU) Good at manipulating all media Transcoding Transizing Transrating Interworking Server-side CPU intensive Client can request different conference mixes Usually client friendly Downsizing & mixing can reduce bandwidth Fewer client streams to process MCU
  23. 23. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 23 Traditional MCU Resource Usage 23 Worst-case process: 1. Each stream decoded at the MCU 2. MCU mixes each conferee 3. MCU encodes individual mix for each conferee MCU 1 1 2 2 3 3 4 45 5 6 6 Ingress streams 6 Egress streams 6 MCU decodes 6 MCU encodes 6
  24. 24. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 24 Efficient MCU Resource Usage 24 Efficient process: 1. Each stream decoded at the MCU 2. MCU mixes each conferee 3. MCU shares same encoder for all conferees MCU 1 2 3 4 5 6 Ingress streams 6 Egress streams 6 MCU decodes 6 MCU encodes 1 1
  25. 25. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 25 Resource Efficient MCU with Encoder Sharing 30%-50% reduction in compute resources 0% 20% 40% 60% 80% 100% 1 2 3 4 5 6 7 8 9 10 11 15 17 20 SystemCPUUtilization Conferees Encoder sharing vs. multi-encode Traditional MCU Dialogic Evolved MCU
  26. 26. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 26 Newer Approach: SFU 26 SFU Selective Forwarding Unit (SFU) routing Clients send one & receive many Client can instruct SFU which streams to send High throughput Can be lots of downlink bandwidth Low latency
  27. 27. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 27 Newer Approach: SFU 27 SFU Selective Forwarding Unit (SFU) routing Clients send one & receive many Client can instruct SFU which streams to send High throughput Can be lots of downlink bandwidth Low latency
  28. 28. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 28 New WebRTC Approach: Simulcast 28 SFU High bitrate Low bitrate Selective Forwarding Unit (SFU) with Simulcast Clients send multiple streams to SFU one high-bit rate one or more lower-bit Client directs SFU which streams to receive Reduces bandwidth vs. SFU Simulcast in WebRTC coming
  29. 29. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 29 A look at Google Hangouts with Simulcast http://webrtchacks.com/hangout-analysis-philipp-hancke/
  30. 30. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 30 Future Approach with VP9 – SVC? 30 SFU MediumHigh LowLayered bitrates: Selective Forwarding Unit (SFU) with Scalable Video Coding (SVC) Clients send layered stream to SFU Layers have varying bitrates – time, size, quality SFU directs who gets what Coming to WebRTC eventually
  31. 31. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 31 Multi-party video summary comparison http://networkfuel.dialogic.com/webrtc-whitepaper
  32. 32. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 32 Many Reasons for a Media Server Conferencing InterworkingTranscoding Stream processing Person-to-machineRecording
  33. 33. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 33 Case Study: Video Recording Service Application highlights Record live events – E.g. Kids soccer game Share event recording with family/friends – Multi-party stream Many Recording Formats .3GP .mp4 .wav Many Codecs G.711, Opus, AMR-NB and AMR- WB (voice) VP8, H.264 (video) Message Storage Local storage Remote message deposit via MSRP HTTP/ MSRP REST (HTTP) Application Server Media Server Message Storage RTP (media) Solution Highlights Software-based Media Server Virtualized (VM) and COTS deployment High Availability and Geographical Redundancy Scalability via Media Resource Broker Architected to support 3.5M Subscriber Network Recording Remote Message Deposit Key Functions Transcoding WebRTC Signaling WAN
  34. 34. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 34 Core WebRTC Gateway & Peripheral Functions HTTP-to-SIP (H2S) Media GW Transcoder Web SIP SBC STUN Server TURN Server API Gateway Regulates API calls Provides media anchoring for NAT Traversal Tells a client what its IP address is Converts non- standard web signaling to SIP Web SDK/ Widget Mobile SDK/ Widget Kit for adding Calls to webpage Kit for adding Calls to native applications Converts one codec to another, trans-rates/sizing Encryption & transport interworking SIP interworking, media binding, and security
  35. 35. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 35 WebRTC Gateways Come in Many Packages API Gateway H2S Media GW SBC Transcoder STUN Server TURN Server API Gateway H2S Media GW SBC Transcoder STUN Server TURN Server H2S Media GW Transcoder SBC API Gateway STUN Server TURN Server API Gateway H2S SBCMedia GW Transcoder STUN Server TURN Server API Gateway H2S SBC Media GW Transcoder STUN Server TURN Server API Gateway H2S Media GW SBC Transcoder STUN Server TURN Server
  36. 36. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 36 Example: Large, Web-Centric Network Architecture Web server SIP/IMS Network SIP Web Media Gateway Firewall APIManager API Calls H2S Server Identity Server App Server App Server WSS server STUN/ TURN Internal REST APIs WebRTC Browser
  37. 37. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 37 WebRTC Servers Summary Server Type Why/when you need it Signaling Server Required to setup a WebRTC session STUN Server Provides NAT traversal as part of ICE protocol TURN Server Relays media when direct connection cannot be established Media Server Provides conferencing, recording, media interworking, transcoding, stream processing WebRTC Gateway Interworks signaling and media with existing VoIP networks
  38. 38. COMPANY CONFIDENTIAL: © COPYRIGHT 2015 DIALOGIC INC. ALL RIGHTS RESERVED. 38 Questions?

×