keyvalpb

package
v0.0.0-...-6611992 Latest Latest
Warning

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

Go to latest
Published: May 8, 2022 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_proto_keyval_proto protoreflect.FileDescriptor
View Source
var KeyValueService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "apidefinitions.keyval.KeyValueService",
	HandlerType: (*KeyValueServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "HasValue",
			Handler:    _KeyValueService_HasValue_Handler,
		},
		{
			MethodName: "GetValue",
			Handler:    _KeyValueService_GetValue_Handler,
		},
		{
			MethodName: "SetValue",
			Handler:    _KeyValueService_SetValue_Handler,
		},
	},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "Transact",
			Handler:       _KeyValueService_Transact_Handler,
			ServerStreams: true,
			ClientStreams: true,
		},
	},
	Metadata: "proto/keyval.proto",
}

KeyValueService_ServiceDesc is the grpc.ServiceDesc for KeyValueService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterKeyValueServiceServer

func RegisterKeyValueServiceServer(s grpc.ServiceRegistrar, srv KeyValueServiceServer)

Types

type GetValueRequest

type GetValueRequest struct {
	Key *Key `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	// contains filtered or unexported fields
}

func (*GetValueRequest) Descriptor deprecated

func (*GetValueRequest) Descriptor() ([]byte, []int)

Deprecated: Use GetValueRequest.ProtoReflect.Descriptor instead.

func (*GetValueRequest) GetKey

func (x *GetValueRequest) GetKey() *Key

func (*GetValueRequest) ProtoMessage

func (*GetValueRequest) ProtoMessage()

func (*GetValueRequest) ProtoReflect

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

func (*GetValueRequest) Reset

func (x *GetValueRequest) Reset()

func (*GetValueRequest) String

func (x *GetValueRequest) String() string

type HasValueRequest

type HasValueRequest struct {
	Key *Key `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	// contains filtered or unexported fields
}

func (*HasValueRequest) Descriptor deprecated

func (*HasValueRequest) Descriptor() ([]byte, []int)

Deprecated: Use HasValueRequest.ProtoReflect.Descriptor instead.

func (*HasValueRequest) GetKey

func (x *HasValueRequest) GetKey() *Key

func (*HasValueRequest) ProtoMessage

func (*HasValueRequest) ProtoMessage()

func (*HasValueRequest) ProtoReflect

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

func (*HasValueRequest) Reset

func (x *HasValueRequest) Reset()

func (*HasValueRequest) String

func (x *HasValueRequest) String() string

type HasValueResponse

type HasValueResponse struct {
	EntryExists bool `protobuf:"varint,1,opt,name=entry_exists,json=entryExists,proto3" json:"entry_exists,omitempty"`
	// contains filtered or unexported fields
}

func (*HasValueResponse) Descriptor deprecated

func (*HasValueResponse) Descriptor() ([]byte, []int)

Deprecated: Use HasValueResponse.ProtoReflect.Descriptor instead.

func (*HasValueResponse) GetEntryExists

func (x *HasValueResponse) GetEntryExists() bool

func (*HasValueResponse) ProtoMessage

func (*HasValueResponse) ProtoMessage()

func (*HasValueResponse) ProtoReflect

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

func (*HasValueResponse) Reset

func (x *HasValueResponse) Reset()

func (*HasValueResponse) String

func (x *HasValueResponse) String() string

type Key

type Key struct {
	KeyBytes []byte `protobuf:"bytes,1,opt,name=key_bytes,json=keyBytes,proto3" json:"key_bytes,omitempty"`
	// contains filtered or unexported fields
}

func (*Key) Descriptor deprecated

func (*Key) Descriptor() ([]byte, []int)

Deprecated: Use Key.ProtoReflect.Descriptor instead.

func (*Key) GetKeyBytes

func (x *Key) GetKeyBytes() []byte

func (*Key) ProtoMessage

func (*Key) ProtoMessage()

func (*Key) ProtoReflect

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

func (*Key) Reset

func (x *Key) Reset()

func (*Key) String

func (x *Key) String() string

type KeyValueServiceClient

type KeyValueServiceClient interface {
	HasValue(ctx context.Context, in *HasValueRequest, opts ...grpc.CallOption) (*HasValueResponse, error)
	GetValue(ctx context.Context, in *GetValueRequest, opts ...grpc.CallOption) (*Value, error)
	SetValue(ctx context.Context, in *SetValueRequest, opts ...grpc.CallOption) (*SetValueResponse, error)
	Transact(ctx context.Context, opts ...grpc.CallOption) (KeyValueService_TransactClient, error)
}

KeyValueServiceClient is the client API for KeyValueService 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 KeyValueServiceServer

type KeyValueServiceServer interface {
	HasValue(context.Context, *HasValueRequest) (*HasValueResponse, error)
	GetValue(context.Context, *GetValueRequest) (*Value, error)
	SetValue(context.Context, *SetValueRequest) (*SetValueResponse, error)
	Transact(KeyValueService_TransactServer) error
	// contains filtered or unexported methods
}

KeyValueServiceServer is the server API for KeyValueService service. All implementations must embed UnimplementedKeyValueServiceServer for forward compatibility

type KeyValueService_TransactClient

type KeyValueService_TransactClient interface {
	Send(*TransactRequest) error
	Recv() (*TransactResponse, error)
	grpc.ClientStream
}

type KeyValueService_TransactServer

type KeyValueService_TransactServer interface {
	Send(*TransactResponse) error
	Recv() (*TransactRequest, error)
	grpc.ServerStream
}

type SetValueRequest

type SetValueRequest struct {
	Key          *Key   `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	Value        *Value `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
	DatabaseName string `protobuf:"bytes,3,opt,name=database_name,json=databaseName,proto3" json:"database_name,omitempty"`
	Overwrite    *bool  `protobuf:"varint,4,opt,name=overwrite,proto3,oneof" json:"overwrite,omitempty"`
	// contains filtered or unexported fields
}

func (*SetValueRequest) Descriptor deprecated

func (*SetValueRequest) Descriptor() ([]byte, []int)

Deprecated: Use SetValueRequest.ProtoReflect.Descriptor instead.

func (*SetValueRequest) GetDatabaseName

func (x *SetValueRequest) GetDatabaseName() string

func (*SetValueRequest) GetKey

func (x *SetValueRequest) GetKey() *Key

func (*SetValueRequest) GetOverwrite

func (x *SetValueRequest) GetOverwrite() bool

func (*SetValueRequest) GetValue

func (x *SetValueRequest) GetValue() *Value

func (*SetValueRequest) ProtoMessage

func (*SetValueRequest) ProtoMessage()

func (*SetValueRequest) ProtoReflect

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

func (*SetValueRequest) Reset

func (x *SetValueRequest) Reset()

func (*SetValueRequest) String

func (x *SetValueRequest) String() string

type SetValueResponse

type SetValueResponse struct {
	// contains filtered or unexported fields
}

func (*SetValueResponse) Descriptor deprecated

func (*SetValueResponse) Descriptor() ([]byte, []int)

Deprecated: Use SetValueResponse.ProtoReflect.Descriptor instead.

func (*SetValueResponse) ProtoMessage

func (*SetValueResponse) ProtoMessage()

func (*SetValueResponse) ProtoReflect

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

func (*SetValueResponse) Reset

func (x *SetValueResponse) Reset()

func (*SetValueResponse) String

func (x *SetValueResponse) String() string

type TransactRequest

type TransactRequest struct {
	RequestId string `protobuf:"bytes,1,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"`
	// Types that are assignable to Action:
	//	*TransactRequest_GetValueRequest
	//	*TransactRequest_HasValueRequest
	//	*TransactRequest_SetValueRequest
	//	*TransactRequest_CommitRequest_
	//	*TransactRequest_AbortRequest_
	Action isTransactRequest_Action `protobuf_oneof:"action"`
	// contains filtered or unexported fields
}

func (*TransactRequest) Descriptor deprecated

func (*TransactRequest) Descriptor() ([]byte, []int)

Deprecated: Use TransactRequest.ProtoReflect.Descriptor instead.

func (*TransactRequest) GetAbortRequest

func (x *TransactRequest) GetAbortRequest() *TransactRequest_AbortRequest

func (*TransactRequest) GetAction

func (m *TransactRequest) GetAction() isTransactRequest_Action

func (*TransactRequest) GetCommitRequest

func (x *TransactRequest) GetCommitRequest() *TransactRequest_CommitRequest

func (*TransactRequest) GetGetValueRequest

func (x *TransactRequest) GetGetValueRequest() *GetValueRequest

func (*TransactRequest) GetHasValueRequest

func (x *TransactRequest) GetHasValueRequest() *HasValueRequest

func (*TransactRequest) GetRequestId

func (x *TransactRequest) GetRequestId() string

func (*TransactRequest) GetSetValueRequest

func (x *TransactRequest) GetSetValueRequest() *SetValueRequest

func (*TransactRequest) ProtoMessage

func (*TransactRequest) ProtoMessage()

func (*TransactRequest) ProtoReflect

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

func (*TransactRequest) Reset

func (x *TransactRequest) Reset()

func (*TransactRequest) String

func (x *TransactRequest) String() string

type TransactRequest_AbortRequest

type TransactRequest_AbortRequest struct {
	// contains filtered or unexported fields
}

func (*TransactRequest_AbortRequest) Descriptor deprecated

func (*TransactRequest_AbortRequest) Descriptor() ([]byte, []int)

Deprecated: Use TransactRequest_AbortRequest.ProtoReflect.Descriptor instead.

func (*TransactRequest_AbortRequest) ProtoMessage

func (*TransactRequest_AbortRequest) ProtoMessage()

func (*TransactRequest_AbortRequest) ProtoReflect

func (*TransactRequest_AbortRequest) Reset

func (x *TransactRequest_AbortRequest) Reset()

func (*TransactRequest_AbortRequest) String

type TransactRequest_AbortRequest_

type TransactRequest_AbortRequest_ struct {
	AbortRequest *TransactRequest_AbortRequest `protobuf:"bytes,6,opt,name=abort_request,json=abortRequest,proto3,oneof"`
}

type TransactRequest_CommitRequest

type TransactRequest_CommitRequest struct {
	// contains filtered or unexported fields
}

func (*TransactRequest_CommitRequest) Descriptor deprecated

func (*TransactRequest_CommitRequest) Descriptor() ([]byte, []int)

Deprecated: Use TransactRequest_CommitRequest.ProtoReflect.Descriptor instead.

func (*TransactRequest_CommitRequest) ProtoMessage

func (*TransactRequest_CommitRequest) ProtoMessage()

func (*TransactRequest_CommitRequest) ProtoReflect

func (*TransactRequest_CommitRequest) Reset

func (x *TransactRequest_CommitRequest) Reset()

func (*TransactRequest_CommitRequest) String

type TransactRequest_CommitRequest_

type TransactRequest_CommitRequest_ struct {
	CommitRequest *TransactRequest_CommitRequest `protobuf:"bytes,5,opt,name=commit_request,json=commitRequest,proto3,oneof"`
}

type TransactRequest_GetValueRequest

type TransactRequest_GetValueRequest struct {
	GetValueRequest *GetValueRequest `protobuf:"bytes,2,opt,name=get_value_request,json=getValueRequest,proto3,oneof"`
}

type TransactRequest_HasValueRequest

type TransactRequest_HasValueRequest struct {
	HasValueRequest *HasValueRequest `protobuf:"bytes,3,opt,name=has_value_request,json=hasValueRequest,proto3,oneof"`
}

type TransactRequest_SetValueRequest

type TransactRequest_SetValueRequest struct {
	SetValueRequest *SetValueRequest `protobuf:"bytes,4,opt,name=set_value_request,json=setValueRequest,proto3,oneof"`
}

type TransactResponse

type TransactResponse struct {
	RequestId string `protobuf:"bytes,1,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"`
	// Types that are assignable to Response:
	//	*TransactResponse_GetValueResponse
	//	*TransactResponse_HasValueResponse
	//	*TransactResponse_SetValueResponse
	//	*TransactResponse_CommitResponse_
	//	*TransactResponse_AbortResponse_
	Response isTransactResponse_Response `protobuf_oneof:"response"`
	// contains filtered or unexported fields
}

func (*TransactResponse) Descriptor deprecated

func (*TransactResponse) Descriptor() ([]byte, []int)

Deprecated: Use TransactResponse.ProtoReflect.Descriptor instead.

func (*TransactResponse) GetAbortResponse

func (x *TransactResponse) GetAbortResponse() *TransactResponse_AbortResponse

func (*TransactResponse) GetCommitResponse

func (x *TransactResponse) GetCommitResponse() *TransactResponse_CommitResponse

func (*TransactResponse) GetGetValueResponse

func (x *TransactResponse) GetGetValueResponse() *Value

func (*TransactResponse) GetHasValueResponse

func (x *TransactResponse) GetHasValueResponse() *HasValueResponse

func (*TransactResponse) GetRequestId

func (x *TransactResponse) GetRequestId() string

func (*TransactResponse) GetResponse

func (m *TransactResponse) GetResponse() isTransactResponse_Response

func (*TransactResponse) GetSetValueResponse

func (x *TransactResponse) GetSetValueResponse() *SetValueResponse

func (*TransactResponse) ProtoMessage

func (*TransactResponse) ProtoMessage()

func (*TransactResponse) ProtoReflect

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

func (*TransactResponse) Reset

func (x *TransactResponse) Reset()

func (*TransactResponse) String

func (x *TransactResponse) String() string

type TransactResponse_AbortResponse

type TransactResponse_AbortResponse struct {
	// contains filtered or unexported fields
}

func (*TransactResponse_AbortResponse) Descriptor deprecated

func (*TransactResponse_AbortResponse) Descriptor() ([]byte, []int)

Deprecated: Use TransactResponse_AbortResponse.ProtoReflect.Descriptor instead.

func (*TransactResponse_AbortResponse) ProtoMessage

func (*TransactResponse_AbortResponse) ProtoMessage()

func (*TransactResponse_AbortResponse) ProtoReflect

func (*TransactResponse_AbortResponse) Reset

func (x *TransactResponse_AbortResponse) Reset()

func (*TransactResponse_AbortResponse) String

type TransactResponse_AbortResponse_

type TransactResponse_AbortResponse_ struct {
	AbortResponse *TransactResponse_AbortResponse `protobuf:"bytes,6,opt,name=abort_response,json=abortResponse,proto3,oneof"`
}

type TransactResponse_CommitResponse

type TransactResponse_CommitResponse struct {
	// contains filtered or unexported fields
}

func (*TransactResponse_CommitResponse) Descriptor deprecated

func (*TransactResponse_CommitResponse) Descriptor() ([]byte, []int)

Deprecated: Use TransactResponse_CommitResponse.ProtoReflect.Descriptor instead.

func (*TransactResponse_CommitResponse) ProtoMessage

func (*TransactResponse_CommitResponse) ProtoMessage()

func (*TransactResponse_CommitResponse) ProtoReflect

func (*TransactResponse_CommitResponse) Reset

func (*TransactResponse_CommitResponse) String

type TransactResponse_CommitResponse_

type TransactResponse_CommitResponse_ struct {
	CommitResponse *TransactResponse_CommitResponse `protobuf:"bytes,5,opt,name=commit_response,json=commitResponse,proto3,oneof"`
}

type TransactResponse_GetValueResponse

type TransactResponse_GetValueResponse struct {
	GetValueResponse *Value `protobuf:"bytes,2,opt,name=get_value_response,json=getValueResponse,proto3,oneof"`
}

type TransactResponse_HasValueResponse

type TransactResponse_HasValueResponse struct {
	HasValueResponse *HasValueResponse `protobuf:"bytes,3,opt,name=has_value_response,json=hasValueResponse,proto3,oneof"`
}

type TransactResponse_SetValueResponse

type TransactResponse_SetValueResponse struct {
	SetValueResponse *SetValueResponse `protobuf:"bytes,4,opt,name=set_value_response,json=setValueResponse,proto3,oneof"`
}

type UnimplementedKeyValueServiceServer

type UnimplementedKeyValueServiceServer struct {
}

UnimplementedKeyValueServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedKeyValueServiceServer) GetValue

func (UnimplementedKeyValueServiceServer) HasValue

func (UnimplementedKeyValueServiceServer) SetValue

func (UnimplementedKeyValueServiceServer) Transact

type UnsafeKeyValueServiceServer

type UnsafeKeyValueServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeKeyValueServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to KeyValueServiceServer will result in compilation errors.

type Value

type Value struct {
	ValueBytes []byte `protobuf:"bytes,1,opt,name=value_bytes,json=valueBytes,proto3" json:"value_bytes,omitempty"`
	// contains filtered or unexported fields
}

func (*Value) Descriptor deprecated

func (*Value) Descriptor() ([]byte, []int)

Deprecated: Use Value.ProtoReflect.Descriptor instead.

func (*Value) GetValueBytes

func (x *Value) GetValueBytes() []byte

func (*Value) ProtoMessage

func (*Value) ProtoMessage()

func (*Value) ProtoReflect

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

func (*Value) Reset

func (x *Value) Reset()

func (*Value) String

func (x *Value) String() string

Jump to

Keyboard shortcuts

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