Documentation
¶
Index ¶
- Constants
- Variables
- func RegisterQueryServiceServer(s grpc.ServiceRegistrar, srv QueryServiceServer)
- type IsoLevel
- type Query
- type QueryNamespace
- func (*QueryNamespace) Descriptor() ([]byte, []int)deprecated
- func (x *QueryNamespace) GetKeys() [][]byte
- func (x *QueryNamespace) GetNsId() string
- func (*QueryNamespace) ProtoMessage()
- func (x *QueryNamespace) ProtoReflect() protoreflect.Message
- func (x *QueryNamespace) Reset()
- func (x *QueryNamespace) String() string
- type QueryServiceClient
- type QueryServiceServer
- type Row
- type Rows
- type RowsNamespace
- func (*RowsNamespace) Descriptor() ([]byte, []int)deprecated
- func (x *RowsNamespace) GetNsId() string
- func (x *RowsNamespace) GetRows() []*Row
- func (*RowsNamespace) ProtoMessage()
- func (x *RowsNamespace) ProtoReflect() protoreflect.Message
- func (x *RowsNamespace) Reset()
- func (x *RowsNamespace) String() string
- type UnimplementedQueryServiceServer
- func (UnimplementedQueryServiceServer) BeginView(context.Context, *ViewParameters) (*View, error)
- func (UnimplementedQueryServiceServer) EndView(context.Context, *View) (*View, error)
- func (UnimplementedQueryServiceServer) GetConfigTransaction(context.Context, *emptypb.Empty) (*protoblocktx.ConfigTransaction, error)
- func (UnimplementedQueryServiceServer) GetNamespacePolicies(context.Context, *emptypb.Empty) (*protoblocktx.NamespacePolicies, error)
- func (UnimplementedQueryServiceServer) GetRows(context.Context, *Query) (*Rows, error)
- type UnsafeQueryServiceServer
- type View
- type ViewParameters
- func (*ViewParameters) Descriptor() ([]byte, []int)deprecated
- func (x *ViewParameters) GetIsoLevel() IsoLevel
- func (x *ViewParameters) GetNonDeferrable() bool
- func (x *ViewParameters) GetTimeoutMilliseconds() uint64
- func (*ViewParameters) ProtoMessage()
- func (x *ViewParameters) ProtoReflect() protoreflect.Message
- func (x *ViewParameters) Reset()
- func (x *ViewParameters) String() string
Constants ¶
const ( QueryService_GetRows_FullMethodName = "/protoqueryservice.QueryService/GetRows" QueryService_BeginView_FullMethodName = "/protoqueryservice.QueryService/BeginView" QueryService_EndView_FullMethodName = "/protoqueryservice.QueryService/EndView" QueryService_GetNamespacePolicies_FullMethodName = "/protoqueryservice.QueryService/GetNamespacePolicies" QueryService_GetConfigTransaction_FullMethodName = "/protoqueryservice.QueryService/GetConfigTransaction" )
Variables ¶
var ( IsoLevel_name = map[int32]string{ 0: "Serializable", 1: "RepeatableRead", 2: "ReadCommitted", 3: "ReadUncommitted", } IsoLevel_value = map[string]int32{ "Serializable": 0, "RepeatableRead": 1, "ReadCommitted": 2, "ReadUncommitted": 3, } )
Enum value maps for IsoLevel.
var File_api_protoqueryservice_query_proto protoreflect.FileDescriptor
var QueryService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "protoqueryservice.QueryService", HandlerType: (*QueryServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "GetRows", Handler: _QueryService_GetRows_Handler, }, { MethodName: "BeginView", Handler: _QueryService_BeginView_Handler, }, { MethodName: "EndView", Handler: _QueryService_EndView_Handler, }, { MethodName: "GetNamespacePolicies", Handler: _QueryService_GetNamespacePolicies_Handler, }, { MethodName: "GetConfigTransaction", Handler: _QueryService_GetConfigTransaction_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "api/protoqueryservice/query.proto", }
QueryService_ServiceDesc is the grpc.ServiceDesc for QueryService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterQueryServiceServer ¶
func RegisterQueryServiceServer(s grpc.ServiceRegistrar, srv QueryServiceServer)
Types ¶
type IsoLevel ¶
type IsoLevel int32
func (IsoLevel) Descriptor ¶
func (IsoLevel) Descriptor() protoreflect.EnumDescriptor
func (IsoLevel) EnumDescriptor
deprecated
func (IsoLevel) Number ¶
func (x IsoLevel) Number() protoreflect.EnumNumber
func (IsoLevel) Type ¶
func (IsoLevel) Type() protoreflect.EnumType
type Query ¶
type Query struct { View *View `protobuf:"bytes,1,opt,name=view,proto3,oneof" json:"view,omitempty"` Namespaces []*QueryNamespace `protobuf:"bytes,2,rep,name=namespaces,proto3" json:"namespaces,omitempty"` // contains filtered or unexported fields }
func (*Query) Descriptor
deprecated
func (*Query) GetNamespaces ¶
func (x *Query) GetNamespaces() []*QueryNamespace
func (*Query) ProtoMessage ¶
func (*Query) ProtoMessage()
func (*Query) ProtoReflect ¶
func (x *Query) ProtoReflect() protoreflect.Message
type QueryNamespace ¶
type QueryNamespace struct { NsId string `protobuf:"bytes,1,opt,name=ns_id,json=nsId,proto3" json:"ns_id,omitempty"` Keys [][]byte `protobuf:"bytes,2,rep,name=keys,proto3" json:"keys,omitempty"` // contains filtered or unexported fields }
func (*QueryNamespace) Descriptor
deprecated
func (*QueryNamespace) Descriptor() ([]byte, []int)
Deprecated: Use QueryNamespace.ProtoReflect.Descriptor instead.
func (*QueryNamespace) GetKeys ¶
func (x *QueryNamespace) GetKeys() [][]byte
func (*QueryNamespace) GetNsId ¶
func (x *QueryNamespace) GetNsId() string
func (*QueryNamespace) ProtoMessage ¶
func (*QueryNamespace) ProtoMessage()
func (*QueryNamespace) ProtoReflect ¶
func (x *QueryNamespace) ProtoReflect() protoreflect.Message
func (*QueryNamespace) Reset ¶
func (x *QueryNamespace) Reset()
func (*QueryNamespace) String ¶
func (x *QueryNamespace) String() string
type QueryServiceClient ¶
type QueryServiceClient interface { GetRows(ctx context.Context, in *Query, opts ...grpc.CallOption) (*Rows, error) BeginView(ctx context.Context, in *ViewParameters, opts ...grpc.CallOption) (*View, error) EndView(ctx context.Context, in *View, opts ...grpc.CallOption) (*View, error) GetNamespacePolicies(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*protoblocktx.NamespacePolicies, error) GetConfigTransaction(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*protoblocktx.ConfigTransaction, error) }
QueryServiceClient is the client API for QueryService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
func NewQueryServiceClient ¶
func NewQueryServiceClient(cc grpc.ClientConnInterface) QueryServiceClient
type QueryServiceServer ¶
type QueryServiceServer interface { GetRows(context.Context, *Query) (*Rows, error) BeginView(context.Context, *ViewParameters) (*View, error) EndView(context.Context, *View) (*View, error) GetNamespacePolicies(context.Context, *emptypb.Empty) (*protoblocktx.NamespacePolicies, error) GetConfigTransaction(context.Context, *emptypb.Empty) (*protoblocktx.ConfigTransaction, error) // contains filtered or unexported methods }
QueryServiceServer is the server API for QueryService service. All implementations must embed UnimplementedQueryServiceServer for forward compatibility
type Row ¶
type Row struct { Key []byte `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` Version uint64 `protobuf:"varint,3,opt,name=version,proto3" json:"version,omitempty"` // contains filtered or unexported fields }
func (*Row) Descriptor
deprecated
func (*Row) GetVersion ¶
func (*Row) ProtoMessage ¶
func (*Row) ProtoMessage()
func (*Row) ProtoReflect ¶
func (x *Row) ProtoReflect() protoreflect.Message
type Rows ¶
type Rows struct { Namespaces []*RowsNamespace `protobuf:"bytes,1,rep,name=namespaces,proto3" json:"namespaces,omitempty"` // contains filtered or unexported fields }
func (*Rows) Descriptor
deprecated
func (*Rows) GetNamespaces ¶
func (x *Rows) GetNamespaces() []*RowsNamespace
func (*Rows) ProtoMessage ¶
func (*Rows) ProtoMessage()
func (*Rows) ProtoReflect ¶
func (x *Rows) ProtoReflect() protoreflect.Message
type RowsNamespace ¶
type RowsNamespace struct { NsId string `protobuf:"bytes,1,opt,name=ns_id,json=nsId,proto3" json:"ns_id,omitempty"` Rows []*Row `protobuf:"bytes,2,rep,name=rows,proto3" json:"rows,omitempty"` // contains filtered or unexported fields }
func (*RowsNamespace) Descriptor
deprecated
func (*RowsNamespace) Descriptor() ([]byte, []int)
Deprecated: Use RowsNamespace.ProtoReflect.Descriptor instead.
func (*RowsNamespace) GetNsId ¶
func (x *RowsNamespace) GetNsId() string
func (*RowsNamespace) GetRows ¶
func (x *RowsNamespace) GetRows() []*Row
func (*RowsNamespace) ProtoMessage ¶
func (*RowsNamespace) ProtoMessage()
func (*RowsNamespace) ProtoReflect ¶
func (x *RowsNamespace) ProtoReflect() protoreflect.Message
func (*RowsNamespace) Reset ¶
func (x *RowsNamespace) Reset()
func (*RowsNamespace) String ¶
func (x *RowsNamespace) String() string
type UnimplementedQueryServiceServer ¶
type UnimplementedQueryServiceServer struct { }
UnimplementedQueryServiceServer must be embedded to have forward compatible implementations.
func (UnimplementedQueryServiceServer) BeginView ¶
func (UnimplementedQueryServiceServer) BeginView(context.Context, *ViewParameters) (*View, error)
func (UnimplementedQueryServiceServer) GetConfigTransaction ¶
func (UnimplementedQueryServiceServer) GetConfigTransaction(context.Context, *emptypb.Empty) (*protoblocktx.ConfigTransaction, error)
func (UnimplementedQueryServiceServer) GetNamespacePolicies ¶
func (UnimplementedQueryServiceServer) GetNamespacePolicies(context.Context, *emptypb.Empty) (*protoblocktx.NamespacePolicies, error)
type UnsafeQueryServiceServer ¶
type UnsafeQueryServiceServer interface {
// contains filtered or unexported methods
}
UnsafeQueryServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to QueryServiceServer will result in compilation errors.
type View ¶
type View struct { Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` // contains filtered or unexported fields }
func (*View) Descriptor
deprecated
func (*View) ProtoMessage ¶
func (*View) ProtoMessage()
func (*View) ProtoReflect ¶
func (x *View) ProtoReflect() protoreflect.Message
type ViewParameters ¶
type ViewParameters struct { IsoLevel IsoLevel `protobuf:"varint,1,opt,name=iso_level,json=isoLevel,proto3,enum=protoqueryservice.IsoLevel" json:"iso_level,omitempty"` // View's isolation level. Defaults to serializable. NonDeferrable bool `protobuf:"varint,2,opt,name=nonDeferrable,proto3" json:"nonDeferrable,omitempty"` // Do not defer errors. Defaults deferrable. TimeoutMilliseconds uint64 `protobuf:"varint,3,opt,name=timeout_milliseconds,json=timeoutMilliseconds,proto3" json:"timeout_milliseconds,omitempty"` // View's timeout. Zero => maximal value // contains filtered or unexported fields }
func (*ViewParameters) Descriptor
deprecated
func (*ViewParameters) Descriptor() ([]byte, []int)
Deprecated: Use ViewParameters.ProtoReflect.Descriptor instead.
func (*ViewParameters) GetIsoLevel ¶
func (x *ViewParameters) GetIsoLevel() IsoLevel
func (*ViewParameters) GetNonDeferrable ¶
func (x *ViewParameters) GetNonDeferrable() bool
func (*ViewParameters) GetTimeoutMilliseconds ¶
func (x *ViewParameters) GetTimeoutMilliseconds() uint64
func (*ViewParameters) ProtoMessage ¶
func (*ViewParameters) ProtoMessage()
func (*ViewParameters) ProtoReflect ¶
func (x *ViewParameters) ProtoReflect() protoreflect.Message
func (*ViewParameters) Reset ¶
func (x *ViewParameters) Reset()
func (*ViewParameters) String ¶
func (x *ViewParameters) String() string