proto

package
v0.0.0-...-88c50f3 Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2024 License: Apache-2.0 Imports: 10 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	State_name = map[int32]string{
		0: "SOFT_SYNC",
		1: "HARD_SYNC",
		2: "MASTER",
	}
	State_value = map[string]int32{
		"SOFT_SYNC": 0,
		"HARD_SYNC": 1,
		"MASTER":    2,
	}
)

Enum value maps for State.

View Source
var File_server_proto protoreflect.FileDescriptor

Functions

func RegisterKeyStoreServiceServer

func RegisterKeyStoreServiceServer(s grpc.ServiceRegistrar, srv KeyStoreServiceServer)

Types

type DeleteObject

type DeleteObject struct {
	Deletes int64 `protobuf:"varint,1,opt,name=deletes,proto3" json:"deletes,omitempty"`
	// contains filtered or unexported fields
}

func (*DeleteObject) Descriptor deprecated

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

Deprecated: Use DeleteObject.ProtoReflect.Descriptor instead.

func (*DeleteObject) GetDeletes

func (x *DeleteObject) GetDeletes() int64

func (*DeleteObject) ProtoMessage

func (*DeleteObject) ProtoMessage()

func (*DeleteObject) ProtoReflect

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

func (*DeleteObject) Reset

func (x *DeleteObject) Reset()

func (*DeleteObject) String

func (x *DeleteObject) String() string

type DeleteRequest

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

func (*DeleteRequest) Descriptor deprecated

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

Deprecated: Use DeleteRequest.ProtoReflect.Descriptor instead.

func (*DeleteRequest) GetKey

func (x *DeleteRequest) GetKey() string

func (*DeleteRequest) ProtoMessage

func (*DeleteRequest) ProtoMessage()

func (*DeleteRequest) ProtoReflect

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

func (*DeleteRequest) Reset

func (x *DeleteRequest) Reset()

func (*DeleteRequest) String

func (x *DeleteRequest) String() string

type DeleteResponse

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

func (*DeleteResponse) Descriptor deprecated

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

Deprecated: Use DeleteResponse.ProtoReflect.Descriptor instead.

func (*DeleteResponse) ProtoMessage

func (*DeleteResponse) ProtoMessage()

func (*DeleteResponse) ProtoReflect

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

func (*DeleteResponse) Reset

func (x *DeleteResponse) Reset()

func (*DeleteResponse) String

func (x *DeleteResponse) String() string

type Empty

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

func (*Empty) Descriptor deprecated

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

Deprecated: Use Empty.ProtoReflect.Descriptor instead.

func (*Empty) ProtoMessage

func (*Empty) ProtoMessage()

func (*Empty) ProtoReflect

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

func (*Empty) Reset

func (x *Empty) Reset()

func (*Empty) String

func (x *Empty) String() string

type FileMeta

type FileMeta struct {
	Version int64  `protobuf:"varint,1,opt,name=version,proto3" json:"version,omitempty"`
	Key     string `protobuf:"bytes,2,opt,name=key,proto3" json:"key,omitempty"`
	// contains filtered or unexported fields
}

func (*FileMeta) Descriptor deprecated

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

Deprecated: Use FileMeta.ProtoReflect.Descriptor instead.

func (*FileMeta) GetKey

func (x *FileMeta) GetKey() string

func (*FileMeta) GetVersion

func (x *FileMeta) GetVersion() int64

func (*FileMeta) ProtoMessage

func (*FileMeta) ProtoMessage()

func (*FileMeta) ProtoReflect

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

func (*FileMeta) Reset

func (x *FileMeta) Reset()

func (*FileMeta) String

func (x *FileMeta) String() string

type GetDirectoryRequest

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

func (*GetDirectoryRequest) Descriptor deprecated

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

Deprecated: Use GetDirectoryRequest.ProtoReflect.Descriptor instead.

func (*GetDirectoryRequest) ProtoMessage

func (*GetDirectoryRequest) ProtoMessage()

func (*GetDirectoryRequest) ProtoReflect

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

func (*GetDirectoryRequest) Reset

func (x *GetDirectoryRequest) Reset()

func (*GetDirectoryRequest) String

func (x *GetDirectoryRequest) String() string

type GetDirectoryResponse

type GetDirectoryResponse struct {
	Keys    []*FileMeta `protobuf:"bytes,1,rep,name=keys,proto3" json:"keys,omitempty"`
	Version int64       `protobuf:"varint,2,opt,name=version,proto3" json:"version,omitempty"`
	// contains filtered or unexported fields
}

func (*GetDirectoryResponse) Descriptor deprecated

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

Deprecated: Use GetDirectoryResponse.ProtoReflect.Descriptor instead.

func (*GetDirectoryResponse) GetKeys

func (x *GetDirectoryResponse) GetKeys() []*FileMeta

func (*GetDirectoryResponse) GetVersion

func (x *GetDirectoryResponse) GetVersion() int64

func (*GetDirectoryResponse) ProtoMessage

func (*GetDirectoryResponse) ProtoMessage()

func (*GetDirectoryResponse) ProtoReflect

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

func (*GetDirectoryResponse) Reset

func (x *GetDirectoryResponse) Reset()

func (*GetDirectoryResponse) String

func (x *GetDirectoryResponse) String() string

type KeyStoreServiceClient

type KeyStoreServiceClient interface {
	Save(ctx context.Context, in *SaveRequest, opts ...grpc.CallOption) (*Empty, error)
	Read(ctx context.Context, in *ReadRequest, opts ...grpc.CallOption) (*ReadResponse, error)
	GetMeta(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*StoreMeta, error)
	GetDirectory(ctx context.Context, in *GetDirectoryRequest, opts ...grpc.CallOption) (*GetDirectoryResponse, error)
	Delete(ctx context.Context, in *DeleteRequest, opts ...grpc.CallOption) (*DeleteResponse, error)
}

KeyStoreServiceClient is the client API for KeyStoreService 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 KeyStoreServiceServer

KeyStoreServiceServer is the server API for KeyStoreService service. All implementations should embed UnimplementedKeyStoreServiceServer for forward compatibility

type ReadRequest

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

func (*ReadRequest) Descriptor deprecated

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

Deprecated: Use ReadRequest.ProtoReflect.Descriptor instead.

func (*ReadRequest) GetKey

func (x *ReadRequest) GetKey() string

func (*ReadRequest) ProtoMessage

func (*ReadRequest) ProtoMessage()

func (*ReadRequest) ProtoReflect

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

func (*ReadRequest) Reset

func (x *ReadRequest) Reset()

func (*ReadRequest) String

func (x *ReadRequest) String() string

type ReadResponse

type ReadResponse struct {
	Payload  *any.Any `protobuf:"bytes,1,opt,name=payload,proto3" json:"payload,omitempty"`
	ReadTime int64    `protobuf:"varint,2,opt,name=read_time,json=readTime,proto3" json:"read_time,omitempty"`
	// contains filtered or unexported fields
}

func (*ReadResponse) Descriptor deprecated

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

Deprecated: Use ReadResponse.ProtoReflect.Descriptor instead.

func (*ReadResponse) GetPayload

func (x *ReadResponse) GetPayload() *any.Any

func (*ReadResponse) GetReadTime

func (x *ReadResponse) GetReadTime() int64

func (*ReadResponse) ProtoMessage

func (*ReadResponse) ProtoMessage()

func (*ReadResponse) ProtoReflect

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

func (*ReadResponse) Reset

func (x *ReadResponse) Reset()

func (*ReadResponse) String

func (x *ReadResponse) String() string

type SaveRequest

type SaveRequest struct {
	Key          string     `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	Value        *any.Any   `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
	WriteVersion int64      `protobuf:"varint,3,opt,name=write_version,json=writeVersion,proto3" json:"write_version,omitempty"`
	Meta         *StoreMeta `protobuf:"bytes,4,opt,name=meta,proto3" json:"meta,omitempty"`
	Origin       string     `protobuf:"bytes,5,opt,name=origin,proto3" json:"origin,omitempty"`
	// contains filtered or unexported fields
}

func (*SaveRequest) Descriptor deprecated

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

Deprecated: Use SaveRequest.ProtoReflect.Descriptor instead.

func (*SaveRequest) GetKey

func (x *SaveRequest) GetKey() string

func (*SaveRequest) GetMeta

func (x *SaveRequest) GetMeta() *StoreMeta

func (*SaveRequest) GetOrigin

func (x *SaveRequest) GetOrigin() string

func (*SaveRequest) GetValue

func (x *SaveRequest) GetValue() *any.Any

func (*SaveRequest) GetWriteVersion

func (x *SaveRequest) GetWriteVersion() int64

func (*SaveRequest) ProtoMessage

func (*SaveRequest) ProtoMessage()

func (*SaveRequest) ProtoReflect

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

func (*SaveRequest) Reset

func (x *SaveRequest) Reset()

func (*SaveRequest) String

func (x *SaveRequest) String() string

type State

type State int32
const (
	State_SOFT_SYNC State = 0
	State_HARD_SYNC State = 1
	State_MASTER    State = 2
)

func (State) Descriptor

func (State) Descriptor() protoreflect.EnumDescriptor

func (State) Enum

func (x State) Enum() *State

func (State) EnumDescriptor deprecated

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

Deprecated: Use State.Descriptor instead.

func (State) Number

func (x State) Number() protoreflect.EnumNumber

func (State) String

func (x State) String() string

func (State) Type

func (State) Type() protoreflect.EnumType

type StoreMeta

type StoreMeta struct {
	Version     int64    `protobuf:"varint,1,opt,name=version,proto3" json:"version,omitempty"`
	DeletedKeys []string `protobuf:"bytes,2,rep,name=deleted_keys,json=deletedKeys,proto3" json:"deleted_keys,omitempty"`
	// contains filtered or unexported fields
}

func (*StoreMeta) Descriptor deprecated

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

Deprecated: Use StoreMeta.ProtoReflect.Descriptor instead.

func (*StoreMeta) GetDeletedKeys

func (x *StoreMeta) GetDeletedKeys() []string

func (*StoreMeta) GetVersion

func (x *StoreMeta) GetVersion() int64

func (*StoreMeta) ProtoMessage

func (*StoreMeta) ProtoMessage()

func (*StoreMeta) ProtoReflect

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

func (*StoreMeta) Reset

func (x *StoreMeta) Reset()

func (*StoreMeta) String

func (x *StoreMeta) String() string

type UnimplementedKeyStoreServiceServer

type UnimplementedKeyStoreServiceServer struct {
}

UnimplementedKeyStoreServiceServer should be embedded to have forward compatible implementations.

func (UnimplementedKeyStoreServiceServer) Delete

func (UnimplementedKeyStoreServiceServer) GetDirectory

func (UnimplementedKeyStoreServiceServer) GetMeta

func (UnimplementedKeyStoreServiceServer) Read

func (UnimplementedKeyStoreServiceServer) Save

type UnsafeKeyStoreServiceServer

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

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

Jump to

Keyboard shortcuts

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