Systems | Development | Analytics | API | Testing

Advanced Ecto for Elixir Monitoring with AppSignal

In our previous article, we explored the basics of monitoring Ecto with AppSignal, covering everything from initial setup to tracking key metrics such as query execution time and resource consumption. We even set up custom instrumentation for database connection pools to gain deeper insights into our application's performance. However, setting up monitoring is just the first step toward maintaining a healthy, high-performing Elixir application.

Deploying Phoenix Applications with Kamal

Deploying Phoenix applications in production environments poses unique challenges due to Elixir and the Erlang Virtual Machine (VM). The ecosystem offers multiple strategies — ranging from releases to mix-based approaches (as detailed in the Phoenix Deployment Guide) — and various platforms employ different methods. While some rely on buildpacks (for example, Heroku and Gigalixir), others use containerization (like Fly).

Getting Started with Dialyzer in Elixir

Dialyzer (DIscrepancy AnaLYZer for ERlang programs) is a powerful static analysis tool that helps developers identify potential issues in their Elixir code without executing it. It excels at finding type mismatches, unreachable code, and unnecessary functions through sophisticated flow analysis. In part one of this two-part series, we'll first get to grips with the basics of Dialyzer. In part two, we'll examine more advanced use cases.

Building a Distributed Rate Limiter in Elixir with HashRing

Communication between processes in the Erlang VM happens through message passing. In fact, all communication across processes occurs through the same mechanism. All you need is an address and you can send a message to it, with the lower level building blocks being send and receive. This is true even if that address is on another node in a cluster of Elixir nodes that are aware of each other. In fact, it works in exactly the same way.

Out-of-the-box Elixir telemetry with Phoenix

Knowledge is power, and this is especially true for software. Telemetry puts software engineers in the driver's seat by exposing the underlying performance of a system. Identifying possible problems before they occur and proactively fixing them is better than waiting for users to point them out for you. Telemetry refers to the instrumentation of a system. When you use your web application and take action, you emit events.

Distributed Phoenix: Deployment and Scaling

In part one of this series, we managed distributed state using GenServers. This provided a foundation for understanding some core concepts in distributed Phoenix applications. Now, we turn our focus to deployment and scaling strategies. As your application evolves to meet growing demands, knowing how to scale horizontally, maintain high availability, and monitor distributed components becomes crucial.

How to Track Errors in Oban for Elixir Using AppSignal

When developing an Elixir app, you'll often need to handle tasks in a way that does not interrupt the normal user request-response cycle. Tasks like sending emails are great examples of jobs that should be delegated to a capable background job processing service. In the Elixir ecosystem, Oban is one such background job processing library. In this article, we'll learn what Oban is, how it works, and how to instrument it using AppSignal.

Managing Distributed State with GenServers in Phoenix and Elixir

Phoenix and Elixir are designed at their core to build real-time, fault-tolerant applications. With its elegant syntax and the robustness of the Erlang VM, Elixir is an ideal candidate for tackling the challenges of distributed state management. This two-part series will guide Phoenix/Elixir developers through the intricacies of working with Phoenix in a distributed setup.

Find and Fix N+1 Queries Using AppSignal for a Phoenix App in Elixir

N+1 queries are a frequent issue in complex applications built with Elixir and Phoenix. These queries can silently degrade application performance, often going unnoticed until they've compounded into a significant problem. They can substantially increase web page load times, as each additional query adds overhead to a database, consuming more time and resources. That's why it's crucial to detect and resolve N+1 queries to optimize production systems.