Accept JSON and Avro records and store them as Avrov1.3+
Use a schema registry with schema_type any so clients can produce either JSON or Avro, and store only Avro in the backend cluster.
The parent Schema Validation policy validates the record value against a schema registry
whose schema_type is any, so a client can produce records in either JSON or Avro.
With output_format: avro, this policy converts JSON records to Avro and leaves records that are already Avro unchanged.
It looks up the target Avro schema in the same registry by subject and version, and prefixes converted records with the
schema reference in the Confluent wire format, so any Confluent-compatible consumer can deserialize them.
This is useful while producers migrate from JSON to Avro and both formats are in flight for a period of time.
Prerequisites
- A Schema Validation Produce policy that validates the record value against a schema registry configured with
schema_type: any.
Environment variables
PARENT_POLICY_ID: The UUID of the parent Schema Validation policy.