pg_registry
pg_extensions · Stores and validates JSON Schemas, generates schemas from tables, and binds schemas to Kafka topics.
Overview
| ID | Extension | Package | Version | Category | License | Language |
|---|---|---|---|---|---|---|
| 101084 | pg_registry | pg_extensions | 0.3.0 | FEAT | Matroid-SAL-1.0 | Rust |
PostgreSQL · 14, 15, 16, 17
Usage
Sources:
pg_registry version 0.3.0 stores versioned JSON Schemas in PostgreSQL, validates JSONB values, generates schemas from tables, and records schema-to-topic or table-to-topic bindings for companion streaming integrations.
Core Workflow
Important functions are register_schema, register_schema_from_table, generate_schema_from_table, get_schema, get_latest_schema, drop_schema, validate, and validate_for_topic. Topic functions manage key/value schema bindings; table functions can create a table from a schema and store stream or upsert binding metadata.
Operational Notes
Objects live in the non-relocatable pgregistry schema, and the control file requires superuser installation. STRICT and LOG are stored validation modes, but enforcement during Kafka traffic depends on the companion integration consuming these bindings; pg_registry alone does not start a Kafka client. Generated schemas and tables cover the documented PostgreSQL-to-JSON type mapping and may not preserve every domain, constraint, generated expression, or application invariant. Review generated DDL and access to schema-management functions before production use.
Version 0.3.0 Boundary
This is an unsupported proof of concept under Matroid Source Available License 1.0. APIs may change. Version 0.3.0 is the new upgrade baseline: earlier 0.2.0 installations require a rehearsed data migration/recreation, not ordinary ALTER EXTENSION UPDATE. Back up data and dependencies before following that destructive upstream path.