WebRTC Infrastructure the Hard Parts: Media

24
COMPANY CONFIDENTIAL © COPYRIGHT 2015 DIALOGIC CORPORATION. ALL RIGHTS RESERVED. 1 COMPANY CONFIDENTIAL © COPYRIGHT 2015 DIALOGIC CORPORATION. ALL RIGHTS RESERVED. WebRTC Infrastructure: THE HARD PARTS WebRTC Global Summit

Transcript of WebRTC Infrastructure the Hard Parts: Media

Page 1: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  1  

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  

WebRTC  Infrastructure:  THE  HARD  PARTS  

WebRTC  Global  Summit  

Page 2: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  2  

Why  Terminate  Media?  

NAT  Traversal:  TURN   Gateway   Media  Server  

Page 3: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  3  

NAT  Traversal:  TURN   Gateway   Media  Server  

Why  Terminate  Media?  

TURN  Server  

TURN  for  NAT  Traversal  

Page 4: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  4  

NAT  Traversal:  TURN   Gateway   Media  Server  

Why  Terminate  Media?  

Gateway  for  Interworking  

Web  signaling  

WebRTC  media  

SIP  

VoIP  media  

GW   SIP

Page 5: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  5  

NAT  Traversal:  TURN   Gateway   Media  Server  

Why  Terminate  Media?  

Media  Servers  for…  

Page 6: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  6  

Many  Reasons  for  a  Media  Server  

Conferencing   Interworking  Transcoding  

Stream  processing  Recording   Person-­‐to-­‐machine  

Page 7: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  7  

Why  process  media  server-­‐side?  

Page 8: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  8  

Many  Reasons  for  a  Media  Server  Conferencing  

Conferencing  

Page 9: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  9  

Mesh  model  does  not  scale  

Distributed  peer-­‐to-­‐peer  mesh   Centralized  with  media  server  

Page 10: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  10  

Many  Reasons  for  a  Media  Server  Transcoding  

Transcoding  

Transcoding:  because  we  live  in  an  imperfect  world  

Page 11: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  11  

Many  Reasons  for  a  Media  Server  Server  Side  Media-­‐Processing  

Server-­‐side  media  handling  for:  ¥  ApplicaYon  work-­‐flows  ¥  Security  ¥  Compliance  ¥  Performance  ¥  Reliability  

Stream  processing  Recording   Person-­‐to-­‐machine  

Page 12: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  12  

Add  value  to  terminated  media  

+ Today  •  Audio  &  video  conferencing  •  MulY-­‐camera  switching  •  Compliance  recording  •  Speech  detecYon  •  Audio/video  inserYon  •  Speech  recogniYon  •  Automated  IVR  navigaYon  •  Speaker  CDR  analyYcs  

Not  too  far  away  •  Live  RTC  stream  distribuYon  •  Facial  recogniYon  •  Voice  fingerprinYng  •  Health  biometrics  •  Object  detecYon  •  Machine  vision  •  SenYment  analysis  •  Augmented  reality  

Page 13: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  13  

Many  Reasons  for  a  Media  Server  Conferencing  

Conferencing  

Page 14: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  14  

TradiOonal  MCU  Resource  Usage  

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  4  5  

5  6  6  

Ingress  streams   6  

Egress  streams   6  

MCU  decodes   6  

MCU  encodes   6  

Page 15: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  15  

Efficient  MCU  Resource  Usage  

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  

30%-­‐50%  reducYon  in  compute  resources  

Page 16: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  16  

Newer  Approach:  SFU  

SFU  

SelecOve  Forwarding  Unit  (SFU)  rouOng    Clients  send  one  &  receive  

many    Client  can  instruct  SFU  

which  streams  to  send    High  throughput    Can  be  lots  of  downlink  

bandwidth    Low  latency  

n  =  number  of  conferees  in  a  conference  

PerspecOve   Streams  

Client  

Server  (SFU)  

Network  

Page 17: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  17  

Newer  Approach:  SFU  

SFU  

SelecOve  Forwarding  Unit  (SFU)  rouOng    Clients  send  one  &  receive  

many    Client  can  instruct  SFU  

which  streams  to  send    High  throughput    Can  be  lots  of  downlink  

bandwidth    Low  latency  

n  =  number  of  conferees  in  a  conference  

PerspecOve   Streams  

Client  

Server  (SFU)  

Network  

Page 18: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  18  

New  WebRTC  Approach:  Simulcast  

SFU  High  bitrate  

Low  bitrate  

SelecOve  Forwarding  Unit  (SFU)  with  Simulcast    Clients  send  mulYple  

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  

Page 19: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  19  

Future  Approach  with  VP9  –  SVC?  

SFU  

Medium  High   Low  Layered  bitrates:  

SelecOve  Forwarding  Unit  (SFU)  with  Scalable  Video  Coding  (SVC)    Clients  send  layered  

stream  to  SFU    Layers  have  varying  bitrates  –  

Yme,  size,  quality  

  SFU  directs  who  gets  what    Coming  to  WebRTC  

eventually  

Page 20: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  20  

Media  server  network  model  

Load  Balancer  MRB  

Client   Client   Client   Client   Client   Client  

App  Server  App  Server  App  Server  

Media  Server  

Media  Resource  Broker:  Intelligent  load  balancer  &  orchestraYon  for  media  servers  

Page 21: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  21  

Pseudo  Call-­‐flow  with  a  media  server  

AS   MRB   MS1   MS2   Client  

Call  signaling  

Media  control  

MS1  status  MS2  status  

Media  control   Media  

Page 22: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  22  

Pseudo  Call-­‐flow  –  tradiOonal  fail-­‐over  with  RE-­‐INVITE  

AS   MRB   MS1   MS2   Client  

Call  signaling  –  REINVITE  with    new  addresses  

Media  control  

MS1  status  MS2  status  

Media  control  +  call  states  

Media  

Page 23: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  23  

Pseudo  Call-­‐flow  –  fail-­‐over  the  cloud/NFV  way  

AS   MRB   MS1   MS2   Client  

Media  control  

MS1  status  MS2  status  

New  container  

Media  

Memcache  &  Virtual  IP  Address  

Page 24: WebRTC Infrastructure the Hard Parts: Media

COMPANY  CONFIDENTIAL    ©  COPYRIGHT  2015  DIALOGIC  CORPORATION.    ALL  RIGHTS  RESERVED.  24  

Conclusions  

¥  TerminaYng  media  isn’t  cheap,  so  avoid  it  if  you  can  

¥  Like  it  or  not,  you  will  probably  need  server-­‐side  media  someYmes  

¥  If  you  need  server-­‐side  media,  maximize  the  value  you  get  from  it  

¥  Architectures  are  evolving  to  make  media-­‐processing  more  efficient  &  scalable