Sagas and View Models inside GetEventStore

Hi,

Been looking for an eventstore database for our next CQRS driven arquitecture project and geteventstore is one of the possibilities.

Mind you I don’t know much about geteventstore as I only started yesterday trying to figure out my head around it. I do have knowledge about CQRS but documentation and samples seams lacking in certain areas, at least I could not finding anything convincing for Sagas and View Models.

I had a look on projections and here are two questions:

  1. Is it a good practice to build a V>iew and store it a stream? By reading about projections it seams feasible to start a projection with some View state and have it emit View changes into what I could call a view stream. The thing would go like this:

Say I have a order-21056 stream, a customer-201221 stream and a order-view-21056 stream:

step 1: on $init load the projection state with the latest changed event from the Order View Stream

step 2: compute the view based on subscribed events from the streams,

step 3. emit a view changed to the Order View Stream

Here I’m concerned with memory as I would have a projection per order

  1. Saga.

Cant the same principles be used for a Saga? Say the state containing the Saga state …

Can we add, suspend and remove projections dynamically?

Thank you for any help

PS: I’m consideting this to avoid developing the piping and other stuff to compute projections for views and sagas.

I would not use GES projections this way. Really they are there to support stream partitioning.

For process managers / sagas, you might be able to repartition all your streams by correlation id. However IMO this is way too generic, you are better off doing this in your code.