Skip to content

Add vtctld get-vschema command - #1318

Closed
planetscale-ai-tools[bot] wants to merge 1 commit into
mainfrom
cursor/vtctld-get-vschema-7ed3
Closed

Add vtctld get-vschema command#1318
planetscale-ai-tools[bot] wants to merge 1 commit into
mainfrom
cursor/vtctld-get-vschema-7ed3

Conversation

@planetscale-ai-tools

Copy link
Copy Markdown

Adds pscale branch vtctld get-vschema <database> <branch> --keyspace <keyspace> for reading live VSchema state through the API. The client and command preserve the existing raw JSON output conventions used by other vtctld commands.

Testing:

  • go test ./internal/planetscale ./internal/cmd/branch/vtctld
  • go vet ./internal/planetscale ./internal/cmd/branch/vtctld
  • staticcheck ./internal/planetscale ./internal/cmd/branch/vtctld

Security impact:

None. This is a client for a read-only, server-authorized API endpoint.

@planetscale-ai-tools

Copy link
Copy Markdown
Author

Closing: the Inventory2 runbook GetVSchema / multi_tenant_spec pre-check is already covered by existing pscale keyspace vschema show (and update).

Verified on dev-aws-us-east-1-3 with a sharded keyspace: after pscale keyspace vschema update with multi_tenant_spec, pscale keyspace vschema show … | jq -c '.multi_tenant_spec' returns exactly:

{"tenant_id_column_name":"source_shard_id","tenant_id_column_type":"INT64"}

No new public vtctld GetVSchema surface is needed for this runbook gap.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant