Manage Your Application’s Memory Effectively

Software depends on memory to run properly. You won’t necessarily get big performance boosts by using less memory, but you’ll be able to scale your application to more users while using fewer servers if you think about how memory is used by your application. You can use a few simple techniques to dramatically reduce your exposure to memory problems in Elixir applications.

The main principle that we’ll cover in this section is memory allocation and garbage collection. Elixir doesn’t have a radical garbage collector, but it has key differences when compared to other languages. We’ll cover how garbage collection works before looking at how short-life and long-life processes differ in memory usage. You’ll ...

Get Real-Time Phoenix now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.