Thalweg · API reference ← Main docs

Crate twg

Crate twg 

Source
Expand description

The twg command — Thalweg’s single entry point.

One binary with subcommands rather than separate executables, so streaming and batch share not just the pipeline but the invocation surface:

twg stream run the streaming daemon (Kafka/Pulsar/Flight sources) –mode ingest|recovery|both deployment role; default both. recovery disables source consumption entirely and replays leased windows from raw into lagging sinks, so a backfill cannot throttle live ingest. twg batch run a bounded batch ingest (file sources) twg config secrets enumerate the secret references a config requires twg config validate validate a config without starting the pipeline twg proto bundle bundle a proto source into a FileDescriptorSet + .proto

Streaming and batch are the same pipeline with different sources: batch is a bounded Source in connector-core terms, feeding the identical decode → contract/DQ → transform → sink → DLQ path.

stream, batch, and config are scaffolds today; proto bundle is the first fully-wired subcommand (ADR-0063).

Structs§

BundleCmd 🔒
Cli 🔒

Enums§

Command 🔒
ConflictArg 🔒
EmitKind 🔒
One artefact the bundler can write. Validated by clap, so a typo fails fast instead of silently producing nothing.
ProtoCmd 🔒
WktArg 🔒

Functions§

emit_odcs 🔒
Project the bundle’s .pb into an ODCS v3.1.0 contract and write it. Runs at the CLI layer (not inside twg-proto-bundle) so the bundling crate carries no contract/ODCS dependency; the bridge consumes the produced descriptor set.
main 🔒
run_bundle 🔒