Skip to content
0:00 / 0:00

#phoenix#elixir#websockets

Gary Rennie - The Road to 2 Million Websocket Connections in Phoenix (ElixirConfEU 2016)

Erlang Solutions

18K subscribers • 48 videos on Hallway

YouTube
  • Recommended by 2 people: 2 in engineering communities.
  • A classic. People kept recommending it from 2016 to 2024.
  • Presented by Gary Rennie, member of the Phoenix core team
  • May be out of date. Uploaded 10 years ago, in an area where tools change fast.

Intermediate. Assumes working knowledge.

5.4K views10 years ago2 recommendations

Web developmentSystems programmingWeb performanceConcurrency and parallelismNetworking and protocols

Gary Rennie explains how the Phoenix team benchmarked and optimized Elixir to support two million concurrent WebSocket connections on a single machine.

Slides and more info: elixirconf.eu/elixirconf2016/gary-rennie This talk will discuss how the Phoenix team was able to create a single chat room with 2 million users on a single machine. Benchmarking WebSockets is a little more in depth than benchmarking HTTP requests, this talk covers the Tsung tool which was used for the benchmarks and how it can be configured for different testing scenarios. I will cover how Tsung was used to find the concurrent connection limits that Phoenix could handle. I will then cover the techniques that were used to find the parts of the Phoenix codebase with the bottlenecks that caused these limits and how these limits were overcome. Talk objectives Learn how to benchmark WebSockets using Tsung Explore how to find and fix bottlenecks. Target audience Anyone interested in Phoenix Channel performance. Gary is a member of the Phoenix core team, often found answering questions on StackOverflow for the elixir and phoenix-framework tags. He is developer at VoiceLayer using Elixir and Phoenix on a daily basis. Github: Gazler Twitter: @TheGazler

Why it's here

2 people recommend this

What people say. Recommended as a classic demonstration of the BEAM's concurrency capabilities and how to benchmark and resolve WebSocket bottlenecks.

u/sunnyohnoin r/elixir • Recommends

On “How complex it's to work with websockets or any persistent connection in elixir ”

First watch this to satisfy your itch: link to this video Then watch this, because this should sell you on the BEAM better than any other resource. It's my favorite video on Elixir/Erlang: link to this video Then search "Code BEAM" and "Elixir conf" talks on Youtube.

u/OlivanderTheSwiftin r/elixir • Recommends

The Road to 2 Million Websocket Connections in Phoenix (ElixirConfEU 2016)