API Reference
cqrsEventOutboxCommands()
Creates a CQRS event outbox commands.
Import
import { cqrsEventOutboxCommands } from "@graphrefly/ts/cqrs/messaging";
Signature
function cqrsEventOutboxCommands(
graph: Graph,
events: Node<CqrsEvent<TEvent>>,
topic: string,
opts: { readonly name?: string } = {},
): Node<MessageBusCommand>
Parameters
| Parameter | Type | Description |
|---|---|---|
graph | Graph | Graph that owns the created nodes or projector. |
events | Node<CqrsEvent<TEvent>> | Event node or event collection to consume. |
topic | string | topic value used by the helper. |
opts | { readonly name?: string } | Options that configure the helper. |
Returns
The CQRS event outbox commands result.
Example
import { cqrsEventOutboxCommands } from "@graphrefly/ts/cqrs/messaging";
Source
packages/ts/src/cqrs/messaging.ts