3 ms·
Did you use live view for those projects? If so, what sort of scale are they? I've been seriously considering learning Elixir+Phoenix, but don't whether live vi
by zamalek 3y ago
Did you use live view for those projects? If so, what sort of scale are they? I've been seriously considering learning Elixir+Phoenix, but don't whether live view is suitable for serious projects (where serious blog project ∉ serious projects).
- benzible 3y agoCheck out this recent talk about cars.com moving to LiveView: https://www.youtube.com/watch?v=XzAupUHiryg https://www.youtube.com/watch?v=XzAupUHiryg Seems like most of their issues would not apply to a greenfield project and now that things are stable, they're quite happy with the choice. Traffic estimate: https://www.similarweb.com/website/cars.com/#overview https://www.similarweb.com/website/cars.com/#overview
- ricketycricket 3y agoAfter wondering this myself, I finally just went all in on LiveView and was extremely surprised at how efficient it was. I have had over 4,000 concurrent users on a single LiveView with real-time messaging, streaming transcriptions, viewer counter updates (don't use presence for this), and the typical interactivity (signing on, navigating, etc.). On a single 8-core machine it maxed at 20% CPU during the few minutes everyone was signing on (via OAuth) and idled at less than 5%. RAM never exceeded 900MB. I've since distributed the same application into EMEA and APAC to provide better latency for those users (which takes libcluster and about 20 lines of config to set up), and zero problems with that either.
- Existenceblinks 3y agoYou have to provide how your view looks like, because a large part of memory consumption coming from diffs that server keeps. Each session will have their similar diffs.
- ricketycricket 3y agoOf course, each case will be unique. I heavily optimized with temporary assigns so the message lists would not be persisted in server memory. This is even better now with the new streams functionality. The knobs to tweak are there.
- sph 3y agoNot a direct answer but the BEAM, Elixir and LiveView are ridiculously easy to scale vertically (i.e. add more CPU and RAM, the scheduler takes care of everything else), and horizontally (cluster forming and distribution of processes among multiple nodes is a first-class feature) If people build multi-billion dollar companies on top of PHP and Node.js, I would not even be concerned about scaling Phoenix.