ProjectionModule
PackageFCQRS
Constructors for the two projection-handler shapes.
Summary
| Name | Signature | Synopsis |
|---|---|---|
| multi | multi lastOffset handle | Multi-event handler with full control. |
| single | single lastOffset handle | Single-event handler: just update the read model (returns unit); each aggregate event is then published to subscribers as-is. |
| filtered | filtered lastOffset handle | Filtered single-event handler: update the read model, then return Publish/Suppress to decide whether *this* event wakes subscribers. |
Multi-event handler with full control. Return exactly the notifications to
publish (empty list = nothing). Use when notifications must be filtered
or transformed, e.g. suppressing intermediate events so read-your-writes
only wakes on the final one.
Parameters
| Name | Type | Description |
|---|---|---|
| lastOffset | int64 | |
| handle | int64 -> obj -> IMessageWithCID list |
Returns
Projection
Single-event handler: just update the read model (returns unit); each
aggregate event is then published to subscribers as-is. The common case
when every event is worth notifying.
Parameters
| Name | Type | Description |
|---|---|---|
| lastOffset | int64 | |
| handle | int64 -> obj -> unit |
Returns
Projection
Filtered single-event handler: update the read model, then return
Publish/Suppress to decide whether *this* event wakes subscribers. The
middle rung between `single` (always publish) and `multi` (return an
arbitrary notification list). Use it for the common "publish each
event except the intermediate ones" case, without building a list.
Parameters
| Name | Type | Description |
|---|---|---|
| lastOffset | int64 | |
| handle | int64 -> obj -> Notify |
Returns
Projection