diff --git a/go/cmd/vtctldclient/internal/command/vschemas.go b/go/cmd/vtctldclient/internal/command/vschemas.go index 1dae2fdef56..1c5e848e6d2 100644 --- a/go/cmd/vtctldclient/internal/command/vschemas.go +++ b/go/cmd/vtctldclient/internal/command/vschemas.go @@ -33,6 +33,12 @@ var ( Args: cobra.ExactArgs(1), RunE: commandGetSrvVSchema, } + // GetVSchema makes a GetVSchema gRPC call to a vtctld. + GetVSchema = &cobra.Command{ + Use: "GetVSchema keyspace", + Args: cobra.ExactArgs(1), + RunE: commandGetVSchema, + } ) func commandGetSrvVSchema(cmd *cobra.Command, args []string) error { @@ -55,6 +61,27 @@ func commandGetSrvVSchema(cmd *cobra.Command, args []string) error { return nil } +func commandGetVSchema(cmd *cobra.Command, args []string) error { + keyspace := cmd.Flags().Arg(0) + + resp, err := client.GetVSchema(commandCtx, &vtctldatapb.GetVSchemaRequest{ + Keyspace: keyspace, + }) + if err != nil { + return err + } + + data, err := cli.MarshalJSON(resp.VSchema) + if err != nil { + return err + } + + fmt.Printf("%s\n", data) + + return nil +} + func init() { Root.AddCommand(GetSrvVSchema) + Root.AddCommand(GetVSchema) } diff --git a/go/vt/proto/vtctldata/vtctldata.pb.go b/go/vt/proto/vtctldata/vtctldata.pb.go index 73307d4733b..5b42a77c754 100644 --- a/go/vt/proto/vtctldata/vtctldata.pb.go +++ b/go/vt/proto/vtctldata/vtctldata.pb.go @@ -950,6 +950,84 @@ func (m *GetTabletsResponse) GetTablets() []*topodata.Tablet { return nil } +type GetVSchemaRequest struct { + Keyspace string `protobuf:"bytes,1,opt,name=keyspace,proto3" json:"keyspace,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *GetVSchemaRequest) Reset() { *m = GetVSchemaRequest{} } +func (m *GetVSchemaRequest) String() string { return proto.CompactTextString(m) } +func (*GetVSchemaRequest) ProtoMessage() {} +func (*GetVSchemaRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_f41247b323a1ab2e, []int{22} +} + +func (m *GetVSchemaRequest) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_GetVSchemaRequest.Unmarshal(m, b) +} +func (m *GetVSchemaRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_GetVSchemaRequest.Marshal(b, m, deterministic) +} +func (m *GetVSchemaRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetVSchemaRequest.Merge(m, src) +} +func (m *GetVSchemaRequest) XXX_Size() int { + return xxx_messageInfo_GetVSchemaRequest.Size(m) +} +func (m *GetVSchemaRequest) XXX_DiscardUnknown() { + xxx_messageInfo_GetVSchemaRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_GetVSchemaRequest proto.InternalMessageInfo + +func (m *GetVSchemaRequest) GetKeyspace() string { + if m != nil { + return m.Keyspace + } + return "" +} + +type GetVSchemaResponse struct { + VSchema *vschema.Keyspace `protobuf:"bytes,1,opt,name=v_schema,json=vSchema,proto3" json:"v_schema,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *GetVSchemaResponse) Reset() { *m = GetVSchemaResponse{} } +func (m *GetVSchemaResponse) String() string { return proto.CompactTextString(m) } +func (*GetVSchemaResponse) ProtoMessage() {} +func (*GetVSchemaResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_f41247b323a1ab2e, []int{23} +} + +func (m *GetVSchemaResponse) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_GetVSchemaResponse.Unmarshal(m, b) +} +func (m *GetVSchemaResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_GetVSchemaResponse.Marshal(b, m, deterministic) +} +func (m *GetVSchemaResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetVSchemaResponse.Merge(m, src) +} +func (m *GetVSchemaResponse) XXX_Size() int { + return xxx_messageInfo_GetVSchemaResponse.Size(m) +} +func (m *GetVSchemaResponse) XXX_DiscardUnknown() { + xxx_messageInfo_GetVSchemaResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_GetVSchemaResponse proto.InternalMessageInfo + +func (m *GetVSchemaResponse) GetVSchema() *vschema.Keyspace { + if m != nil { + return m.VSchema + } + return nil +} + type Keyspace struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Keyspace *topodata.Keyspace `protobuf:"bytes,2,opt,name=keyspace,proto3" json:"keyspace,omitempty"` @@ -962,7 +1040,7 @@ func (m *Keyspace) Reset() { *m = Keyspace{} } func (m *Keyspace) String() string { return proto.CompactTextString(m) } func (*Keyspace) ProtoMessage() {} func (*Keyspace) Descriptor() ([]byte, []int) { - return fileDescriptor_f41247b323a1ab2e, []int{22} + return fileDescriptor_f41247b323a1ab2e, []int{24} } func (m *Keyspace) XXX_Unmarshal(b []byte) error { @@ -1008,7 +1086,7 @@ func (m *FindAllShardsInKeyspaceRequest) Reset() { *m = FindAllShardsInK func (m *FindAllShardsInKeyspaceRequest) String() string { return proto.CompactTextString(m) } func (*FindAllShardsInKeyspaceRequest) ProtoMessage() {} func (*FindAllShardsInKeyspaceRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_f41247b323a1ab2e, []int{23} + return fileDescriptor_f41247b323a1ab2e, []int{25} } func (m *FindAllShardsInKeyspaceRequest) XXX_Unmarshal(b []byte) error { @@ -1047,7 +1125,7 @@ func (m *FindAllShardsInKeyspaceResponse) Reset() { *m = FindAllShardsIn func (m *FindAllShardsInKeyspaceResponse) String() string { return proto.CompactTextString(m) } func (*FindAllShardsInKeyspaceResponse) ProtoMessage() {} func (*FindAllShardsInKeyspaceResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_f41247b323a1ab2e, []int{24} + return fileDescriptor_f41247b323a1ab2e, []int{26} } func (m *FindAllShardsInKeyspaceResponse) XXX_Unmarshal(b []byte) error { @@ -1088,7 +1166,7 @@ func (m *Shard) Reset() { *m = Shard{} } func (m *Shard) String() string { return proto.CompactTextString(m) } func (*Shard) ProtoMessage() {} func (*Shard) Descriptor() ([]byte, []int) { - return fileDescriptor_f41247b323a1ab2e, []int{25} + return fileDescriptor_f41247b323a1ab2e, []int{27} } func (m *Shard) XXX_Unmarshal(b []byte) error { @@ -1148,7 +1226,7 @@ func (m *TableMaterializeSettings) Reset() { *m = TableMaterializeSettin func (m *TableMaterializeSettings) String() string { return proto.CompactTextString(m) } func (*TableMaterializeSettings) ProtoMessage() {} func (*TableMaterializeSettings) Descriptor() ([]byte, []int) { - return fileDescriptor_f41247b323a1ab2e, []int{26} + return fileDescriptor_f41247b323a1ab2e, []int{28} } func (m *TableMaterializeSettings) XXX_Unmarshal(b []byte) error { @@ -1211,7 +1289,7 @@ func (m *MaterializeSettings) Reset() { *m = MaterializeSettings{} } func (m *MaterializeSettings) String() string { return proto.CompactTextString(m) } func (*MaterializeSettings) ProtoMessage() {} func (*MaterializeSettings) Descriptor() ([]byte, []int) { - return fileDescriptor_f41247b323a1ab2e, []int{27} + return fileDescriptor_f41247b323a1ab2e, []int{29} } func (m *MaterializeSettings) XXX_Unmarshal(b []byte) error { @@ -1305,6 +1383,8 @@ func init() { proto.RegisterType((*GetTabletResponse)(nil), "vtctldata.GetTabletResponse") proto.RegisterType((*GetTabletsRequest)(nil), "vtctldata.GetTabletsRequest") proto.RegisterType((*GetTabletsResponse)(nil), "vtctldata.GetTabletsResponse") + proto.RegisterType((*GetVSchemaRequest)(nil), "vtctldata.GetVSchemaRequest") + proto.RegisterType((*GetVSchemaResponse)(nil), "vtctldata.GetVSchemaResponse") proto.RegisterType((*Keyspace)(nil), "vtctldata.Keyspace") proto.RegisterType((*FindAllShardsInKeyspaceRequest)(nil), "vtctldata.FindAllShardsInKeyspaceRequest") proto.RegisterType((*FindAllShardsInKeyspaceResponse)(nil), "vtctldata.FindAllShardsInKeyspaceResponse") @@ -1317,72 +1397,74 @@ func init() { func init() { proto.RegisterFile("vtctldata.proto", fileDescriptor_f41247b323a1ab2e) } var fileDescriptor_f41247b323a1ab2e = []byte{ - // 1071 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x56, 0x5d, 0x6f, 0x1b, 0x45, - 0x17, 0x96, 0x9d, 0xda, 0x89, 0x4f, 0xe2, 0x8f, 0x6e, 0x92, 0x76, 0x5f, 0xbf, 0x02, 0xc2, 0x86, - 0xa6, 0x56, 0x90, 0xd6, 0xa5, 0x08, 0x54, 0xf1, 0x21, 0x91, 0x26, 0x6e, 0x14, 0x0a, 0xa1, 0x5a, - 0x47, 0x41, 0x02, 0x89, 0xd5, 0x66, 0x3d, 0x76, 0x57, 0x19, 0xef, 0x6c, 0x77, 0xc6, 0x9b, 0xb8, - 0xd7, 0xdc, 0xf0, 0x67, 0xb8, 0xe4, 0x92, 0xdf, 0x86, 0x66, 0xe6, 0xcc, 0xee, 0x3a, 0x71, 0xa8, - 0x80, 0xbb, 0x3d, 0xcf, 0xf9, 0x7e, 0xce, 0x99, 0x63, 0x43, 0x3b, 0x13, 0xa1, 0xa0, 0xa3, 0x40, - 0x04, 0x6e, 0x92, 0x32, 0xc1, 0xac, 0x46, 0x0e, 0x74, 0x9b, 0x94, 0x4d, 0x66, 0x22, 0xa2, 0x5a, - 0xd3, 0x6d, 0x4d, 0xe7, 0xfc, 0x0d, 0x0d, 0x85, 0x91, 0x1f, 0x8a, 0xe0, 0x82, 0x12, 0x31, 0x0d, - 0xe2, 0x60, 0x42, 0xd2, 0x22, 0x44, 0xb7, 0x25, 0x58, 0xc2, 0x4a, 0x72, 0x33, 0xe3, 0xe1, 0x6b, - 0x32, 0x45, 0xd1, 0xf9, 0x11, 0xba, 0x83, 0x6b, 0x12, 0xce, 0x04, 0x39, 0x97, 0xa9, 0x0e, 0xd9, - 0x74, 0x1a, 0xc4, 0x23, 0x8f, 0xbc, 0x99, 0x11, 0x2e, 0x2c, 0x0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0xe4, 0xb8, 0xf5, 0x1e, 0x40, 0x98, 0x92, 0x40, 0x10, 0x7f, 0x34, 0xa2, 0xaa, 0xb0, - 0x86, 0xd7, 0xd0, 0xc8, 0xd1, 0x88, 0x3a, 0xbf, 0x57, 0x61, 0x73, 0x59, 0x19, 0x5d, 0x58, 0xbb, - 0x62, 0xe9, 0xe5, 0x98, 0xb2, 0x2b, 0xd3, 0xba, 0x91, 0xad, 0xc7, 0xd0, 0xc6, 0xfc, 0x0b, 0x5b, - 0xd5, 0xf0, 0x5a, 0x1a, 0xce, 0x77, 0xf1, 0x31, 0xb4, 0xb1, 0x97, 0xdc, 0x50, 0x17, 0xd0, 0xd2, - 0x70, 0x6e, 0xb8, 0x07, 0x6d, 0x2e, 0x58, 0xe2, 0x07, 0x63, 0x41, 0x52, 0x3f, 0x64, 0xc9, 0x1c, - 0xaf, 0x66, 0x53, 0xc2, 0x07, 0x12, 0x3d, 0x64, 0xc9, 0xdc, 0xfa, 0x16, 0x5a, 0x78, 0x0c, 0xb1, - 0x4e, 0xbb, 0xa6, 0xd6, 0x67, 0xb7, 0x34, 0xce, 0xbb, 0x98, 0xf5, 0x9a, 0xfa, 0x5e, 0x9a, 0x0e, - 0xcd, 0x11, 0xab, 0x17, 0x47, 0x4c, 0x93, 0xaf, 0x0e, 0x8c, 0x98, 0x27, 0x84, 0xdb, 0xab, 0x86, - 0x7c, 0x89, 0x9d, 0x49, 0xe8, 0x79, 0xef, 0xa7, 0xbd, 0x2c, 0x12, 0x84, 0x73, 0x37, 0x62, 0x7d, - 0xfd, 0xd5, 0x9f, 0xb0, 0x7e, 0x26, 0xfa, 0xea, 0x5f, 0x62, 0x3f, 0x2f, 0xe4, 0xa2, 0xae, 0x80, - 0x4f, 0xff, 0x0a, 0x00, 0x00, 0xff, 0xff, 0x07, 0x33, 0x99, 0x59, 0xab, 0x0a, 0x00, 0x00, + // 1097 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00,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0xa3, 0x15, 0x87, 0x39, 0x6e, 0x7d, 0x00, + 0x10, 0xa6, 0x24, 0x10, 0xc4, 0x1f, 0x0c, 0xa8, 0x2a, 0xac, 0xe9, 0x35, 0x35, 0x72, 0x30, 0xa0, + 0xce, 0x5f, 0x55, 0x58, 0x9b, 0x57, 0x46, 0x17, 0x1a, 0xd7, 0x2c, 0xbd, 0xba, 0xa4, 0xec, 0xda, + 0xb4, 0x6e, 0x64, 0xeb, 0x11, 0xac, 0x60, 0xfe, 0xa9, 0xad, 0x6a, 0x7a, 0x6d, 0x0d, 0xe7, 0xbb, + 0xf8, 0x08, 0x56, 0xb0, 0x97, 0xdc, 0x50, 0x17, 0xd0, 0xd6, 0x70, 0x6e, 0xb8, 0x0d, 0x2b, 0x5c, + 0xb0, 0xc4, 0x0f, 0x2e, 0x05, 0x49, 0xfd, 0x90, 0x25, 0x13, 0x3c, 0xd5, 0x2d, 0x09, 0xef, 0x4a, + 0x74, 0x9f, 0x25, 0x13, 0xeb, 0x07, 0x68, 0xe3, 0x05, 0xc6, 0x3a, 0xed, 0x9a, 0x5a, 0x9f, 0xad, + 0xd2, 0x38, 0xef, 0x62, 0xd6, 0x6b, 0xe9, 0x23, 0x6d, 0x3a, 0x34, 0x97, 0xb3, 0x5e, 0x5c, 0x4e, + 0x4d, 0xbe, 0xba, 0x6a, 0x62, 0x92, 0x10, 0x6e, 0x2f, 0x1a, 0xf2, 0x25, 0x76, 0x26, 0xa1, 0xbd, + 0xde, 0xaf, 0xdb, 0x59, 0x24, 0x08, 0xe7, 0x6e, 0xc4, 0xfa, 0xfa, 0xab, 0x3f, 0x64, 0xfd, 0x4c, + 0xf4, 0xd5, 0x5f, 0xd3, 0x7e, 0x5e, 0xc8, 0x45, 0x5d, 0x01, 0x5f, 0xfc, 0x1b, 0x00, 0x00, 0xff, + 0xff, 0x66, 0x2a, 0x0a, 0x0a, 0x20, 0x0b, 0x00, 0x00, } diff --git a/go/vt/proto/vtctlservice/vtctlservice.pb.go b/go/vt/proto/vtctlservice/vtctlservice.pb.go index c76446f657d..6dd54ce6e4f 100644 --- a/go/vt/proto/vtctlservice/vtctlservice.pb.go +++ b/go/vt/proto/vtctlservice/vtctlservice.pb.go @@ -29,32 +29,32 @@ const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package func init() { proto.RegisterFile("vtctlservice.proto", fileDescriptor_27055cdbb1148d2b) } var fileDescriptor_27055cdbb1148d2b = []byte{ - // 385 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x94, 0xc1, 0x4e, 0xea, 0x40, - 0x14, 0x86, 0xef, 0x5d, 0x5c, 0x6e, 0x1c, 0x31, 0x98, 0x71, 0x61, 0x82, 0x80, 0x8a, 0xd1, 0x04, - 0x4d, 0xa8, 0xc1, 0x27, 0x00, 0xa2, 0x48, 0x48, 0x48, 0x14, 0xc2, 0x82, 0xc4, 0xc5, 0xd0, 0x1e, - 0xa5, 0xb1, 0xed, 0x94, 0x9e, 0xa1, 0xd1, 0x97, 0xf2, 0x19, 0x0d, 0x2d, 0x33, 0x94, 0x81, 0x41, - 0x77, 0xed, 0xff, 0x9d, 0xf3, 0xf5, 0x4f, 0x3a, 0x19, 0x42, 0x63, 0x61, 0x0b, 0x0f, 0x21, 0x8a, - 0x5d, 0x1b, 0xea, 0x61, 0xc4, 0x05, 0xa7, 0xf9, 0x6c, 0x56, 0x2c, 0x24, 0x6f, 0x0e, 0x13, 0x2c, - 0xc5, 0x8d, 0x19, 0xf9, 0x37, 0x5a, 0x44, 0x74, 0x4a, 0x8e, 0xee, 0x3f, 0xc0, 0x9e, 0x0b, 0x48, - 0xde, 0xdb, 0xdc, 0xf7, 0x59, 0xe0, 0xd0, 0xcb, 0xfa, 0x6a, 0x63, 0x0b, 0x7f, 0x86, 0xd9, 0x1c, - 0x50, 0x14, 0xaf, 0x7e, 0x1a, 0xc3, 0x90, 0x07, 0x08, 0xd5, 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43, 0x36, 0xf1, 0x40, 0xe8, 0xfd, 0xd2, 0xd4, 0xd0, 0x4f, 0x42, 0xed, 0x90, 0xa7, 0xf1, 0xc6, - 0x21, 0x5f, 0xc6, 0x86, 0x43, 0xae, 0xa8, 0x94, 0xb5, 0x6e, 0xc6, 0xb5, 0xd8, 0x15, 0x80, 0x58, - 0x77, 0xb9, 0x95, 0x3e, 0x59, 0x6f, 0xdc, 0x8a, 0x85, 0x95, 0xdc, 0x21, 0x56, 0xf6, 0x86, 0x99, - 0xe4, 0x92, 0xec, 0xee, 0x3b, 0x00, 0x00, 0xff, 0xff, 0x78, 0x06, 0x02, 0xde, 0x8c, 0x04, 0x00, - 0x00, + // 395 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x94, 0x51, 0x4f, 0xea, 0x30, + 0x14, 0xc7, 0xef, 0x7d, 0xb8, 0xdc, 0x58, 0x31, 0x98, 0xfa, 0x60, 0x82, 0x80, 0x8a, 0xd1, 0x04, + 0x4d, 0x98, 0xc1, 0x4f, 0x00, 0x44, 0x91, 0x90, 0x90, 0x28, 0x84, 0x07, 0x12, 0x1f, 0xca, 0x76, + 0x94, 0xc5, 0x6d, 0x1d, 0x3b, 0x65, 0xd1, 0xcf, 0xee, 0x8b, 0x61, 0xa3, 0x65, 0x14, 0x8a, 0xbe, + 0x6d, 0xff, 0xdf, 0x39, 0xbf, 0x9e, 0xa6, 0x4d, 0x09, 0x8d, 0x85, 0x2d, 0x3c, 0x84, 0x28, 0x76, + 0x6d, 0xa8, 0x87, 0x11, 0x17, 0x9c, 0xe6, 0xb3, 0x59, 0xb1, 0x90, 0xfc, 0x39, 0x4c, 0xb0, 0x14, + 0x37, 0x66, 0xe4, 0xdf, 0x68, 0x11, 0xd1, 0x29, 0x39, 0xba, 0xff, 0x00, 0x7b, 0x2e, 0x20, 0xf9, + 0x6f, 0x73, 0xdf, 0x67, 0x81, 0x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1, 0x32, 0x0d, 0xc9, 0xc1, + 0x22, 0x8e, 0xe2, 0xd1, 0xd2, 0xa6, 0xad, 0xbe, 0x22, 0xd2, 0x78, 0x66, 0x2e, 0xd0, 0xe6, 0x1b, + 0xb2, 0x89, 0x07, 0x42, 0x9f, 0x2f, 0x4d, 0x0d, 0xf3, 0x49, 0xa8, 0x5d, 0xf2, 0x34, 0xde, 0xb8, + 0xe4, 0xcb, 0xd8, 0x70, 0xc9, 0x15, 0xd5, 0x64, 0x72, 0xa7, 0x9a, 0x4c, 0xdb, 0x66, 0xd9, 0x40, + 0xa5, 0xac, 0x75, 0x33, 0xae, 0xc5, 0xae, 0x00, 0xc4, 0xba, 0xcb, 0xad, 0xf4, 0xcb, 0x7a, 0xe3, + 0x56, 0x2c, 0xac, 0xe4, 0x41, 0xb2, 0xb2, 0xcf, 0xd5, 0x24, 0x97, 0x64, 0x77, 0xdf, 0x01, 0x00, + 0x00, 0xff, 0xff, 0xd1, 0x33, 0xf9, 0x95, 0xd9, 0x04, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -194,6 +194,8 @@ type VtctldClient interface { GetTablet(ctx context.Context, in *vtctldata.GetTabletRequest, opts ...grpc.CallOption) (*vtctldata.GetTabletResponse, error) // GetTablets returns tablets, optionally filtered by keyspace and shard. GetTablets(ctx context.Context, in *vtctldata.GetTabletsRequest, opts ...grpc.CallOption) (*vtctldata.GetTabletsResponse, error) + // GetVSchema returns the vschema for a keyspace. + GetVSchema(ctx context.Context, in *vtctldata.GetVSchemaRequest, opts ...grpc.CallOption) (*vtctldata.GetVSchemaResponse, error) } type vtctldClient struct { @@ -303,6 +305,15 @@ func (c *vtctldClient) GetTablets(ctx context.Context, in *vtctldata.GetTabletsR return out, nil } +func (c *vtctldClient) GetVSchema(ctx context.Context, in *vtctldata.GetVSchemaRequest, opts ...grpc.CallOption) (*vtctldata.GetVSchemaResponse, error) { + out := new(vtctldata.GetVSchemaResponse) + err := c.cc.Invoke(ctx, "/vtctlservice.Vtctld/GetVSchema", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // VtctldServer is the server API for Vtctld service. type VtctldServer interface { // FindAllShardsInKeyspace returns a map of shard names to shard references @@ -331,6 +342,8 @@ type VtctldServer interface { GetTablet(context.Context, *vtctldata.GetTabletRequest) (*vtctldata.GetTabletResponse, error) // GetTablets returns tablets, optionally filtered by keyspace and shard. GetTablets(context.Context, *vtctldata.GetTabletsRequest) (*vtctldata.GetTabletsResponse, error) + // GetVSchema returns the vschema for a keyspace. + GetVSchema(context.Context, *vtctldata.GetVSchemaRequest) (*vtctldata.GetVSchemaResponse, error) } // UnimplementedVtctldServer can be embedded to have forward compatible implementations. @@ -370,6 +383,9 @@ func (*UnimplementedVtctldServer) GetTablet(ctx context.Context, req *vtctldata. func (*UnimplementedVtctldServer) GetTablets(ctx context.Context, req *vtctldata.GetTabletsRequest) (*vtctldata.GetTabletsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method GetTablets not implemented") } +func (*UnimplementedVtctldServer) GetVSchema(ctx context.Context, req *vtctldata.GetVSchemaRequest) (*vtctldata.GetVSchemaResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetVSchema not implemented") +} func RegisterVtctldServer(s *grpc.Server, srv VtctldServer) { s.RegisterService(&_Vtctld_serviceDesc, srv) @@ -573,6 +589,24 @@ func _Vtctld_GetTablets_Handler(srv interface{}, ctx context.Context, dec func(i return interceptor(ctx, in, info, handler) } +func _Vtctld_GetVSchema_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(vtctldata.GetVSchemaRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(VtctldServer).GetVSchema(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/vtctlservice.Vtctld/GetVSchema", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(VtctldServer).GetVSchema(ctx, req.(*vtctldata.GetVSchemaRequest)) + } + return interceptor(ctx, in, info, handler) +} + var _Vtctld_serviceDesc = grpc.ServiceDesc{ ServiceName: "vtctlservice.Vtctld", HandlerType: (*VtctldServer)(nil), @@ -621,6 +655,10 @@ var _Vtctld_serviceDesc = grpc.ServiceDesc{ MethodName: "GetTablets", Handler: _Vtctld_GetTablets_Handler, }, + { + MethodName: "GetVSchema", + Handler: _Vtctld_GetVSchema_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "vtctlservice.proto", diff --git a/go/vt/vtctl/grpcvtctldclient/client_gen.go b/go/vt/vtctl/grpcvtctldclient/client_gen.go index 994124545d1..ed32a09c69f 100644 --- a/go/vt/vtctl/grpcvtctldclient/client_gen.go +++ b/go/vt/vtctl/grpcvtctldclient/client_gen.go @@ -126,3 +126,12 @@ func (client *gRPCVtctldClient) GetTablets(ctx context.Context, in *vtctldatapb. return client.c.GetTablets(ctx, in, opts...) } + +// GetVSchema is part of the vtctlservicepb.VtctldClient interface. +func (client *gRPCVtctldClient) GetVSchema(ctx context.Context, in *vtctldatapb.GetVSchemaRequest, opts ...grpc.CallOption) (*vtctldatapb.GetVSchemaResponse, error) { + if client.c == nil { + return nil, status.Error(codes.Unavailable, connClosedMsg) + } + + return client.c.GetVSchema(ctx, in, opts...) +} diff --git a/go/vt/vtctl/grpcvtctldserver/server.go b/go/vt/vtctl/grpcvtctldserver/server.go index 28db37f564f..96245825f3b 100644 --- a/go/vt/vtctl/grpcvtctldserver/server.go +++ b/go/vt/vtctl/grpcvtctldserver/server.go @@ -328,6 +328,18 @@ func (s *VtctldServer) GetTablets(ctx context.Context, req *vtctldatapb.GetTable }, nil } +// GetVSchema is part of the vtctlservicepb.VtctldServer interface. +func (s *VtctldServer) GetVSchema(ctx context.Context, req *vtctldatapb.GetVSchemaRequest) (*vtctldatapb.GetVSchemaResponse, error) { + vschema, err := s.ts.GetVSchema(ctx, req.Keyspace) + if err != nil { + return nil, err + } + + return &vtctldatapb.GetVSchemaResponse{ + VSchema: vschema, + }, nil +} + // StartServer registers a VtctldServer for RPCs on the given gRPC server. func StartServer(s *grpc.Server, ts *topo.Server) { vtctlservicepb.RegisterVtctldServer(s, NewVtctldServer(ts)) diff --git a/go/vt/vtctl/grpcvtctldserver/server_test.go b/go/vt/vtctl/grpcvtctldserver/server_test.go index af2cf77ebe5..4bcb2e12b99 100644 --- a/go/vt/vtctl/grpcvtctldserver/server_test.go +++ b/go/vt/vtctl/grpcvtctldserver/server_test.go @@ -859,3 +859,43 @@ func TestGetTablets(t *testing.T) { }) } } + +func TestGetVSchema(t *testing.T) { + ctx := context.Background() + ts := memorytopo.NewServer("zone1") + vtctld := NewVtctldServer(ts) + + err := ts.SaveVSchema(ctx, "testkeyspace", &vschemapb.Keyspace{ + Sharded: true, + Vindexes: map[string]*vschemapb.Vindex{ + "v1": { + Type: "hash", + }, + }, + }) + require.NoError(t, err) + + expected := &vtctldatapb.GetVSchemaResponse{ + VSchema: &vschemapb.Keyspace{ + Sharded: true, + Vindexes: map[string]*vschemapb.Vindex{ + "v1": { + Type: "hash", + }, + }, + }, + } + + resp, err := vtctld.GetVSchema(ctx, &vtctldatapb.GetVSchemaRequest{ + Keyspace: "testkeyspace", + }) + assert.NoError(t, err) + assert.Equal(t, expected, resp) + + t.Run("not found", func(t *testing.T) { + _, err := vtctld.GetVSchema(ctx, &vtctldatapb.GetVSchemaRequest{ + Keyspace: "doesnotexist", + }) + assert.Error(t, err) + }) +} diff --git a/proto/vtctldata.proto b/proto/vtctldata.proto index c8fe5a5decd..69c6f561488 100644 --- a/proto/vtctldata.proto +++ b/proto/vtctldata.proto @@ -140,6 +140,14 @@ message GetTabletsResponse { repeated topodata.Tablet tablets = 1; } +message GetVSchemaRequest { + string keyspace = 1; +} + +message GetVSchemaResponse { + vschema.Keyspace v_schema = 1; +} + message Keyspace { string name = 1; topodata.Keyspace keyspace = 2; diff --git a/proto/vtctlservice.proto b/proto/vtctlservice.proto index 8ca3f581b21..bcf94e9aa98 100644 --- a/proto/vtctlservice.proto +++ b/proto/vtctlservice.proto @@ -57,4 +57,6 @@ service Vtctld { rpc GetTablet(vtctldata.GetTabletRequest) returns (vtctldata.GetTabletResponse) {}; // GetTablets returns tablets, optionally filtered by keyspace and shard. rpc GetTablets(vtctldata.GetTabletsRequest) returns (vtctldata.GetTabletsResponse) {}; + // GetVSchema returns the vschema for a keyspace. + rpc GetVSchema(vtctldata.GetVSchemaRequest) returns (vtctldata.GetVSchemaResponse) {}; }