STREAMING_ENABLED=true. When STREAMING_KAFKA_BROKERS is also set, the worker publishes report.finished and report.partial to Kafka as well. When streaming is off, Reporter publishes no events.
Envelope and routing
Every event usesce-source reporter and a source-qualified ce-type in the form studio.lerian.reporter.<resource>.<event>. The payload is JSON with snake_case keys.
Both copies carry the same
ce-id.
Use the shared envelope for the complete CloudEvents header contract.
Delivery semantics
Reporter emits after the business-state change has committed. Publication errors do not fail the underlying operation.- Important: direct publication, with durable outbox fallback when the broker circuit is open.
- Critical: Reporter skips direct publication. It always persists the event to the durable outbox for dispatch and retry.
- Both policies request
on_routable_failure, but the routes define no explicit DLQ destination. The publisher sees a routable failure. No copy goes to a dead-letter route. - Broker delivery is at least once. Consumers must be idempotent and deduplicate with
(ce-source, ce-id).
Emitted event catalog
A regulatory filing emits
regulatory.draft_ready instead of report.finished. A failed filing run emits report.errored.
Event identifiers
Reporter sets a deterministicce-id on these events:
Every
report.errored variant uses the same ce-id. A consumer deduplicating on (ce-source, ce-id) therefore keeps only the first report.errored received for a report_id. Template events, report.requested, and deadline create, update, and delete events carry a generated identifier.
Complete data contracts
These TypeScript-style declarations mirror the JSON wire shape. ? means the property is optional. | null means the property is present but can be JSON null.
document_type carries the template category. It holds an empty string on the worker failure variant that carries no template_id. Treat an empty value as no category. document_id and document_version on report.errored name the regulatory document when a subscription generated the report, and are empty strings otherwise.
artifact_object_key on report.finished, report.partial, and regulatory.filing_approved is the storage key of the file exactly as Reporter wrote it, and it is never empty. Use it as is. Do not rebuild it from other fields. On regulatory.filing_approved, verify the stored object against artifact_sha256 before you send it. parameters carries the generation parameters without the ones that start with system..
binding_gaps_count on regulatory.version_adopted counts the fields of the adopted version that the existing mapping leaves unmapped. The mapping_broken field is true when Reporter could not assess the existing mapping against the adopted version. In that case, binding_gaps_count is 0.
Separate internal command rail
Manager sends worker a non-CloudEvents JSON command on RabbitMQ. It usesRABBITMQ_EXCHANGE, RABBITMQ_GENERATE_REPORT_KEY, and RABBITMQ_GENERATE_REPORT_QUEUE, with persistent delivery. This command is not part of the public event catalog, and its shape is not a public contract.

