itopiz
Are you using in-memory projections with CQRS/ES commanded?
Hi,
I am working on an application using CQRS and Event Sourcing with the help of the commanded library.
I am interesting in using in-memory projections for some of my read models instead of persisting them to a database (for example).
Does anyone (@slashdotdash? ) have experience with this and feedback to share?
Thank you
Marked As Solved
slashdotdash
The next version of EventStore has support for transient subscriptions (#215). These subscriptions won’t persist the last seen event so if you restart the subscription it will replay all the events from wherever you configure it to start from (origin, current, or specific event number). You could use this feature to have projections replay their events each time they start.
The downside of this approach is that it will take longer to build the projection as more events are stored. For this reason I always prefer to use persistent read model projections and not rebuild them from scratch. A hyrbid approach might be to snapshot the projection after a certain number of events and then rebuild the projection starting with the latest snaphot and creating a subscription from the next event after the snapshot’s version.
Also Liked
slashdotdash
Last Post!
slashdotdash
Popular in Questions
Other popular topics
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #deployment
- #library
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #channels
- #elixirconf
- #exunit
- #discussion
- #code-sync
- #javascript
- #podcasts
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #elixir-ls
- #phoenix_html
- #iex
- #blog-post
- #graphql
- #genstage
- #ai
- #websockets
- #supervisor
- #elixirconf-us
- #advent-of-code
- #distillery
- #processes
- #forms
- #api
- #metaprogramming
- #security
- #hex









