loading...
Cover image for WebRTC Audio Conferencing Architecture

WebRTC Audio Conferencing Architecture

cedricfung profile image Cedric Fung Updated on ・1 min read

Today I released my audio conferencing service on GitHub https://github.com/MixinNetwork/kraken.fm

Kraken is an instant and anonymous audio conferencing service built with WebRTC technology. People can join the room with their browsers, no need to download or install any software.

For the server side, we are using Pion, which is a pure Go implementation of WebRTC, specifically, we are using ION, which is an SFU built with the Pion WebRTC library.

  const constraints = {
    audio: true,
    video: false
  };
  const configuration = {
    iceServers: [{
      urls: "turn:34.85.105.240:443",
      username: "webrtc",
      credential: "turnpassword"
    }],
    iceTransportPolicy: 'relay',
    bundlePolicy: 'max-bundle',
    rtcpMuxPolicy: 'require',
    sdpSemantics: 'unified-plan'
  };

The code above should expose Kraken's core technology choices:

  1. Audio only
  2. All peers relay through TURN
  3. All peers forward with SFU, e.g. ION
  4. Unified plan for RTP stream bundle
  5. Enforced RTCP MUX

With these decisions, Kraken can handle hundreds of peers in a room without quality sacrifice. TRUN and the SFU connect with internal virtual network, which gives them more reliable connections.

Peers connect through TURN to increase the connection reliablity and reduce initial connection time. The SFU allow each peer to upload only one stream to connect with hundreds of peers.

We have an instant room for DEV Community https://kraken.fm/dev

Discussion

pic
Editor guide
Collapse
sibi profile image
sibi

Great job @cedricfung . I love kraken.fm/, been using this from the past couple of days, works like charm. I'm new to the pion community, excited to build something out of it. Wondering why Kraken was restricted to only audio? any specific reason. Thanks again for building Kraken.

Collapse
cedricfung profile image
Cedric Fung Author

Wow, thank you for the praise. I build Kraken for our remote team, and we use it everyday. Most of the team members are developers and we don't have the habit or need to show the face or any other video. And audio only will ensure high quality of the conversation at most time, even with more than 10 participants.

Collapse
sibi profile image
sibi

ah! that totally makes sense. Thanks for your response.
I am on a mission in building it too. I will share my version once I build it.

Thread Thread
cedricfung profile image
Cedric Fung Author

Great. Is your version also audio only?

Thread Thread
sibi profile image
sibi

targeting both video and audio.

Thread Thread
cedricfung profile image
Cedric Fung Author

Someone is building one with Pion github.com/jeremija/peer-calls

Thread Thread
sibi profile image
sibi

wow. this looks like a full product. great stuff.

Collapse
ramesh profile image
Ramesh Elaiyavalli

@cedricfung - Great initiative. WebRTC is very powerful.

  1. Create audio-only experiences. Secure 1:1 or team calls.
  2. Video chats and screen share.
  3. Most interesting is RTCDataChannel. You can do so much with that. From in-session chat to p2p file shares, to Augmented reality.

Pion is a great library. No doubt. Happy to help any way I can.

Keep building.