Chris McCord - 10 lines of code


In Elixir: a Mini-Documentary
you talked about that 10 lines of code that you modified to make the codebase handle from 30k user to 2M, is that with Phoenix? and if it is, would you be kind to point me into that specific 10lines in the codebase?

I’m not 100% sure, but I think it is a reference to the work that is described in more detail in the article The Road to 2 million websockets.
There is a link to a commit in there (this link) which I expect might have contained the small changes that were made to improve the scaling, but it seems that the old references/branches do not exist any more, so the link is now effectively dead.


Some digging turned up the merge commit from that now-deleted branch. Here’s a working diff link:

and the originating PR: