Features
Schema Diagnostics
The Schema Diagnostics page provides a developer-facing view of your Vextro schema metadata. It shows all registered collections and globals, their field configurations, fingerprint sync status, and helps identify stale or archived metadata that may need attention.
Setup
Import the page component and mount it in your Astro routing:
---
import VextroSchemaDiagnosticsPage from "vextro/pages/VextroSchemaDiagnosticsPage.astro";
---
<VextroSchemaDiagnosticsPage
convex={convex}
api={api}
basePath="/admin"
config={config}
/> Page props
| Prop | Type | Required | Description |
|---|---|---|---|
convex | ConvexClient | Yes | Convex client instance. |
api | AdminAPI | Yes | Admin API reference from createVextroAdminModule. |
brandName | string | No | Custom brand name displayed in the header. Defaults to "Vextro". |
basePath | string | No | URL base path for routing links. |
config | VextroConfig | No | Vextro configuration object. |
Features
Fingerprint status
A banner at the top shows whether the schema metadata is in sync:
| Status | Description |
|---|---|
| Synced | The current schema fingerprint matches the stored fingerprint. Metadata is up to date. |
| Stale | The fingerprints do not match. The schema has changed since the last seed. Run vextro-sync to update. |
| Unknown | No stored fingerprint found. The schema has not been seeded yet. |
The fingerprint details section shows the current fingerprint, stored fingerprint, and last seeded timestamp.
Metadata guardrails
Metadata activation now enforces strict safety checks before a slot flip:
- Canonical partitions are compacted to
blocks.typeKeysreferences before evaluation; expandedblocks.typespayloads are only used for discovery. - Editor metadata is encoded when authored depth exceeds the storage budget of
10, then certified at persisted depth13and hard-failed at14. - Canonical partitions hard-fail above
750,000bytes per partition or2,500,000bytes total. - Canonical and materialized rows are validated against byte and depth guardrails.
- Activation aborts if any row shape, fingerprint, count, depth, or byte invariant fails.
- Failed activations keep the previously active slot unchanged.
Depth preflight is contract-driven and reports:
maxProjectedEditorRowDepthfor encoded editor-row depth certificationdepthHeadroom(16 - maxProjectedEditorRowDepth) to track runtime ceiling marginencodingAppliedCountshowing how often deep branches were encodedtopDepthEntities(top 5) with projected depth and projected bytes per entityprojectedCanonicalPartitionBytesMaxfor the largest projected canonical shardprojectedCanonicalTotalBytesfor the combined canonical payload sizeprojectedCanonicalPartitionCountfor the number of projected canonical shardscycleErrorswhen block graph cycles are detected during preflighthardErrorswhen any guardrail would block activation
Use these diagnostics to reduce shape complexity before cutover. Do not bypass guardrails.
If a migration fails with a guardrail error, treat it as a schema-shape regression. Do not bypass the guardrail in production; fix the schema payload so metadata remains compact and bounded.
Summary cards
Four summary cards at the top provide a quick overview:
| Card | Description |
|---|---|
| Collections | Total number of registered collections. |
| Globals | Total number of registered globals. |
| Active Fields | Total active (non-archived) fields across all collections and globals. |
| Last Seeded | Timestamp of the most recent schema seed operation. |
Collections table
An expandable table lists every registered collection with:
| Column | Description |
|---|---|
| Label | The collection's display name. |
| Slug | The collection's unique slug identifier. |
| Table | The Convex table name. |
| Type | The collection type (e.g., content, config, system). |
| Fields | Count of active and archived fields. |
| Status | Active or archived indicator. |
| Updated | Last modification timestamp. |
Expanded details
Click any collection row to expand and view:
- Description and group metadata
- Upload configuration (if applicable)
- Versioning status
- Active fields table -- name, label, field type, and sort order for each active field
- Archived fields table -- highlighted with red styling and strikethrough text
- Relationships table -- target collection, relationship type, field mapping, and status
Globals table
The globals table follows the same structure as the collections table, with expandable rows showing field details.
Expand via URL
Use the expand query parameter to deep-link to a specific collection or global:
/admin/diagnostics?expand=posts # Expand the "posts" collection
/admin/diagnostics?expand=global:settings # Expand the "settings" global Use cases
- Debugging schema mismatches -- identify when metadata is stale after schema changes
- Tracking archived fields -- see which fields have been removed from the schema but still have metadata records
- Verifying seed operations -- confirm that
vextro-syncran successfully and all collections are registered - Inspecting relationships -- view how collections reference each other through relationship fields
Developer tool
The Schema Diagnostics page is primarily a developer and debugging tool. Consider restricting access to admin users or hiding it from non-technical editors in production.