Arno Dirlam

Elixir Dev, Mentor & Consultant @ Team Engine Ltd

Arno has been using Elixir since 2016, when he was blown away by the elegance and simplicity that Elixir brings to the table. Now, he helps software engineering teams make the most of Elixir and its wonderful ecosystem. He’s repeatedly experienced first-hand, how quickly developers pick up this language and become productive with it. Arno’s role is to help facilitate this learning process and evolve teams, both in size and knowledge, to enable them to continuously deliver features and improvements without compromising on long-term maintainability of the code base.

Run Elixir in the database using Dx

Imagine you could write Elixir code as if all Ecto data is already loaded. With pattern matching to match associations; Enum functions to navigate associated data; accessing fields in associations without a second thought. Even using data from non-associated schemas without having to think about data loading at all, just using Enum functions to slice and dice the data as needed.

This is what the Dx library does. Just like Nx (numerical Elixir) translates Elixir code to run optimized for the GPU, Dx (data-driven Elixir) translates Elixir code to run optimized for the database. It translates your code either to Ecto queries, or to a version with automatic data loading, optimized using batching and concurrency.

This makes for clear and easy-to-read Elixir code that’s structured in modules and functions as usual, without any need to implement data loading. The code is easier to maintain and refactor, compared to implementations with Ecto queries and/or preloading, yet efficient.

Key Takeaways:

  • Getting to know Dx as a new option for data-driven applications
  • Lots of examples with code plus what queries it executes
  • Application architecture fit: Functional core & Imperative shell
  • Restrictions and caveats
  • Glimpse into how it’s implemented
  • State of development and future plans

Target Audience:


  • working with Ecto a lot
  • interested in software architecture
  • interested in the Elixir compiler
  • interested in new approaches and the overall ecosystem