Skip to content

Commit

Permalink
docs: enhance readme howto sections
Browse files Browse the repository at this point in the history
  • Loading branch information
Tochemey committed Dec 17, 2024
1 parent c43fc33 commit 6ae972c
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,9 @@ To define an event sourced entity, one needs to:
2. define the various commands that will be handled by the event sourced entity
3. define the various events that are result of the command handlers and that will be handled by the event sourced
entity to return the new state of the event sourced entity
4. implement the [`EventSourcedBehavior`](./behavior.go) interface.
5. call the `Entity` method of eGo [engine](./engine.go)
4. define and make sure the [`events store`](./persistence/events_store.go) is properly implemented.
5. implement the [`EventSourcedBehavior`](./behavior.go) interface.
6. call the `Entity` method of eGo [engine](./engine.go)

#### Events Stream

Expand All @@ -76,9 +77,9 @@ the [Event](./protos/ego/v3/ego.proto).

#### Projection

One can add a projection to the eGo engine to help build a read model. Projections in eGo rely on an offset store to
One can add a projection to the eGo engine to help build a read model. Projections in eGo rely on an [offset store](#offsets-store) to
track how far they have consumed events
persisted by the write model. The offset used in eGo is a timestamp-based offset. One can also:
persisted by the write model. The offset used in eGo is a _timestamp-based offset_. One can also:

- remove a given projection: this will stop the projection and remove it from the system
- check the status of a given projection
Expand Down Expand Up @@ -132,9 +133,10 @@ To define a durable state entity, one needs to:

1. define the state of the entity using google protocol buffers message
2. define the various commands that will be handled by the entity
3. implements the [`DurableStateBehavior`](./behavior.go) interface
4. start eGo engine with the option durable store using `WithStateStore`
5. call the `DurableStateEntity` method of eGo [engine](./engine.go)
3. define and make sure the [`durable state store`](./persistence/state_store.go) is properly implemented.
4. implements the [`DurableStateBehavior`](./behavior.go) interface
5. start eGo engine with the option durable store using `WithStateStore`
6. call the `DurableStateEntity` method of eGo [engine](./engine.go)

#### Events Stream

Expand Down

0 comments on commit 6ae972c

Please sign in to comment.