SchemaRegistration
Defined in: src/persistence/migration/SchemaRegistry.ts:60
What a single registered version contributes to the registry.
Extended by
Section titled “Extended by”Type Parameters
Section titled “Type Parameters”Wire = unknown
Upcasted
Section titled “Upcasted”Upcasted = unknown
Properties
Section titled “Properties”
readonlycodec:Codec<Wire>
Defined in: src/persistence/migration/SchemaRegistry.ts:62
Codec used to validate / shape payloads at this version.
compatibility?
Section titled “compatibility?”
readonlyoptionalcompatibility?:"none"|"backward"|"sample"
Defined in: src/persistence/migration/SchemaRegistry.ts:70
Compatibility-check mode applied at register time. Default 'none'.
sample?
Section titled “sample?”
readonlyoptionalsample?:unknown
Defined in: src/persistence/migration/SchemaRegistry.ts:76
Optional sample value used by 'sample' compat checks — passed
through the previous version’s encode → decode → upcast → this
version’s encode round-trip. Throws if any step fails.
upcastFromPrev?
Section titled “upcastFromPrev?”
readonlyoptionalupcastFromPrev?: (prev) =>Upcasted
Defined in: src/persistence/migration/SchemaRegistry.ts:68
Pure function prevVersionDomain → thisVersionDomain used on
the read path to bring data forward. Required for any version
1 if reads from older data are expected to succeed.
Parameters
Section titled “Parameters”unknown
Returns
Section titled “Returns”Upcasted