GoodAnalytics.Connectors.Replay (GoodAnalytics v0.1.1)

Copy Markdown View Source

Replays failed connector dispatches from stored source context.

Replay rebuilds the outbound payload from the stored source_context rather than relying on live visitor state, ensuring deterministic results.

Summary

Functions

Replays a failed dispatch by creating a new dispatch from stored source context.

Replays all failed dispatches for a workspace and connector type.

Functions

replay(dispatch_id)

Replays a failed dispatch by creating a new dispatch from stored source context.

The new dispatch is linked to the original via replayed_from_id. Returns {:ok, new_dispatch} or {:error, reason}.

replay_all(workspace_id, connector_type)

Replays all failed dispatches for a workspace and connector type.

Returns {:ok, count} with the number of replayed dispatches.