v0.5.0 · Interface

producer

Binding-scoped Kafka publishing.

Importing this interface grants a component one producer capability. The import binding fixes the brokers, credentials, transport, client policy and topic grant before the component runs. A named import selects a different admitted binding; no function accepts a connection or client configuration.

The provider owns and reuses the native producer behind the binding. It may share connections, metadata and batching state across concurrent component instances without exposing that client as guest-owned state. Each operation still has its own completion boundary, so one invocation never needs to flush another invocation's queue.

Every function is async. A host component plugin installs concurrent host functions on the caller's linker, and a synchronous function cannot be served by that path.