Skip to main content

Module sync

Module sync 

Source
Expand description

Sync daemon: redacted outbox → POST /v1/events.

Re-exports§

pub use canonical::CanonicalEnvelope;
pub use canonical::CanonicalEventName;
pub use canonical::CanonicalItem;
pub use canonical::EventItem;
pub use canonical::KAIZEN_SCHEMA_VERSION;
pub use canonical::RepoSnapshotChunkItem;
pub use canonical::ToolSpanItem;
pub use canonical::WorkspaceFactSnapshotItem;
pub use canonical::expand_ingest_batch;
pub use context::SyncIngestContext;
pub use engine::FlushExporters;
pub use engine::FlushStats;
pub use engine::flush_outbox_once;
pub use export_batch::IngestExportBatch;
pub use outbound::EventsBatchBody;
pub use outbound::OutboundEvent;
pub use outbound::hash_with_salt;
pub use outbound::workspace_hash;
pub use telemetry_replay::chunk_events_into_ingest_batches;

Modules§

canonical
Per-item canonical telemetry payloads: expand IngestExportBatch for exporters, future provider pull, and goldens. Primary POST / outbox stay batch-oriented.
client
HTTP sync client: gzip JSON, retries, batch split on 413.
context
Context passed when appending events so the store can enqueue the sync outbox.
engine
Flush outbox batches: size limits, split on 413, backoff on 429 / transient errors. Optional FlushExporters runs HTTP fan-out in parallel with the primary Kaizen POST; only a successful (or 409) primary result commits outbox. Secondary Err is observed only in that same step (and blocks commit when fail_open is false).
export_batch
Redacted batch payload shared by Kaizen sync POST and pluggable exporter fan-out.
outbound
Typed outbound JSON matching POST /v1/events (single-event shape used in outbox rows).
redact
Client-side redaction before enqueueing sync outbox rows.
smart
Sync shapes for tool spans and repo snapshots.
telemetry_replay
Chunk local OutboundEvent vectors into IngestExportBatch for telemetry replay (exporter fan-out only). Packing mirrors crate::sync::engine outbox batch limits.

Functions§

ingest_ctx
When sync endpoint is configured, pass this into append_event_with_sync.