pcharbon
This is a new extension for the Ash framework that lets you use the Commanded library in a more declarative manner and removes most of the repetive ceremony while using the Commanded libraru. By combining the power of the Spark DSL library and the Domain/Resources concepts of Ash, this extension will generate for you at runtime all you need to implement a CQRS/ES system. Your commanded Aggregates, Events. Commands, etc will still all be there.
AshCommanded is an Elixir library that provides Command Query Responsibility Segregation (CQRS) and Event-Sourcing (ES) patterns for the Ash Framework. It extends Ash resources with a Commanded DSL that enables defining commands, events, and projections. The extension relies on the excellent Commanded library. The Commanded Guides section explains the different concepts better than I could.
Feedback always very welcomed!
Trending in Announcing
Other Trending Topics
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #library
- #deployment
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #elixirconf
- #channels
- #exunit
- #discussion
- #code-sync
- #podcasts
- #javascript
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #elixirconf-us
- #ai
- #blog-post
- #elixir-ls
- #phoenix_html
- #iex
- #graphql
- #genstage
- #websockets
- #supervisor
- #advent-of-code
- #distillery
- #processes
- #api
- #forms
- #hex
- #security
- #metaprogramming










Showing Posts 1 to 10- Show Best Posts
- Show All (oldest first)
- Show All (newest first)
johnsseruwagi
Thank you so much for this great library, am currently learning CQRS/ES following the book real world event sourcing in elixir, am primarily a Ash framework developer, so I was looking for an extension for proper ES in Ash and then found this,
However on your Where are the process mangers? Section, you said that you recommend using Reactor for this kind of ochestration and I honestly agree with you.
However the commanded Process Manager behavior gives us some out of the box implementations such as the starting, continuation and stoping coordination and I think it works mechanically well with the router.
My point is, to someone who has not implemented the saga pattern on their own, it would be difficult to replace the commanded Process Manager with reactor.
Can you please provide an extensive example of how to do that with Ash Commanded.
And also if you can provide a fully CQRS/ES application built with ash_commanded this would do so great
suranyami
Just been trying to use this in the last few days, an found that the library doesn’t compile. Not sure if something has changed in one of the other frameworks involved (perhaps
spark?) but it’s currently unusable.I’ve written up an issue on the Github repo for it here: AshCommanded.Commanded.ParameterTransformer.__struct__/0 is undefined or private exception thrown during compilation · Issue #3 · accountex-org/ash_commanded · GitHub
pcharbon
Sorry about the not compiling. It hss been fixed by someone already in a PR and I forgot to update the version. I will do that tomorrow as soon as possible.
Regarding providing an example, I will be happy to write one and add it to the repo as well. I am also easily reacheable online at any time on Discord under the same username. Feel free to contact me for any questions or discussions on your project. I will be happy to help.
Pascal
pcharbon
The fixes have now been published on version 0.2. Thank you for your patience.
pcharbon
I will try to write some example application this week but you can still use the Process Manager with the Ash Commanded extension. It will not overwrite any Process Managers you have or other files. Sorry for the late reply. This commend somehow got past me. I really need to work toward that zero emails zen state
johnsseruwagi
Thank you so much, I will be eagerly waiting for the example, I have been diving deeper into reactor and it makes a lot of sense for ochestration, no worries atleast you have responded and it means a lot to me
johnsseruwagi
Hello, any updates on this, please
pcharbon
I am sorry I did not have time to write a complete example yet as I have been busy lately. I have not forgotten you and it is on my to-do list. I appreciate your patience. Feel free to contact me directly on discord for any questions in the meantime.
suranyami
Tried getting a bit further with
ash_commanded, and encountering an error when trying to generate theAggregate:I’ve documented the issue on Github here: undefined function `snapshot_state_if_needed/1` when generating Aggregate · Issue #6 · accountex-org/ash_commanded · GitHub
It would be really great if anyone has a working MVP that works, so that others can follow along.
I’m happy to write up a detailed walk-through and add it to the docs if someone wants to point me to such an example.
suranyami
Also, reported this issue last week: commanded/application throws nil exception · Issue #4 · accountex-org/ash_commanded · GitHub
With a PR to fix here: Allow application/prefix to be nil by suranyami · Pull Request #5 · accountex-org/ash_commanded · GitHub