# \#architecture

**URL:** https://forum.elixirforum.com/tag/architecture/103.md

[Latest](https://forum.elixirforum.com/latest.md) · [Categories](https://forum.elixirforum.com/categories.md) · [Tags](https://forum.elixirforum.com/tags.md)

---

## [Calculating P&L When a Trade Spans Multiple Sessions](https://forum.elixirforum.com/t/calculating-p-l-when-a-trade-spans-multiple-sessions/76271)

<div class="topic-metadata">

**Author:** [@ryanrborn](https://forum.elixirforum.com/u/ryanrborn)\
**Replies:** 0\
**Last updated:** [August 6, 2026, 3:26pm UTC](https://forum.elixirforum.com/t/calculating-p-l-when-a-trade-spans-multiple-sessions/76271 "2026-08-06T15:26:00Z")

</div>

A long-running process in my system owns a unit of work and everything it creates is scoped to that process’s id. When the process rotates on a schedule and a late event arrives from an external system, the event gets f…

---

## [ArchTest - Architecture rules as tests. Enforced from bytecode](https://forum.elixirforum.com/t/archtest-architecture-rules-as-tests-enforced-from-bytecode/74558)

<div class="topic-metadata">

**Author:** [@yoavgeva](https://forum.elixirforum.com/u/yoavgeva)\
**Replies:** 12\
**Last updated:** [May 21, 2026, 11:20am UTC](https://forum.elixirforum.com/t/archtest-architecture-rules-as-tests-enforced-from-bytecode/74558 "2026-05-21T11:20:13Z")

</div>

ArchTest – Architecture rules as tests. Enforced from bytecode. ArchTest is an ArchUnit-inspired architecture testing library for Elixir. Rules live in plain ExUnit tests, run with mix test, and produce structured failu…

---

## [Designing a Broker-Agnostic API Layer in Elixir](https://forum.elixirforum.com/t/designing-a-broker-agnostic-api-layer-in-elixir/75234)

<div class="topic-metadata">

**Author:** [@ryanrborn](https://forum.elixirforum.com/u/ryanrborn)\
**Replies:** 0\
**Last updated:** [May 5, 2026, 3:24pm UTC](https://forum.elixirforum.com/t/designing-a-broker-agnostic-api-layer-in-elixir/75234 "2026-05-05T15:24:12Z")

</div>

Four Elixir behaviours keep a production trading pipeline completely broker-agnostic — not one big interface but four, each with a distinct responsibility. The dispatch mechanism stores the broker module as an atom in th…

---

## [Exploring ArchUnit-like Architecture Testing for Elixir](https://forum.elixirforum.com/t/exploring-archunit-like-architecture-testing-for-elixir/73588)

<div class="topic-metadata">

**Author:** [@oullette](https://forum.elixirforum.com/u/oullette)\
**Replies:** 6\
**Last updated:** [March 7, 2026, 8:36pm UTC](https://forum.elixirforum.com/t/exploring-archunit-like-architecture-testing-for-elixir/73588 "2026-03-07T20:36:08Z")

</div>

Like most engineers these days, I’ve been thinking about the intersection of LLM driven development and using Elixir to do so. After being particular inspired by this blog post, I’ve been looking at implementing architec…

---

## [Edifice - 92 neural network architectures for Nx/Axon](https://forum.elixirforum.com/t/edifice-92-neural-network-architectures-for-nx-axon/74360)

<div class="topic-metadata">

**Author:** [@blasphemetheus](https://forum.elixirforum.com/u/blasphemetheus)\
**Replies:** 3\
**Last updated:** [February 21, 2026, 10:01pm UTC](https://forum.elixirforum.com/t/edifice-92-neural-network-architectures-for-nx-axon/74360 "2026-02-21T22:01:00Z")

</div>

I’ve been working on an open-source framework for training bots for Super Smash Bros. Melee in Elixir (ExPhil). Along the way I got thoroughly distracted by the plethora of architectures to try, benchmarks to run, and op…

---

## [Phoenix LiveView vs SPA](https://forum.elixirforum.com/t/phoenix-liveview-vs-spa/34743)

<div class="topic-metadata">

**Author:** [@marciol](https://forum.elixirforum.com/u/marciol)\
**Replies:** 90\
**Last updated:** [November 15, 2025, 3:24pm UTC](https://forum.elixirforum.com/t/phoenix-liveview-vs-spa/34743 "2025-11-15T15:24:15Z")

</div>

Please, let me know if this kind of discussion already took place in another topic . Hi all, how do you consider if is better to build an app around SPA paradigm instead of use Server Side Rendering technologies. I wa…

---

## [The beauty of Plain Old Elixir Modules - POEM](https://forum.elixirforum.com/t/the-beauty-of-plain-old-elixir-modules-poem/15882)

<div class="topic-metadata">

**Author:** [@marciol](https://forum.elixirforum.com/u/marciol)\
**Replies:** 7\
**Last updated:** [August 1, 2025, 4:44am UTC](https://forum.elixirforum.com/t/the-beauty-of-plain-old-elixir-modules-poem/15882 "2025-08-01T04:44:29Z")

</div>

Thinking about how Contexts on Phoenix 1.3 are beautiful in the simplicity, elegance and minimalism, coalesced in the smallest unity of Elixir, the Plain Old Elixir Modules, I got surprised by the acronym obtained from t…

---

## [Wanted: examples of well organized Phoenix LiveView apps](https://forum.elixirforum.com/t/wanted-examples-of-well-organized-phoenix-liveview-apps/71723)

<div class="topic-metadata">

**Author:** [@dogweather](https://forum.elixirforum.com/u/dogweather)\
**Replies:** 4\
**Last updated:** [July 17, 2025, 4:55am UTC](https://forum.elixirforum.com/t/wanted-examples-of-well-organized-phoenix-liveview-apps/71723 "2025-07-17T04:55:12Z")

</div>

I feel lost in my Phoenix LiveView code base. Coming from Rails, I can’t find anything. But I also have no confidence that I’m got it organized according to best practices. For example, where should the template for a c…

---

## [What’s wrong with Umbrella Apps?](https://forum.elixirforum.com/t/what-s-wrong-with-umbrella-apps/49585)

<div class="topic-metadata">

**Author:** [@paulanthonywilson](https://forum.elixirforum.com/u/paulanthonywilson)\
**Replies:** 41\
**Last updated:** [June 22, 2025, 8:26pm UTC](https://forum.elixirforum.com/t/what-s-wrong-with-umbrella-apps/49585 "2025-06-22T20:26:24Z")

</div>

I like Umbrella projects and pretty much always use them for personal Elixir stuff, especially Nerves things. But I don’t think this is a popular choice. I’ve never really understood why they are disliked. The two argum…

---

## [Complex components lead to us always calling \`detach\_hook/3\` before \`attach\_hook/4\`](https://forum.elixirforum.com/t/complex-components-lead-to-us-always-calling-detach-hook-3-before-attach-hook-4/71233)

<div class="topic-metadata">

**Author:** [@slouchpie](https://forum.elixirforum.com/u/slouchpie)\
**Replies:** 18\
**Last updated:** [June 19, 2025, 5:46pm UTC](https://forum.elixirforum.com/t/complex-components-lead-to-us-always-calling-detach-hook-3-before-attach-hook-4/71233 "2025-06-19T17:46:20Z")

</div>

Greetings, comrades. At work, we have been converting some legacy LiveComponents into functional components. This typically involves moving much of the update lifecycle function logic into a handle\_params hook which is …

---

## [How can I do a better code and architecture design with Elixir Erlang and FP principles](https://forum.elixirforum.com/t/how-can-i-do-a-better-code-and-architecture-design-with-elixir-erlang-and-fp-principles/70989)

<div class="topic-metadata">

**Author:** [@henriquesati](https://forum.elixirforum.com/u/henriquesati)\
**Replies:** 6\
**Last updated:** [June 11, 2025, 9:36pm UTC](https://forum.elixirforum.com/t/how-can-i-do-a-better-code-and-architecture-design-with-elixir-erlang-and-fp-principles/70989 "2025-06-11T21:36:49Z")

</div>

Hi, I’ve been developing a project for a few months and since the beginning i’ve been paying attention to the design of my code, writing it modular, well separated and those kind of things, but it’s been growing and i’m …

---

## [BEAM Devs: Asking for Feedback on the Software Architecture Draft](https://forum.elixirforum.com/t/beam-devs-asking-for-feedback-on-the-software-architecture-draft/69638)

<div class="topic-metadata">

**Author:** [@Exadra37](https://forum.elixirforum.com/u/Exadra37)\
**Replies:** 6\
**Last updated:** [March 29, 2025, 2:24pm UTC](https://forum.elixirforum.com/t/beam-devs-asking-for-feedback-on-the-software-architecture-draft/69638 "2025-03-29T14:24:17Z")

</div>

In my first two UK roles, software architecture always included a failover system, an independent, exact copy of production running in another cloud or on-premises data center. This differs from redundancy within the …

---

## [Separating Consumers from Producers in different BEAM instances](https://forum.elixirforum.com/t/separating-consumers-from-producers-in-different-beam-instances/70027)

<div class="topic-metadata">

**Author:** [@dch](https://forum.elixirforum.com/u/dch)\
**Replies:** 3\
**Last updated:** [March 21, 2025, 4:39pm UTC](https://forum.elixirforum.com/t/separating-consumers-from-producers-in-different-beam-instances/70027 "2025-03-21T16:39:53Z")

</div>

Overview For security compliance reasons, I need to ensure a complete separation between some of the consumers, and the producers that submit jobs to the queue. It’s sufficient to have the jobs go to a common PostgreSQL …

---

## [2025/10/17 - FUNARCH2025 at ICFP/Splash Call for Papers is Open! - Singapore](https://forum.elixirforum.com/t/2025-10-17-funarch2025-at-icfp-splash-call-for-papers-is-open-singapore/70070)

<div class="topic-metadata">

**Author:** [@doyougnu](https://forum.elixirforum.com/u/doyougnu)\
**Replies:** 0\
**Last updated:** [March 21, 2025, 11:55am UTC](https://forum.elixirforum.com/t/2025-10-17-funarch2025-at-icfp-splash-call-for-papers-is-open-singapore/70070 "2025-03-21T11:55:03Z")

</div>

Hello everyone, This year I am chairing the Functional Architecture workshop colocated with ICFP and SPLASH. I’m happy to announce that the Call for Papers for FUNARCH2025 is open - deadline is June 16th! Send us resea…

---

## [Options for connecting two Elixir apps?](https://forum.elixirforum.com/t/options-for-connecting-two-elixir-apps/69761)

<div class="topic-metadata">

**Author:** [@rump13](https://forum.elixirforum.com/u/rump13)\
**Replies:** 7\
**Last updated:** [March 5, 2025, 11:20pm UTC](https://forum.elixirforum.com/t/options-for-connecting-two-elixir-apps/69761 "2025-03-05T23:20:18Z")

</div>

Hi all, I’m playing with designing a multi-tenant SaaS pet project using the Control Plane / Application Plane model. There will probably be two main web apps (control and application planes) in Elixir/Phoenix. The cont…

---

## [Using Ash with DuckDB/MotherDuck: Possible and/or Useful?](https://forum.elixirforum.com/t/using-ash-with-duckdb-motherduck-possible-and-or-useful/69098)

<div class="topic-metadata">

**Author:** [@alecStewart1](https://forum.elixirforum.com/u/alecStewart1)\
**Replies:** 2\
**Last updated:** [January 31, 2025, 3:28pm UTC](https://forum.elixirforum.com/t/using-ash-with-duckdb-motherduck-possible-and-or-useful/69098 "2025-01-31T15:28:05Z")

</div>

Hey friends! I had this thought given an actual real world problem at work. Generally whenever you have some kind of front-facing app that consumes data from somewhere, usually an API of sorts, if you’re using data fro…

---

## [Examples of Plugin Architecture in Elixir?](https://forum.elixirforum.com/t/examples-of-plugin-architecture-in-elixir/68973)

<div class="topic-metadata">

**Author:** [@Fl4m3Ph03n1x](https://forum.elixirforum.com/u/Fl4m3Ph03n1x)\
**Replies:** 6\
**Last updated:** [January 31, 2025, 1:39pm UTC](https://forum.elixirforum.com/t/examples-of-plugin-architecture-in-elixir/68973 "2025-01-31T13:39:22Z")

</div>

Background I am studying the concept of Plugin Architecture and part of this task involves finding examples of this within the Elixir community. My first attempt at searching for this resulted in finding this post by @m…

---

## [REST API structure at a medium sized project?](https://forum.elixirforum.com/t/rest-api-structure-at-a-medium-sized-project/67752)

<div class="topic-metadata">

**Author:** [@Morzaram](https://forum.elixirforum.com/u/Morzaram)\
**Replies:** 1\
**Last updated:** [November 29, 2024, 6:26am UTC](https://forum.elixirforum.com/t/rest-api-structure-at-a-medium-sized-project/67752 "2024-11-29T06:26:18Z")

</div>

Hey everyone I was wondering what does your basic REST API controllers look like? I miss the rails way of dry.rb based form validation object using AR directly in the controller for saving rendering response Instead …

---

## [Should we use presence to store player position?](https://forum.elixirforum.com/t/should-we-use-presence-to-store-player-position/67304)

<div class="topic-metadata">

**Author:** [@danielrachi](https://forum.elixirforum.com/u/danielrachi)\
**Replies:** 1\
**Last updated:** [November 7, 2024, 7:21am UTC](https://forum.elixirforum.com/t/should-we-use-presence-to-store-player-position/67304 "2024-11-07T07:21:08Z")

</div>

We are creating a multiplayer version of Pong. This is the architecture we’re currently using: The browsers retrieve the position of the ball and the score from the GenServer by handling a tick message broadcast from…

---

## [Structuring LiveViews and routes for multi-step process with and without back button](https://forum.elixirforum.com/t/structuring-liveviews-and-routes-for-multi-step-process-with-and-without-back-button/66347)

<div class="topic-metadata">

**Author:** [@Almah](https://forum.elixirforum.com/u/Almah)\
**Replies:** 1\
**Last updated:** [September 27, 2024, 9:35am UTC](https://forum.elixirforum.com/t/structuring-liveviews-and-routes-for-multi-step-process-with-and-without-back-button/66347 "2024-09-27T09:35:15Z")

</div>

This is in the context of a tabletop roleplaying game, think Dungeons & Dragons. In such a game you create a character by going through a branching multi-step process such as determining attributes, picking a species, se…

---

## [Is this a good way to visualise the Phoenix architecture?](https://forum.elixirforum.com/t/is-this-a-good-way-to-visualise-the-phoenix-architecture/66013)

<div class="topic-metadata">

**Author:** [@FedericoAlcantara](https://forum.elixirforum.com/u/FedericoAlcantara)\
**Replies:** 0\
**Last updated:** [September 10, 2024, 3:57pm UTC](https://forum.elixirforum.com/t/is-this-a-good-way-to-visualise-the-phoenix-architecture/66013 "2024-09-10T15:57:29Z")

</div>

To have a visual overview of the Phoenix framework proposed architecture, I have this simple diagram: I’ve found some interesting articles and videos that helped understand the Phoenix’s proposed architecture, and go…

---

## [How to structure a large live view app?](https://forum.elixirforum.com/t/how-to-structure-a-large-live-view-app/65192)

<div class="topic-metadata">

**Author:** [@Morzaram](https://forum.elixirforum.com/u/Morzaram)\
**Replies:** 30\
**Last updated:** [August 6, 2024, 10:37pm UTC](https://forum.elixirforum.com/t/how-to-structure-a-large-live-view-app/65192 "2024-08-06T22:37:13Z")

</div>

Hey everyone, I have a live view app that is slowly getting bigger and I’m really struggling to find a way to manage all of the logic for each page. Components, queries, page, etc. I was hoping to get some insight on h…

---

## [Database Layout for an audit log?](https://forum.elixirforum.com/t/database-layout-for-an-audit-log/64554)

<div class="topic-metadata">

**Author:** [@larshei](https://forum.elixirforum.com/u/larshei)\
**Replies:** 1\
**Last updated:** [June 27, 2024, 12:01pm UTC](https://forum.elixirforum.com/t/database-layout-for-an-audit-log/64554 "2024-06-27T12:01:29Z")

</div>

Yesterday, I built a small Audig Log functionality to record changes to a graph database. My initial approach was to have two separate tables, an audit\_nodes that records all changes to nodes in the graph and an audit\_r…

---

## [Help with OTP and architectural design for a proxy MUD system](https://forum.elixirforum.com/t/help-with-otp-and-architectural-design-for-a-proxy-mud-system/63616)

<div class="topic-metadata">

**Author:** [@LionOps](https://forum.elixirforum.com/u/LionOps)\
**Replies:** 2\
**Last updated:** [May 17, 2024, 8:30am UTC](https://forum.elixirforum.com/t/help-with-otp-and-architectural-design-for-a-proxy-mud-system/63616 "2024-05-17T08:30:13Z")

</div>

I’ve read the Mix & OTP section of the hex docs and semi-grok things. What I’m struggling with is how everything fits together in my use case, and advice/guidance is appreciated as I’m new to Elixir (and OTP). I want to…

---

## [Any idea of what code to put in the domain's main file](https://forum.elixirforum.com/t/any-idea-of-what-code-to-put-in-the-domains-main-file/62891)

<div class="topic-metadata">

**Author:** [@rubynho](https://forum.elixirforum.com/u/rubynho)\
**Replies:** 11\
**Last updated:** [April 16, 2024, 3:12am UTC](https://forum.elixirforum.com/t/any-idea-of-what-code-to-put-in-the-domains-main-file/62891 "2024-04-16T03:12:24Z")

</div>

Context Generating a phoenix app with name foo, an empty module will be created in the foo/lib/foo.ex file like so: defmodule Foo do @moduledoc """ Foo keeps the contexts that define your domain and business logic…

---

## [How would you scale up an Elixir/Phoenix application if only a specific part is responsible for that requirement?](https://forum.elixirforum.com/t/how-would-you-scale-up-an-elixir-phoenix-application-if-only-a-specific-part-is-responsible-for-that-requirement/61559)

<div class="topic-metadata">

**Author:** [@Pistrie](https://forum.elixirforum.com/u/Pistrie)\
**Replies:** 6\
**Last updated:** [February 10, 2024, 8:15pm UTC](https://forum.elixirforum.com/t/how-would-you-scale-up-an-elixir-phoenix-application-if-only-a-specific-part-is-responsible-for-that-requirement/61559 "2024-02-10T20:15:36Z")

</div>

Hi everyone, I’ve got a question related to project architecture. In the microservice sphere there is this concept where you can scale up individual services when needed. So imagine the following scenario: ┌──────…

---

## [Wiring up a Dashboard for Dynamic Supervised GenServers](https://forum.elixirforum.com/t/wiring-up-a-dashboard-for-dynamic-supervised-genservers/61088)

<div class="topic-metadata">

**Author:** [@Paperelectron](https://forum.elixirforum.com/u/Paperelectron)\
**Replies:** 7\
**Last updated:** [January 19, 2024, 12:20pm UTC](https://forum.elixirforum.com/t/wiring-up-a-dashboard-for-dynamic-supervised-genservers/61088 "2024-01-19T12:20:00Z")

</div>

Hey all, I’m looking to get some general advice on how to wire up a bunch of Dynamic Supervised GenServers, named via the registry, to a LiveView frontend. I’d like them to be able to broadcast updates about what they a…

---

## [Phoenix frontend without the HTML stack?](https://forum.elixirforum.com/t/phoenix-frontend-without-the-html-stack/59285)

<div class="topic-metadata">

**Author:** [@victorolinasc](https://forum.elixirforum.com/u/victorolinasc)\
**Replies:** 6\
**Last updated:** [October 31, 2023, 9:49am UTC](https://forum.elixirforum.com/t/phoenix-frontend-without-the-html-stack/59285 "2023-10-31T09:49:31Z")

</div>

The Elixir community and more specifically the Phoenix community have always been involved with some form of frontend development. Initially through server side rendered HTML/CSS/JS directly in Phoenix, passing through s…

---

## [Independent applications as local dependencies?](https://forum.elixirforum.com/t/independent-applications-as-local-dependencies/57109)

<div class="topic-metadata">

**Author:** [@mksaga](https://forum.elixirforum.com/u/mksaga)\
**Replies:** 4\
**Last updated:** [July 17, 2023, 8:45pm UTC](https://forum.elixirforum.com/t/independent-applications-as-local-dependencies/57109 "2023-07-17T20:45:30Z")

</div>

Hello folks, Hope you are well! Have been playing around with Elixir for a few months, loving the language :slight\_smile: I’m looking for advice on how to manage dependencies between multiple Elixir applications. My in…

---

## [LiveView architecture decisions: LiveViews vs LiveComponents and where and how to store data?](https://forum.elixirforum.com/t/liveview-architecture-decisions-liveviews-vs-livecomponents-and-where-and-how-to-store-data/57028)

<div class="topic-metadata">

**Author:** [@neurodynamic](https://forum.elixirforum.com/u/neurodynamic)\
**Replies:** 1\
**Last updated:** [July 13, 2023, 2:07am UTC](https://forum.elixirforum.com/t/liveview-architecture-decisions-liveviews-vs-livecomponents-and-where-and-how-to-store-data/57028 "2023-07-13T02:07:33Z")

</div>

I’m working on a social network with posts and comments using LiveView, and I’m trying to figure out how and when to use the different constructs LiveView provides. There are a few different pages where you will see list…

[Next page](https://forum.elixirforum.com/tag/architecture/103.md?match_all_tags=true&page=1&tags%5B%5D=architecture)
