From c1e50ed909aee7198826e174d93245c8427e1385 Mon Sep 17 00:00:00 2001 From: Cody Soyland Date: Thu, 17 Sep 2020 11:20:58 -0500 Subject: [PATCH 1/5] Remove VDS references from pilosa proto file, begin porting VDSM service --- Makefile | 1 + proto/pilosa.pb.go | 626 ++------------ proto/pilosa.proto | 43 +- proto/vdsm/vdsm.pb.go | 1902 +++++++++++++++++++++++++++++++++++++++++ proto/vdsm/vdsm.proto | 146 ++++ server/grpc.go | 132 ++- 6 files changed, 2200 insertions(+), 650 deletions(-) create mode 100644 proto/vdsm/vdsm.pb.go create mode 100644 proto/vdsm/vdsm.proto diff --git a/Makefile b/Makefile index ba3d994a8..f6ca2fe1f 100644 --- a/Makefile +++ b/Makefile @@ -169,6 +169,7 @@ generate-pql: require-peg # dunno if protoc-gen-gofast is actually needed here generate-proto-grpc: require-protoc require-protoc-gen-gofast protoc -I proto proto/pilosa.proto --go_out=plugins=grpc:proto + protoc -I proto proto/vdsm/vdsm.proto --go_out=plugins=grpc:proto # `go generate` all needed packages generate: generate-protoc generate-statik generate-stringer generate-pql diff --git a/proto/pilosa.pb.go b/proto/pilosa.pb.go index a48ae519b..45ac65612 100644 --- a/proto/pilosa.pb.go +++ b/proto/pilosa.pb.go @@ -24,349 +24,6 @@ var _ = math.Inf // proto package needs to be updated. const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package -type VDS struct { - Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *VDS) Reset() { *m = VDS{} } -func (m *VDS) String() string { return proto.CompactTextString(m) } -func (*VDS) ProtoMessage() {} -func (*VDS) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{0} -} - -func (m *VDS) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_VDS.Unmarshal(m, b) -} -func (m *VDS) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_VDS.Marshal(b, m, deterministic) -} -func (m *VDS) XXX_Merge(src proto.Message) { - xxx_messageInfo_VDS.Merge(m, src) -} -func (m *VDS) XXX_Size() int { - return xxx_messageInfo_VDS.Size(m) -} -func (m *VDS) XXX_DiscardUnknown() { - xxx_messageInfo_VDS.DiscardUnknown(m) -} - -var xxx_messageInfo_VDS proto.InternalMessageInfo - -func (m *VDS) GetName() string { - if m != nil { - return m.Name - } - return "" -} - -type GetVDSsRequest struct { - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *GetVDSsRequest) Reset() { *m = GetVDSsRequest{} } -func (m *GetVDSsRequest) String() string { return proto.CompactTextString(m) } -func (*GetVDSsRequest) ProtoMessage() {} -func (*GetVDSsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{1} -} - -func (m *GetVDSsRequest) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_GetVDSsRequest.Unmarshal(m, b) -} -func (m *GetVDSsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_GetVDSsRequest.Marshal(b, m, deterministic) -} -func (m *GetVDSsRequest) XXX_Merge(src proto.Message) { - xxx_messageInfo_GetVDSsRequest.Merge(m, src) -} -func (m *GetVDSsRequest) XXX_Size() int { - return xxx_messageInfo_GetVDSsRequest.Size(m) -} -func (m *GetVDSsRequest) XXX_DiscardUnknown() { - xxx_messageInfo_GetVDSsRequest.DiscardUnknown(m) -} - -var xxx_messageInfo_GetVDSsRequest proto.InternalMessageInfo - -type GetVDSsResponse struct { - Vdss []*VDS `protobuf:"bytes,1,rep,name=vdss,proto3" json:"vdss,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *GetVDSsResponse) Reset() { *m = GetVDSsResponse{} } -func (m *GetVDSsResponse) String() string { return proto.CompactTextString(m) } -func (*GetVDSsResponse) ProtoMessage() {} -func (*GetVDSsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{2} -} - -func (m *GetVDSsResponse) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_GetVDSsResponse.Unmarshal(m, b) -} -func (m *GetVDSsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_GetVDSsResponse.Marshal(b, m, deterministic) -} -func (m *GetVDSsResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_GetVDSsResponse.Merge(m, src) -} -func (m *GetVDSsResponse) XXX_Size() int { - return xxx_messageInfo_GetVDSsResponse.Size(m) -} -func (m *GetVDSsResponse) XXX_DiscardUnknown() { - xxx_messageInfo_GetVDSsResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_GetVDSsResponse proto.InternalMessageInfo - -func (m *GetVDSsResponse) GetVdss() []*VDS { - if m != nil { - return m.Vdss - } - return nil -} - -type GetVDSRequest struct { - Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *GetVDSRequest) Reset() { *m = GetVDSRequest{} } -func (m *GetVDSRequest) String() string { return proto.CompactTextString(m) } -func (*GetVDSRequest) ProtoMessage() {} -func (*GetVDSRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{3} -} - -func (m *GetVDSRequest) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_GetVDSRequest.Unmarshal(m, b) -} -func (m *GetVDSRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_GetVDSRequest.Marshal(b, m, deterministic) -} -func (m *GetVDSRequest) XXX_Merge(src proto.Message) { - xxx_messageInfo_GetVDSRequest.Merge(m, src) -} -func (m *GetVDSRequest) XXX_Size() int { - return xxx_messageInfo_GetVDSRequest.Size(m) -} -func (m *GetVDSRequest) XXX_DiscardUnknown() { - xxx_messageInfo_GetVDSRequest.DiscardUnknown(m) -} - -var xxx_messageInfo_GetVDSRequest proto.InternalMessageInfo - -func (m *GetVDSRequest) GetName() string { - if m != nil { - return m.Name - } - return "" -} - -type GetVDSResponse struct { - Vds *VDS `protobuf:"bytes,1,opt,name=vds,proto3" json:"vds,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *GetVDSResponse) Reset() { *m = GetVDSResponse{} } -func (m *GetVDSResponse) String() string { return proto.CompactTextString(m) } -func (*GetVDSResponse) ProtoMessage() {} -func (*GetVDSResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{4} -} - -func (m *GetVDSResponse) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_GetVDSResponse.Unmarshal(m, b) -} -func (m *GetVDSResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_GetVDSResponse.Marshal(b, m, deterministic) -} -func (m *GetVDSResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_GetVDSResponse.Merge(m, src) -} -func (m *GetVDSResponse) XXX_Size() int { - return xxx_messageInfo_GetVDSResponse.Size(m) -} -func (m *GetVDSResponse) XXX_DiscardUnknown() { - xxx_messageInfo_GetVDSResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_GetVDSResponse proto.InternalMessageInfo - -func (m *GetVDSResponse) GetVds() *VDS { - if m != nil { - return m.Vds - } - return nil -} - -type PostVDSRequest struct { - Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` - Keys bool `protobuf:"varint,2,opt,name=keys,proto3" json:"keys,omitempty"` - TrackExistence bool `protobuf:"varint,3,opt,name=trackExistence,proto3" json:"trackExistence,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *PostVDSRequest) Reset() { *m = PostVDSRequest{} } -func (m *PostVDSRequest) String() string { return proto.CompactTextString(m) } -func (*PostVDSRequest) ProtoMessage() {} -func (*PostVDSRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{5} -} - -func (m *PostVDSRequest) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_PostVDSRequest.Unmarshal(m, b) -} -func (m *PostVDSRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_PostVDSRequest.Marshal(b, m, deterministic) -} -func (m *PostVDSRequest) XXX_Merge(src proto.Message) { - xxx_messageInfo_PostVDSRequest.Merge(m, src) -} -func (m *PostVDSRequest) XXX_Size() int { - return xxx_messageInfo_PostVDSRequest.Size(m) -} -func (m *PostVDSRequest) XXX_DiscardUnknown() { - xxx_messageInfo_PostVDSRequest.DiscardUnknown(m) -} - -var xxx_messageInfo_PostVDSRequest proto.InternalMessageInfo - -func (m *PostVDSRequest) GetName() string { - if m != nil { - return m.Name - } - return "" -} - -func (m *PostVDSRequest) GetKeys() bool { - if m != nil { - return m.Keys - } - return false -} - -func (m *PostVDSRequest) GetTrackExistence() bool { - if m != nil { - return m.TrackExistence - } - return false -} - -type PostVDSResponse struct { - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *PostVDSResponse) Reset() { *m = PostVDSResponse{} } -func (m *PostVDSResponse) String() string { return proto.CompactTextString(m) } -func (*PostVDSResponse) ProtoMessage() {} -func (*PostVDSResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{6} -} - -func (m *PostVDSResponse) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_PostVDSResponse.Unmarshal(m, b) -} -func (m *PostVDSResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_PostVDSResponse.Marshal(b, m, deterministic) -} -func (m *PostVDSResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_PostVDSResponse.Merge(m, src) -} -func (m *PostVDSResponse) XXX_Size() int { - return xxx_messageInfo_PostVDSResponse.Size(m) -} -func (m *PostVDSResponse) XXX_DiscardUnknown() { - xxx_messageInfo_PostVDSResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_PostVDSResponse proto.InternalMessageInfo - -type DeleteVDSRequest struct { - Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *DeleteVDSRequest) Reset() { *m = DeleteVDSRequest{} } -func (m *DeleteVDSRequest) String() string { return proto.CompactTextString(m) } -func (*DeleteVDSRequest) ProtoMessage() {} -func (*DeleteVDSRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{7} -} - -func (m *DeleteVDSRequest) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_DeleteVDSRequest.Unmarshal(m, b) -} -func (m *DeleteVDSRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_DeleteVDSRequest.Marshal(b, m, deterministic) -} -func (m *DeleteVDSRequest) XXX_Merge(src proto.Message) { - xxx_messageInfo_DeleteVDSRequest.Merge(m, src) -} -func (m *DeleteVDSRequest) XXX_Size() int { - return xxx_messageInfo_DeleteVDSRequest.Size(m) -} -func (m *DeleteVDSRequest) XXX_DiscardUnknown() { - xxx_messageInfo_DeleteVDSRequest.DiscardUnknown(m) -} - -var xxx_messageInfo_DeleteVDSRequest proto.InternalMessageInfo - -func (m *DeleteVDSRequest) GetName() string { - if m != nil { - return m.Name - } - return "" -} - -type DeleteVDSResponse struct { - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *DeleteVDSResponse) Reset() { *m = DeleteVDSResponse{} } -func (m *DeleteVDSResponse) String() string { return proto.CompactTextString(m) } -func (*DeleteVDSResponse) ProtoMessage() {} -func (*DeleteVDSResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{8} -} - -func (m *DeleteVDSResponse) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_DeleteVDSResponse.Unmarshal(m, b) -} -func (m *DeleteVDSResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_DeleteVDSResponse.Marshal(b, m, deterministic) -} -func (m *DeleteVDSResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_DeleteVDSResponse.Merge(m, src) -} -func (m *DeleteVDSResponse) XXX_Size() int { - return xxx_messageInfo_DeleteVDSResponse.Size(m) -} -func (m *DeleteVDSResponse) XXX_DiscardUnknown() { - xxx_messageInfo_DeleteVDSResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_DeleteVDSResponse proto.InternalMessageInfo - type QueryPQLRequest struct { Index string `protobuf:"bytes,1,opt,name=index,proto3" json:"index,omitempty"` Pql string `protobuf:"bytes,2,opt,name=pql,proto3" json:"pql,omitempty"` @@ -379,7 +36,7 @@ func (m *QueryPQLRequest) Reset() { *m = QueryPQLRequest{} } func (m *QueryPQLRequest) String() string { return proto.CompactTextString(m) } func (*QueryPQLRequest) ProtoMessage() {} func (*QueryPQLRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{9} + return fileDescriptor_ef0691a44d1e275c, []int{0} } func (m *QueryPQLRequest) XXX_Unmarshal(b []byte) error { @@ -425,7 +82,7 @@ func (m *QuerySQLRequest) Reset() { *m = QuerySQLRequest{} } func (m *QuerySQLRequest) String() string { return proto.CompactTextString(m) } func (*QuerySQLRequest) ProtoMessage() {} func (*QuerySQLRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{10} + return fileDescriptor_ef0691a44d1e275c, []int{1} } func (m *QuerySQLRequest) XXX_Unmarshal(b []byte) error { @@ -465,7 +122,7 @@ func (m *StatusError) Reset() { *m = StatusError{} } func (m *StatusError) String() string { return proto.CompactTextString(m) } func (*StatusError) ProtoMessage() {} func (*StatusError) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{11} + return fileDescriptor_ef0691a44d1e275c, []int{2} } func (m *StatusError) XXX_Unmarshal(b []byte) error { @@ -513,7 +170,7 @@ func (m *RowResponse) Reset() { *m = RowResponse{} } func (m *RowResponse) String() string { return proto.CompactTextString(m) } func (*RowResponse) ProtoMessage() {} func (*RowResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{12} + return fileDescriptor_ef0691a44d1e275c, []int{3} } func (m *RowResponse) XXX_Unmarshal(b []byte) error { @@ -566,7 +223,7 @@ func (m *Row) Reset() { *m = Row{} } func (m *Row) String() string { return proto.CompactTextString(m) } func (*Row) ProtoMessage() {} func (*Row) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{13} + return fileDescriptor_ef0691a44d1e275c, []int{4} } func (m *Row) XXX_Unmarshal(b []byte) error { @@ -607,7 +264,7 @@ func (m *TableResponse) Reset() { *m = TableResponse{} } func (m *TableResponse) String() string { return proto.CompactTextString(m) } func (*TableResponse) ProtoMessage() {} func (*TableResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{14} + return fileDescriptor_ef0691a44d1e275c, []int{5} } func (m *TableResponse) XXX_Unmarshal(b []byte) error { @@ -661,7 +318,7 @@ func (m *ColumnInfo) Reset() { *m = ColumnInfo{} } func (m *ColumnInfo) String() string { return proto.CompactTextString(m) } func (*ColumnInfo) ProtoMessage() {} func (*ColumnInfo) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{15} + return fileDescriptor_ef0691a44d1e275c, []int{6} } func (m *ColumnInfo) XXX_Unmarshal(b []byte) error { @@ -717,7 +374,7 @@ func (m *ColumnResponse) Reset() { *m = ColumnResponse{} } func (m *ColumnResponse) String() string { return proto.CompactTextString(m) } func (*ColumnResponse) ProtoMessage() {} func (*ColumnResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{16} + return fileDescriptor_ef0691a44d1e275c, []int{7} } func (m *ColumnResponse) XXX_Unmarshal(b []byte) error { @@ -893,7 +550,7 @@ func (m *Decimal) Reset() { *m = Decimal{} } func (m *Decimal) String() string { return proto.CompactTextString(m) } func (*Decimal) ProtoMessage() {} func (*Decimal) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{17} + return fileDescriptor_ef0691a44d1e275c, []int{8} } func (m *Decimal) XXX_Unmarshal(b []byte) error { @@ -944,7 +601,7 @@ func (m *InspectRequest) Reset() { *m = InspectRequest{} } func (m *InspectRequest) String() string { return proto.CompactTextString(m) } func (*InspectRequest) ProtoMessage() {} func (*InspectRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{18} + return fileDescriptor_ef0691a44d1e275c, []int{9} } func (m *InspectRequest) XXX_Unmarshal(b []byte) error { @@ -1018,7 +675,7 @@ func (m *Uint64Array) Reset() { *m = Uint64Array{} } func (m *Uint64Array) String() string { return proto.CompactTextString(m) } func (*Uint64Array) ProtoMessage() {} func (*Uint64Array) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{19} + return fileDescriptor_ef0691a44d1e275c, []int{10} } func (m *Uint64Array) XXX_Unmarshal(b []byte) error { @@ -1057,7 +714,7 @@ func (m *StringArray) Reset() { *m = StringArray{} } func (m *StringArray) String() string { return proto.CompactTextString(m) } func (*StringArray) ProtoMessage() {} func (*StringArray) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{20} + return fileDescriptor_ef0691a44d1e275c, []int{11} } func (m *StringArray) XXX_Unmarshal(b []byte) error { @@ -1099,7 +756,7 @@ func (m *IdsOrKeys) Reset() { *m = IdsOrKeys{} } func (m *IdsOrKeys) String() string { return proto.CompactTextString(m) } func (*IdsOrKeys) ProtoMessage() {} func (*IdsOrKeys) Descriptor() ([]byte, []int) { - return fileDescriptor_ef0691a44d1e275c, []int{21} + return fileDescriptor_ef0691a44d1e275c, []int{12} } func (m *IdsOrKeys) XXX_Unmarshal(b []byte) error { @@ -1166,15 +823,6 @@ func (*IdsOrKeys) XXX_OneofWrappers() []interface{} { } func init() { - proto.RegisterType((*VDS)(nil), "pilosa.VDS") - proto.RegisterType((*GetVDSsRequest)(nil), "pilosa.GetVDSsRequest") - proto.RegisterType((*GetVDSsResponse)(nil), "pilosa.GetVDSsResponse") - proto.RegisterType((*GetVDSRequest)(nil), "pilosa.GetVDSRequest") - proto.RegisterType((*GetVDSResponse)(nil), "pilosa.GetVDSResponse") - proto.RegisterType((*PostVDSRequest)(nil), "pilosa.PostVDSRequest") - proto.RegisterType((*PostVDSResponse)(nil), "pilosa.PostVDSResponse") - proto.RegisterType((*DeleteVDSRequest)(nil), "pilosa.DeleteVDSRequest") - proto.RegisterType((*DeleteVDSResponse)(nil), "pilosa.DeleteVDSResponse") proto.RegisterType((*QueryPQLRequest)(nil), "pilosa.QueryPQLRequest") proto.RegisterType((*QuerySQLRequest)(nil), "pilosa.QuerySQLRequest") proto.RegisterType((*StatusError)(nil), "pilosa.StatusError") @@ -1193,64 +841,52 @@ func init() { func init() { proto.RegisterFile("pilosa.proto", fileDescriptor_ef0691a44d1e275c) } var fileDescriptor_ef0691a44d1e275c = []byte{ - // 897 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x56, 0xdd, 0x72, 0xdb, 0x44, - 0x14, 0xb6, 0x90, 0x6a, 0x59, 0xc7, 0x89, 0x93, 0x6c, 0x20, 0xb8, 0x1e, 0xa0, 0x66, 0x3b, 0x53, - 0xcc, 0xc0, 0x94, 0x12, 0x28, 0x4c, 0x21, 0x5c, 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- 0x6f, 0xc6, 0x78, 0x03, 0x3d, 0x82, 0xa6, 0x56, 0xa2, 0x77, 0xea, 0x24, 0x6b, 0x7b, 0xb0, 0xae, - 0x76, 0xa6, 0x47, 0x10, 0x9a, 0x9d, 0x52, 0x06, 0xae, 0xaf, 0xb1, 0x32, 0xf0, 0xfa, 0xf2, 0x69, - 0xa0, 0x63, 0x88, 0xdc, 0x5a, 0x41, 0xdd, 0xf2, 0x7a, 0xd6, 0x37, 0x52, 0xef, 0xf6, 0x35, 0x48, - 0x25, 0x83, 0x96, 0x5d, 0x25, 0xc8, 0x85, 0x5a, 0x5b, 0x2e, 0xbd, 0xfd, 0xea, 0x7c, 0x73, 0xb6, - 0x0f, 0x3c, 0xf4, 0x18, 0xb6, 0x2d, 0xf7, 0x79, 0x46, 0xf3, 0xd5, 0x66, 0x17, 0xee, 0x68, 0x6a, - 0x53, 0xb7, 0x92, 0xc0, 0xf8, 0x95, 0x04, 0xc6, 0xff, 0x23, 0x81, 0xf1, 0xf5, 0x09, 0x8c, 0xdf, - 0x20, 0x81, 0x6f, 0x20, 0x34, 0x6f, 0xae, 0xec, 0x41, 0xfd, 0x11, 0x6e, 0x0c, 0x7f, 0xda, 0x54, - 0xff, 0x4e, 0x5f, 0xfc, 0x1b, 0x00, 0x00, 0xff, 0xff, 0x1e, 0xff, 0x07, 0x47, 0x4b, 0x09, 0x00, - 0x00, + // 718 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x55, 0xdd, 0x52, 0xd3, 0x4e, + 0x14, 0x6f, 0x48, 0x68, 0x9b, 0x53, 0xbe, 0xfe, 0xcb, 0x5f, 0xcc, 0x30, 0x8e, 0xc6, 0x78, 0x61, + 0x1c, 0x1d, 0x06, 0x51, 0x74, 0x54, 0xbc, 0x00, 0xd4, 0x29, 0xa3, 0x8e, 0x65, 0x11, 0xee, 0xb7, + 0xcd, 0x16, 0x33, 0x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ee, 0x82, 0x1d, 0x47, 0x42, 0xd5, 0x3e, 0x73, 0x38, 0x24, 0x03, + 0xdd, 0x03, 0xe7, 0x33, 0x9d, 0x98, 0xaf, 0x31, 0x63, 0x0e, 0x14, 0x65, 0xaf, 0x0e, 0x8e, 0x5c, + 0x96, 0xad, 0x9f, 0x73, 0x50, 0xef, 0x28, 0x1a, 0xda, 0x81, 0xa6, 0xb9, 0xa7, 0xe8, 0xba, 0xb1, + 0xbd, 0x70, 0x61, 0xd7, 0x57, 0xcb, 0x4b, 0x9e, 0xaf, 0x57, 0x50, 0xdb, 0xb4, 0xd0, 0x2e, 0x2c, + 0x1a, 0xee, 0x71, 0x42, 0xd2, 0xc9, 0x6c, 0x17, 0xd7, 0x0c, 0x50, 0x39, 0x3d, 0x41, 0xad, 0x48, + 0xa0, 0xf3, 0x5b, 0x02, 0x9d, 0x7f, 0x48, 0xa0, 0xf3, 0xe7, 0x04, 0x3a, 0x97, 0x48, 0xe0, 0x39, + 0x34, 0xf2, 0xc1, 0x43, 0xc5, 0xed, 0xac, 0x4e, 0xe2, 0xcc, 0xf0, 0xdd, 0xba, 0xfa, 0xaf, 0x3d, + 0xfa, 0x15, 0x00, 0x00, 0xff, 0xff, 0x7e, 0x8d, 0x53, 0x0b, 0xe7, 0x06, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -1265,10 +901,6 @@ const _ = grpc.SupportPackageIsVersion4 // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type PilosaClient interface { - GetVDSs(ctx context.Context, in *GetVDSsRequest, opts ...grpc.CallOption) (*GetVDSsResponse, error) - GetVDS(ctx context.Context, in *GetVDSRequest, opts ...grpc.CallOption) (*GetVDSResponse, error) - PostVDS(ctx context.Context, in *PostVDSRequest, opts ...grpc.CallOption) (*PostVDSResponse, error) - DeleteVDS(ctx context.Context, in *DeleteVDSRequest, opts ...grpc.CallOption) (*DeleteVDSResponse, error) QuerySQL(ctx context.Context, in *QuerySQLRequest, opts ...grpc.CallOption) (Pilosa_QuerySQLClient, error) QuerySQLUnary(ctx context.Context, in *QuerySQLRequest, opts ...grpc.CallOption) (*TableResponse, error) QueryPQL(ctx context.Context, in *QueryPQLRequest, opts ...grpc.CallOption) (Pilosa_QueryPQLClient, error) @@ -1284,42 +916,6 @@ func NewPilosaClient(cc *grpc.ClientConn) PilosaClient { return &pilosaClient{cc} } -func (c *pilosaClient) GetVDSs(ctx context.Context, in *GetVDSsRequest, opts ...grpc.CallOption) (*GetVDSsResponse, error) { - out := new(GetVDSsResponse) - err := c.cc.Invoke(ctx, "/pilosa.Pilosa/GetVDSs", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *pilosaClient) GetVDS(ctx context.Context, in *GetVDSRequest, opts ...grpc.CallOption) (*GetVDSResponse, error) { - out := new(GetVDSResponse) - err := c.cc.Invoke(ctx, "/pilosa.Pilosa/GetVDS", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *pilosaClient) PostVDS(ctx context.Context, in *PostVDSRequest, opts ...grpc.CallOption) (*PostVDSResponse, error) { - out := new(PostVDSResponse) - err := c.cc.Invoke(ctx, "/pilosa.Pilosa/PostVDS", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *pilosaClient) DeleteVDS(ctx context.Context, in *DeleteVDSRequest, opts ...grpc.CallOption) (*DeleteVDSResponse, error) { - out := new(DeleteVDSResponse) - err := c.cc.Invoke(ctx, "/pilosa.Pilosa/DeleteVDS", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - func (c *pilosaClient) QuerySQL(ctx context.Context, in *QuerySQLRequest, opts ...grpc.CallOption) (Pilosa_QuerySQLClient, error) { stream, err := c.cc.NewStream(ctx, &_Pilosa_serviceDesc.Streams[0], "/pilosa.Pilosa/QuerySQL", opts...) if err != nil { @@ -1436,10 +1032,6 @@ func (x *pilosaInspectClient) Recv() (*RowResponse, error) { // PilosaServer is the server API for Pilosa service. type PilosaServer interface { - GetVDSs(context.Context, *GetVDSsRequest) (*GetVDSsResponse, error) - GetVDS(context.Context, *GetVDSRequest) (*GetVDSResponse, error) - PostVDS(context.Context, *PostVDSRequest) (*PostVDSResponse, error) - DeleteVDS(context.Context, *DeleteVDSRequest) (*DeleteVDSResponse, error) QuerySQL(*QuerySQLRequest, Pilosa_QuerySQLServer) error QuerySQLUnary(context.Context, *QuerySQLRequest) (*TableResponse, error) QueryPQL(*QueryPQLRequest, Pilosa_QueryPQLServer) error @@ -1451,18 +1043,6 @@ type PilosaServer interface { type UnimplementedPilosaServer struct { } -func (*UnimplementedPilosaServer) GetVDSs(ctx context.Context, req *GetVDSsRequest) (*GetVDSsResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method GetVDSs not implemented") -} -func (*UnimplementedPilosaServer) GetVDS(ctx context.Context, req *GetVDSRequest) (*GetVDSResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method GetVDS not implemented") -} -func (*UnimplementedPilosaServer) PostVDS(ctx context.Context, req *PostVDSRequest) (*PostVDSResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method PostVDS not implemented") -} -func (*UnimplementedPilosaServer) DeleteVDS(ctx context.Context, req *DeleteVDSRequest) (*DeleteVDSResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method DeleteVDS not implemented") -} func (*UnimplementedPilosaServer) QuerySQL(req *QuerySQLRequest, srv Pilosa_QuerySQLServer) error { return status.Errorf(codes.Unimplemented, "method QuerySQL not implemented") } @@ -1483,78 +1063,6 @@ func RegisterPilosaServer(s *grpc.Server, srv PilosaServer) { s.RegisterService(&_Pilosa_serviceDesc, srv) } -func _Pilosa_GetVDSs_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(GetVDSsRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(PilosaServer).GetVDSs(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/pilosa.Pilosa/GetVDSs", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(PilosaServer).GetVDSs(ctx, req.(*GetVDSsRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _Pilosa_GetVDS_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(GetVDSRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(PilosaServer).GetVDS(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/pilosa.Pilosa/GetVDS", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(PilosaServer).GetVDS(ctx, req.(*GetVDSRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _Pilosa_PostVDS_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(PostVDSRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(PilosaServer).PostVDS(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/pilosa.Pilosa/PostVDS", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(PilosaServer).PostVDS(ctx, req.(*PostVDSRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _Pilosa_DeleteVDS_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(DeleteVDSRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(PilosaServer).DeleteVDS(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/pilosa.Pilosa/DeleteVDS", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(PilosaServer).DeleteVDS(ctx, req.(*DeleteVDSRequest)) - } - return interceptor(ctx, in, info, handler) -} - func _Pilosa_QuerySQL_Handler(srv interface{}, stream grpc.ServerStream) error { m := new(QuerySQLRequest) if err := stream.RecvMsg(m); err != nil { @@ -1658,22 +1166,6 @@ var _Pilosa_serviceDesc = grpc.ServiceDesc{ ServiceName: "pilosa.Pilosa", HandlerType: (*PilosaServer)(nil), Methods: []grpc.MethodDesc{ - { - MethodName: "GetVDSs", - Handler: _Pilosa_GetVDSs_Handler, - }, - { - MethodName: "GetVDS", - Handler: _Pilosa_GetVDS_Handler, - }, - { - MethodName: "PostVDS", - Handler: _Pilosa_PostVDS_Handler, - }, - { - MethodName: "DeleteVDS", - Handler: _Pilosa_DeleteVDS_Handler, - }, { MethodName: "QuerySQLUnary", Handler: _Pilosa_QuerySQLUnary_Handler, diff --git a/proto/pilosa.proto b/proto/pilosa.proto index f51a45502..1fc966083 100644 --- a/proto/pilosa.proto +++ b/proto/pilosa.proto @@ -1,42 +1,7 @@ syntax = "proto3"; package pilosa; -import "public.proto"; - -message VDS { - string name = 1; -} - -message GetVDSsRequest { -} - -message GetVDSsResponse { - repeated VDS vdss = 1; -} - -message GetVDSRequest { - string name = 1; -} - -message GetVDSResponse { - VDS vds = 1; -} - -message PostVDSRequest { - string name = 1; - bool keys = 2; - bool trackExistence = 3; -} - -message PostVDSResponse { -} - -message DeleteVDSRequest { - string name = 1; -} - -message DeleteVDSResponse { -} +//import "public.proto"; message QueryPQLRequest { string index = 1; @@ -117,14 +82,10 @@ message IdsOrKeys { } service Pilosa { - rpc GetVDSs(GetVDSsRequest) returns (GetVDSsResponse) {}; - rpc GetVDS(GetVDSRequest) returns (GetVDSResponse) {}; - rpc PostVDS(PostVDSRequest) returns (PostVDSResponse) {}; - rpc DeleteVDS(DeleteVDSRequest) returns (DeleteVDSResponse) {}; rpc QuerySQL(QuerySQLRequest) returns (stream RowResponse) {}; rpc QuerySQLUnary(QuerySQLRequest) returns (TableResponse) {}; rpc QueryPQL(QueryPQLRequest) returns (stream RowResponse) {}; rpc QueryPQLUnary(QueryPQLRequest) returns (TableResponse) {}; rpc Inspect(InspectRequest) returns (stream RowResponse) {}; - rpc ImportAtomicRecord(stream AtomicRecord) returns (AtomicImportResponse) {}; + //rpc ImportAtomicRecord(stream AtomicRecord) returns (AtomicImportResponse) {}; } diff --git a/proto/vdsm/vdsm.pb.go b/proto/vdsm/vdsm.pb.go new file mode 100644 index 000000000..2d4deaf42 --- /dev/null +++ b/proto/vdsm/vdsm.pb.go @@ -0,0 +1,1902 @@ +// Code generated by protoc-gen-go. DO NOT EDIT. +// source: vdsm/vdsm.proto + +package vdsm + +import ( + context "context" + fmt "fmt" + proto "github.com/golang/protobuf/proto" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" + math "math" +) + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package + +// deprecated +type DataSource struct { + Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` + Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` + Description string `protobuf:"bytes,3,opt,name=description,proto3" json:"description,omitempty"` + Type string `protobuf:"bytes,4,opt,name=type,proto3" json:"type,omitempty"` + Config map[string]string `protobuf:"bytes,5,rep,name=config,proto3" json:"config,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` + Status string `protobuf:"bytes,6,opt,name=status,proto3" json:"status,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *DataSource) Reset() { *m = DataSource{} } +func (m *DataSource) String() string { return proto.CompactTextString(m) } +func (*DataSource) ProtoMessage() {} +func (*DataSource) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{0} +} + +func (m *DataSource) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_DataSource.Unmarshal(m, b) +} +func (m *DataSource) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_DataSource.Marshal(b, m, deterministic) +} +func (m *DataSource) XXX_Merge(src proto.Message) { + xxx_messageInfo_DataSource.Merge(m, src) +} +func (m *DataSource) XXX_Size() int { + return xxx_messageInfo_DataSource.Size(m) +} +func (m *DataSource) XXX_DiscardUnknown() { + xxx_messageInfo_DataSource.DiscardUnknown(m) +} + +var xxx_messageInfo_DataSource proto.InternalMessageInfo + +func (m *DataSource) GetId() int64 { + if m != nil { + return m.Id + } + return 0 +} + +func (m *DataSource) GetName() string { + if m != nil { + return m.Name + } + return "" +} + +func (m *DataSource) GetDescription() string { + if m != nil { + return m.Description + } + return "" +} + +func (m *DataSource) GetType() string { + if m != nil { + return m.Type + } + return "" +} + +func (m *DataSource) GetConfig() map[string]string { + if m != nil { + return m.Config + } + return nil +} + +func (m *DataSource) GetStatus() string { + if m != nil { + return m.Status + } + return "" +} + +type VDS struct { + Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` + Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` + Description string `protobuf:"bytes,3,opt,name=description,proto3" json:"description,omitempty"` + PilosaIndex string `protobuf:"bytes,4,opt,name=pilosa_index,json=pilosaIndex,proto3" json:"pilosa_index,omitempty"` + Datasources []*DataSource `protobuf:"bytes,5,rep,name=datasources,proto3" json:"datasources,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *VDS) Reset() { *m = VDS{} } +func (m *VDS) String() string { return proto.CompactTextString(m) } +func (*VDS) ProtoMessage() {} +func (*VDS) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{1} +} + +func (m *VDS) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_VDS.Unmarshal(m, b) +} +func (m *VDS) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_VDS.Marshal(b, m, deterministic) +} +func (m *VDS) XXX_Merge(src proto.Message) { + xxx_messageInfo_VDS.Merge(m, src) +} +func (m *VDS) XXX_Size() int { + return xxx_messageInfo_VDS.Size(m) +} +func (m *VDS) XXX_DiscardUnknown() { + xxx_messageInfo_VDS.DiscardUnknown(m) +} + +var xxx_messageInfo_VDS proto.InternalMessageInfo + +func (m *VDS) GetId() string { + if m != nil { + return m.Id + } + return "" +} + +func (m *VDS) GetName() string { + if m != nil { + return m.Name + } + return "" +} + +func (m *VDS) GetDescription() string { + if m != nil { + return m.Description + } + return "" +} + +func (m *VDS) GetPilosaIndex() string { + if m != nil { + return m.PilosaIndex + } + return "" +} + +func (m *VDS) GetDatasources() []*DataSource { + if m != nil { + return m.Datasources + } + return nil +} + +type GetVDSsRequest struct { + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *GetVDSsRequest) Reset() { *m = GetVDSsRequest{} } +func (m *GetVDSsRequest) String() string { return proto.CompactTextString(m) } +func (*GetVDSsRequest) ProtoMessage() {} +func (*GetVDSsRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{2} +} + +func (m *GetVDSsRequest) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_GetVDSsRequest.Unmarshal(m, b) +} +func (m *GetVDSsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_GetVDSsRequest.Marshal(b, m, deterministic) +} +func (m *GetVDSsRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetVDSsRequest.Merge(m, src) +} +func (m *GetVDSsRequest) XXX_Size() int { + return xxx_messageInfo_GetVDSsRequest.Size(m) +} +func (m *GetVDSsRequest) XXX_DiscardUnknown() { + xxx_messageInfo_GetVDSsRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_GetVDSsRequest proto.InternalMessageInfo + +type GetVDSsResponse struct { + Vdss []*VDS `protobuf:"bytes,1,rep,name=vdss,proto3" json:"vdss,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *GetVDSsResponse) Reset() { *m = GetVDSsResponse{} } +func (m *GetVDSsResponse) String() string { return proto.CompactTextString(m) } +func (*GetVDSsResponse) ProtoMessage() {} +func (*GetVDSsResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{3} +} + +func (m *GetVDSsResponse) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_GetVDSsResponse.Unmarshal(m, b) +} +func (m *GetVDSsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_GetVDSsResponse.Marshal(b, m, deterministic) +} +func (m *GetVDSsResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetVDSsResponse.Merge(m, src) +} +func (m *GetVDSsResponse) XXX_Size() int { + return xxx_messageInfo_GetVDSsResponse.Size(m) +} +func (m *GetVDSsResponse) XXX_DiscardUnknown() { + xxx_messageInfo_GetVDSsResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_GetVDSsResponse proto.InternalMessageInfo + +func (m *GetVDSsResponse) GetVdss() []*VDS { + if m != nil { + return m.Vdss + } + return nil +} + +type GetVDSRequest struct { + // Types that are valid to be assigned to IdOrName: + // *GetVDSRequest_Id + // *GetVDSRequest_Name + IdOrName isGetVDSRequest_IdOrName `protobuf_oneof:"idOrName"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *GetVDSRequest) Reset() { *m = GetVDSRequest{} } +func (m *GetVDSRequest) String() string { return proto.CompactTextString(m) } +func (*GetVDSRequest) ProtoMessage() {} +func (*GetVDSRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{4} +} + +func (m *GetVDSRequest) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_GetVDSRequest.Unmarshal(m, b) +} +func (m *GetVDSRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_GetVDSRequest.Marshal(b, m, deterministic) +} +func (m *GetVDSRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetVDSRequest.Merge(m, src) +} +func (m *GetVDSRequest) XXX_Size() int { + return xxx_messageInfo_GetVDSRequest.Size(m) +} +func (m *GetVDSRequest) XXX_DiscardUnknown() { + xxx_messageInfo_GetVDSRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_GetVDSRequest proto.InternalMessageInfo + +type isGetVDSRequest_IdOrName interface { + isGetVDSRequest_IdOrName() +} + +type GetVDSRequest_Id struct { + Id string `protobuf:"bytes,1,opt,name=id,proto3,oneof"` +} + +type GetVDSRequest_Name struct { + Name string `protobuf:"bytes,2,opt,name=name,proto3,oneof"` +} + +func (*GetVDSRequest_Id) isGetVDSRequest_IdOrName() {} + +func (*GetVDSRequest_Name) isGetVDSRequest_IdOrName() {} + +func (m *GetVDSRequest) GetIdOrName() isGetVDSRequest_IdOrName { + if m != nil { + return m.IdOrName + } + return nil +} + +func (m *GetVDSRequest) GetId() string { + if x, ok := m.GetIdOrName().(*GetVDSRequest_Id); ok { + return x.Id + } + return "" +} + +func (m *GetVDSRequest) GetName() string { + if x, ok := m.GetIdOrName().(*GetVDSRequest_Name); ok { + return x.Name + } + return "" +} + +// XXX_OneofWrappers is for the internal use of the proto package. +func (*GetVDSRequest) XXX_OneofWrappers() []interface{} { + return []interface{}{ + (*GetVDSRequest_Id)(nil), + (*GetVDSRequest_Name)(nil), + } +} + +type GetVDSResponse struct { + Vds *VDS `protobuf:"bytes,1,opt,name=vds,proto3" json:"vds,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *GetVDSResponse) Reset() { *m = GetVDSResponse{} } +func (m *GetVDSResponse) String() string { return proto.CompactTextString(m) } +func (*GetVDSResponse) ProtoMessage() {} +func (*GetVDSResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{5} +} + +func (m *GetVDSResponse) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_GetVDSResponse.Unmarshal(m, b) +} +func (m *GetVDSResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_GetVDSResponse.Marshal(b, m, deterministic) +} +func (m *GetVDSResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetVDSResponse.Merge(m, src) +} +func (m *GetVDSResponse) XXX_Size() int { + return xxx_messageInfo_GetVDSResponse.Size(m) +} +func (m *GetVDSResponse) XXX_DiscardUnknown() { + xxx_messageInfo_GetVDSResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_GetVDSResponse proto.InternalMessageInfo + +func (m *GetVDSResponse) GetVds() *VDS { + if m != nil { + return m.Vds + } + return nil +} + +type PostVDSRequest struct { + Definition string `protobuf:"bytes,1,opt,name=definition,proto3" json:"definition,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *PostVDSRequest) Reset() { *m = PostVDSRequest{} } +func (m *PostVDSRequest) String() string { return proto.CompactTextString(m) } +func (*PostVDSRequest) ProtoMessage() {} +func (*PostVDSRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{6} +} + +func (m *PostVDSRequest) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_PostVDSRequest.Unmarshal(m, b) +} +func (m *PostVDSRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_PostVDSRequest.Marshal(b, m, deterministic) +} +func (m *PostVDSRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_PostVDSRequest.Merge(m, src) +} +func (m *PostVDSRequest) XXX_Size() int { + return xxx_messageInfo_PostVDSRequest.Size(m) +} +func (m *PostVDSRequest) XXX_DiscardUnknown() { + xxx_messageInfo_PostVDSRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_PostVDSRequest proto.InternalMessageInfo + +func (m *PostVDSRequest) GetDefinition() string { + if m != nil { + return m.Definition + } + return "" +} + +type PostVDSResponse struct { + Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` + Uri string `protobuf:"bytes,2,opt,name=uri,proto3" json:"uri,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *PostVDSResponse) Reset() { *m = PostVDSResponse{} } +func (m *PostVDSResponse) String() string { return proto.CompactTextString(m) } +func (*PostVDSResponse) ProtoMessage() {} +func (*PostVDSResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{7} +} + +func (m *PostVDSResponse) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_PostVDSResponse.Unmarshal(m, b) +} +func (m *PostVDSResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_PostVDSResponse.Marshal(b, m, deterministic) +} +func (m *PostVDSResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_PostVDSResponse.Merge(m, src) +} +func (m *PostVDSResponse) XXX_Size() int { + return xxx_messageInfo_PostVDSResponse.Size(m) +} +func (m *PostVDSResponse) XXX_DiscardUnknown() { + xxx_messageInfo_PostVDSResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_PostVDSResponse proto.InternalMessageInfo + +func (m *PostVDSResponse) GetId() string { + if m != nil { + return m.Id + } + return "" +} + +func (m *PostVDSResponse) GetUri() string { + if m != nil { + return m.Uri + } + return "" +} + +type DeleteVDSRequest struct { + // Types that are valid to be assigned to IdOrName: + // *DeleteVDSRequest_Id + // *DeleteVDSRequest_Name + IdOrName isDeleteVDSRequest_IdOrName `protobuf_oneof:"idOrName"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *DeleteVDSRequest) Reset() { *m = DeleteVDSRequest{} } +func (m *DeleteVDSRequest) String() string { return proto.CompactTextString(m) } +func (*DeleteVDSRequest) ProtoMessage() {} +func (*DeleteVDSRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{8} +} + +func (m *DeleteVDSRequest) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_DeleteVDSRequest.Unmarshal(m, b) +} +func (m *DeleteVDSRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_DeleteVDSRequest.Marshal(b, m, deterministic) +} +func (m *DeleteVDSRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_DeleteVDSRequest.Merge(m, src) +} +func (m *DeleteVDSRequest) XXX_Size() int { + return xxx_messageInfo_DeleteVDSRequest.Size(m) +} +func (m *DeleteVDSRequest) XXX_DiscardUnknown() { + xxx_messageInfo_DeleteVDSRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_DeleteVDSRequest proto.InternalMessageInfo + +type isDeleteVDSRequest_IdOrName interface { + isDeleteVDSRequest_IdOrName() +} + +type DeleteVDSRequest_Id struct { + Id string `protobuf:"bytes,1,opt,name=id,proto3,oneof"` +} + +type DeleteVDSRequest_Name struct { + Name string `protobuf:"bytes,2,opt,name=name,proto3,oneof"` +} + +func (*DeleteVDSRequest_Id) isDeleteVDSRequest_IdOrName() {} + +func (*DeleteVDSRequest_Name) isDeleteVDSRequest_IdOrName() {} + +func (m *DeleteVDSRequest) GetIdOrName() isDeleteVDSRequest_IdOrName { + if m != nil { + return m.IdOrName + } + return nil +} + +func (m *DeleteVDSRequest) GetId() string { + if x, ok := m.GetIdOrName().(*DeleteVDSRequest_Id); ok { + return x.Id + } + return "" +} + +func (m *DeleteVDSRequest) GetName() string { + if x, ok := m.GetIdOrName().(*DeleteVDSRequest_Name); ok { + return x.Name + } + return "" +} + +// XXX_OneofWrappers is for the internal use of the proto package. +func (*DeleteVDSRequest) XXX_OneofWrappers() []interface{} { + return []interface{}{ + (*DeleteVDSRequest_Id)(nil), + (*DeleteVDSRequest_Name)(nil), + } +} + +type DeleteVDSResponse struct { + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *DeleteVDSResponse) Reset() { *m = DeleteVDSResponse{} } +func (m *DeleteVDSResponse) String() string { return proto.CompactTextString(m) } +func (*DeleteVDSResponse) ProtoMessage() {} +func (*DeleteVDSResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{9} +} + +func (m *DeleteVDSResponse) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_DeleteVDSResponse.Unmarshal(m, b) +} +func (m *DeleteVDSResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_DeleteVDSResponse.Marshal(b, m, deterministic) +} +func (m *DeleteVDSResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_DeleteVDSResponse.Merge(m, src) +} +func (m *DeleteVDSResponse) XXX_Size() int { + return xxx_messageInfo_DeleteVDSResponse.Size(m) +} +func (m *DeleteVDSResponse) XXX_DiscardUnknown() { + xxx_messageInfo_DeleteVDSResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_DeleteVDSResponse proto.InternalMessageInfo + +type QueryPQLRequest struct { + Vds string `protobuf:"bytes,1,opt,name=vds,proto3" json:"vds,omitempty"` + Pql string `protobuf:"bytes,2,opt,name=pql,proto3" json:"pql,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *QueryPQLRequest) Reset() { *m = QueryPQLRequest{} } +func (m *QueryPQLRequest) String() string { return proto.CompactTextString(m) } +func (*QueryPQLRequest) ProtoMessage() {} +func (*QueryPQLRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{10} +} + +func (m *QueryPQLRequest) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_QueryPQLRequest.Unmarshal(m, b) +} +func (m *QueryPQLRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_QueryPQLRequest.Marshal(b, m, deterministic) +} +func (m *QueryPQLRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_QueryPQLRequest.Merge(m, src) +} +func (m *QueryPQLRequest) XXX_Size() int { + return xxx_messageInfo_QueryPQLRequest.Size(m) +} +func (m *QueryPQLRequest) XXX_DiscardUnknown() { + xxx_messageInfo_QueryPQLRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_QueryPQLRequest proto.InternalMessageInfo + +func (m *QueryPQLRequest) GetVds() string { + if m != nil { + return m.Vds + } + return "" +} + +func (m *QueryPQLRequest) GetPql() string { + if m != nil { + return m.Pql + } + return "" +} + +type QuerySQLRequest struct { + Sql string `protobuf:"bytes,1,opt,name=sql,proto3" json:"sql,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *QuerySQLRequest) Reset() { *m = QuerySQLRequest{} } +func (m *QuerySQLRequest) String() string { return proto.CompactTextString(m) } +func (*QuerySQLRequest) ProtoMessage() {} +func (*QuerySQLRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{11} +} + +func (m *QuerySQLRequest) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_QuerySQLRequest.Unmarshal(m, b) +} +func (m *QuerySQLRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_QuerySQLRequest.Marshal(b, m, deterministic) +} +func (m *QuerySQLRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_QuerySQLRequest.Merge(m, src) +} +func (m *QuerySQLRequest) XXX_Size() int { + return xxx_messageInfo_QuerySQLRequest.Size(m) +} +func (m *QuerySQLRequest) XXX_DiscardUnknown() { + xxx_messageInfo_QuerySQLRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_QuerySQLRequest proto.InternalMessageInfo + +func (m *QuerySQLRequest) GetSql() string { + if m != nil { + return m.Sql + } + return "" +} + +type StatusError struct { + Code uint32 `protobuf:"varint,1,opt,name=Code,proto3" json:"Code,omitempty"` + Message string `protobuf:"bytes,2,opt,name=Message,proto3" json:"Message,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *StatusError) Reset() { *m = StatusError{} } +func (m *StatusError) String() string { return proto.CompactTextString(m) } +func (*StatusError) ProtoMessage() {} +func (*StatusError) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{12} +} + +func (m *StatusError) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_StatusError.Unmarshal(m, b) +} +func (m *StatusError) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_StatusError.Marshal(b, m, deterministic) +} +func (m *StatusError) XXX_Merge(src proto.Message) { + xxx_messageInfo_StatusError.Merge(m, src) +} +func (m *StatusError) XXX_Size() int { + return xxx_messageInfo_StatusError.Size(m) +} +func (m *StatusError) XXX_DiscardUnknown() { + xxx_messageInfo_StatusError.DiscardUnknown(m) +} + +var xxx_messageInfo_StatusError proto.InternalMessageInfo + +func (m *StatusError) GetCode() uint32 { + if m != nil { + return m.Code + } + return 0 +} + +func (m *StatusError) GetMessage() string { + if m != nil { + return m.Message + } + return "" +} + +type RowResponse struct { + Headers []*ColumnInfo `protobuf:"bytes,1,rep,name=headers,proto3" json:"headers,omitempty"` + Columns []*ColumnResponse `protobuf:"bytes,2,rep,name=columns,proto3" json:"columns,omitempty"` + StatusError *StatusError `protobuf:"bytes,3,opt,name=StatusError,proto3" json:"StatusError,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *RowResponse) Reset() { *m = RowResponse{} } +func (m *RowResponse) String() string { return proto.CompactTextString(m) } +func (*RowResponse) ProtoMessage() {} +func (*RowResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{13} +} + +func (m *RowResponse) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_RowResponse.Unmarshal(m, b) +} +func (m *RowResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_RowResponse.Marshal(b, m, deterministic) +} +func (m *RowResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_RowResponse.Merge(m, src) +} +func (m *RowResponse) XXX_Size() int { + return xxx_messageInfo_RowResponse.Size(m) +} +func (m *RowResponse) XXX_DiscardUnknown() { + xxx_messageInfo_RowResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_RowResponse proto.InternalMessageInfo + +func (m *RowResponse) GetHeaders() []*ColumnInfo { + if m != nil { + return m.Headers + } + return nil +} + +func (m *RowResponse) GetColumns() []*ColumnResponse { + if m != nil { + return m.Columns + } + return nil +} + +func (m *RowResponse) GetStatusError() *StatusError { + if m != nil { + return m.StatusError + } + return nil +} + +type Row struct { + Columns []*ColumnResponse `protobuf:"bytes,1,rep,name=columns,proto3" json:"columns,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *Row) Reset() { *m = Row{} } +func (m *Row) String() string { return proto.CompactTextString(m) } +func (*Row) ProtoMessage() {} +func (*Row) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{14} +} + +func (m *Row) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_Row.Unmarshal(m, b) +} +func (m *Row) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_Row.Marshal(b, m, deterministic) +} +func (m *Row) XXX_Merge(src proto.Message) { + xxx_messageInfo_Row.Merge(m, src) +} +func (m *Row) XXX_Size() int { + return xxx_messageInfo_Row.Size(m) +} +func (m *Row) XXX_DiscardUnknown() { + xxx_messageInfo_Row.DiscardUnknown(m) +} + +var xxx_messageInfo_Row proto.InternalMessageInfo + +func (m *Row) GetColumns() []*ColumnResponse { + if m != nil { + return m.Columns + } + return nil +} + +type TableResponse struct { + Headers []*ColumnInfo `protobuf:"bytes,1,rep,name=headers,proto3" json:"headers,omitempty"` + Rows []*Row `protobuf:"bytes,2,rep,name=rows,proto3" json:"rows,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *TableResponse) Reset() { *m = TableResponse{} } +func (m *TableResponse) String() string { return proto.CompactTextString(m) } +func (*TableResponse) ProtoMessage() {} +func (*TableResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{15} +} + +func (m *TableResponse) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_TableResponse.Unmarshal(m, b) +} +func (m *TableResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_TableResponse.Marshal(b, m, deterministic) +} +func (m *TableResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_TableResponse.Merge(m, src) +} +func (m *TableResponse) XXX_Size() int { + return xxx_messageInfo_TableResponse.Size(m) +} +func (m *TableResponse) XXX_DiscardUnknown() { + xxx_messageInfo_TableResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_TableResponse proto.InternalMessageInfo + +func (m *TableResponse) GetHeaders() []*ColumnInfo { + if m != nil { + return m.Headers + } + return nil +} + +func (m *TableResponse) GetRows() []*Row { + if m != nil { + return m.Rows + } + return nil +} + +type ColumnInfo struct { + Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` + Datatype string `protobuf:"bytes,2,opt,name=datatype,proto3" json:"datatype,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *ColumnInfo) Reset() { *m = ColumnInfo{} } +func (m *ColumnInfo) String() string { return proto.CompactTextString(m) } +func (*ColumnInfo) ProtoMessage() {} +func (*ColumnInfo) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{16} +} + +func (m *ColumnInfo) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_ColumnInfo.Unmarshal(m, b) +} +func (m *ColumnInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_ColumnInfo.Marshal(b, m, deterministic) +} +func (m *ColumnInfo) XXX_Merge(src proto.Message) { + xxx_messageInfo_ColumnInfo.Merge(m, src) +} +func (m *ColumnInfo) XXX_Size() int { + return xxx_messageInfo_ColumnInfo.Size(m) +} +func (m *ColumnInfo) XXX_DiscardUnknown() { + xxx_messageInfo_ColumnInfo.DiscardUnknown(m) +} + +var xxx_messageInfo_ColumnInfo proto.InternalMessageInfo + +func (m *ColumnInfo) GetName() string { + if m != nil { + return m.Name + } + return "" +} + +func (m *ColumnInfo) GetDatatype() string { + if m != nil { + return m.Datatype + } + return "" +} + +type ColumnResponse struct { + // Types that are valid to be assigned to ColumnVal: + // *ColumnResponse_StringVal + // *ColumnResponse_Uint64Val + // *ColumnResponse_Int64Val + // *ColumnResponse_BoolVal + // *ColumnResponse_BlobVal + // *ColumnResponse_Uint64ArrayVal + // *ColumnResponse_StringArrayVal + // *ColumnResponse_Float64Val + // *ColumnResponse_DecimalVal + ColumnVal isColumnResponse_ColumnVal `protobuf_oneof:"columnVal"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *ColumnResponse) Reset() { *m = ColumnResponse{} } +func (m *ColumnResponse) String() string { return proto.CompactTextString(m) } +func (*ColumnResponse) ProtoMessage() {} +func (*ColumnResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{17} +} + +func (m *ColumnResponse) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_ColumnResponse.Unmarshal(m, b) +} +func (m *ColumnResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_ColumnResponse.Marshal(b, m, deterministic) +} +func (m *ColumnResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_ColumnResponse.Merge(m, src) +} +func (m *ColumnResponse) XXX_Size() int { + return xxx_messageInfo_ColumnResponse.Size(m) +} +func (m *ColumnResponse) XXX_DiscardUnknown() { + xxx_messageInfo_ColumnResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_ColumnResponse proto.InternalMessageInfo + +type isColumnResponse_ColumnVal interface { + isColumnResponse_ColumnVal() +} + +type ColumnResponse_StringVal struct { + StringVal string `protobuf:"bytes,1,opt,name=stringVal,proto3,oneof"` +} + +type ColumnResponse_Uint64Val struct { + Uint64Val uint64 `protobuf:"varint,2,opt,name=uint64Val,proto3,oneof"` +} + +type ColumnResponse_Int64Val struct { + Int64Val int64 `protobuf:"varint,3,opt,name=int64Val,proto3,oneof"` +} + +type ColumnResponse_BoolVal struct { + BoolVal bool `protobuf:"varint,4,opt,name=boolVal,proto3,oneof"` +} + +type ColumnResponse_BlobVal struct { + BlobVal []byte `protobuf:"bytes,5,opt,name=blobVal,proto3,oneof"` +} + +type ColumnResponse_Uint64ArrayVal struct { + Uint64ArrayVal *Uint64Array `protobuf:"bytes,6,opt,name=uint64ArrayVal,proto3,oneof"` +} + +type ColumnResponse_StringArrayVal struct { + StringArrayVal *StringArray `protobuf:"bytes,7,opt,name=stringArrayVal,proto3,oneof"` +} + +type ColumnResponse_Float64Val struct { + Float64Val float64 `protobuf:"fixed64,8,opt,name=float64Val,proto3,oneof"` +} + +type ColumnResponse_DecimalVal struct { + DecimalVal *Decimal `protobuf:"bytes,9,opt,name=decimalVal,proto3,oneof"` +} + +func (*ColumnResponse_StringVal) isColumnResponse_ColumnVal() {} + +func (*ColumnResponse_Uint64Val) isColumnResponse_ColumnVal() {} + +func (*ColumnResponse_Int64Val) isColumnResponse_ColumnVal() {} + +func (*ColumnResponse_BoolVal) isColumnResponse_ColumnVal() {} + +func (*ColumnResponse_BlobVal) isColumnResponse_ColumnVal() {} + +func (*ColumnResponse_Uint64ArrayVal) isColumnResponse_ColumnVal() {} + +func (*ColumnResponse_StringArrayVal) isColumnResponse_ColumnVal() {} + +func (*ColumnResponse_Float64Val) isColumnResponse_ColumnVal() {} + +func (*ColumnResponse_DecimalVal) isColumnResponse_ColumnVal() {} + +func (m *ColumnResponse) GetColumnVal() isColumnResponse_ColumnVal { + if m != nil { + return m.ColumnVal + } + return nil +} + +func (m *ColumnResponse) GetStringVal() string { + if x, ok := m.GetColumnVal().(*ColumnResponse_StringVal); ok { + return x.StringVal + } + return "" +} + +func (m *ColumnResponse) GetUint64Val() uint64 { + if x, ok := m.GetColumnVal().(*ColumnResponse_Uint64Val); ok { + return x.Uint64Val + } + return 0 +} + +func (m *ColumnResponse) GetInt64Val() int64 { + if x, ok := m.GetColumnVal().(*ColumnResponse_Int64Val); ok { + return x.Int64Val + } + return 0 +} + +func (m *ColumnResponse) GetBoolVal() bool { + if x, ok := m.GetColumnVal().(*ColumnResponse_BoolVal); ok { + return x.BoolVal + } + return false +} + +func (m *ColumnResponse) GetBlobVal() []byte { + if x, ok := m.GetColumnVal().(*ColumnResponse_BlobVal); ok { + return x.BlobVal + } + return nil +} + +func (m *ColumnResponse) GetUint64ArrayVal() *Uint64Array { + if x, ok := m.GetColumnVal().(*ColumnResponse_Uint64ArrayVal); ok { + return x.Uint64ArrayVal + } + return nil +} + +func (m *ColumnResponse) GetStringArrayVal() *StringArray { + if x, ok := m.GetColumnVal().(*ColumnResponse_StringArrayVal); ok { + return x.StringArrayVal + } + return nil +} + +func (m *ColumnResponse) GetFloat64Val() float64 { + if x, ok := m.GetColumnVal().(*ColumnResponse_Float64Val); ok { + return x.Float64Val + } + return 0 +} + +func (m *ColumnResponse) GetDecimalVal() *Decimal { + if x, ok := m.GetColumnVal().(*ColumnResponse_DecimalVal); ok { + return x.DecimalVal + } + return nil +} + +// XXX_OneofWrappers is for the internal use of the proto package. +func (*ColumnResponse) XXX_OneofWrappers() []interface{} { + return []interface{}{ + (*ColumnResponse_StringVal)(nil), + (*ColumnResponse_Uint64Val)(nil), + (*ColumnResponse_Int64Val)(nil), + (*ColumnResponse_BoolVal)(nil), + (*ColumnResponse_BlobVal)(nil), + (*ColumnResponse_Uint64ArrayVal)(nil), + (*ColumnResponse_StringArrayVal)(nil), + (*ColumnResponse_Float64Val)(nil), + (*ColumnResponse_DecimalVal)(nil), + } +} + +type Decimal struct { + Value int64 `protobuf:"varint,1,opt,name=value,proto3" json:"value,omitempty"` + Scale int64 `protobuf:"varint,2,opt,name=scale,proto3" json:"scale,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *Decimal) Reset() { *m = Decimal{} } +func (m *Decimal) String() string { return proto.CompactTextString(m) } +func (*Decimal) ProtoMessage() {} +func (*Decimal) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{18} +} + +func (m *Decimal) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_Decimal.Unmarshal(m, b) +} +func (m *Decimal) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_Decimal.Marshal(b, m, deterministic) +} +func (m *Decimal) XXX_Merge(src proto.Message) { + xxx_messageInfo_Decimal.Merge(m, src) +} +func (m *Decimal) XXX_Size() int { + return xxx_messageInfo_Decimal.Size(m) +} +func (m *Decimal) XXX_DiscardUnknown() { + xxx_messageInfo_Decimal.DiscardUnknown(m) +} + +var xxx_messageInfo_Decimal proto.InternalMessageInfo + +func (m *Decimal) GetValue() int64 { + if m != nil { + return m.Value + } + return 0 +} + +func (m *Decimal) GetScale() int64 { + if m != nil { + return m.Scale + } + return 0 +} + +type InspectRequest struct { + Vds string `protobuf:"bytes,1,opt,name=vds,proto3" json:"vds,omitempty"` + Records *IdsOrKeys `protobuf:"bytes,2,opt,name=records,proto3" json:"records,omitempty"` + FilterFields []string `protobuf:"bytes,3,rep,name=filterFields,proto3" json:"filterFields,omitempty"` + Limit uint64 `protobuf:"varint,4,opt,name=limit,proto3" json:"limit,omitempty"` + Offset uint64 `protobuf:"varint,5,opt,name=offset,proto3" json:"offset,omitempty"` + Query string `protobuf:"bytes,6,opt,name=query,proto3" json:"query,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *InspectRequest) Reset() { *m = InspectRequest{} } +func (m *InspectRequest) String() string { return proto.CompactTextString(m) } +func (*InspectRequest) ProtoMessage() {} +func (*InspectRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{19} +} + +func (m *InspectRequest) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_InspectRequest.Unmarshal(m, b) +} +func (m *InspectRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_InspectRequest.Marshal(b, m, deterministic) +} +func (m *InspectRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_InspectRequest.Merge(m, src) +} +func (m *InspectRequest) XXX_Size() int { + return xxx_messageInfo_InspectRequest.Size(m) +} +func (m *InspectRequest) XXX_DiscardUnknown() { + xxx_messageInfo_InspectRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_InspectRequest proto.InternalMessageInfo + +func (m *InspectRequest) GetVds() string { + if m != nil { + return m.Vds + } + return "" +} + +func (m *InspectRequest) GetRecords() *IdsOrKeys { + if m != nil { + return m.Records + } + return nil +} + +func (m *InspectRequest) GetFilterFields() []string { + if m != nil { + return m.FilterFields + } + return nil +} + +func (m *InspectRequest) GetLimit() uint64 { + if m != nil { + return m.Limit + } + return 0 +} + +func (m *InspectRequest) GetOffset() uint64 { + if m != nil { + return m.Offset + } + return 0 +} + +func (m *InspectRequest) GetQuery() string { + if m != nil { + return m.Query + } + return "" +} + +type Uint64Array struct { + Vals []uint64 `protobuf:"varint,1,rep,packed,name=vals,proto3" json:"vals,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *Uint64Array) Reset() { *m = Uint64Array{} } +func (m *Uint64Array) String() string { return proto.CompactTextString(m) } +func (*Uint64Array) ProtoMessage() {} +func (*Uint64Array) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{20} +} + +func (m *Uint64Array) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_Uint64Array.Unmarshal(m, b) +} +func (m *Uint64Array) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_Uint64Array.Marshal(b, m, deterministic) +} +func (m *Uint64Array) XXX_Merge(src proto.Message) { + xxx_messageInfo_Uint64Array.Merge(m, src) +} +func (m *Uint64Array) XXX_Size() int { + return xxx_messageInfo_Uint64Array.Size(m) +} +func (m *Uint64Array) XXX_DiscardUnknown() { + xxx_messageInfo_Uint64Array.DiscardUnknown(m) +} + +var xxx_messageInfo_Uint64Array proto.InternalMessageInfo + +func (m *Uint64Array) GetVals() []uint64 { + if m != nil { + return m.Vals + } + return nil +} + +type StringArray struct { + Vals []string `protobuf:"bytes,1,rep,name=vals,proto3" json:"vals,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *StringArray) Reset() { *m = StringArray{} } +func (m *StringArray) String() string { return proto.CompactTextString(m) } +func (*StringArray) ProtoMessage() {} +func (*StringArray) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{21} +} + +func (m *StringArray) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_StringArray.Unmarshal(m, b) +} +func (m *StringArray) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_StringArray.Marshal(b, m, deterministic) +} +func (m *StringArray) XXX_Merge(src proto.Message) { + xxx_messageInfo_StringArray.Merge(m, src) +} +func (m *StringArray) XXX_Size() int { + return xxx_messageInfo_StringArray.Size(m) +} +func (m *StringArray) XXX_DiscardUnknown() { + xxx_messageInfo_StringArray.DiscardUnknown(m) +} + +var xxx_messageInfo_StringArray proto.InternalMessageInfo + +func (m *StringArray) GetVals() []string { + if m != nil { + return m.Vals + } + return nil +} + +type IdsOrKeys struct { + // Types that are valid to be assigned to Type: + // *IdsOrKeys_Ids + // *IdsOrKeys_Keys + Type isIdsOrKeys_Type `protobuf_oneof:"type"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *IdsOrKeys) Reset() { *m = IdsOrKeys{} } +func (m *IdsOrKeys) String() string { return proto.CompactTextString(m) } +func (*IdsOrKeys) ProtoMessage() {} +func (*IdsOrKeys) Descriptor() ([]byte, []int) { + return fileDescriptor_3849c3e549495f50, []int{22} +} + +func (m *IdsOrKeys) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_IdsOrKeys.Unmarshal(m, b) +} +func (m *IdsOrKeys) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_IdsOrKeys.Marshal(b, m, deterministic) +} +func (m *IdsOrKeys) XXX_Merge(src proto.Message) { + xxx_messageInfo_IdsOrKeys.Merge(m, src) +} +func (m *IdsOrKeys) XXX_Size() int { + return xxx_messageInfo_IdsOrKeys.Size(m) +} +func (m *IdsOrKeys) XXX_DiscardUnknown() { + xxx_messageInfo_IdsOrKeys.DiscardUnknown(m) +} + +var xxx_messageInfo_IdsOrKeys proto.InternalMessageInfo + +type isIdsOrKeys_Type interface { + isIdsOrKeys_Type() +} + +type IdsOrKeys_Ids struct { + Ids *Uint64Array `protobuf:"bytes,1,opt,name=ids,proto3,oneof"` +} + +type IdsOrKeys_Keys struct { + Keys *StringArray `protobuf:"bytes,2,opt,name=keys,proto3,oneof"` +} + +func (*IdsOrKeys_Ids) isIdsOrKeys_Type() {} + +func (*IdsOrKeys_Keys) isIdsOrKeys_Type() {} + +func (m *IdsOrKeys) GetType() isIdsOrKeys_Type { + if m != nil { + return m.Type + } + return nil +} + +func (m *IdsOrKeys) GetIds() *Uint64Array { + if x, ok := m.GetType().(*IdsOrKeys_Ids); ok { + return x.Ids + } + return nil +} + +func (m *IdsOrKeys) GetKeys() *StringArray { + if x, ok := m.GetType().(*IdsOrKeys_Keys); ok { + return x.Keys + } + return nil +} + +// XXX_OneofWrappers is for the internal use of the proto package. +func (*IdsOrKeys) XXX_OneofWrappers() []interface{} { + return []interface{}{ + (*IdsOrKeys_Ids)(nil), + (*IdsOrKeys_Keys)(nil), + } +} + +func init() { + proto.RegisterType((*DataSource)(nil), "vdsm.DataSource") + proto.RegisterMapType((map[string]string)(nil), "vdsm.DataSource.ConfigEntry") + proto.RegisterType((*VDS)(nil), "vdsm.VDS") + proto.RegisterType((*GetVDSsRequest)(nil), "vdsm.GetVDSsRequest") + proto.RegisterType((*GetVDSsResponse)(nil), "vdsm.GetVDSsResponse") + proto.RegisterType((*GetVDSRequest)(nil), "vdsm.GetVDSRequest") + proto.RegisterType((*GetVDSResponse)(nil), "vdsm.GetVDSResponse") + proto.RegisterType((*PostVDSRequest)(nil), "vdsm.PostVDSRequest") + proto.RegisterType((*PostVDSResponse)(nil), "vdsm.PostVDSResponse") + proto.RegisterType((*DeleteVDSRequest)(nil), "vdsm.DeleteVDSRequest") + proto.RegisterType((*DeleteVDSResponse)(nil), "vdsm.DeleteVDSResponse") + proto.RegisterType((*QueryPQLRequest)(nil), "vdsm.QueryPQLRequest") + proto.RegisterType((*QuerySQLRequest)(nil), "vdsm.QuerySQLRequest") + proto.RegisterType((*StatusError)(nil), "vdsm.StatusError") + proto.RegisterType((*RowResponse)(nil), "vdsm.RowResponse") + proto.RegisterType((*Row)(nil), "vdsm.Row") + proto.RegisterType((*TableResponse)(nil), "vdsm.TableResponse") + proto.RegisterType((*ColumnInfo)(nil), "vdsm.ColumnInfo") + proto.RegisterType((*ColumnResponse)(nil), "vdsm.ColumnResponse") + proto.RegisterType((*Decimal)(nil), "vdsm.Decimal") + proto.RegisterType((*InspectRequest)(nil), "vdsm.InspectRequest") + proto.RegisterType((*Uint64Array)(nil), "vdsm.Uint64Array") + proto.RegisterType((*StringArray)(nil), "vdsm.StringArray") + proto.RegisterType((*IdsOrKeys)(nil), "vdsm.IdsOrKeys") +} + +func init() { proto.RegisterFile("vdsm/vdsm.proto", fileDescriptor_3849c3e549495f50) } + +var fileDescriptor_3849c3e549495f50 = []byte{ + // 1065 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x56, 0xdd, 0x6e, 0x1b, 0x45, + 0x14, 0xf6, 0x66, 0x1d, 0xdb, 0x7b, 0x36, 0x71, 0x9c, 0x69, 0x28, 0x96, 0x69, 0x2b, 0x77, 0x10, + 0xc2, 0x20, 0x91, 0x46, 0x49, 0x53, 0x05, 0x0a, 0x48, 0x24, 0x69, 0x71, 0x04, 0xa5, 0xee, 0x98, + 0xe6, 0x82, 0x1b, 0x34, 0xf1, 0x8e, 0xc3, 0xaa, 0xe3, 0x1d, 0x7b, 0x67, 0x9d, 0xe0, 0x3b, 0x9e, + 0x04, 0x24, 0xde, 0x81, 0xe7, 0xe2, 0x15, 0xd0, 0xfc, 0xad, 0x77, 0x4d, 0x22, 0x2a, 0x7a, 0x63, + 0xed, 0x7c, 0xe7, 0x3b, 0x7f, 0x73, 0xce, 0x9c, 0x63, 0xd8, 0xba, 0x8a, 0xe4, 0xe4, 0x91, 0xfa, + 0xd9, 0x9d, 0xa6, 0x22, 0x13, 0xa8, 0xaa, 0xbe, 0x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d3, 0xc5, 0x6d, 0xea, 0xf6, 0x22, 0x4a, 0x43, 0xb1, 0xe0, 0x78, 0xb0, 0xe2, 0x78, + 0xf0, 0xd6, 0x8e, 0x07, 0x37, 0x39, 0x1e, 0xfc, 0xa7, 0xe3, 0x27, 0x50, 0xb7, 0x6f, 0xc9, 0xdd, + 0x75, 0xf9, 0x69, 0xdd, 0xe2, 0xf6, 0xa2, 0xa6, 0xff, 0x69, 0x1e, 0xfc, 0x13, 0x00, 0x00, 0xff, + 0xff, 0xa0, 0xf1, 0x1f, 0xe4, 0x7c, 0x0a, 0x00, 0x00, +} + +// Reference imports to suppress errors if they are not otherwise used. +var _ context.Context +var _ grpc.ClientConn + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +const _ = grpc.SupportPackageIsVersion4 + +// MoleculaClient is the client API for Molecula service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. +type MoleculaClient interface { + GetVDSs(ctx context.Context, in *GetVDSsRequest, opts ...grpc.CallOption) (*GetVDSsResponse, error) + GetVDS(ctx context.Context, in *GetVDSRequest, opts ...grpc.CallOption) (*GetVDSResponse, error) + PostVDS(ctx context.Context, in *PostVDSRequest, opts ...grpc.CallOption) (*PostVDSResponse, error) + DeleteVDS(ctx context.Context, in *DeleteVDSRequest, opts ...grpc.CallOption) (*DeleteVDSResponse, error) + QuerySQL(ctx context.Context, in *QuerySQLRequest, opts ...grpc.CallOption) (Molecula_QuerySQLClient, error) + QuerySQLUnary(ctx context.Context, in *QuerySQLRequest, opts ...grpc.CallOption) (*TableResponse, error) + QueryPQL(ctx context.Context, in *QueryPQLRequest, opts ...grpc.CallOption) (Molecula_QueryPQLClient, error) + QueryPQLUnary(ctx context.Context, in *QueryPQLRequest, opts ...grpc.CallOption) (*TableResponse, error) + Inspect(ctx context.Context, in *InspectRequest, opts ...grpc.CallOption) (Molecula_InspectClient, error) +} + +type moleculaClient struct { + cc *grpc.ClientConn +} + +func NewMoleculaClient(cc *grpc.ClientConn) MoleculaClient { + return &moleculaClient{cc} +} + +func (c *moleculaClient) GetVDSs(ctx context.Context, in *GetVDSsRequest, opts ...grpc.CallOption) (*GetVDSsResponse, error) { + out := new(GetVDSsResponse) + err := c.cc.Invoke(ctx, "/vdsm.Molecula/GetVDSs", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *moleculaClient) GetVDS(ctx context.Context, in *GetVDSRequest, opts ...grpc.CallOption) (*GetVDSResponse, error) { + out := new(GetVDSResponse) + err := c.cc.Invoke(ctx, "/vdsm.Molecula/GetVDS", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *moleculaClient) PostVDS(ctx context.Context, in *PostVDSRequest, opts ...grpc.CallOption) (*PostVDSResponse, error) { + out := new(PostVDSResponse) + err := c.cc.Invoke(ctx, "/vdsm.Molecula/PostVDS", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *moleculaClient) DeleteVDS(ctx context.Context, in *DeleteVDSRequest, opts ...grpc.CallOption) (*DeleteVDSResponse, error) { + out := new(DeleteVDSResponse) + err := c.cc.Invoke(ctx, "/vdsm.Molecula/DeleteVDS", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *moleculaClient) QuerySQL(ctx context.Context, in *QuerySQLRequest, opts ...grpc.CallOption) (Molecula_QuerySQLClient, error) { + stream, err := c.cc.NewStream(ctx, &_Molecula_serviceDesc.Streams[0], "/vdsm.Molecula/QuerySQL", opts...) + if err != nil { + return nil, err + } + x := &moleculaQuerySQLClient{stream} + if err := x.ClientStream.SendMsg(in); err != nil { + return nil, err + } + if err := x.ClientStream.CloseSend(); err != nil { + return nil, err + } + return x, nil +} + +type Molecula_QuerySQLClient interface { + Recv() (*RowResponse, error) + grpc.ClientStream +} + +type moleculaQuerySQLClient struct { + grpc.ClientStream +} + +func (x *moleculaQuerySQLClient) Recv() (*RowResponse, error) { + m := new(RowResponse) + if err := x.ClientStream.RecvMsg(m); err != nil { + return nil, err + } + return m, nil +} + +func (c *moleculaClient) QuerySQLUnary(ctx context.Context, in *QuerySQLRequest, opts ...grpc.CallOption) (*TableResponse, error) { + out := new(TableResponse) + err := c.cc.Invoke(ctx, "/vdsm.Molecula/QuerySQLUnary", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *moleculaClient) QueryPQL(ctx context.Context, in *QueryPQLRequest, opts ...grpc.CallOption) (Molecula_QueryPQLClient, error) { + stream, err := c.cc.NewStream(ctx, &_Molecula_serviceDesc.Streams[1], "/vdsm.Molecula/QueryPQL", opts...) + if err != nil { + return nil, err + } + x := &moleculaQueryPQLClient{stream} + if err := x.ClientStream.SendMsg(in); err != nil { + return nil, err + } + if err := x.ClientStream.CloseSend(); err != nil { + return nil, err + } + return x, nil +} + +type Molecula_QueryPQLClient interface { + Recv() (*RowResponse, error) + grpc.ClientStream +} + +type moleculaQueryPQLClient struct { + grpc.ClientStream +} + +func (x *moleculaQueryPQLClient) Recv() (*RowResponse, error) { + m := new(RowResponse) + if err := x.ClientStream.RecvMsg(m); err != nil { + return nil, err + } + return m, nil +} + +func (c *moleculaClient) QueryPQLUnary(ctx context.Context, in *QueryPQLRequest, opts ...grpc.CallOption) (*TableResponse, error) { + out := new(TableResponse) + err := c.cc.Invoke(ctx, "/vdsm.Molecula/QueryPQLUnary", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *moleculaClient) Inspect(ctx context.Context, in *InspectRequest, opts ...grpc.CallOption) (Molecula_InspectClient, error) { + stream, err := c.cc.NewStream(ctx, &_Molecula_serviceDesc.Streams[2], "/vdsm.Molecula/Inspect", opts...) + if err != nil { + return nil, err + } + x := &moleculaInspectClient{stream} + if err := x.ClientStream.SendMsg(in); err != nil { + return nil, err + } + if err := x.ClientStream.CloseSend(); err != nil { + return nil, err + } + return x, nil +} + +type Molecula_InspectClient interface { + Recv() (*RowResponse, error) + grpc.ClientStream +} + +type moleculaInspectClient struct { + grpc.ClientStream +} + +func (x *moleculaInspectClient) Recv() (*RowResponse, error) { + m := new(RowResponse) + if err := x.ClientStream.RecvMsg(m); err != nil { + return nil, err + } + return m, nil +} + +// MoleculaServer is the server API for Molecula service. +type MoleculaServer interface { + GetVDSs(context.Context, *GetVDSsRequest) (*GetVDSsResponse, error) + GetVDS(context.Context, *GetVDSRequest) (*GetVDSResponse, error) + PostVDS(context.Context, *PostVDSRequest) (*PostVDSResponse, error) + DeleteVDS(context.Context, *DeleteVDSRequest) (*DeleteVDSResponse, error) + QuerySQL(*QuerySQLRequest, Molecula_QuerySQLServer) error + QuerySQLUnary(context.Context, *QuerySQLRequest) (*TableResponse, error) + QueryPQL(*QueryPQLRequest, Molecula_QueryPQLServer) error + QueryPQLUnary(context.Context, *QueryPQLRequest) (*TableResponse, error) + Inspect(*InspectRequest, Molecula_InspectServer) error +} + +// UnimplementedMoleculaServer can be embedded to have forward compatible implementations. +type UnimplementedMoleculaServer struct { +} + +func (*UnimplementedMoleculaServer) GetVDSs(ctx context.Context, req *GetVDSsRequest) (*GetVDSsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetVDSs not implemented") +} +func (*UnimplementedMoleculaServer) GetVDS(ctx context.Context, req *GetVDSRequest) (*GetVDSResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetVDS not implemented") +} +func (*UnimplementedMoleculaServer) PostVDS(ctx context.Context, req *PostVDSRequest) (*PostVDSResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method PostVDS not implemented") +} +func (*UnimplementedMoleculaServer) DeleteVDS(ctx context.Context, req *DeleteVDSRequest) (*DeleteVDSResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method DeleteVDS not implemented") +} +func (*UnimplementedMoleculaServer) QuerySQL(req *QuerySQLRequest, srv Molecula_QuerySQLServer) error { + return status.Errorf(codes.Unimplemented, "method QuerySQL not implemented") +} +func (*UnimplementedMoleculaServer) QuerySQLUnary(ctx context.Context, req *QuerySQLRequest) (*TableResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method QuerySQLUnary not implemented") +} +func (*UnimplementedMoleculaServer) QueryPQL(req *QueryPQLRequest, srv Molecula_QueryPQLServer) error { + return status.Errorf(codes.Unimplemented, "method QueryPQL not implemented") +} +func (*UnimplementedMoleculaServer) QueryPQLUnary(ctx context.Context, req *QueryPQLRequest) (*TableResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method QueryPQLUnary not implemented") +} +func (*UnimplementedMoleculaServer) Inspect(req *InspectRequest, srv Molecula_InspectServer) error { + return status.Errorf(codes.Unimplemented, "method Inspect not implemented") +} + +func RegisterMoleculaServer(s *grpc.Server, srv MoleculaServer) { + s.RegisterService(&_Molecula_serviceDesc, srv) +} + +func _Molecula_GetVDSs_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(GetVDSsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MoleculaServer).GetVDSs(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/vdsm.Molecula/GetVDSs", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MoleculaServer).GetVDSs(ctx, req.(*GetVDSsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Molecula_GetVDS_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(GetVDSRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MoleculaServer).GetVDS(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/vdsm.Molecula/GetVDS", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MoleculaServer).GetVDS(ctx, req.(*GetVDSRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Molecula_PostVDS_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(PostVDSRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MoleculaServer).PostVDS(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/vdsm.Molecula/PostVDS", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MoleculaServer).PostVDS(ctx, req.(*PostVDSRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Molecula_DeleteVDS_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(DeleteVDSRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MoleculaServer).DeleteVDS(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/vdsm.Molecula/DeleteVDS", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MoleculaServer).DeleteVDS(ctx, req.(*DeleteVDSRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Molecula_QuerySQL_Handler(srv interface{}, stream grpc.ServerStream) error { + m := new(QuerySQLRequest) + if err := stream.RecvMsg(m); err != nil { + return err + } + return srv.(MoleculaServer).QuerySQL(m, &moleculaQuerySQLServer{stream}) +} + +type Molecula_QuerySQLServer interface { + Send(*RowResponse) error + grpc.ServerStream +} + +type moleculaQuerySQLServer struct { + grpc.ServerStream +} + +func (x *moleculaQuerySQLServer) Send(m *RowResponse) error { + return x.ServerStream.SendMsg(m) +} + +func _Molecula_QuerySQLUnary_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QuerySQLRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MoleculaServer).QuerySQLUnary(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/vdsm.Molecula/QuerySQLUnary", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MoleculaServer).QuerySQLUnary(ctx, req.(*QuerySQLRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Molecula_QueryPQL_Handler(srv interface{}, stream grpc.ServerStream) error { + m := new(QueryPQLRequest) + if err := stream.RecvMsg(m); err != nil { + return err + } + return srv.(MoleculaServer).QueryPQL(m, &moleculaQueryPQLServer{stream}) +} + +type Molecula_QueryPQLServer interface { + Send(*RowResponse) error + grpc.ServerStream +} + +type moleculaQueryPQLServer struct { + grpc.ServerStream +} + +func (x *moleculaQueryPQLServer) Send(m *RowResponse) error { + return x.ServerStream.SendMsg(m) +} + +func _Molecula_QueryPQLUnary_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(QueryPQLRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MoleculaServer).QueryPQLUnary(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/vdsm.Molecula/QueryPQLUnary", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MoleculaServer).QueryPQLUnary(ctx, req.(*QueryPQLRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _Molecula_Inspect_Handler(srv interface{}, stream grpc.ServerStream) error { + m := new(InspectRequest) + if err := stream.RecvMsg(m); err != nil { + return err + } + return srv.(MoleculaServer).Inspect(m, &moleculaInspectServer{stream}) +} + +type Molecula_InspectServer interface { + Send(*RowResponse) error + grpc.ServerStream +} + +type moleculaInspectServer struct { + grpc.ServerStream +} + +func (x *moleculaInspectServer) Send(m *RowResponse) error { + return x.ServerStream.SendMsg(m) +} + +var _Molecula_serviceDesc = grpc.ServiceDesc{ + ServiceName: "vdsm.Molecula", + HandlerType: (*MoleculaServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "GetVDSs", + Handler: _Molecula_GetVDSs_Handler, + }, + { + MethodName: "GetVDS", + Handler: _Molecula_GetVDS_Handler, + }, + { + MethodName: "PostVDS", + Handler: _Molecula_PostVDS_Handler, + }, + { + MethodName: "DeleteVDS", + Handler: _Molecula_DeleteVDS_Handler, + }, + { + MethodName: "QuerySQLUnary", + Handler: _Molecula_QuerySQLUnary_Handler, + }, + { + MethodName: "QueryPQLUnary", + Handler: _Molecula_QueryPQLUnary_Handler, + }, + }, + Streams: []grpc.StreamDesc{ + { + StreamName: "QuerySQL", + Handler: _Molecula_QuerySQL_Handler, + ServerStreams: true, + }, + { + StreamName: "QueryPQL", + Handler: _Molecula_QueryPQL_Handler, + ServerStreams: true, + }, + { + StreamName: "Inspect", + Handler: _Molecula_Inspect_Handler, + ServerStreams: true, + }, + }, + Metadata: "vdsm/vdsm.proto", +} diff --git a/proto/vdsm/vdsm.proto b/proto/vdsm/vdsm.proto new file mode 100644 index 000000000..2798b2cc5 --- /dev/null +++ b/proto/vdsm/vdsm.proto @@ -0,0 +1,146 @@ +syntax = "proto3"; +package vdsm; + +// deprecated +message DataSource { + int64 id = 1; + string name = 2; + string description = 3; + string type = 4; + map config = 5; + string status = 6; +} + +message VDS { + string id = 1; + string name = 2; + string description = 3; + string pilosa_index = 4; + repeated DataSource datasources = 5; +} + +message GetVDSsRequest { +} + +message GetVDSsResponse { + repeated VDS vdss = 1; +} + +message GetVDSRequest { + oneof idOrName { + string id = 1; + string name = 2; + } +} + +message GetVDSResponse { + VDS vds = 1; +} + +message PostVDSRequest { + string definition = 1; +} + +message PostVDSResponse { + string id = 1; + string uri = 2; +} + +message DeleteVDSRequest { + oneof idOrName { + string id = 1; + string name = 2; + } +} + +message DeleteVDSResponse { +} + +message QueryPQLRequest { + string vds = 1; + string pql = 2; +} + +message QuerySQLRequest { + string sql = 1; +} + +message StatusError{ + uint32 Code = 1; + string Message = 2; +} + +message RowResponse{ + repeated ColumnInfo headers = 1; + repeated ColumnResponse columns = 2; + StatusError StatusError = 3; +} + +message Row { + repeated ColumnResponse columns = 1; +} + +message TableResponse{ + repeated ColumnInfo headers = 1; + repeated Row rows = 2; +} + +message ColumnInfo { + string name = 1; + string datatype = 2; +} + +message ColumnResponse{ + oneof columnVal { + string stringVal = 1; + uint64 uint64Val = 2; + int64 int64Val = 3; + bool boolVal = 4; + bytes blobVal = 5; + Uint64Array uint64ArrayVal = 6; + StringArray stringArrayVal = 7; + double float64Val = 8; + Decimal decimalVal = 9; + } +} + +message Decimal { + int64 value = 1; + int64 scale = 2; +} + +message InspectRequest { + string vds = 1; + IdsOrKeys records = 2; + repeated string filterFields = 3; + uint64 limit = 4; + uint64 offset = 5; + string query = 6; +} + +message Uint64Array { + repeated uint64 vals = 1; +} + +message StringArray { + repeated string vals = 1; +} + +message IdsOrKeys { + oneof type { + Uint64Array ids = 1; + StringArray keys = 2; + } +} + +service Molecula { + rpc GetVDSs(GetVDSsRequest) returns (GetVDSsResponse) {}; + rpc GetVDS(GetVDSRequest) returns (GetVDSResponse) {}; + rpc PostVDS(PostVDSRequest) returns (PostVDSResponse) {}; + rpc DeleteVDS(DeleteVDSRequest) returns (DeleteVDSResponse) {}; + rpc QuerySQL(QuerySQLRequest) returns (stream RowResponse) {}; + rpc QuerySQLUnary(QuerySQLRequest) returns (TableResponse) {}; + rpc QueryPQL(QueryPQLRequest) returns (stream RowResponse) {}; + rpc QueryPQLUnary(QueryPQLRequest) returns (TableResponse) {}; + rpc Inspect(InspectRequest) returns (stream RowResponse) {}; +} diff --git a/server/grpc.go b/server/grpc.go index ec99f0685..a84e059f9 100644 --- a/server/grpc.go +++ b/server/grpc.go @@ -26,6 +26,7 @@ import ( "github.com/pilosa/pilosa/v2" "github.com/pilosa/pilosa/v2/logger" pb "github.com/pilosa/pilosa/v2/proto" + vdsm_pb "github.com/pilosa/pilosa/v2/proto/vdsm" "github.com/pilosa/pilosa/v2/stats" "github.com/pkg/errors" "google.golang.org/grpc" @@ -125,48 +126,6 @@ func errToStatusError(err error) error { return status.Error(codes.Unknown, err.Error()) } -// GetVDSs returns a single VDS given a name -func (h *GRPCHandler) GetVDS(ctx context.Context, req *pb.GetVDSRequest) (*pb.GetVDSResponse, error) { - // TODO: Return all schema information associated with the VDS. - // It's obviously not very useful to return the same data as given. - schema := h.api.Schema(ctx) - for _, index := range schema { - if req.Name == index.Name { - return &pb.GetVDSResponse{Vds: &pb.VDS{Name: index.Name}}, nil - } - } - return nil, status.Error(codes.NotFound, fmt.Sprintf("VDS with name %s not found", req.Name)) -} - -// GetVDSs returns a list of all VDSs -func (h *GRPCHandler) GetVDSs(ctx context.Context, req *pb.GetVDSsRequest) (*pb.GetVDSsResponse, error) { - schema := h.api.Schema(ctx) - vdss := make([]*pb.VDS, len(schema)) - for i, index := range schema { - vdss[i] = &pb.VDS{Name: index.Name} - } - return &pb.GetVDSsResponse{Vdss: vdss}, nil -} - -// PostVDS creates a new VDS -func (h *GRPCHandler) PostVDS(ctx context.Context, req *pb.PostVDSRequest) (*pb.PostVDSResponse, error) { - opts := pilosa.IndexOptions{Keys: req.Keys, TrackExistence: req.TrackExistence} - _, err := h.api.CreateIndex(ctx, req.Name, opts) - if err != nil { - return nil, errToStatusError(err) - } - return &pb.PostVDSResponse{}, nil -} - -// DeleteVDS deletes a VDS -func (h *GRPCHandler) DeleteVDS(ctx context.Context, req *pb.DeleteVDSRequest) (*pb.DeleteVDSResponse, error) { - err := h.api.DeleteIndex(ctx, req.Name) - if err != nil { - return nil, errToStatusError(err) - } - return &pb.DeleteVDSResponse{}, nil -} - func (h *GRPCHandler) execSQL(ctx context.Context, queryStr string) (pb.ToRowser, error) { h.stats.Count(pilosa.MetricSqlQueries, 1, 1) return execSQL(ctx, h.api, h.logger, queryStr) @@ -292,6 +251,94 @@ func (h *GRPCHandler) QueryPQLUnary(ctx context.Context, req *pb.QueryPQLRequest return table, errToStatusError(nil) } +// VDSMGRPCHandler contains methods which handle the various gRPC requests, ported from VDSM. +type VDSMGRPCHandler struct { + api *pilosa.API + logger logger.Logger + stats stats.StatsClient +} + +func NewVDSMGRPCHandler(api *pilosa.API) *VDSMGRPCHandler { + return &VDSMGRPCHandler{api: api, logger: logger.NopLogger, stats: stats.NopStatsClient} +} + +func (h *VDSMGRPCHandler) WithLogger(logger logger.Logger) *VDSMGRPCHandler { + h.logger = logger + return h +} + +func (h *VDSMGRPCHandler) WithStats(stats stats.StatsClient) *VDSMGRPCHandler { + h.stats = stats + return h +} + +// GetVDSs returns a single VDS given a name +func (h *VDSMGRPCHandler) GetVDS(ctx context.Context, req *vdsm_pb.GetVDSRequest) (*vdsm_pb.GetVDSResponse, error) { + typedIdOrName := req.GetIdOrName() + switch idOrName := typedIdOrName.(type) { + case *vdsm_pb.GetVDSRequest_Id: + return nil, status.Error(codes.InvalidArgument, "VDS IDs are no longer supported") + case *vdsm_pb.GetVDSRequest_Name: + schema := h.api.Schema(ctx) + for _, index := range schema { + if idOrName.Name == index.Name { + return &vdsm_pb.GetVDSResponse{Vds: &vdsm_pb.VDS{Name: index.Name}}, nil + } + } + return nil, status.Error(codes.NotFound, fmt.Sprintf("VDS with name %s not found", idOrName.Name)) + default: + return nil, status.Error(codes.NotFound, "VDS not found") + } +} + +// GetVDSs returns a list of all VDSs +func (h *VDSMGRPCHandler) GetVDSs(ctx context.Context, req *vdsm_pb.GetVDSsRequest) (*vdsm_pb.GetVDSsResponse, error) { + schema := h.api.Schema(ctx) + vdss := make([]*vdsm_pb.VDS, len(schema)) + for i, index := range schema { + vdss[i] = &vdsm_pb.VDS{Name: index.Name} + } + return &vdsm_pb.GetVDSsResponse{Vdss: vdss}, nil +} + +// PostVDS creates a new VDS +func (*VDSMGRPCHandler) PostVDS(ctx context.Context, req *vdsm_pb.PostVDSRequest) (*vdsm_pb.PostVDSResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method PostVDS not implemented") +} + +// DeleteVDS deletes a VDS +func (h *VDSMGRPCHandler) DeleteVDS(ctx context.Context, req *vdsm_pb.DeleteVDSRequest) (*vdsm_pb.DeleteVDSResponse, error) { + typedIdOrName := req.GetIdOrName() + switch idOrName := typedIdOrName.(type) { + case *vdsm_pb.DeleteVDSRequest_Id: + return nil, status.Error(codes.InvalidArgument, "VDS IDs are no longer supported") + case *vdsm_pb.DeleteVDSRequest_Name: + err := h.api.DeleteIndex(ctx, idOrName.Name) + if err != nil { + return nil, errToStatusError(err) + } + return &vdsm_pb.DeleteVDSResponse{}, nil + default: + return nil, status.Error(codes.NotFound, "") + } +} + +func (*VDSMGRPCHandler) QuerySQL(req *vdsm_pb.QuerySQLRequest, srv vdsm_pb.Molecula_QuerySQLServer) error { + return status.Errorf(codes.Unimplemented, "method QuerySQL not implemented") +} +func (*VDSMGRPCHandler) QuerySQLUnary(ctx context.Context, req *vdsm_pb.QuerySQLRequest) (*vdsm_pb.TableResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method QuerySQLUnary not implemented") +} +func (*VDSMGRPCHandler) QueryPQL(req *vdsm_pb.QueryPQLRequest, srv vdsm_pb.Molecula_QueryPQLServer) error { + return status.Errorf(codes.Unimplemented, "method QueryPQL not implemented") +} +func (*VDSMGRPCHandler) QueryPQLUnary(ctx context.Context, req *vdsm_pb.QueryPQLRequest) (*vdsm_pb.TableResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method QueryPQLUnary not implemented") +} +func (*VDSMGRPCHandler) Inspect(req *vdsm_pb.InspectRequest, srv vdsm_pb.Molecula_InspectServer) error { + return status.Errorf(codes.Unimplemented, "method Inspect not implemented") +} + // ResultUint64 is a wrapper around a uint64 result type // so that we can implement the ToTabler and ToRowser // interfaces. @@ -1145,6 +1192,7 @@ func (s *grpcServer) Serve(tlsConfig *tls.Config) error { s.mu.Lock() s.grpcServer = grpc.NewServer(opts...) pb.RegisterPilosaServer(s.grpcServer, NewGRPCHandler(s.api).WithLogger(s.logger).WithStats(s.stats)) + vdsm_pb.RegisterMoleculaServer(s.grpcServer, NewVDSMGRPCHandler(s.api).WithLogger(s.logger).WithStats(s.stats)) // register the server so its services are available to grpc_cli and others reflection.Register(s.grpcServer) From 83704e7973f358a4ad942352f0b53e5c785a8e8c Mon Sep 17 00:00:00 2001 From: Cody Soyland Date: Thu, 17 Sep 2020 14:21:56 -0500 Subject: [PATCH 2/5] Proxy unary methods to Pilosa gRPC handler --- proto/vdsm/vdsm.pb.go | 151 ++++++++++++++++++++++-------------------- proto/vdsm/vdsm.proto | 3 +- server/grpc.go | 89 ++++++++++++++++++++++--- 3 files changed, 160 insertions(+), 83 deletions(-) diff --git a/proto/vdsm/vdsm.pb.go b/proto/vdsm/vdsm.pb.go index 2d4deaf42..edb45edde 100644 --- a/proto/vdsm/vdsm.pb.go +++ b/proto/vdsm/vdsm.pb.go @@ -562,7 +562,7 @@ func (m *DeleteVDSResponse) XXX_DiscardUnknown() { var xxx_messageInfo_DeleteVDSResponse proto.InternalMessageInfo type QueryPQLRequest struct { - Vds string `protobuf:"bytes,1,opt,name=vds,proto3" json:"vds,omitempty"` + Index string `protobuf:"bytes,1,opt,name=index,proto3" json:"index,omitempty"` Pql string `protobuf:"bytes,2,opt,name=pql,proto3" json:"pql,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` @@ -594,9 +594,9 @@ func (m *QueryPQLRequest) XXX_DiscardUnknown() { var xxx_messageInfo_QueryPQLRequest proto.InternalMessageInfo -func (m *QueryPQLRequest) GetVds() string { +func (m *QueryPQLRequest) GetIndex() string { if m != nil { - return m.Vds + return m.Index } return "" } @@ -791,6 +791,7 @@ func (m *Row) GetColumns() []*ColumnResponse { type TableResponse struct { Headers []*ColumnInfo `protobuf:"bytes,1,rep,name=headers,proto3" json:"headers,omitempty"` Rows []*Row `protobuf:"bytes,2,rep,name=rows,proto3" json:"rows,omitempty"` + StatusError *StatusError `protobuf:"bytes,3,opt,name=StatusError,proto3" json:"StatusError,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` @@ -835,6 +836,13 @@ func (m *TableResponse) GetRows() []*Row { return nil } +func (m *TableResponse) GetStatusError() *StatusError { + if m != nil { + return m.StatusError + } + return nil +} + type ColumnInfo struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Datatype string `protobuf:"bytes,2,opt,name=datatype,proto3" json:"datatype,omitempty"` @@ -1381,74 +1389,75 @@ func init() { func init() { proto.RegisterFile("vdsm/vdsm.proto", fileDescriptor_3849c3e549495f50) } var fileDescriptor_3849c3e549495f50 = []byte{ - // 1065 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x56, 0xdd, 0x6e, 0x1b, 0x45, - 0x14, 0xf6, 0x66, 0x1d, 0xdb, 0x7b, 0x36, 0x71, 0x9c, 0x69, 0x28, 0x96, 0x69, 0x2b, 0x77, 0x10, - 0xc2, 0x20, 0x91, 0x46, 0x49, 0x53, 0x05, 0x0a, 0x48, 0x24, 0x69, 0x71, 0x04, 0xa5, 0xee, 0x98, - 0xe6, 0x82, 0x1b, 0x34, 0xf1, 0x8e, 0xc3, 0xaa, 0xe3, 0x1d, 0x7b, 0x67, 0x9d, 0xe0, 0x3b, 0x9e, - 0x04, 0x24, 0xde, 0x81, 0xe7, 0xe2, 0x15, 0xd0, 0xfc, 0xad, 0x77, 0x4d, 0x22, 0x2a, 0x7a, 0x63, - 0xed, 0x7c, 0xe7, 0x3b, 0x7f, 0x73, 0xce, 0x9c, 0x63, 0xd8, 0xba, 0x8a, 0xe4, 0xe4, 0x91, 0xfa, - 0xd9, 0x9d, 0xa6, 0x22, 0x13, 0xa8, 0xaa, 0xbe, 0xf1, 0xdf, 0x1e, 0xc0, 0x29, 0xcd, 0xe8, 0x50, - 0xcc, 0xd3, 0x11, 0x43, 0x4d, 0x58, 0x8b, 0xa3, 0xb6, 0xd7, 0xf5, 0x7a, 0x3e, 0x59, 0x8b, 0x23, - 0x84, 0xa0, 0x9a, 0xd0, 0x09, 0x6b, 0xaf, 0x75, 0xbd, 0x5e, 0x40, 0xf4, 0x37, 0xea, 0x42, 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 0x69, 0x1e, 0xfc, 0x13, 0x00, 0x00, 0xff, - 0xff, 0xa0, 0xf1, 0x1f, 0xe4, 0x7c, 0x0a, 0x00, 0x00, + // 1081 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x56, 0xef, 0x6e, 0x1b, 0x45, + 0x10, 0xf7, 0xe5, 0x1c, 0xdb, 0x37, 0x97, 0x38, 0xce, 0x36, 0x14, 0xcb, 0xb4, 0x95, 0x7b, 0x08, + 0x61, 0x90, 0x48, 0xa3, 0xa4, 0xa9, 0x52, 0x0a, 0x48, 0x24, 0x69, 0x71, 0x04, 0xa5, 0xee, 0x9a, + 0xe6, 0x2b, 0xda, 0xf8, 0xd6, 0xe1, 0xd4, 0xf5, 0xad, 0x7d, 0x7b, 0x4e, 0xf0, 0x37, 0xde, 0x80, + 0x37, 0x00, 0x89, 0x77, 0xe0, 0xb9, 0x78, 0x05, 0xb4, 0xff, 0xce, 0x7b, 0x26, 0x15, 0x55, 0xfb, + 0xc5, 0xda, 0xfd, 0xcd, 0x6f, 0xfe, 0xed, 0xcc, 0xcd, 0x18, 0xb6, 0xae, 0x62, 0x31, 0x79, 0x20, + 0x7f, 0x76, 0xa7, 0x19, 0xcf, 0x39, 0xaa, 0xca, 0x73, 0xf4, 0x8f, 0x07, 0x70, 0x4a, 0x72, 0x32, + 0xe4, 0xf3, 0x6c, 0x44, 0x51, 0x13, 0xd6, 0x92, 0xb8, 0xed, 0x75, 0xbd, 0x9e, 0x8f, 0xd7, 0x92, + 0x18, 0x21, 0xa8, 0xa6, 0x64, 0x42, 0xdb, 0x6b, 0x5d, 0xaf, 0x17, 0x60, 0x75, 0x46, 0x5d, 0x08, + 0x63, 0x2a, 0x46, 0x59, 0x32, 0xcd, 0x13, 0x9e, 0xb6, 0x7d, 0x25, 0x72, 0x21, 0xa9, 0x95, 0x2f, + 0xa6, 0xb4, 0x5d, 0xd5, 0x5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 0xb6, 0x0a, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. diff --git a/proto/vdsm/vdsm.proto b/proto/vdsm/vdsm.proto index 2798b2cc5..34b13de70 100644 --- a/proto/vdsm/vdsm.proto +++ b/proto/vdsm/vdsm.proto @@ -57,7 +57,7 @@ message DeleteVDSResponse { } message QueryPQLRequest { - string vds = 1; + string index = 1; string pql = 2; } @@ -83,6 +83,7 @@ message Row { message TableResponse{ repeated ColumnInfo headers = 1; repeated Row rows = 2; + StatusError StatusError = 3; } message ColumnInfo { diff --git a/server/grpc.go b/server/grpc.go index a84e059f9..7dba6558e 100644 --- a/server/grpc.go +++ b/server/grpc.go @@ -253,13 +253,14 @@ func (h *GRPCHandler) QueryPQLUnary(ctx context.Context, req *pb.QueryPQLRequest // VDSMGRPCHandler contains methods which handle the various gRPC requests, ported from VDSM. type VDSMGRPCHandler struct { - api *pilosa.API - logger logger.Logger - stats stats.StatsClient + grpcHandler *GRPCHandler + api *pilosa.API + logger logger.Logger + stats stats.StatsClient } -func NewVDSMGRPCHandler(api *pilosa.API) *VDSMGRPCHandler { - return &VDSMGRPCHandler{api: api, logger: logger.NopLogger, stats: stats.NopStatsClient} +func NewVDSMGRPCHandler(grpcHandler *GRPCHandler, api *pilosa.API) *VDSMGRPCHandler { + return &VDSMGRPCHandler{grpcHandler: grpcHandler, api: api, logger: logger.NopLogger, stats: stats.NopStatsClient} } func (h *VDSMGRPCHandler) WithLogger(logger logger.Logger) *VDSMGRPCHandler { @@ -303,6 +304,7 @@ func (h *VDSMGRPCHandler) GetVDSs(ctx context.Context, req *vdsm_pb.GetVDSsReque // PostVDS creates a new VDS func (*VDSMGRPCHandler) PostVDS(ctx context.Context, req *vdsm_pb.PostVDSRequest) (*vdsm_pb.PostVDSResponse, error) { + // Pilosa doesn't implement VDSD files, so this is unimplemented return nil, status.Errorf(codes.Unimplemented, "method PostVDS not implemented") } @@ -326,15 +328,31 @@ func (h *VDSMGRPCHandler) DeleteVDS(ctx context.Context, req *vdsm_pb.DeleteVDSR func (*VDSMGRPCHandler) QuerySQL(req *vdsm_pb.QuerySQLRequest, srv vdsm_pb.Molecula_QuerySQLServer) error { return status.Errorf(codes.Unimplemented, "method QuerySQL not implemented") } -func (*VDSMGRPCHandler) QuerySQLUnary(ctx context.Context, req *vdsm_pb.QuerySQLRequest) (*vdsm_pb.TableResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method QuerySQLUnary not implemented") + +func (h *VDSMGRPCHandler) QuerySQLUnary(ctx context.Context, req *vdsm_pb.QuerySQLRequest) (*vdsm_pb.TableResponse, error) { + pReq := pb.QuerySQLRequest(*req) + resp, err := h.grpcHandler.QuerySQLUnary(ctx, &pReq) + if err != nil { + return nil, err + } + pResp, err := tableToTable(resp) + return pResp, err } + func (*VDSMGRPCHandler) QueryPQL(req *vdsm_pb.QueryPQLRequest, srv vdsm_pb.Molecula_QueryPQLServer) error { return status.Errorf(codes.Unimplemented, "method QueryPQL not implemented") } -func (*VDSMGRPCHandler) QueryPQLUnary(ctx context.Context, req *vdsm_pb.QueryPQLRequest) (*vdsm_pb.TableResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method QueryPQLUnary not implemented") + +func (h *VDSMGRPCHandler) QueryPQLUnary(ctx context.Context, req *vdsm_pb.QueryPQLRequest) (*vdsm_pb.TableResponse, error) { + pReq := pb.QueryPQLRequest(*req) + resp, err := h.grpcHandler.QueryPQLUnary(ctx, &pReq) + if err != nil { + return nil, err + } + pResp, err := tableToTable(resp) + return pResp, err } + func (*VDSMGRPCHandler) Inspect(req *vdsm_pb.InspectRequest, srv vdsm_pb.Molecula_InspectServer) error { return status.Errorf(codes.Unimplemented, "method Inspect not implemented") } @@ -1191,8 +1209,9 @@ func (s *grpcServer) Serve(tlsConfig *tls.Config) error { // create grpc server s.mu.Lock() s.grpcServer = grpc.NewServer(opts...) - pb.RegisterPilosaServer(s.grpcServer, NewGRPCHandler(s.api).WithLogger(s.logger).WithStats(s.stats)) - vdsm_pb.RegisterMoleculaServer(s.grpcServer, NewVDSMGRPCHandler(s.api).WithLogger(s.logger).WithStats(s.stats)) + grpcHandler := NewGRPCHandler(s.api).WithLogger(s.logger).WithStats(s.stats) + pb.RegisterPilosaServer(s.grpcServer, grpcHandler) + vdsm_pb.RegisterMoleculaServer(s.grpcServer, NewVDSMGRPCHandler(grpcHandler, s.api).WithLogger(s.logger).WithStats(s.stats)) // register the server so its services are available to grpc_cli and others reflection.Register(s.grpcServer) @@ -1227,3 +1246,51 @@ func NewGRPCServer(opts ...grpcServerOption) (*grpcServer, error) { } return server, nil } + +// tableToTable is a helper function used by QueryPQLUnary +// to convert a pb.TableResponse into a vdsm_pb.TableResponse. +func tableToTable(ptbl *pb.TableResponse) (*vdsm_pb.TableResponse, error) { + vtbl := &vdsm_pb.TableResponse{ + Headers: make([]*vdsm_pb.ColumnInfo, len(ptbl.Headers)), + Rows: make([]*vdsm_pb.Row, len(ptbl.Rows)), + } + + // Headers + for i, info := range ptbl.Headers { + vtbl.Headers[i] = &vdsm_pb.ColumnInfo{Name: info.Name, Datatype: info.Datatype} + } + + // Rows + for r := range ptbl.Rows { + columns := make([]*vdsm_pb.ColumnResponse, len(ptbl.Rows[r].Columns)) + for i, col := range ptbl.Rows[r].Columns { + switch v := col.GetColumnVal().(type) { + case *pb.ColumnResponse_StringVal: + columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_StringVal{StringVal: v.StringVal}} + case *pb.ColumnResponse_Uint64Val: + columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_Uint64Val{Uint64Val: v.Uint64Val}} + case *pb.ColumnResponse_Int64Val: + columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_Int64Val{Int64Val: v.Int64Val}} + case *pb.ColumnResponse_BoolVal: + columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_BoolVal{BoolVal: v.BoolVal}} + case *pb.ColumnResponse_BlobVal: + columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_BlobVal{BlobVal: v.BlobVal}} + case *pb.ColumnResponse_Uint64ArrayVal: + columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_Uint64ArrayVal{Uint64ArrayVal: &vdsm_pb.Uint64Array{Vals: v.Uint64ArrayVal.Vals}}} + case *pb.ColumnResponse_StringArrayVal: + columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_StringArrayVal{StringArrayVal: &vdsm_pb.StringArray{Vals: v.StringArrayVal.Vals}}} + case *pb.ColumnResponse_Float64Val: + columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_Float64Val{Float64Val: v.Float64Val}} + case *pb.ColumnResponse_DecimalVal: + columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_DecimalVal{DecimalVal: &vdsm_pb.Decimal{Value: v.DecimalVal.Value, Scale: v.DecimalVal.Scale}}} + case nil: + columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: nil} + default: + return nil, errors.Errorf("unhandled columnval type: %T", col.GetColumnVal()) + } + } + vtbl.Rows[r] = &vdsm_pb.Row{Columns: columns} + } + + return vtbl, nil +} From fdce92eb404cee2bd2283a93e066f9cd380c2551 Mon Sep 17 00:00:00 2001 From: Cody Soyland Date: Thu, 17 Sep 2020 16:27:48 -0500 Subject: [PATCH 3/5] Use shared types from pilosa proto file and enable generic proxying of query calls --- Makefile | 11 +- proto/interface.go | 2 +- proto/pilosa.pb.go | 96 ++-- proto/pilosa.proto | 2 + proto/vdsm/vdsm.pb.go | 1008 ++++------------------------------------- proto/vdsm/vdsm.proto | 92 +--- server/grpc.go | 126 +++--- 7 files changed, 211 insertions(+), 1126 deletions(-) diff --git a/Makefile b/Makefile index f6ca2fe1f..52d246c64 100644 --- a/Makefile +++ b/Makefile @@ -166,10 +166,14 @@ generate-stringer: generate-pql: require-peg cd pql && peg -inline pql.peg && cd .. -# dunno if protoc-gen-gofast is actually needed here -generate-proto-grpc: require-protoc require-protoc-gen-gofast +generate-proto-grpc: require-protoc require-protoc-gen-go protoc -I proto proto/pilosa.proto --go_out=plugins=grpc:proto protoc -I proto proto/vdsm/vdsm.proto --go_out=plugins=grpc:proto + # TODO: Modify above commands and remove the below mv if possible. + # See https://go-review.googlesource.com/c/protobuf/+/219298/ for info on --go-opt + # I couldn't get it to work during development - Cody + cp -r proto/github.com/pilosa/pilosa/v2/proto/ proto/ + rm -rf proto/github.com # `go generate` all needed packages generate: generate-protoc generate-statik generate-stringer generate-pql @@ -387,6 +391,9 @@ install-stringer: install-protoc-gen-gofast: GO111MODULE=off go get -u github.com/gogo/protobuf/protoc-gen-gofast +install-protoc-gen-go: + GO111MODULE=off go get -u github.com/golang/protobuf/protoc-gen-go + install-protoc: @echo This tool cannot automatically install protoc. Please download and install protoc from https://google.github.io/proto-lens/installing-protoc.html diff --git a/proto/interface.go b/proto/interface.go index af2599707..77ba3fd8d 100644 --- a/proto/interface.go +++ b/proto/interface.go @@ -12,7 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. -package pilosa +package proto import ( "fmt" diff --git a/proto/pilosa.pb.go b/proto/pilosa.pb.go index 45ac65612..973b6e173 100644 --- a/proto/pilosa.pb.go +++ b/proto/pilosa.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // source: pilosa.proto -package pilosa +package proto import ( context "context" @@ -841,52 +841,54 @@ func init() { func init() { proto.RegisterFile("pilosa.proto", fileDescriptor_ef0691a44d1e275c) } var fileDescriptor_ef0691a44d1e275c = []byte{ - // 718 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x55, 0xdd, 0x52, 0xd3, 0x4e, - 0x14, 0x6f, 0x48, 0x68, 0x9b, 0x53, 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0xb5, 0x10, 0xdc, 0x86, 0x56, 0xa9, 0x6d, 0x72, - 0x78, 0xcf, 0x08, 0xd3, 0xdb, 0xe4, 0x60, 0xf5, 0x96, 0x94, 0x52, 0x6b, 0x2a, 0x14, 0x37, 0xa7, - 0x9c, 0x82, 0x5b, 0xd4, 0x80, 0xee, 0x82, 0x1d, 0x47, 0x42, 0xd5, 0x3e, 0x73, 0x38, 0x24, 0x03, - 0xdd, 0x03, 0xe7, 0x33, 0x9d, 0x98, 0xaf, 0x31, 0x63, 0x0e, 0x14, 0x65, 0xaf, 0x0e, 0x8e, 0x5c, - 0x96, 0xad, 0x9f, 0x73, 0x50, 0xef, 0x28, 0x1a, 0xda, 0x81, 0xa6, 0xb9, 0xa7, 0xe8, 0xba, 0xb1, - 0xbd, 0x70, 0x61, 0xd7, 0x57, 0xcb, 0x4b, 0x9e, 0xaf, 0x57, 0x50, 0xdb, 0xb4, 0xd0, 0x2e, 0x2c, - 0x1a, 0xee, 0x71, 0x42, 0xd2, 0xc9, 0x6c, 0x17, 0xd7, 0x0c, 0x50, 0x39, 0x3d, 0x41, 0xad, 0x48, - 0xa0, 0xf3, 0x5b, 0x02, 0x9d, 0x7f, 0x48, 0xa0, 0xf3, 0xe7, 0x04, 0x3a, 0x97, 0x48, 0xe0, 0x39, - 0x34, 0xf2, 0xc1, 0x43, 0xc5, 0xed, 0xac, 0x4e, 0xe2, 0xcc, 0xf0, 0xdd, 0xba, 0xfa, 0xaf, 0x3d, - 0xfa, 0x15, 0x00, 0x00, 0xff, 0xff, 0x7e, 0x8d, 0x53, 0x0b, 0xe7, 0x06, 0x00, 0x00, + // 745 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x55, 0xdd, 0x72, 0xd3, 0x3a, + 0x10, 0x8e, 0x6b, 0x37, 0x89, 0x37, 0xfd, 0x3b, 0xea, 0x39, 0x3d, 0x99, 0xce, 0x99, 0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x69, 0x17, 0xfb, 0x71, + 0x4c, 0x26, 0x92, 0x52, 0x2e, 0x3e, 0xd0, 0xe9, 0x14, 0x6d, 0x95, 0xf0, 0x15, 0xb2, 0x34, 0xd7, + 0x19, 0x64, 0xe6, 0x95, 0xab, 0xef, 0x9b, 0xa1, 0xd2, 0xbc, 0x48, 0x46, 0x1e, 0x40, 0x8f, 0x71, + 0x92, 0x66, 0x55, 0xf5, 0xac, 0x86, 0xd5, 0x2a, 0xe1, 0x9c, 0x0e, 0xdd, 0x07, 0x08, 0x68, 0x37, + 0x1c, 0x10, 0x95, 0x9a, 0xab, 0x2e, 0x5f, 0x36, 0x97, 0xbf, 0xd0, 0x88, 0x34, 0x99, 0x92, 0x0e, + 0x6a, 0xe0, 0xea, 0xe6, 0x3a, 0x23, 0xcc, 0xdf, 0x85, 0x4a, 0xca, 0x92, 0x33, 0x7d, 0x41, 0xd8, + 0x58, 0x17, 0xd1, 0xc6, 0x5a, 0x90, 0x5a, 0xd1, 0x25, 0x4c, 0x97, 0xd0, 0xc6, 0x5a, 0xf0, 0xbf, + 0x59, 0xb0, 0x74, 0x14, 0x89, 0x21, 0xed, 0x26, 0xbf, 0x5f, 0x09, 0x77, 0xf3, 0x03, 0x26, 0x83, + 0xfb, 0xcb, 0x04, 0x77, 0x14, 0x88, 0x77, 0xf1, 0x6b, 0x3a, 0x11, 0xd3, 0xd9, 0xf2, 0x61, 0xa1, + 0x17, 0xb2, 0x84, 0xc6, 0xaf, 0x42, 0xca, 0x02, 0x51, 0xb7, 0x3d, 0xbb, 0xe1, 0xe2, 0x82, 0x4e, + 0xba, 0x61, 0xe1, 0x20, 0x4c, 0x54, 0x19, 0x1d, 0xac, 0x05, 0xb4, 0x06, 0x65, 0xde, 0xeb, 0x09, + 0x9a, 0xa8, 0x0a, 0x3a, 0x38, 0x95, 0x24, 0x7b, 0x24, 0xf7, 0x8f, 0xaa, 0x9a, 0x8b, 0xb5, 0xe0, + 0x6f, 0x40, 0x2d, 0x57, 0x36, 0xd9, 0xbc, 0x17, 0x84, 0xe9, 0x69, 0x72, 0xb0, 0x3a, 0x4b, 0x4a, + 0xae, 0x34, 0x05, 0x8a, 0x9b, 0x52, 0xfa, 0xe0, 0x66, 0x39, 0xa0, 0xdb, 0x60, 0x87, 0x81, 0x50, + 0xb9, 0xcf, 0x6c, 0x0e, 0xc9, 0x40, 0x77, 0xc0, 0xf9, 0x48, 0x27, 0xe6, 0x35, 0x66, 0xf4, 0x81, + 0xa2, 0x1c, 0x94, 0xc1, 0x91, 0xc3, 0xd2, 0xfc, 0x3e, 0x07, 0xe5, 0xb6, 0xa2, 0xa1, 0x3d, 0xa8, + 0x9a, 0x7d, 0x8a, 0xfe, 0x35, 0xb6, 0x57, 0x36, 0xec, 0xfa, 0x6a, 0x7e, 0xc8, 0xd3, 0xf1, 0xf2, + 0x4b, 0x3b, 0x16, 0xda, 0x87, 0x45, 0xc3, 0x3d, 0x8d, 0x48, 0x3c, 0x99, 0x7d, 0xc5, 0x3f, 0x06, + 0x28, 0xac, 0x1e, 0xbf, 0x94, 0x05, 0xd0, 0xfe, 0x29, 0x80, 0xf6, 0x1f, 0x04, 0xd0, 0xfe, 0x75, + 0x00, 0xed, 0x6b, 0x04, 0xf0, 0x14, 0x2a, 0x69, 0xe3, 0xa1, 0x6c, 0x77, 0x16, 0x3b, 0x71, 0xa6, + 0xfb, 0x83, 0xcd, 0x0f, 0x1b, 0xfd, 0x30, 0x39, 0x1f, 0x77, 0xb6, 0xba, 0x7c, 0xb0, 0xad, 0x49, + 0xe6, 0x73, 0xd1, 0xdc, 0x56, 0x7f, 0xbd, 0x4e, 0x59, 0x7d, 0x1e, 0xfc, 0x08, 0x00, 0x00, 0xff, + 0xff, 0x60, 0xce, 0x2e, 0x49, 0x0c, 0x07, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. diff --git a/proto/pilosa.proto b/proto/pilosa.proto index 1fc966083..05bfbd9e4 100644 --- a/proto/pilosa.proto +++ b/proto/pilosa.proto @@ -3,6 +3,8 @@ package pilosa; //import "public.proto"; +option go_package = "github.com/pilosa/pilosa/v2/proto"; + message QueryPQLRequest { string index = 1; string pql = 2; diff --git a/proto/vdsm/vdsm.pb.go b/proto/vdsm/vdsm.pb.go index edb45edde..99f04cda2 100644 --- a/proto/vdsm/vdsm.pb.go +++ b/proto/vdsm/vdsm.pb.go @@ -7,6 +7,7 @@ import ( context "context" fmt "fmt" proto "github.com/golang/protobuf/proto" + proto1 "github.com/pilosa/pilosa/v2/proto" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" @@ -561,804 +562,6 @@ func (m *DeleteVDSResponse) XXX_DiscardUnknown() { var xxx_messageInfo_DeleteVDSResponse proto.InternalMessageInfo -type QueryPQLRequest struct { - Index string `protobuf:"bytes,1,opt,name=index,proto3" json:"index,omitempty"` - Pql string `protobuf:"bytes,2,opt,name=pql,proto3" json:"pql,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *QueryPQLRequest) Reset() { *m = QueryPQLRequest{} } -func (m *QueryPQLRequest) String() string { return proto.CompactTextString(m) } -func (*QueryPQLRequest) ProtoMessage() {} -func (*QueryPQLRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3849c3e549495f50, []int{10} -} - -func (m *QueryPQLRequest) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_QueryPQLRequest.Unmarshal(m, b) -} -func (m *QueryPQLRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_QueryPQLRequest.Marshal(b, m, deterministic) -} -func (m *QueryPQLRequest) XXX_Merge(src proto.Message) { - xxx_messageInfo_QueryPQLRequest.Merge(m, src) -} -func (m *QueryPQLRequest) XXX_Size() int { - return xxx_messageInfo_QueryPQLRequest.Size(m) -} -func (m *QueryPQLRequest) XXX_DiscardUnknown() { - xxx_messageInfo_QueryPQLRequest.DiscardUnknown(m) -} - -var xxx_messageInfo_QueryPQLRequest proto.InternalMessageInfo - -func (m *QueryPQLRequest) GetIndex() string { - if m != nil { - return m.Index - } - return "" -} - -func (m *QueryPQLRequest) GetPql() string { - if m != nil { - return m.Pql - } - return "" -} - -type QuerySQLRequest struct { - Sql string `protobuf:"bytes,1,opt,name=sql,proto3" json:"sql,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *QuerySQLRequest) Reset() { *m = QuerySQLRequest{} } -func (m *QuerySQLRequest) String() string { return proto.CompactTextString(m) } -func (*QuerySQLRequest) ProtoMessage() {} -func (*QuerySQLRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3849c3e549495f50, []int{11} -} - -func (m *QuerySQLRequest) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_QuerySQLRequest.Unmarshal(m, b) -} -func (m *QuerySQLRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_QuerySQLRequest.Marshal(b, m, deterministic) -} -func (m *QuerySQLRequest) XXX_Merge(src proto.Message) { - xxx_messageInfo_QuerySQLRequest.Merge(m, src) -} -func (m *QuerySQLRequest) XXX_Size() int { - return xxx_messageInfo_QuerySQLRequest.Size(m) -} -func (m *QuerySQLRequest) XXX_DiscardUnknown() { - xxx_messageInfo_QuerySQLRequest.DiscardUnknown(m) -} - -var xxx_messageInfo_QuerySQLRequest proto.InternalMessageInfo - -func (m *QuerySQLRequest) GetSql() string { - if m != nil { - return m.Sql - } - return "" -} - -type StatusError struct { - Code uint32 `protobuf:"varint,1,opt,name=Code,proto3" json:"Code,omitempty"` - Message string `protobuf:"bytes,2,opt,name=Message,proto3" json:"Message,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *StatusError) Reset() { *m = StatusError{} } -func (m *StatusError) String() string { return proto.CompactTextString(m) } -func (*StatusError) ProtoMessage() {} -func (*StatusError) Descriptor() ([]byte, []int) { - return fileDescriptor_3849c3e549495f50, []int{12} -} - -func (m *StatusError) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_StatusError.Unmarshal(m, b) -} -func (m *StatusError) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_StatusError.Marshal(b, m, deterministic) -} -func (m *StatusError) XXX_Merge(src proto.Message) { - xxx_messageInfo_StatusError.Merge(m, src) -} -func (m *StatusError) XXX_Size() int { - return xxx_messageInfo_StatusError.Size(m) -} -func (m *StatusError) XXX_DiscardUnknown() { - xxx_messageInfo_StatusError.DiscardUnknown(m) -} - -var xxx_messageInfo_StatusError proto.InternalMessageInfo - -func (m *StatusError) GetCode() uint32 { - if m != nil { - return m.Code - } - return 0 -} - -func (m *StatusError) GetMessage() string { - if m != nil { - return m.Message - } - return "" -} - -type RowResponse struct { - Headers []*ColumnInfo `protobuf:"bytes,1,rep,name=headers,proto3" json:"headers,omitempty"` - Columns []*ColumnResponse `protobuf:"bytes,2,rep,name=columns,proto3" json:"columns,omitempty"` - StatusError *StatusError `protobuf:"bytes,3,opt,name=StatusError,proto3" json:"StatusError,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *RowResponse) Reset() { *m = RowResponse{} } -func (m *RowResponse) String() string { return proto.CompactTextString(m) } -func (*RowResponse) ProtoMessage() {} -func (*RowResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3849c3e549495f50, []int{13} -} - -func (m *RowResponse) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_RowResponse.Unmarshal(m, b) -} -func (m *RowResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_RowResponse.Marshal(b, m, deterministic) -} -func (m *RowResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_RowResponse.Merge(m, src) -} -func (m *RowResponse) XXX_Size() int { - return xxx_messageInfo_RowResponse.Size(m) -} -func (m *RowResponse) XXX_DiscardUnknown() { - xxx_messageInfo_RowResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_RowResponse proto.InternalMessageInfo - -func (m *RowResponse) GetHeaders() []*ColumnInfo { - if m != nil { - return m.Headers - } - return nil -} - -func (m *RowResponse) GetColumns() []*ColumnResponse { - if m != nil { - return m.Columns - } - return nil -} - -func (m *RowResponse) GetStatusError() *StatusError { - if m != nil { - return m.StatusError - } - return nil -} - -type Row struct { - Columns []*ColumnResponse `protobuf:"bytes,1,rep,name=columns,proto3" json:"columns,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *Row) Reset() { *m = Row{} } -func (m *Row) String() string { return proto.CompactTextString(m) } -func (*Row) ProtoMessage() {} -func (*Row) Descriptor() ([]byte, []int) { - return fileDescriptor_3849c3e549495f50, []int{14} -} - -func (m *Row) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_Row.Unmarshal(m, b) -} -func (m *Row) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_Row.Marshal(b, m, deterministic) -} -func (m *Row) XXX_Merge(src proto.Message) { - xxx_messageInfo_Row.Merge(m, src) -} -func (m *Row) XXX_Size() int { - return xxx_messageInfo_Row.Size(m) -} -func (m *Row) XXX_DiscardUnknown() { - xxx_messageInfo_Row.DiscardUnknown(m) -} - -var xxx_messageInfo_Row proto.InternalMessageInfo - -func (m *Row) GetColumns() []*ColumnResponse { - if m != nil { - return m.Columns - } - return nil -} - -type TableResponse struct { - Headers []*ColumnInfo `protobuf:"bytes,1,rep,name=headers,proto3" json:"headers,omitempty"` - Rows []*Row `protobuf:"bytes,2,rep,name=rows,proto3" json:"rows,omitempty"` - StatusError *StatusError `protobuf:"bytes,3,opt,name=StatusError,proto3" json:"StatusError,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *TableResponse) Reset() { *m = TableResponse{} } -func (m *TableResponse) String() string { return proto.CompactTextString(m) } -func (*TableResponse) ProtoMessage() {} -func (*TableResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3849c3e549495f50, []int{15} -} - -func (m *TableResponse) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_TableResponse.Unmarshal(m, b) -} -func (m *TableResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_TableResponse.Marshal(b, m, deterministic) -} -func (m *TableResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_TableResponse.Merge(m, src) -} -func (m *TableResponse) XXX_Size() int { - return xxx_messageInfo_TableResponse.Size(m) -} -func (m *TableResponse) XXX_DiscardUnknown() { - xxx_messageInfo_TableResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_TableResponse proto.InternalMessageInfo - -func (m *TableResponse) GetHeaders() []*ColumnInfo { - if m != nil { - return m.Headers - } - return nil -} - -func (m *TableResponse) GetRows() []*Row { - if m != nil { - return m.Rows - } - return nil -} - -func (m *TableResponse) GetStatusError() *StatusError { - if m != nil { - return m.StatusError - } - return nil -} - -type ColumnInfo struct { - Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` - Datatype string `protobuf:"bytes,2,opt,name=datatype,proto3" json:"datatype,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *ColumnInfo) Reset() { *m = ColumnInfo{} } -func (m *ColumnInfo) String() string { return proto.CompactTextString(m) } -func (*ColumnInfo) ProtoMessage() {} -func (*ColumnInfo) Descriptor() ([]byte, []int) { - return fileDescriptor_3849c3e549495f50, []int{16} -} - -func (m *ColumnInfo) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_ColumnInfo.Unmarshal(m, b) -} -func (m *ColumnInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_ColumnInfo.Marshal(b, m, deterministic) -} -func (m *ColumnInfo) XXX_Merge(src proto.Message) { - xxx_messageInfo_ColumnInfo.Merge(m, src) -} -func (m *ColumnInfo) XXX_Size() int { - return xxx_messageInfo_ColumnInfo.Size(m) -} -func (m *ColumnInfo) XXX_DiscardUnknown() { - xxx_messageInfo_ColumnInfo.DiscardUnknown(m) -} - -var xxx_messageInfo_ColumnInfo proto.InternalMessageInfo - -func (m *ColumnInfo) GetName() string { - if m != nil { - return m.Name - } - return "" -} - -func (m *ColumnInfo) GetDatatype() string { - if m != nil { - return m.Datatype - } - return "" -} - -type ColumnResponse struct { - // Types that are valid to be assigned to ColumnVal: - // *ColumnResponse_StringVal - // *ColumnResponse_Uint64Val - // *ColumnResponse_Int64Val - // *ColumnResponse_BoolVal - // *ColumnResponse_BlobVal - // *ColumnResponse_Uint64ArrayVal - // *ColumnResponse_StringArrayVal - // *ColumnResponse_Float64Val - // *ColumnResponse_DecimalVal - ColumnVal isColumnResponse_ColumnVal `protobuf_oneof:"columnVal"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *ColumnResponse) Reset() { *m = ColumnResponse{} } -func (m *ColumnResponse) String() string { return proto.CompactTextString(m) } -func (*ColumnResponse) ProtoMessage() {} -func (*ColumnResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_3849c3e549495f50, []int{17} -} - -func (m *ColumnResponse) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_ColumnResponse.Unmarshal(m, b) -} -func (m *ColumnResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_ColumnResponse.Marshal(b, m, deterministic) -} -func (m *ColumnResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_ColumnResponse.Merge(m, src) -} -func (m *ColumnResponse) XXX_Size() int { - return xxx_messageInfo_ColumnResponse.Size(m) -} -func (m *ColumnResponse) XXX_DiscardUnknown() { - xxx_messageInfo_ColumnResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_ColumnResponse proto.InternalMessageInfo - -type isColumnResponse_ColumnVal interface { - isColumnResponse_ColumnVal() -} - -type ColumnResponse_StringVal struct { - StringVal string `protobuf:"bytes,1,opt,name=stringVal,proto3,oneof"` -} - -type ColumnResponse_Uint64Val struct { - Uint64Val uint64 `protobuf:"varint,2,opt,name=uint64Val,proto3,oneof"` -} - -type ColumnResponse_Int64Val struct { - Int64Val int64 `protobuf:"varint,3,opt,name=int64Val,proto3,oneof"` -} - -type ColumnResponse_BoolVal struct { - BoolVal bool `protobuf:"varint,4,opt,name=boolVal,proto3,oneof"` -} - -type ColumnResponse_BlobVal struct { - BlobVal []byte `protobuf:"bytes,5,opt,name=blobVal,proto3,oneof"` -} - -type ColumnResponse_Uint64ArrayVal struct { - Uint64ArrayVal *Uint64Array `protobuf:"bytes,6,opt,name=uint64ArrayVal,proto3,oneof"` -} - -type ColumnResponse_StringArrayVal struct { - StringArrayVal *StringArray `protobuf:"bytes,7,opt,name=stringArrayVal,proto3,oneof"` -} - -type ColumnResponse_Float64Val struct { - Float64Val float64 `protobuf:"fixed64,8,opt,name=float64Val,proto3,oneof"` -} - -type ColumnResponse_DecimalVal struct { - DecimalVal *Decimal `protobuf:"bytes,9,opt,name=decimalVal,proto3,oneof"` -} - -func (*ColumnResponse_StringVal) isColumnResponse_ColumnVal() {} - -func (*ColumnResponse_Uint64Val) isColumnResponse_ColumnVal() {} - -func (*ColumnResponse_Int64Val) isColumnResponse_ColumnVal() {} - -func (*ColumnResponse_BoolVal) isColumnResponse_ColumnVal() {} - -func (*ColumnResponse_BlobVal) isColumnResponse_ColumnVal() {} - -func (*ColumnResponse_Uint64ArrayVal) isColumnResponse_ColumnVal() {} - -func (*ColumnResponse_StringArrayVal) isColumnResponse_ColumnVal() {} - -func (*ColumnResponse_Float64Val) isColumnResponse_ColumnVal() {} - -func (*ColumnResponse_DecimalVal) isColumnResponse_ColumnVal() {} - -func (m *ColumnResponse) GetColumnVal() isColumnResponse_ColumnVal { - if m != nil { - return m.ColumnVal - } - return nil -} - -func (m *ColumnResponse) GetStringVal() string { - if x, ok := m.GetColumnVal().(*ColumnResponse_StringVal); ok { - return x.StringVal - } - return "" -} - -func (m *ColumnResponse) GetUint64Val() uint64 { - if x, ok := m.GetColumnVal().(*ColumnResponse_Uint64Val); ok { - return x.Uint64Val - } - return 0 -} - -func (m *ColumnResponse) GetInt64Val() int64 { - if x, ok := m.GetColumnVal().(*ColumnResponse_Int64Val); ok { - return x.Int64Val - } - return 0 -} - -func (m *ColumnResponse) GetBoolVal() bool { - if x, ok := m.GetColumnVal().(*ColumnResponse_BoolVal); ok { - return x.BoolVal - } - return false -} - -func (m *ColumnResponse) GetBlobVal() []byte { - if x, ok := m.GetColumnVal().(*ColumnResponse_BlobVal); ok { - return x.BlobVal - } - return nil -} - -func (m *ColumnResponse) GetUint64ArrayVal() *Uint64Array { - if x, ok := m.GetColumnVal().(*ColumnResponse_Uint64ArrayVal); ok { - return x.Uint64ArrayVal - } - return nil -} - -func (m *ColumnResponse) GetStringArrayVal() *StringArray { - if x, ok := m.GetColumnVal().(*ColumnResponse_StringArrayVal); ok { - return x.StringArrayVal - } - return nil -} - -func (m *ColumnResponse) GetFloat64Val() float64 { - if x, ok := m.GetColumnVal().(*ColumnResponse_Float64Val); ok { - return x.Float64Val - } - return 0 -} - -func (m *ColumnResponse) GetDecimalVal() *Decimal { - if x, ok := m.GetColumnVal().(*ColumnResponse_DecimalVal); ok { - return x.DecimalVal - } - return nil -} - -// XXX_OneofWrappers is for the internal use of the proto package. -func (*ColumnResponse) XXX_OneofWrappers() []interface{} { - return []interface{}{ - (*ColumnResponse_StringVal)(nil), - (*ColumnResponse_Uint64Val)(nil), - (*ColumnResponse_Int64Val)(nil), - (*ColumnResponse_BoolVal)(nil), - (*ColumnResponse_BlobVal)(nil), - (*ColumnResponse_Uint64ArrayVal)(nil), - (*ColumnResponse_StringArrayVal)(nil), - (*ColumnResponse_Float64Val)(nil), - (*ColumnResponse_DecimalVal)(nil), - } -} - -type Decimal struct { - Value int64 `protobuf:"varint,1,opt,name=value,proto3" json:"value,omitempty"` - Scale int64 `protobuf:"varint,2,opt,name=scale,proto3" json:"scale,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *Decimal) Reset() { *m = Decimal{} } -func (m *Decimal) String() string { return proto.CompactTextString(m) } -func (*Decimal) ProtoMessage() {} -func (*Decimal) Descriptor() ([]byte, []int) { - return fileDescriptor_3849c3e549495f50, []int{18} -} - -func (m *Decimal) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_Decimal.Unmarshal(m, b) -} -func (m *Decimal) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_Decimal.Marshal(b, m, deterministic) -} -func (m *Decimal) XXX_Merge(src proto.Message) { - xxx_messageInfo_Decimal.Merge(m, src) -} -func (m *Decimal) XXX_Size() int { - return xxx_messageInfo_Decimal.Size(m) -} -func (m *Decimal) XXX_DiscardUnknown() { - xxx_messageInfo_Decimal.DiscardUnknown(m) -} - -var xxx_messageInfo_Decimal proto.InternalMessageInfo - -func (m *Decimal) GetValue() int64 { - if m != nil { - return m.Value - } - return 0 -} - -func (m *Decimal) GetScale() int64 { - if m != nil { - return m.Scale - } - return 0 -} - -type InspectRequest struct { - Vds string `protobuf:"bytes,1,opt,name=vds,proto3" json:"vds,omitempty"` - Records *IdsOrKeys `protobuf:"bytes,2,opt,name=records,proto3" json:"records,omitempty"` - FilterFields []string `protobuf:"bytes,3,rep,name=filterFields,proto3" json:"filterFields,omitempty"` - Limit uint64 `protobuf:"varint,4,opt,name=limit,proto3" json:"limit,omitempty"` - Offset uint64 `protobuf:"varint,5,opt,name=offset,proto3" json:"offset,omitempty"` - Query string `protobuf:"bytes,6,opt,name=query,proto3" json:"query,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *InspectRequest) Reset() { *m = InspectRequest{} } -func (m *InspectRequest) String() string { return proto.CompactTextString(m) } -func (*InspectRequest) ProtoMessage() {} -func (*InspectRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_3849c3e549495f50, []int{19} -} - -func (m *InspectRequest) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_InspectRequest.Unmarshal(m, b) -} -func (m *InspectRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_InspectRequest.Marshal(b, m, deterministic) -} -func (m *InspectRequest) XXX_Merge(src proto.Message) { - xxx_messageInfo_InspectRequest.Merge(m, src) -} -func (m *InspectRequest) XXX_Size() int { - return xxx_messageInfo_InspectRequest.Size(m) -} -func (m *InspectRequest) XXX_DiscardUnknown() { - xxx_messageInfo_InspectRequest.DiscardUnknown(m) -} - -var xxx_messageInfo_InspectRequest proto.InternalMessageInfo - -func (m *InspectRequest) GetVds() string { - if m != nil { - return m.Vds - } - return "" -} - -func (m *InspectRequest) GetRecords() *IdsOrKeys { - if m != nil { - return m.Records - } - return nil -} - -func (m *InspectRequest) GetFilterFields() []string { - if m != nil { - return m.FilterFields - } - return nil -} - -func (m *InspectRequest) GetLimit() uint64 { - if m != nil { - return m.Limit - } - return 0 -} - -func (m *InspectRequest) GetOffset() uint64 { - if m != nil { - return m.Offset - } - return 0 -} - -func (m *InspectRequest) GetQuery() string { - if m != nil { - return m.Query - } - return "" -} - -type Uint64Array struct { - Vals []uint64 `protobuf:"varint,1,rep,packed,name=vals,proto3" json:"vals,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *Uint64Array) Reset() { *m = Uint64Array{} } -func (m *Uint64Array) String() string { return proto.CompactTextString(m) } -func (*Uint64Array) ProtoMessage() {} -func (*Uint64Array) Descriptor() ([]byte, []int) { - return fileDescriptor_3849c3e549495f50, []int{20} -} - -func (m *Uint64Array) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_Uint64Array.Unmarshal(m, b) -} -func (m *Uint64Array) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_Uint64Array.Marshal(b, m, deterministic) -} -func (m *Uint64Array) XXX_Merge(src proto.Message) { - xxx_messageInfo_Uint64Array.Merge(m, src) -} -func (m *Uint64Array) XXX_Size() int { - return xxx_messageInfo_Uint64Array.Size(m) -} -func (m *Uint64Array) XXX_DiscardUnknown() { - xxx_messageInfo_Uint64Array.DiscardUnknown(m) -} - -var xxx_messageInfo_Uint64Array proto.InternalMessageInfo - -func (m *Uint64Array) GetVals() []uint64 { - if m != nil { - return m.Vals - } - return nil -} - -type StringArray struct { - Vals []string `protobuf:"bytes,1,rep,name=vals,proto3" json:"vals,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *StringArray) Reset() { *m = StringArray{} } -func (m *StringArray) String() string { return proto.CompactTextString(m) } -func (*StringArray) ProtoMessage() {} -func (*StringArray) Descriptor() ([]byte, []int) { - return fileDescriptor_3849c3e549495f50, []int{21} -} - -func (m *StringArray) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_StringArray.Unmarshal(m, b) -} -func (m *StringArray) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_StringArray.Marshal(b, m, deterministic) -} -func (m *StringArray) XXX_Merge(src proto.Message) { - xxx_messageInfo_StringArray.Merge(m, src) -} -func (m *StringArray) XXX_Size() int { - return xxx_messageInfo_StringArray.Size(m) -} -func (m *StringArray) XXX_DiscardUnknown() { - xxx_messageInfo_StringArray.DiscardUnknown(m) -} - -var xxx_messageInfo_StringArray proto.InternalMessageInfo - -func (m *StringArray) GetVals() []string { - if m != nil { - return m.Vals - } - return nil -} - -type IdsOrKeys struct { - // Types that are valid to be assigned to Type: - // *IdsOrKeys_Ids - // *IdsOrKeys_Keys - Type isIdsOrKeys_Type `protobuf_oneof:"type"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *IdsOrKeys) Reset() { *m = IdsOrKeys{} } -func (m *IdsOrKeys) String() string { return proto.CompactTextString(m) } -func (*IdsOrKeys) ProtoMessage() {} -func (*IdsOrKeys) Descriptor() ([]byte, []int) { - return fileDescriptor_3849c3e549495f50, []int{22} -} - -func (m *IdsOrKeys) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_IdsOrKeys.Unmarshal(m, b) -} -func (m *IdsOrKeys) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_IdsOrKeys.Marshal(b, m, deterministic) -} -func (m *IdsOrKeys) XXX_Merge(src proto.Message) { - xxx_messageInfo_IdsOrKeys.Merge(m, src) -} -func (m *IdsOrKeys) XXX_Size() int { - return xxx_messageInfo_IdsOrKeys.Size(m) -} -func (m *IdsOrKeys) XXX_DiscardUnknown() { - xxx_messageInfo_IdsOrKeys.DiscardUnknown(m) -} - -var xxx_messageInfo_IdsOrKeys proto.InternalMessageInfo - -type isIdsOrKeys_Type interface { - isIdsOrKeys_Type() -} - -type IdsOrKeys_Ids struct { - Ids *Uint64Array `protobuf:"bytes,1,opt,name=ids,proto3,oneof"` -} - -type IdsOrKeys_Keys struct { - Keys *StringArray `protobuf:"bytes,2,opt,name=keys,proto3,oneof"` -} - -func (*IdsOrKeys_Ids) isIdsOrKeys_Type() {} - -func (*IdsOrKeys_Keys) isIdsOrKeys_Type() {} - -func (m *IdsOrKeys) GetType() isIdsOrKeys_Type { - if m != nil { - return m.Type - } - return nil -} - -func (m *IdsOrKeys) GetIds() *Uint64Array { - if x, ok := m.GetType().(*IdsOrKeys_Ids); ok { - return x.Ids - } - return nil -} - -func (m *IdsOrKeys) GetKeys() *StringArray { - if x, ok := m.GetType().(*IdsOrKeys_Keys); ok { - return x.Keys - } - return nil -} - -// XXX_OneofWrappers is for the internal use of the proto package. -func (*IdsOrKeys) XXX_OneofWrappers() []interface{} { - return []interface{}{ - (*IdsOrKeys_Ids)(nil), - (*IdsOrKeys_Keys)(nil), - } -} - func init() { proto.RegisterType((*DataSource)(nil), "vdsm.DataSource") proto.RegisterMapType((map[string]string)(nil), "vdsm.DataSource.ConfigEntry") @@ -1371,93 +574,50 @@ func init() { proto.RegisterType((*PostVDSResponse)(nil), "vdsm.PostVDSResponse") proto.RegisterType((*DeleteVDSRequest)(nil), "vdsm.DeleteVDSRequest") proto.RegisterType((*DeleteVDSResponse)(nil), "vdsm.DeleteVDSResponse") - proto.RegisterType((*QueryPQLRequest)(nil), "vdsm.QueryPQLRequest") - proto.RegisterType((*QuerySQLRequest)(nil), "vdsm.QuerySQLRequest") - proto.RegisterType((*StatusError)(nil), "vdsm.StatusError") - proto.RegisterType((*RowResponse)(nil), "vdsm.RowResponse") - proto.RegisterType((*Row)(nil), "vdsm.Row") - proto.RegisterType((*TableResponse)(nil), "vdsm.TableResponse") - proto.RegisterType((*ColumnInfo)(nil), "vdsm.ColumnInfo") - proto.RegisterType((*ColumnResponse)(nil), "vdsm.ColumnResponse") - proto.RegisterType((*Decimal)(nil), "vdsm.Decimal") - proto.RegisterType((*InspectRequest)(nil), "vdsm.InspectRequest") - proto.RegisterType((*Uint64Array)(nil), "vdsm.Uint64Array") - proto.RegisterType((*StringArray)(nil), "vdsm.StringArray") - proto.RegisterType((*IdsOrKeys)(nil), "vdsm.IdsOrKeys") } func init() { proto.RegisterFile("vdsm/vdsm.proto", fileDescriptor_3849c3e549495f50) } var fileDescriptor_3849c3e549495f50 = []byte{ - // 1081 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x56, 0xef, 0x6e, 0x1b, 0x45, - 0x10, 0xf7, 0xe5, 0x1c, 0xdb, 0x37, 0x97, 0x38, 0xce, 0x36, 0x14, 0xcb, 0xb4, 0x95, 0x7b, 0x08, - 0x61, 0x90, 0x48, 0xa3, 0xa4, 0xa9, 0x52, 0x0a, 0x48, 0x24, 0x69, 0x71, 0x04, 0xa5, 0xee, 0x9a, - 0xe6, 0x2b, 0xda, 0xf8, 0xd6, 0xe1, 0xd4, 0xf5, 0xad, 0x7d, 0x7b, 0x4e, 0xf0, 0x37, 0xde, 0x80, - 0x37, 0x00, 0x89, 0x77, 0xe0, 0xb9, 0x78, 0x05, 0xb4, 0xff, 0xce, 0x7b, 0x26, 0x15, 0x55, 0xfb, - 0xc5, 0xda, 0xfd, 0xcd, 0x6f, 0xfe, 0xed, 0xcc, 0xcd, 0x18, 0xb6, 0xae, 0x62, 0x31, 0x79, 0x20, - 0x7f, 0x76, 0xa7, 0x19, 0xcf, 0x39, 0xaa, 0xca, 0x73, 0xf4, 0x8f, 0x07, 0x70, 0x4a, 0x72, 0x32, - 0xe4, 0xf3, 0x6c, 0x44, 0x51, 0x13, 0xd6, 0x92, 0xb8, 0xed, 0x75, 0xbd, 0x9e, 0x8f, 0xd7, 0x92, - 0x18, 0x21, 0xa8, 0xa6, 0x64, 0x42, 0xdb, 0x6b, 0x5d, 0xaf, 0x17, 0x60, 0x75, 0x46, 0x5d, 0x08, - 0x63, 0x2a, 0x46, 0x59, 0x32, 0xcd, 0x13, 0x9e, 0xb6, 0x7d, 0x25, 0x72, 0x21, 0xa9, 0x95, 0x2f, - 0xa6, 0xb4, 0x5d, 0xd5, 0x5a, 0xf2, 0x8c, 0x1e, 0x42, 0x6d, 0xc4, 0xd3, 0x71, 0x72, 0xd9, 0x5e, - 0xef, 0xfa, 0xbd, 0x70, 0xff, 0xce, 0xae, 0x8a, 0x65, 0xe9, 0x7b, 0xf7, 0x44, 0x89, 0x9f, 0xa6, - 0x79, 0xb6, 0xc0, 0x86, 0x8b,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0a, 0x94, 0xe9, 0x4d, 0x33, 0x38, 0x35, 0x2e, - 0x15, 0x96, 0x94, 0xe3, 0x10, 0x02, 0xdd, 0x50, 0xe7, 0x84, 0x45, 0x87, 0x50, 0x37, 0xac, 0xe5, - 0x36, 0xd0, 0x9b, 0x4d, 0x5f, 0x24, 0x2a, 0x46, 0x84, 0xe9, 0xe2, 0xf9, 0x58, 0x5f, 0xa2, 0xbf, - 0x3d, 0x68, 0x9e, 0xa5, 0x62, 0x4a, 0x47, 0xb9, 0xf3, 0x0d, 0xdb, 0x91, 0x17, 0xa8, 0x39, 0x87, - 0x3e, 0x83, 0x7a, 0x46, 0x47, 0x3c, 0x8b, 0x85, 0x52, 0x0e, 0xf7, 0xb7, 0x74, 0x58, 0x67, 0xb1, - 0x78, 0x91, 0x7d, 0x4f, 0x17, 0x02, 0x5b, 0x39, 0x8a, 0x60, 0x63, 0x9c, 0xb0, 0x9c, 0x66, 0xcf, - 0x12, 0xca, 0x62, 0xd1, 0xf6, 0xbb, 0x7e, 0x2f, 0xc0, 0x25, 0x4c, 0x46, 0xc2, 0x92, 0x49, 0x92, - 0xab, 0xd2, 0x55, 0xb1, 0xbe, 0xc8, 0xe5, 0xc7, 0xc7, 0x63, 0x41, 0x73, 0x55, 0xb5, 0x2a, 0x36, - 0x37, 0xc9, 0x9e, 0xc9, 0x29, 0x63, 0x76, 0xa2, 0xbe, 0x44, 0xf7, 0x21, 0x74, 0x8a, 0x25, 0x1b, - 0xf6, 0x8a, 0x30, 0xfd, 0xed, 0x54, 0xb1, 0x3a, 0x4b, 0x8a, 0x53, 0x92, 0x12, 0x25, 0x30, 0x94, - 0x11, 0x04, 0x45, 0x0e, 0xe8, 0x13, 0xf0, 0x93, 0x62, 0xd4, 0xdf, 0xd8, 0x10, 0x52, 0x8e, 0x3e, - 0x85, 0xea, 0x6b, 0xba, 0xb0, 0x2f, 0x71, 0x63, 0xed, 0x15, 0xe1, 0xb8, 0xa6, 0xff, 0x17, 0xec, - 0xff, 0x59, 0x85, 0xc6, 0x73, 0xce, 0xe8, 0x68, 0xce, 0x08, 0x3a, 0x82, 0xba, 0x59, 0x6c, 0xc8, - 0xcc, 0x88, 0xf2, 0xe6, 0xeb, 0x7c, 0xb0, 0x82, 0x9a, 0x31, 0x5d, 0x41, 0x87, 0x50, 0xd3, 0x20, - 0xba, 0xe5, 0x52, 0xac, 0xde, 0x4e, 0x19, 0x2c, 0xd4, 0x8e, 0xa0, 0x6e, 0x36, 0x8e, 0x75, 0x58, - 0x5e, 0x59, 0xd6, 0xe1, 0xca, 0x5a, 0x8a, 0x2a, 0xe8, 0x1b, 0x08, 0x8a, 0x75, 0x81, 0x6e, 0xdb, - 0x46, 0x2c, 0xef, 0xa1, 0xce, 0x87, 0xff, 0xc1, 0x1d, 0xcf, 0x0d, 0xbb, 0x1e, 0x90, 0x71, 0xb2, - 0xb2, 0x2e, 0x3a, 0xdb, 0xcb, 0xd9, 0x55, 0xe8, 0xed, 0x79, 0xe8, 0x6b, 0xd8, 0xb4, 0xcc, 0x57, - 0x29, 0xc9, 0x16, 0x6f, 0x52, 0x37, 0x0f, 0x51, 0x9a, 0xa4, 0x8e, 0xe3, 0xc1, 0x8a, 0xe3, 0xc1, - 0x5b, 0x3b, 0x1e, 0xdc, 0xe4, 0x78, 0xf0, 0xbf, 0x8e, 0x1f, 0x41, 0xdd, 0x7c, 0x4b, 0xf6, 0xad, - 0xcb, 0x9f, 0xd6, 0x1b, 0xdc, 0x5e, 0xd4, 0xd4, 0x7f, 0xd4, 0x83, 0x7f, 0x03, 0x00, 0x00, 0xff, - 0xff, 0x5a, 0xe9, 0x98, 0xbf, 0xb6, 0x0a, 0x00, 0x00, + // 604 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x54, 0xcd, 0x6e, 0xd3, 0x4c, + 0x14, 0x8d, 0xe3, 0x34, 0x6d, 0x6e, 0xbe, 0xb6, 0x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49, 0xc7, 0x8b, 0xa6, 0x07, 0xb2, + 0x49, 0xff, 0x9b, 0xf5, 0x0e, 0xc4, 0x6b, 0x2b, 0x1e, 0xe3, 0x49, 0x55, 0xd4, 0x87, 0xbf, 0x02, + 0x00, 0x00, 0xff, 0xff, 0x39, 0x92, 0xf5, 0x8e, 0xa0, 0x05, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -1476,11 +636,11 @@ type MoleculaClient interface { GetVDS(ctx context.Context, in *GetVDSRequest, opts ...grpc.CallOption) (*GetVDSResponse, error) PostVDS(ctx context.Context, in *PostVDSRequest, opts ...grpc.CallOption) (*PostVDSResponse, error) DeleteVDS(ctx context.Context, in *DeleteVDSRequest, opts ...grpc.CallOption) (*DeleteVDSResponse, error) - QuerySQL(ctx context.Context, in *QuerySQLRequest, opts ...grpc.CallOption) (Molecula_QuerySQLClient, error) - QuerySQLUnary(ctx context.Context, in *QuerySQLRequest, opts ...grpc.CallOption) (*TableResponse, error) - QueryPQL(ctx context.Context, in *QueryPQLRequest, opts ...grpc.CallOption) (Molecula_QueryPQLClient, error) - QueryPQLUnary(ctx context.Context, in *QueryPQLRequest, opts ...grpc.CallOption) (*TableResponse, error) - Inspect(ctx context.Context, in *InspectRequest, opts ...grpc.CallOption) (Molecula_InspectClient, error) + QuerySQL(ctx context.Context, in *proto1.QuerySQLRequest, opts ...grpc.CallOption) (Molecula_QuerySQLClient, error) + QuerySQLUnary(ctx context.Context, in *proto1.QuerySQLRequest, opts ...grpc.CallOption) (*proto1.TableResponse, error) + QueryPQL(ctx context.Context, in *proto1.QueryPQLRequest, opts ...grpc.CallOption) (Molecula_QueryPQLClient, error) + QueryPQLUnary(ctx context.Context, in *proto1.QueryPQLRequest, opts ...grpc.CallOption) (*proto1.TableResponse, error) + Inspect(ctx context.Context, in *proto1.InspectRequest, opts ...grpc.CallOption) (Molecula_InspectClient, error) } type moleculaClient struct { @@ -1527,7 +687,7 @@ func (c *moleculaClient) DeleteVDS(ctx context.Context, in *DeleteVDSRequest, op return out, nil } -func (c *moleculaClient) QuerySQL(ctx context.Context, in *QuerySQLRequest, opts ...grpc.CallOption) (Molecula_QuerySQLClient, error) { +func (c *moleculaClient) QuerySQL(ctx context.Context, in *proto1.QuerySQLRequest, opts ...grpc.CallOption) (Molecula_QuerySQLClient, error) { stream, err := c.cc.NewStream(ctx, &_Molecula_serviceDesc.Streams[0], "/vdsm.Molecula/QuerySQL", opts...) if err != nil { return nil, err @@ -1543,7 +703,7 @@ func (c *moleculaClient) QuerySQL(ctx context.Context, in *QuerySQLRequest, opts } type Molecula_QuerySQLClient interface { - Recv() (*RowResponse, error) + Recv() (*proto1.RowResponse, error) grpc.ClientStream } @@ -1551,16 +711,16 @@ type moleculaQuerySQLClient struct { grpc.ClientStream } -func (x *moleculaQuerySQLClient) Recv() (*RowResponse, error) { - m := new(RowResponse) +func (x *moleculaQuerySQLClient) Recv() (*proto1.RowResponse, error) { + m := new(proto1.RowResponse) if err := x.ClientStream.RecvMsg(m); err != nil { return nil, err } return m, nil } -func (c *moleculaClient) QuerySQLUnary(ctx context.Context, in *QuerySQLRequest, opts ...grpc.CallOption) (*TableResponse, error) { - out := new(TableResponse) +func (c *moleculaClient) QuerySQLUnary(ctx context.Context, in *proto1.QuerySQLRequest, opts ...grpc.CallOption) (*proto1.TableResponse, error) { + out := new(proto1.TableResponse) err := c.cc.Invoke(ctx, "/vdsm.Molecula/QuerySQLUnary", in, out, opts...) if err != nil { return nil, err @@ -1568,7 +728,7 @@ func (c *moleculaClient) QuerySQLUnary(ctx context.Context, in *QuerySQLRequest, return out, nil } -func (c *moleculaClient) QueryPQL(ctx context.Context, in *QueryPQLRequest, opts ...grpc.CallOption) (Molecula_QueryPQLClient, error) { +func (c *moleculaClient) QueryPQL(ctx context.Context, in *proto1.QueryPQLRequest, opts ...grpc.CallOption) (Molecula_QueryPQLClient, error) { stream, err := c.cc.NewStream(ctx, &_Molecula_serviceDesc.Streams[1], "/vdsm.Molecula/QueryPQL", opts...) if err != nil { return nil, err @@ -1584,7 +744,7 @@ func (c *moleculaClient) QueryPQL(ctx context.Context, in *QueryPQLRequest, opts } type Molecula_QueryPQLClient interface { - Recv() (*RowResponse, error) + Recv() (*proto1.RowResponse, error) grpc.ClientStream } @@ -1592,16 +752,16 @@ type moleculaQueryPQLClient struct { grpc.ClientStream } -func (x *moleculaQueryPQLClient) Recv() (*RowResponse, error) { - m := new(RowResponse) +func (x *moleculaQueryPQLClient) Recv() (*proto1.RowResponse, error) { + m := new(proto1.RowResponse) if err := x.ClientStream.RecvMsg(m); err != nil { return nil, err } return m, nil } -func (c *moleculaClient) QueryPQLUnary(ctx context.Context, in *QueryPQLRequest, opts ...grpc.CallOption) (*TableResponse, error) { - out := new(TableResponse) +func (c *moleculaClient) QueryPQLUnary(ctx context.Context, in *proto1.QueryPQLRequest, opts ...grpc.CallOption) (*proto1.TableResponse, error) { + out := new(proto1.TableResponse) err := c.cc.Invoke(ctx, "/vdsm.Molecula/QueryPQLUnary", in, out, opts...) if err != nil { return nil, err @@ -1609,7 +769,7 @@ func (c *moleculaClient) QueryPQLUnary(ctx context.Context, in *QueryPQLRequest, return out, nil } -func (c *moleculaClient) Inspect(ctx context.Context, in *InspectRequest, opts ...grpc.CallOption) (Molecula_InspectClient, error) { +func (c *moleculaClient) Inspect(ctx context.Context, in *proto1.InspectRequest, opts ...grpc.CallOption) (Molecula_InspectClient, error) { stream, err := c.cc.NewStream(ctx, &_Molecula_serviceDesc.Streams[2], "/vdsm.Molecula/Inspect", opts...) if err != nil { return nil, err @@ -1625,7 +785,7 @@ func (c *moleculaClient) Inspect(ctx context.Context, in *InspectRequest, opts . } type Molecula_InspectClient interface { - Recv() (*RowResponse, error) + Recv() (*proto1.RowResponse, error) grpc.ClientStream } @@ -1633,8 +793,8 @@ type moleculaInspectClient struct { grpc.ClientStream } -func (x *moleculaInspectClient) Recv() (*RowResponse, error) { - m := new(RowResponse) +func (x *moleculaInspectClient) Recv() (*proto1.RowResponse, error) { + m := new(proto1.RowResponse) if err := x.ClientStream.RecvMsg(m); err != nil { return nil, err } @@ -1647,11 +807,11 @@ type MoleculaServer interface { GetVDS(context.Context, *GetVDSRequest) (*GetVDSResponse, error) PostVDS(context.Context, *PostVDSRequest) (*PostVDSResponse, error) DeleteVDS(context.Context, *DeleteVDSRequest) (*DeleteVDSResponse, error) - QuerySQL(*QuerySQLRequest, Molecula_QuerySQLServer) error - QuerySQLUnary(context.Context, *QuerySQLRequest) (*TableResponse, error) - QueryPQL(*QueryPQLRequest, Molecula_QueryPQLServer) error - QueryPQLUnary(context.Context, *QueryPQLRequest) (*TableResponse, error) - Inspect(*InspectRequest, Molecula_InspectServer) error + QuerySQL(*proto1.QuerySQLRequest, Molecula_QuerySQLServer) error + QuerySQLUnary(context.Context, *proto1.QuerySQLRequest) (*proto1.TableResponse, error) + QueryPQL(*proto1.QueryPQLRequest, Molecula_QueryPQLServer) error + QueryPQLUnary(context.Context, *proto1.QueryPQLRequest) (*proto1.TableResponse, error) + Inspect(*proto1.InspectRequest, Molecula_InspectServer) error } // UnimplementedMoleculaServer can be embedded to have forward compatible implementations. @@ -1670,19 +830,19 @@ func (*UnimplementedMoleculaServer) PostVDS(ctx context.Context, req *PostVDSReq func (*UnimplementedMoleculaServer) DeleteVDS(ctx context.Context, req *DeleteVDSRequest) (*DeleteVDSResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method DeleteVDS not implemented") } -func (*UnimplementedMoleculaServer) QuerySQL(req *QuerySQLRequest, srv Molecula_QuerySQLServer) error { +func (*UnimplementedMoleculaServer) QuerySQL(req *proto1.QuerySQLRequest, srv Molecula_QuerySQLServer) error { return status.Errorf(codes.Unimplemented, "method QuerySQL not implemented") } -func (*UnimplementedMoleculaServer) QuerySQLUnary(ctx context.Context, req *QuerySQLRequest) (*TableResponse, error) { +func (*UnimplementedMoleculaServer) QuerySQLUnary(ctx context.Context, req *proto1.QuerySQLRequest) (*proto1.TableResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method QuerySQLUnary not implemented") } -func (*UnimplementedMoleculaServer) QueryPQL(req *QueryPQLRequest, srv Molecula_QueryPQLServer) error { +func (*UnimplementedMoleculaServer) QueryPQL(req *proto1.QueryPQLRequest, srv Molecula_QueryPQLServer) error { return status.Errorf(codes.Unimplemented, "method QueryPQL not implemented") } -func (*UnimplementedMoleculaServer) QueryPQLUnary(ctx context.Context, req *QueryPQLRequest) (*TableResponse, error) { +func (*UnimplementedMoleculaServer) QueryPQLUnary(ctx context.Context, req *proto1.QueryPQLRequest) (*proto1.TableResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method QueryPQLUnary not implemented") } -func (*UnimplementedMoleculaServer) Inspect(req *InspectRequest, srv Molecula_InspectServer) error { +func (*UnimplementedMoleculaServer) Inspect(req *proto1.InspectRequest, srv Molecula_InspectServer) error { return status.Errorf(codes.Unimplemented, "method Inspect not implemented") } @@ -1763,7 +923,7 @@ func _Molecula_DeleteVDS_Handler(srv interface{}, ctx context.Context, dec func( } func _Molecula_QuerySQL_Handler(srv interface{}, stream grpc.ServerStream) error { - m := new(QuerySQLRequest) + m := new(proto1.QuerySQLRequest) if err := stream.RecvMsg(m); err != nil { return err } @@ -1771,7 +931,7 @@ func _Molecula_QuerySQL_Handler(srv interface{}, stream grpc.ServerStream) error } type Molecula_QuerySQLServer interface { - Send(*RowResponse) error + Send(*proto1.RowResponse) error grpc.ServerStream } @@ -1779,12 +939,12 @@ type moleculaQuerySQLServer struct { grpc.ServerStream } -func (x *moleculaQuerySQLServer) Send(m *RowResponse) error { +func (x *moleculaQuerySQLServer) Send(m *proto1.RowResponse) error { return x.ServerStream.SendMsg(m) } func _Molecula_QuerySQLUnary_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(QuerySQLRequest) + in := new(proto1.QuerySQLRequest) if err := dec(in); err != nil { return nil, err } @@ -1796,13 +956,13 @@ func _Molecula_QuerySQLUnary_Handler(srv interface{}, ctx context.Context, dec f FullMethod: "/vdsm.Molecula/QuerySQLUnary", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MoleculaServer).QuerySQLUnary(ctx, req.(*QuerySQLRequest)) + return srv.(MoleculaServer).QuerySQLUnary(ctx, req.(*proto1.QuerySQLRequest)) } return interceptor(ctx, in, info, handler) } func _Molecula_QueryPQL_Handler(srv interface{}, stream grpc.ServerStream) error { - m := new(QueryPQLRequest) + m := new(proto1.QueryPQLRequest) if err := stream.RecvMsg(m); err != nil { return err } @@ -1810,7 +970,7 @@ func _Molecula_QueryPQL_Handler(srv interface{}, stream grpc.ServerStream) error } type Molecula_QueryPQLServer interface { - Send(*RowResponse) error + Send(*proto1.RowResponse) error grpc.ServerStream } @@ -1818,12 +978,12 @@ type moleculaQueryPQLServer struct { grpc.ServerStream } -func (x *moleculaQueryPQLServer) Send(m *RowResponse) error { +func (x *moleculaQueryPQLServer) Send(m *proto1.RowResponse) error { return x.ServerStream.SendMsg(m) } func _Molecula_QueryPQLUnary_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(QueryPQLRequest) + in := new(proto1.QueryPQLRequest) if err := dec(in); err != nil { return nil, err } @@ -1835,13 +995,13 @@ func _Molecula_QueryPQLUnary_Handler(srv interface{}, ctx context.Context, dec f FullMethod: "/vdsm.Molecula/QueryPQLUnary", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MoleculaServer).QueryPQLUnary(ctx, req.(*QueryPQLRequest)) + return srv.(MoleculaServer).QueryPQLUnary(ctx, req.(*proto1.QueryPQLRequest)) } return interceptor(ctx, in, info, handler) } func _Molecula_Inspect_Handler(srv interface{}, stream grpc.ServerStream) error { - m := new(InspectRequest) + m := new(proto1.InspectRequest) if err := stream.RecvMsg(m); err != nil { return err } @@ -1849,7 +1009,7 @@ func _Molecula_Inspect_Handler(srv interface{}, stream grpc.ServerStream) error } type Molecula_InspectServer interface { - Send(*RowResponse) error + Send(*proto1.RowResponse) error grpc.ServerStream } @@ -1857,7 +1017,7 @@ type moleculaInspectServer struct { grpc.ServerStream } -func (x *moleculaInspectServer) Send(m *RowResponse) error { +func (x *moleculaInspectServer) Send(m *proto1.RowResponse) error { return x.ServerStream.SendMsg(m) } diff --git a/proto/vdsm/vdsm.proto b/proto/vdsm/vdsm.proto index 34b13de70..b72622ac9 100644 --- a/proto/vdsm/vdsm.proto +++ b/proto/vdsm/vdsm.proto @@ -1,6 +1,10 @@ syntax = "proto3"; package vdsm; +option go_package = "github.com/pilosa/pilosa/v2/proto/vdsm"; + +import "pilosa.proto"; + // deprecated message DataSource { int64 id = 1; @@ -56,92 +60,14 @@ message DeleteVDSRequest { message DeleteVDSResponse { } -message QueryPQLRequest { - string index = 1; - string pql = 2; -} - -message QuerySQLRequest { - string sql = 1; -} - -message StatusError{ - uint32 Code = 1; - string Message = 2; -} - -message RowResponse{ - repeated ColumnInfo headers = 1; - repeated ColumnResponse columns = 2; - StatusError StatusError = 3; -} - -message Row { - repeated ColumnResponse columns = 1; -} - -message TableResponse{ - repeated ColumnInfo headers = 1; - repeated Row rows = 2; - StatusError StatusError = 3; -} - -message ColumnInfo { - string name = 1; - string datatype = 2; -} - -message ColumnResponse{ - oneof columnVal { - string stringVal = 1; - uint64 uint64Val = 2; - int64 int64Val = 3; - bool boolVal = 4; - bytes blobVal = 5; - Uint64Array uint64ArrayVal = 6; - StringArray stringArrayVal = 7; - double float64Val = 8; - Decimal decimalVal = 9; - } -} - -message Decimal { - int64 value = 1; - int64 scale = 2; -} - -message InspectRequest { - string vds = 1; - IdsOrKeys records = 2; - repeated string filterFields = 3; - uint64 limit = 4; - uint64 offset = 5; - string query = 6; -} - -message Uint64Array { - repeated uint64 vals = 1; -} - -message StringArray { - repeated string vals = 1; -} - -message IdsOrKeys { - oneof type { - Uint64Array ids = 1; - StringArray keys = 2; - } -} - service Molecula { rpc GetVDSs(GetVDSsRequest) returns (GetVDSsResponse) {}; rpc GetVDS(GetVDSRequest) returns (GetVDSResponse) {}; rpc PostVDS(PostVDSRequest) returns (PostVDSResponse) {}; rpc DeleteVDS(DeleteVDSRequest) returns (DeleteVDSResponse) {}; - rpc QuerySQL(QuerySQLRequest) returns (stream RowResponse) {}; - rpc QuerySQLUnary(QuerySQLRequest) returns (TableResponse) {}; - rpc QueryPQL(QueryPQLRequest) returns (stream RowResponse) {}; - rpc QueryPQLUnary(QueryPQLRequest) returns (TableResponse) {}; - rpc Inspect(InspectRequest) returns (stream RowResponse) {}; + rpc QuerySQL(pilosa.QuerySQLRequest) returns (stream pilosa.RowResponse) {}; + rpc QuerySQLUnary(pilosa.QuerySQLRequest) returns (pilosa.TableResponse) {}; + rpc QueryPQL(pilosa.QueryPQLRequest) returns (stream pilosa.RowResponse) {}; + rpc QueryPQLUnary(pilosa.QueryPQLRequest) returns (pilosa.TableResponse) {}; + rpc Inspect(pilosa.InspectRequest) returns (stream pilosa.RowResponse) {}; } diff --git a/server/grpc.go b/server/grpc.go index 7dba6558e..fb3c92251 100644 --- a/server/grpc.go +++ b/server/grpc.go @@ -325,36 +325,24 @@ func (h *VDSMGRPCHandler) DeleteVDS(ctx context.Context, req *vdsm_pb.DeleteVDSR } } -func (*VDSMGRPCHandler) QuerySQL(req *vdsm_pb.QuerySQLRequest, srv vdsm_pb.Molecula_QuerySQLServer) error { - return status.Errorf(codes.Unimplemented, "method QuerySQL not implemented") +func (h *VDSMGRPCHandler) QuerySQL(req *pb.QuerySQLRequest, srv vdsm_pb.Molecula_QuerySQLServer) error { + return h.grpcHandler.QuerySQL(req, srv) } -func (h *VDSMGRPCHandler) QuerySQLUnary(ctx context.Context, req *vdsm_pb.QuerySQLRequest) (*vdsm_pb.TableResponse, error) { - pReq := pb.QuerySQLRequest(*req) - resp, err := h.grpcHandler.QuerySQLUnary(ctx, &pReq) - if err != nil { - return nil, err - } - pResp, err := tableToTable(resp) - return pResp, err +func (h *VDSMGRPCHandler) QuerySQLUnary(ctx context.Context, req *pb.QuerySQLRequest) (*pb.TableResponse, error) { + return h.grpcHandler.QuerySQLUnary(ctx, req) } -func (*VDSMGRPCHandler) QueryPQL(req *vdsm_pb.QueryPQLRequest, srv vdsm_pb.Molecula_QueryPQLServer) error { - return status.Errorf(codes.Unimplemented, "method QueryPQL not implemented") +func (h *VDSMGRPCHandler) QueryPQL(req *pb.QueryPQLRequest, srv vdsm_pb.Molecula_QueryPQLServer) error { + return h.grpcHandler.QueryPQL(req, srv) } -func (h *VDSMGRPCHandler) QueryPQLUnary(ctx context.Context, req *vdsm_pb.QueryPQLRequest) (*vdsm_pb.TableResponse, error) { - pReq := pb.QueryPQLRequest(*req) - resp, err := h.grpcHandler.QueryPQLUnary(ctx, &pReq) - if err != nil { - return nil, err - } - pResp, err := tableToTable(resp) - return pResp, err +func (h *VDSMGRPCHandler) QueryPQLUnary(ctx context.Context, req *pb.QueryPQLRequest) (*pb.TableResponse, error) { + return h.grpcHandler.QueryPQLUnary(ctx, req) } -func (*VDSMGRPCHandler) Inspect(req *vdsm_pb.InspectRequest, srv vdsm_pb.Molecula_InspectServer) error { - return status.Errorf(codes.Unimplemented, "method Inspect not implemented") +func (h *VDSMGRPCHandler) Inspect(req *pb.InspectRequest, srv vdsm_pb.Molecula_InspectServer) error { + return h.grpcHandler.Inspect(req, srv) } // ResultUint64 is a wrapper around a uint64 result type @@ -1247,50 +1235,50 @@ func NewGRPCServer(opts ...grpcServerOption) (*grpcServer, error) { return server, nil } -// tableToTable is a helper function used by QueryPQLUnary -// to convert a pb.TableResponse into a vdsm_pb.TableResponse. -func tableToTable(ptbl *pb.TableResponse) (*vdsm_pb.TableResponse, error) { - vtbl := &vdsm_pb.TableResponse{ - Headers: make([]*vdsm_pb.ColumnInfo, len(ptbl.Headers)), - Rows: make([]*vdsm_pb.Row, len(ptbl.Rows)), - } - - // Headers - for i, info := range ptbl.Headers { - vtbl.Headers[i] = &vdsm_pb.ColumnInfo{Name: info.Name, Datatype: info.Datatype} - } - - // Rows - for r := range ptbl.Rows { - columns := make([]*vdsm_pb.ColumnResponse, len(ptbl.Rows[r].Columns)) - for i, col := range ptbl.Rows[r].Columns { - switch v := col.GetColumnVal().(type) { - case *pb.ColumnResponse_StringVal: - columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_StringVal{StringVal: v.StringVal}} - case *pb.ColumnResponse_Uint64Val: - columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_Uint64Val{Uint64Val: v.Uint64Val}} - case *pb.ColumnResponse_Int64Val: - columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_Int64Val{Int64Val: v.Int64Val}} - case *pb.ColumnResponse_BoolVal: - columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_BoolVal{BoolVal: v.BoolVal}} - case *pb.ColumnResponse_BlobVal: - columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_BlobVal{BlobVal: v.BlobVal}} - case *pb.ColumnResponse_Uint64ArrayVal: - columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_Uint64ArrayVal{Uint64ArrayVal: &vdsm_pb.Uint64Array{Vals: v.Uint64ArrayVal.Vals}}} - case *pb.ColumnResponse_StringArrayVal: - columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_StringArrayVal{StringArrayVal: &vdsm_pb.StringArray{Vals: v.StringArrayVal.Vals}}} - case *pb.ColumnResponse_Float64Val: - columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_Float64Val{Float64Val: v.Float64Val}} - case *pb.ColumnResponse_DecimalVal: - columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_DecimalVal{DecimalVal: &vdsm_pb.Decimal{Value: v.DecimalVal.Value, Scale: v.DecimalVal.Scale}}} - case nil: - columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: nil} - default: - return nil, errors.Errorf("unhandled columnval type: %T", col.GetColumnVal()) - } - } - vtbl.Rows[r] = &vdsm_pb.Row{Columns: columns} - } - - return vtbl, nil -} +//// tableToTable is a helper function used by QueryPQLUnary +//// to convert a pb.TableResponse into a vdsm_pb.TableResponse. +//func tableToTable(ptbl *pb.TableResponse) (*vdsm_pb.TableResponse, error) { +// vtbl := &vdsm_pb.TableResponse{ +// Headers: make([]*vdsm_pb.ColumnInfo, len(ptbl.Headers)), +// Rows: make([]*vdsm_pb.Row, len(ptbl.Rows)), +// } +// +// // Headers +// for i, info := range ptbl.Headers { +// vtbl.Headers[i] = &vdsm_pb.ColumnInfo{Name: info.Name, Datatype: info.Datatype} +// } +// +// // Rows +// for r := range ptbl.Rows { +// columns := make([]*vdsm_pb.ColumnResponse, len(ptbl.Rows[r].Columns)) +// for i, col := range ptbl.Rows[r].Columns { +// switch v := col.GetColumnVal().(type) { +// case *pb.ColumnResponse_StringVal: +// columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_StringVal{StringVal: v.StringVal}} +// case *pb.ColumnResponse_Uint64Val: +// columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_Uint64Val{Uint64Val: v.Uint64Val}} +// case *pb.ColumnResponse_Int64Val: +// columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_Int64Val{Int64Val: v.Int64Val}} +// case *pb.ColumnResponse_BoolVal: +// columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_BoolVal{BoolVal: v.BoolVal}} +// case *pb.ColumnResponse_BlobVal: +// columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_BlobVal{BlobVal: v.BlobVal}} +// case *pb.ColumnResponse_Uint64ArrayVal: +// columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_Uint64ArrayVal{Uint64ArrayVal: &vdsm_pb.Uint64Array{Vals: v.Uint64ArrayVal.Vals}}} +// case *pb.ColumnResponse_StringArrayVal: +// columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_StringArrayVal{StringArrayVal: &vdsm_pb.StringArray{Vals: v.StringArrayVal.Vals}}} +// case *pb.ColumnResponse_Float64Val: +// columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_Float64Val{Float64Val: v.Float64Val}} +// case *pb.ColumnResponse_DecimalVal: +// columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_DecimalVal{DecimalVal: &vdsm_pb.Decimal{Value: v.DecimalVal.Value, Scale: v.DecimalVal.Scale}}} +// case nil: +// columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: nil} +// default: +// return nil, errors.Errorf("unhandled columnval type: %T", col.GetColumnVal()) +// } +// } +// vtbl.Rows[r] = &vdsm_pb.Row{Columns: columns} +// } +// +// return vtbl, nil +//} From 949ca882fc0f94e96361068a82a168b0b1997d8b Mon Sep 17 00:00:00 2001 From: Cody Soyland Date: Thu, 17 Sep 2020 16:34:13 -0500 Subject: [PATCH 4/5] Remove unused helper func --- server/grpc.go | 48 ------------------------------------------------ 1 file changed, 48 deletions(-) diff --git a/server/grpc.go b/server/grpc.go index fb3c92251..f378fd403 100644 --- a/server/grpc.go +++ b/server/grpc.go @@ -1234,51 +1234,3 @@ func NewGRPCServer(opts ...grpcServerOption) (*grpcServer, error) { } return server, nil } - -//// tableToTable is a helper function used by QueryPQLUnary -//// to convert a pb.TableResponse into a vdsm_pb.TableResponse. -//func tableToTable(ptbl *pb.TableResponse) (*vdsm_pb.TableResponse, error) { -// vtbl := &vdsm_pb.TableResponse{ -// Headers: make([]*vdsm_pb.ColumnInfo, len(ptbl.Headers)), -// Rows: make([]*vdsm_pb.Row, len(ptbl.Rows)), -// } -// -// // Headers -// for i, info := range ptbl.Headers { -// vtbl.Headers[i] = &vdsm_pb.ColumnInfo{Name: info.Name, Datatype: info.Datatype} -// } -// -// // Rows -// for r := range ptbl.Rows { -// columns := make([]*vdsm_pb.ColumnResponse, len(ptbl.Rows[r].Columns)) -// for i, col := range ptbl.Rows[r].Columns { -// switch v := col.GetColumnVal().(type) { -// case *pb.ColumnResponse_StringVal: -// columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_StringVal{StringVal: v.StringVal}} -// case *pb.ColumnResponse_Uint64Val: -// columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_Uint64Val{Uint64Val: v.Uint64Val}} -// case *pb.ColumnResponse_Int64Val: -// columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_Int64Val{Int64Val: v.Int64Val}} -// case *pb.ColumnResponse_BoolVal: -// columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_BoolVal{BoolVal: v.BoolVal}} -// case *pb.ColumnResponse_BlobVal: -// columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_BlobVal{BlobVal: v.BlobVal}} -// case *pb.ColumnResponse_Uint64ArrayVal: -// columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_Uint64ArrayVal{Uint64ArrayVal: &vdsm_pb.Uint64Array{Vals: v.Uint64ArrayVal.Vals}}} -// case *pb.ColumnResponse_StringArrayVal: -// columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_StringArrayVal{StringArrayVal: &vdsm_pb.StringArray{Vals: v.StringArrayVal.Vals}}} -// case *pb.ColumnResponse_Float64Val: -// columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_Float64Val{Float64Val: v.Float64Val}} -// case *pb.ColumnResponse_DecimalVal: -// columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: &vdsm_pb.ColumnResponse_DecimalVal{DecimalVal: &vdsm_pb.Decimal{Value: v.DecimalVal.Value, Scale: v.DecimalVal.Scale}}} -// case nil: -// columns[i] = &vdsm_pb.ColumnResponse{ColumnVal: nil} -// default: -// return nil, errors.Errorf("unhandled columnval type: %T", col.GetColumnVal()) -// } -// } -// vtbl.Rows[r] = &vdsm_pb.Row{Columns: columns} -// } -// -// return vtbl, nil -//} From 0e8564e2bebd67a3892e8b0754ad1ad83cd1476e Mon Sep 17 00:00:00 2001 From: Jason Aten Date: Tue, 22 Sep 2020 12:07:31 -0500 Subject: [PATCH 5/5] fix license exceptions for vdsm/proto --- license.exceptions | 2 ++ 1 file changed, 2 insertions(+) diff --git a/license.exceptions b/license.exceptions index ffb08a26e..5fb7846e8 100644 --- a/license.exceptions +++ b/license.exceptions @@ -19,3 +19,5 @@ ./cmd/pilosa-keydump/vprint.go ./cmd/pilosa-keydump/keydump.go ./synthload/vprint.go +./proto/vdsm/vdsm.proto +./proto/vdsm/vdsm.pb.go