protoqueryservice

package
v0.1.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 10, 2025 License: Apache-2.0 Imports: 10 Imported by: 2

Documentation

Index

Constants

View Source
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

View Source
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.

View Source
var File_api_protoqueryservice_query_proto protoreflect.FileDescriptor
View Source
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
const (
	IsoLevel_Serializable    IsoLevel = 0
	IsoLevel_RepeatableRead  IsoLevel = 1
	IsoLevel_ReadCommitted   IsoLevel = 2
	IsoLevel_ReadUncommitted IsoLevel = 3
)

func (IsoLevel) Descriptor

func (IsoLevel) Descriptor() protoreflect.EnumDescriptor

func (IsoLevel) Enum

func (x IsoLevel) Enum() *IsoLevel

func (IsoLevel) EnumDescriptor deprecated

func (IsoLevel) EnumDescriptor() ([]byte, []int)

Deprecated: Use IsoLevel.Descriptor instead.

func (IsoLevel) Number

func (x IsoLevel) Number() protoreflect.EnumNumber

func (IsoLevel) String

func (x IsoLevel) String() string

func (IsoLevel) Type

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) Descriptor() ([]byte, []int)

Deprecated: Use Query.ProtoReflect.Descriptor instead.

func (*Query) GetNamespaces

func (x *Query) GetNamespaces() []*QueryNamespace

func (*Query) GetView

func (x *Query) GetView() *View

func (*Query) ProtoMessage

func (*Query) ProtoMessage()

func (*Query) ProtoReflect

func (x *Query) ProtoReflect() protoreflect.Message

func (*Query) Reset

func (x *Query) Reset()

func (*Query) String

func (x *Query) String() string

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.

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) Descriptor() ([]byte, []int)

Deprecated: Use Row.ProtoReflect.Descriptor instead.

func (*Row) GetKey

func (x *Row) GetKey() []byte

func (*Row) GetValue

func (x *Row) GetValue() []byte

func (*Row) GetVersion

func (x *Row) GetVersion() uint64

func (*Row) ProtoMessage

func (*Row) ProtoMessage()

func (*Row) ProtoReflect

func (x *Row) ProtoReflect() protoreflect.Message

func (*Row) Reset

func (x *Row) Reset()

func (*Row) String

func (x *Row) String() string

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) Descriptor() ([]byte, []int)

Deprecated: Use Rows.ProtoReflect.Descriptor instead.

func (*Rows) GetNamespaces

func (x *Rows) GetNamespaces() []*RowsNamespace

func (*Rows) ProtoMessage

func (*Rows) ProtoMessage()

func (*Rows) ProtoReflect

func (x *Rows) ProtoReflect() protoreflect.Message

func (*Rows) Reset

func (x *Rows) Reset()

func (*Rows) String

func (x *Rows) String() string

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) EndView

func (UnimplementedQueryServiceServer) GetConfigTransaction

func (UnimplementedQueryServiceServer) GetNamespacePolicies

func (UnimplementedQueryServiceServer) GetRows

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) Descriptor() ([]byte, []int)

Deprecated: Use View.ProtoReflect.Descriptor instead.

func (*View) GetId

func (x *View) GetId() string

func (*View) ProtoMessage

func (*View) ProtoMessage()

func (*View) ProtoReflect

func (x *View) ProtoReflect() protoreflect.Message

func (*View) Reset

func (x *View) Reset()

func (*View) String

func (x *View) String() string

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

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL