tinykvpb

package
v0.0.0-...-b5bbcdc Latest Latest
Warning

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

Go to latest
Published: Oct 4, 2022 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterTinyKvServer

func RegisterTinyKvServer(s *grpc.Server, srv TinyKvServer)

Types

type TinyKvClient

type TinyKvClient interface {
	// KV commands with mvcc/txn supported.
	KvGet(ctx context.Context, in *kvrpcpb.GetRequest, opts ...grpc.CallOption) (*kvrpcpb.GetResponse, error)
	KvScan(ctx context.Context, in *kvrpcpb.ScanRequest, opts ...grpc.CallOption) (*kvrpcpb.ScanResponse, error)
	KvPrewrite(ctx context.Context, in *kvrpcpb.PrewriteRequest, opts ...grpc.CallOption) (*kvrpcpb.PrewriteResponse, error)
	KvCommit(ctx context.Context, in *kvrpcpb.CommitRequest, opts ...grpc.CallOption) (*kvrpcpb.CommitResponse, error)
	KvCheckTxnStatus(ctx context.Context, in *kvrpcpb.CheckTxnStatusRequest, opts ...grpc.CallOption) (*kvrpcpb.CheckTxnStatusResponse, error)
	KvBatchRollback(ctx context.Context, in *kvrpcpb.BatchRollbackRequest, opts ...grpc.CallOption) (*kvrpcpb.BatchRollbackResponse, error)
	KvResolveLock(ctx context.Context, in *kvrpcpb.ResolveLockRequest, opts ...grpc.CallOption) (*kvrpcpb.ResolveLockResponse, error)
	// RawKV commands.
	RawGet(ctx context.Context, in *kvrpcpb.RawGetRequest, opts ...grpc.CallOption) (*kvrpcpb.RawGetResponse, error)
	RawPut(ctx context.Context, in *kvrpcpb.RawPutRequest, opts ...grpc.CallOption) (*kvrpcpb.RawPutResponse, error)
	RawDelete(ctx context.Context, in *kvrpcpb.RawDeleteRequest, opts ...grpc.CallOption) (*kvrpcpb.RawDeleteResponse, error)
	RawScan(ctx context.Context, in *kvrpcpb.RawScanRequest, opts ...grpc.CallOption) (*kvrpcpb.RawScanResponse, error)
	// Raft commands (tinykv <-> tinykv).
	Raft(ctx context.Context, opts ...grpc.CallOption) (TinyKv_RaftClient, error)
	Snapshot(ctx context.Context, opts ...grpc.CallOption) (TinyKv_SnapshotClient, error)
	// Coprocessor
	Coprocessor(ctx context.Context, in *coprocessor.Request, opts ...grpc.CallOption) (*coprocessor.Response, error)
}

TinyKvClient is the client API for TinyKv service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewTinyKvClient

func NewTinyKvClient(cc *grpc.ClientConn) TinyKvClient

type TinyKv_RaftClient

type TinyKv_RaftClient interface {
	Send(*raft_serverpb.RaftMessage) error
	CloseAndRecv() (*raft_serverpb.Done, error)
	grpc.ClientStream
}

type TinyKv_RaftServer

type TinyKv_RaftServer interface {
	SendAndClose(*raft_serverpb.Done) error
	Recv() (*raft_serverpb.RaftMessage, error)
	grpc.ServerStream
}

type TinyKv_SnapshotClient

type TinyKv_SnapshotClient interface {
	Send(*raft_serverpb.SnapshotChunk) error
	CloseAndRecv() (*raft_serverpb.Done, error)
	grpc.ClientStream
}

type TinyKv_SnapshotServer

type TinyKv_SnapshotServer interface {
	SendAndClose(*raft_serverpb.Done) error
	Recv() (*raft_serverpb.SnapshotChunk, error)
	grpc.ServerStream
}

type UnimplementedTinyKvServer

type UnimplementedTinyKvServer struct {
}

UnimplementedTinyKvServer can be embedded to have forward compatible implementations.

func (*UnimplementedTinyKvServer) Coprocessor

func (*UnimplementedTinyKvServer) KvBatchRollback

func (*UnimplementedTinyKvServer) KvCheckTxnStatus

func (*UnimplementedTinyKvServer) KvCommit

func (*UnimplementedTinyKvServer) KvGet

func (*UnimplementedTinyKvServer) KvPrewrite

func (*UnimplementedTinyKvServer) KvResolveLock

func (*UnimplementedTinyKvServer) KvScan

func (*UnimplementedTinyKvServer) Raft

func (*UnimplementedTinyKvServer) RawDelete

func (*UnimplementedTinyKvServer) RawGet

func (*UnimplementedTinyKvServer) RawPut

func (*UnimplementedTinyKvServer) RawScan

func (*UnimplementedTinyKvServer) Snapshot

Jump to

Keyboard shortcuts

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