Tracing with the :dbg module

Having seen how to profile the modules and functions of our application, let's now explore how to do tracing in a live environment. While in the previous section, we had to provide the data for the function we wanted to profile as input, in this section we'll follow a different approach. We will tell the VM the functions that we want to see traced, and then we'll observe the live calls that our users are making in production. This is really interesting because we're analyzing the behavior of our application with real data, which usually allows us to draw better conclusions. Moreover, as we discussed previously, there are certain bugs that only manifest themselves in a live environment. In such cases, we need to ...

Get Mastering Elixir 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.