feat: update client to new v0.1.1
This commit is contained in:
104
client.go
104
client.go
@@ -154,6 +154,36 @@ func (c *Client) DeleteFile(ctx context.Context, logicalPath string) error {
|
|||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (c *Client) MoveFile(
|
||||||
|
ctx context.Context,
|
||||||
|
sourcePath string,
|
||||||
|
destinationPath string,
|
||||||
|
) error {
|
||||||
|
_, err := c.rpc.MoveFile(ctx, &zwdaemonv1.MoveFileRequest{
|
||||||
|
SourcePath: sourcePath,
|
||||||
|
DestinationPath: destinationPath,
|
||||||
|
})
|
||||||
|
if err != nil {
|
||||||
|
return convertRPCError(err)
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (c *Client) CopyFile(
|
||||||
|
ctx context.Context,
|
||||||
|
sourcePath string,
|
||||||
|
destinationPath string,
|
||||||
|
) error {
|
||||||
|
_, err := c.rpc.CopyFile(ctx, &zwdaemonv1.CopyFileRequest{
|
||||||
|
SourcePath: sourcePath,
|
||||||
|
DestinationPath: destinationPath,
|
||||||
|
})
|
||||||
|
if err != nil {
|
||||||
|
return convertRPCError(err)
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
func (c *Client) Compact(ctx context.Context) error {
|
func (c *Client) Compact(ctx context.Context) error {
|
||||||
_, err := c.rpc.Compact(ctx, &zwdaemonv1.CompactRequest{})
|
_, err := c.rpc.Compact(ctx, &zwdaemonv1.CompactRequest{})
|
||||||
if err != nil {
|
if err != nil {
|
||||||
@@ -291,3 +321,77 @@ func (c *Client) AddFile(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (c *Client) ReplaceFile(
|
||||||
|
ctx context.Context,
|
||||||
|
logicalPath string,
|
||||||
|
source io.Reader,
|
||||||
|
sourceLen uint64,
|
||||||
|
) error {
|
||||||
|
uploadCtx, cancel := context.WithCancel(ctx)
|
||||||
|
defer cancel()
|
||||||
|
|
||||||
|
stream, err := c.rpc.ReplaceFile(uploadCtx)
|
||||||
|
if err != nil {
|
||||||
|
return convertRPCError(err)
|
||||||
|
}
|
||||||
|
|
||||||
|
send := func(request *zwdaemonv1.ReplaceFileRequest) error {
|
||||||
|
err := stream.Send(request)
|
||||||
|
if err == nil {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
if errors.Is(err, io.EOF) {
|
||||||
|
_, receiveErr := stream.CloseAndRecv()
|
||||||
|
if receiveErr != nil {
|
||||||
|
return convertRPCError(receiveErr)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return convertRPCError(err)
|
||||||
|
}
|
||||||
|
|
||||||
|
err = send(&zwdaemonv1.ReplaceFileRequest{
|
||||||
|
Payload: &zwdaemonv1.ReplaceFileRequest_Header{
|
||||||
|
Header: &zwdaemonv1.ReplaceFileHeader{
|
||||||
|
LogicalPath: logicalPath,
|
||||||
|
SourceLen: sourceLen,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
})
|
||||||
|
if err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
|
||||||
|
const chunkSize = 512 * 1024
|
||||||
|
buffer := make([]byte, chunkSize)
|
||||||
|
|
||||||
|
for {
|
||||||
|
n, readErr := source.Read(buffer)
|
||||||
|
|
||||||
|
if n > 0 {
|
||||||
|
err := send(&zwdaemonv1.ReplaceFileRequest{
|
||||||
|
Payload: &zwdaemonv1.ReplaceFileRequest_Chunk{
|
||||||
|
Chunk: buffer[:n],
|
||||||
|
},
|
||||||
|
})
|
||||||
|
if err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
switch {
|
||||||
|
case readErr == nil:
|
||||||
|
continue
|
||||||
|
case errors.Is(readErr, io.EOF):
|
||||||
|
_, err := stream.CloseAndRecv()
|
||||||
|
if err != nil {
|
||||||
|
return convertRPCError(err)
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
default:
|
||||||
|
return &UploadReadError{Err: readErr}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
129
client_test.go
129
client_test.go
@@ -42,12 +42,17 @@ type testService struct {
|
|||||||
|
|
||||||
deleteFileRequests chan *zwdaemonv1.DeleteFileRequest
|
deleteFileRequests chan *zwdaemonv1.DeleteFileRequest
|
||||||
deleteFileErr error
|
deleteFileErr error
|
||||||
|
moveFileRequests chan *zwdaemonv1.MoveFileRequest
|
||||||
|
moveFileErr error
|
||||||
|
copyFileRequests chan *zwdaemonv1.CopyFileRequest
|
||||||
|
copyFileErr error
|
||||||
compactCalls chan struct{}
|
compactCalls chan struct{}
|
||||||
compactErr error
|
compactErr error
|
||||||
|
|
||||||
getFile func(*zwdaemonv1.GetFileRequest, grpc.ServerStreamingServer[zwdaemonv1.GetFileResponse]) error
|
getFile func(*zwdaemonv1.GetFileRequest, grpc.ServerStreamingServer[zwdaemonv1.GetFileResponse]) error
|
||||||
getFileRange func(*zwdaemonv1.GetFileRangeRequest, grpc.ServerStreamingServer[zwdaemonv1.GetFileRangeResponse]) error
|
getFileRange func(*zwdaemonv1.GetFileRangeRequest, grpc.ServerStreamingServer[zwdaemonv1.GetFileRangeResponse]) error
|
||||||
addFile func(grpc.ClientStreamingServer[zwdaemonv1.AddFileRequest, zwdaemonv1.AddFileResponse]) error
|
addFile func(grpc.ClientStreamingServer[zwdaemonv1.AddFileRequest, zwdaemonv1.AddFileResponse]) error
|
||||||
|
replaceFile func(grpc.ClientStreamingServer[zwdaemonv1.ReplaceFileRequest, zwdaemonv1.ReplaceFileResponse]) error
|
||||||
}
|
}
|
||||||
|
|
||||||
func (s *testService) GetServerInfo(
|
func (s *testService) GetServerInfo(
|
||||||
@@ -120,6 +125,26 @@ func (s *testService) Compact(
|
|||||||
return &zwdaemonv1.CompactResponse{}, s.compactErr
|
return &zwdaemonv1.CompactResponse{}, s.compactErr
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (s *testService) MoveFile(
|
||||||
|
_ context.Context,
|
||||||
|
request *zwdaemonv1.MoveFileRequest,
|
||||||
|
) (*zwdaemonv1.MoveFileResponse, error) {
|
||||||
|
if s.moveFileRequests != nil {
|
||||||
|
s.moveFileRequests <- request
|
||||||
|
}
|
||||||
|
return &zwdaemonv1.MoveFileResponse{}, s.moveFileErr
|
||||||
|
}
|
||||||
|
|
||||||
|
func (s *testService) CopyFile(
|
||||||
|
_ context.Context,
|
||||||
|
request *zwdaemonv1.CopyFileRequest,
|
||||||
|
) (*zwdaemonv1.CopyFileResponse, error) {
|
||||||
|
if s.copyFileRequests != nil {
|
||||||
|
s.copyFileRequests <- request
|
||||||
|
}
|
||||||
|
return &zwdaemonv1.CopyFileResponse{}, s.copyFileErr
|
||||||
|
}
|
||||||
|
|
||||||
func (s *testService) GetFile(
|
func (s *testService) GetFile(
|
||||||
request *zwdaemonv1.GetFileRequest,
|
request *zwdaemonv1.GetFileRequest,
|
||||||
stream grpc.ServerStreamingServer[zwdaemonv1.GetFileResponse],
|
stream grpc.ServerStreamingServer[zwdaemonv1.GetFileResponse],
|
||||||
@@ -149,6 +174,15 @@ func (s *testService) AddFile(
|
|||||||
return s.addFile(stream)
|
return s.addFile(stream)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (s *testService) ReplaceFile(
|
||||||
|
stream grpc.ClientStreamingServer[zwdaemonv1.ReplaceFileRequest, zwdaemonv1.ReplaceFileResponse],
|
||||||
|
) error {
|
||||||
|
if s.replaceFile == nil {
|
||||||
|
return stream.SendAndClose(&zwdaemonv1.ReplaceFileResponse{})
|
||||||
|
}
|
||||||
|
return s.replaceFile(stream)
|
||||||
|
}
|
||||||
|
|
||||||
func startTestServer(t *testing.T, service *testService) string {
|
func startTestServer(t *testing.T, service *testService) string {
|
||||||
t.Helper()
|
t.Helper()
|
||||||
|
|
||||||
@@ -536,6 +570,32 @@ func TestDeleteFileMapsRequestAndStructuredError(t *testing.T) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func TestMoveAndCopyFileMapRequests(t *testing.T) {
|
||||||
|
service := &testService{
|
||||||
|
moveFileRequests: make(chan *zwdaemonv1.MoveFileRequest, 1),
|
||||||
|
copyFileRequests: make(chan *zwdaemonv1.CopyFileRequest, 1),
|
||||||
|
}
|
||||||
|
client := startConnectedTestClient(t, service)
|
||||||
|
ctx, cancel := context.WithTimeout(context.Background(), 5*time.Second)
|
||||||
|
defer cancel()
|
||||||
|
|
||||||
|
if err := client.MoveFile(ctx, "source.txt", "renamed.txt"); err != nil {
|
||||||
|
t.Fatalf("MoveFile() error = %v", err)
|
||||||
|
}
|
||||||
|
moveRequest := <-service.moveFileRequests
|
||||||
|
if moveRequest.GetSourcePath() != "source.txt" || moveRequest.GetDestinationPath() != "renamed.txt" {
|
||||||
|
t.Errorf("MoveFile request = %#v", moveRequest)
|
||||||
|
}
|
||||||
|
|
||||||
|
if err := client.CopyFile(ctx, "source.txt", "copy.txt"); err != nil {
|
||||||
|
t.Fatalf("CopyFile() error = %v", err)
|
||||||
|
}
|
||||||
|
copyRequest := <-service.copyFileRequests
|
||||||
|
if copyRequest.GetSourcePath() != "source.txt" || copyRequest.GetDestinationPath() != "copy.txt" {
|
||||||
|
t.Errorf("CopyFile request = %#v", copyRequest)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
func TestConvertRPCErrorAcceptsNil(t *testing.T) {
|
func TestConvertRPCErrorAcceptsNil(t *testing.T) {
|
||||||
if err := convertRPCError(nil); err != nil {
|
if err := convertRPCError(nil); err != nil {
|
||||||
t.Fatalf("convertRPCError(nil) = %v", err)
|
t.Fatalf("convertRPCError(nil) = %v", err)
|
||||||
@@ -827,6 +887,41 @@ func TestAddFileProcessesDataReturnedWithEOF(t *testing.T) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func TestReplaceFileSendsHeaderAndChunks(t *testing.T) {
|
||||||
|
received := make(chan receivedReplaceUpload, 1)
|
||||||
|
service := &testService{
|
||||||
|
replaceFile: func(
|
||||||
|
stream grpc.ClientStreamingServer[zwdaemonv1.ReplaceFileRequest, zwdaemonv1.ReplaceFileResponse],
|
||||||
|
) error {
|
||||||
|
upload, err := receiveReplaceUpload(stream)
|
||||||
|
if err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
received <- upload
|
||||||
|
return stream.SendAndClose(&zwdaemonv1.ReplaceFileResponse{})
|
||||||
|
},
|
||||||
|
}
|
||||||
|
client := startConnectedTestClient(t, service)
|
||||||
|
ctx, cancel := context.WithTimeout(context.Background(), 5*time.Second)
|
||||||
|
defer cancel()
|
||||||
|
|
||||||
|
contents := []byte("replacement contents")
|
||||||
|
if err := client.ReplaceFile(ctx, "existing.bin", bytes.NewReader(contents), uint64(len(contents))); err != nil {
|
||||||
|
t.Fatalf("ReplaceFile() error = %v", err)
|
||||||
|
}
|
||||||
|
|
||||||
|
upload := <-received
|
||||||
|
if upload.header.GetLogicalPath() != "existing.bin" {
|
||||||
|
t.Errorf("logical path = %q", upload.header.GetLogicalPath())
|
||||||
|
}
|
||||||
|
if upload.header.GetSourceLen() != uint64(len(contents)) {
|
||||||
|
t.Errorf("source length = %d", upload.header.GetSourceLen())
|
||||||
|
}
|
||||||
|
if !bytes.Equal(upload.contents, contents) {
|
||||||
|
t.Errorf("replacement contents differ")
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
func TestAddFileReturnsLengthRejectionFromCloseAndRecv(t *testing.T) {
|
func TestAddFileReturnsLengthRejectionFromCloseAndRecv(t *testing.T) {
|
||||||
serverStatus, err := status.New(codes.InvalidArgument, "declared length does not match source").WithDetails(
|
serverStatus, err := status.New(codes.InvalidArgument, "declared length does not match source").WithDetails(
|
||||||
&zwdaemonv1.ZwErrorDetail{
|
&zwdaemonv1.ZwErrorDetail{
|
||||||
@@ -977,6 +1072,40 @@ func receiveUpload(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
type receivedReplaceUpload struct {
|
||||||
|
header *zwdaemonv1.ReplaceFileHeader
|
||||||
|
contents []byte
|
||||||
|
}
|
||||||
|
|
||||||
|
func receiveReplaceUpload(
|
||||||
|
stream grpc.ClientStreamingServer[zwdaemonv1.ReplaceFileRequest, zwdaemonv1.ReplaceFileResponse],
|
||||||
|
) (receivedReplaceUpload, error) {
|
||||||
|
first, err := stream.Recv()
|
||||||
|
if err != nil {
|
||||||
|
return receivedReplaceUpload{}, err
|
||||||
|
}
|
||||||
|
header := first.GetHeader()
|
||||||
|
if header == nil {
|
||||||
|
return receivedReplaceUpload{}, status.Error(codes.InvalidArgument, "first replacement message is not a header")
|
||||||
|
}
|
||||||
|
|
||||||
|
upload := receivedReplaceUpload{header: header}
|
||||||
|
for {
|
||||||
|
request, err := stream.Recv()
|
||||||
|
if err == io.EOF {
|
||||||
|
return upload, nil
|
||||||
|
}
|
||||||
|
if err != nil {
|
||||||
|
return upload, err
|
||||||
|
}
|
||||||
|
payload, ok := request.GetPayload().(*zwdaemonv1.ReplaceFileRequest_Chunk)
|
||||||
|
if !ok {
|
||||||
|
return upload, status.Error(codes.InvalidArgument, "replacement message after header is not a chunk")
|
||||||
|
}
|
||||||
|
upload.contents = append(upload.contents, payload.Chunk...)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
type dataAndEOFReader struct {
|
type dataAndEOFReader struct {
|
||||||
data []byte
|
data []byte
|
||||||
done bool
|
done bool
|
||||||
|
|||||||
@@ -427,6 +427,114 @@ func (*DeleteFileResponse) Descriptor() ([]byte, []int) {
|
|||||||
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{8}
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{8}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
type MoveFileResponse struct {
|
||||||
|
state protoimpl.MessageState `protogen:"open.v1"`
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *MoveFileResponse) Reset() {
|
||||||
|
*x = MoveFileResponse{}
|
||||||
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[9]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *MoveFileResponse) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*MoveFileResponse) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *MoveFileResponse) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[9]
|
||||||
|
if x != nil {
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
return ms
|
||||||
|
}
|
||||||
|
return mi.MessageOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
// Deprecated: Use MoveFileResponse.ProtoReflect.Descriptor instead.
|
||||||
|
func (*MoveFileResponse) Descriptor() ([]byte, []int) {
|
||||||
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{9}
|
||||||
|
}
|
||||||
|
|
||||||
|
type CopyFileResponse struct {
|
||||||
|
state protoimpl.MessageState `protogen:"open.v1"`
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *CopyFileResponse) Reset() {
|
||||||
|
*x = CopyFileResponse{}
|
||||||
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[10]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *CopyFileResponse) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*CopyFileResponse) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *CopyFileResponse) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[10]
|
||||||
|
if x != nil {
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
return ms
|
||||||
|
}
|
||||||
|
return mi.MessageOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
// Deprecated: Use CopyFileResponse.ProtoReflect.Descriptor instead.
|
||||||
|
func (*CopyFileResponse) Descriptor() ([]byte, []int) {
|
||||||
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{10}
|
||||||
|
}
|
||||||
|
|
||||||
|
type ReplaceFileResponse struct {
|
||||||
|
state protoimpl.MessageState `protogen:"open.v1"`
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ReplaceFileResponse) Reset() {
|
||||||
|
*x = ReplaceFileResponse{}
|
||||||
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[11]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ReplaceFileResponse) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*ReplaceFileResponse) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *ReplaceFileResponse) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[11]
|
||||||
|
if x != nil {
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
return ms
|
||||||
|
}
|
||||||
|
return mi.MessageOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
// Deprecated: Use ReplaceFileResponse.ProtoReflect.Descriptor instead.
|
||||||
|
func (*ReplaceFileResponse) Descriptor() ([]byte, []int) {
|
||||||
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{11}
|
||||||
|
}
|
||||||
|
|
||||||
type GetServerInfoResponse struct {
|
type GetServerInfoResponse struct {
|
||||||
state protoimpl.MessageState `protogen:"open.v1"`
|
state protoimpl.MessageState `protogen:"open.v1"`
|
||||||
ApiMajor uint32 `protobuf:"varint,1,opt,name=api_major,json=apiMajor,proto3" json:"api_major,omitempty"`
|
ApiMajor uint32 `protobuf:"varint,1,opt,name=api_major,json=apiMajor,proto3" json:"api_major,omitempty"`
|
||||||
@@ -438,7 +546,7 @@ type GetServerInfoResponse struct {
|
|||||||
|
|
||||||
func (x *GetServerInfoResponse) Reset() {
|
func (x *GetServerInfoResponse) Reset() {
|
||||||
*x = GetServerInfoResponse{}
|
*x = GetServerInfoResponse{}
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[9]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[12]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
@@ -450,7 +558,7 @@ func (x *GetServerInfoResponse) String() string {
|
|||||||
func (*GetServerInfoResponse) ProtoMessage() {}
|
func (*GetServerInfoResponse) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *GetServerInfoResponse) ProtoReflect() protoreflect.Message {
|
func (x *GetServerInfoResponse) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[9]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[12]
|
||||||
if x != nil {
|
if x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
@@ -463,7 +571,7 @@ func (x *GetServerInfoResponse) ProtoReflect() protoreflect.Message {
|
|||||||
|
|
||||||
// Deprecated: Use GetServerInfoResponse.ProtoReflect.Descriptor instead.
|
// Deprecated: Use GetServerInfoResponse.ProtoReflect.Descriptor instead.
|
||||||
func (*GetServerInfoResponse) Descriptor() ([]byte, []int) {
|
func (*GetServerInfoResponse) Descriptor() ([]byte, []int) {
|
||||||
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{9}
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{12}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *GetServerInfoResponse) GetApiMajor() uint32 {
|
func (x *GetServerInfoResponse) GetApiMajor() uint32 {
|
||||||
@@ -497,7 +605,7 @@ type CreateRequest struct {
|
|||||||
|
|
||||||
func (x *CreateRequest) Reset() {
|
func (x *CreateRequest) Reset() {
|
||||||
*x = CreateRequest{}
|
*x = CreateRequest{}
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[10]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[13]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
@@ -509,7 +617,7 @@ func (x *CreateRequest) String() string {
|
|||||||
func (*CreateRequest) ProtoMessage() {}
|
func (*CreateRequest) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *CreateRequest) ProtoReflect() protoreflect.Message {
|
func (x *CreateRequest) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[10]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[13]
|
||||||
if x != nil {
|
if x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
@@ -522,7 +630,7 @@ func (x *CreateRequest) ProtoReflect() protoreflect.Message {
|
|||||||
|
|
||||||
// Deprecated: Use CreateRequest.ProtoReflect.Descriptor instead.
|
// Deprecated: Use CreateRequest.ProtoReflect.Descriptor instead.
|
||||||
func (*CreateRequest) Descriptor() ([]byte, []int) {
|
func (*CreateRequest) Descriptor() ([]byte, []int) {
|
||||||
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{10}
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{13}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *CreateRequest) GetVaultPath() string {
|
func (x *CreateRequest) GetVaultPath() string {
|
||||||
@@ -549,7 +657,7 @@ type UnsealRequest struct {
|
|||||||
|
|
||||||
func (x *UnsealRequest) Reset() {
|
func (x *UnsealRequest) Reset() {
|
||||||
*x = UnsealRequest{}
|
*x = UnsealRequest{}
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[11]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[14]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
@@ -561,7 +669,7 @@ func (x *UnsealRequest) String() string {
|
|||||||
func (*UnsealRequest) ProtoMessage() {}
|
func (*UnsealRequest) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *UnsealRequest) ProtoReflect() protoreflect.Message {
|
func (x *UnsealRequest) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[11]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[14]
|
||||||
if x != nil {
|
if x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
@@ -574,7 +682,7 @@ func (x *UnsealRequest) ProtoReflect() protoreflect.Message {
|
|||||||
|
|
||||||
// Deprecated: Use UnsealRequest.ProtoReflect.Descriptor instead.
|
// Deprecated: Use UnsealRequest.ProtoReflect.Descriptor instead.
|
||||||
func (*UnsealRequest) Descriptor() ([]byte, []int) {
|
func (*UnsealRequest) Descriptor() ([]byte, []int) {
|
||||||
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{11}
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{14}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *UnsealRequest) GetVaultPath() string {
|
func (x *UnsealRequest) GetVaultPath() string {
|
||||||
@@ -601,7 +709,7 @@ type ListFilesRequest struct {
|
|||||||
|
|
||||||
func (x *ListFilesRequest) Reset() {
|
func (x *ListFilesRequest) Reset() {
|
||||||
*x = ListFilesRequest{}
|
*x = ListFilesRequest{}
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[12]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[15]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
@@ -613,7 +721,7 @@ func (x *ListFilesRequest) String() string {
|
|||||||
func (*ListFilesRequest) ProtoMessage() {}
|
func (*ListFilesRequest) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *ListFilesRequest) ProtoReflect() protoreflect.Message {
|
func (x *ListFilesRequest) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[12]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[15]
|
||||||
if x != nil {
|
if x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
@@ -626,7 +734,7 @@ func (x *ListFilesRequest) ProtoReflect() protoreflect.Message {
|
|||||||
|
|
||||||
// Deprecated: Use ListFilesRequest.ProtoReflect.Descriptor instead.
|
// Deprecated: Use ListFilesRequest.ProtoReflect.Descriptor instead.
|
||||||
func (*ListFilesRequest) Descriptor() ([]byte, []int) {
|
func (*ListFilesRequest) Descriptor() ([]byte, []int) {
|
||||||
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{12}
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{15}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *ListFilesRequest) GetPrefix() string {
|
func (x *ListFilesRequest) GetPrefix() string {
|
||||||
@@ -652,7 +760,7 @@ type ListFilesResponse struct {
|
|||||||
|
|
||||||
func (x *ListFilesResponse) Reset() {
|
func (x *ListFilesResponse) Reset() {
|
||||||
*x = ListFilesResponse{}
|
*x = ListFilesResponse{}
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[13]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[16]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
@@ -664,7 +772,7 @@ func (x *ListFilesResponse) String() string {
|
|||||||
func (*ListFilesResponse) ProtoMessage() {}
|
func (*ListFilesResponse) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *ListFilesResponse) ProtoReflect() protoreflect.Message {
|
func (x *ListFilesResponse) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[13]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[16]
|
||||||
if x != nil {
|
if x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
@@ -677,7 +785,7 @@ func (x *ListFilesResponse) ProtoReflect() protoreflect.Message {
|
|||||||
|
|
||||||
// Deprecated: Use ListFilesResponse.ProtoReflect.Descriptor instead.
|
// Deprecated: Use ListFilesResponse.ProtoReflect.Descriptor instead.
|
||||||
func (*ListFilesResponse) Descriptor() ([]byte, []int) {
|
func (*ListFilesResponse) Descriptor() ([]byte, []int) {
|
||||||
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{13}
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{16}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *ListFilesResponse) GetFiles() []*ListedFile {
|
func (x *ListFilesResponse) GetFiles() []*ListedFile {
|
||||||
@@ -697,7 +805,7 @@ type ListedFile struct {
|
|||||||
|
|
||||||
func (x *ListedFile) Reset() {
|
func (x *ListedFile) Reset() {
|
||||||
*x = ListedFile{}
|
*x = ListedFile{}
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[14]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[17]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
@@ -709,7 +817,7 @@ func (x *ListedFile) String() string {
|
|||||||
func (*ListedFile) ProtoMessage() {}
|
func (*ListedFile) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *ListedFile) ProtoReflect() protoreflect.Message {
|
func (x *ListedFile) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[14]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[17]
|
||||||
if x != nil {
|
if x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
@@ -722,7 +830,7 @@ func (x *ListedFile) ProtoReflect() protoreflect.Message {
|
|||||||
|
|
||||||
// Deprecated: Use ListedFile.ProtoReflect.Descriptor instead.
|
// Deprecated: Use ListedFile.ProtoReflect.Descriptor instead.
|
||||||
func (*ListedFile) Descriptor() ([]byte, []int) {
|
func (*ListedFile) Descriptor() ([]byte, []int) {
|
||||||
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{14}
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{17}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *ListedFile) GetLogicalPath() string {
|
func (x *ListedFile) GetLogicalPath() string {
|
||||||
@@ -748,7 +856,7 @@ type GetFileRequest struct {
|
|||||||
|
|
||||||
func (x *GetFileRequest) Reset() {
|
func (x *GetFileRequest) Reset() {
|
||||||
*x = GetFileRequest{}
|
*x = GetFileRequest{}
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[15]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[18]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
@@ -760,7 +868,7 @@ func (x *GetFileRequest) String() string {
|
|||||||
func (*GetFileRequest) ProtoMessage() {}
|
func (*GetFileRequest) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *GetFileRequest) ProtoReflect() protoreflect.Message {
|
func (x *GetFileRequest) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[15]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[18]
|
||||||
if x != nil {
|
if x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
@@ -773,7 +881,7 @@ func (x *GetFileRequest) ProtoReflect() protoreflect.Message {
|
|||||||
|
|
||||||
// Deprecated: Use GetFileRequest.ProtoReflect.Descriptor instead.
|
// Deprecated: Use GetFileRequest.ProtoReflect.Descriptor instead.
|
||||||
func (*GetFileRequest) Descriptor() ([]byte, []int) {
|
func (*GetFileRequest) Descriptor() ([]byte, []int) {
|
||||||
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{15}
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{18}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *GetFileRequest) GetLogicalPath() string {
|
func (x *GetFileRequest) GetLogicalPath() string {
|
||||||
@@ -783,6 +891,110 @@ func (x *GetFileRequest) GetLogicalPath() string {
|
|||||||
return ""
|
return ""
|
||||||
}
|
}
|
||||||
|
|
||||||
|
type MoveFileRequest struct {
|
||||||
|
state protoimpl.MessageState `protogen:"open.v1"`
|
||||||
|
SourcePath string `protobuf:"bytes,1,opt,name=source_path,json=sourcePath,proto3" json:"source_path,omitempty"`
|
||||||
|
DestinationPath string `protobuf:"bytes,2,opt,name=destination_path,json=destinationPath,proto3" json:"destination_path,omitempty"`
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *MoveFileRequest) Reset() {
|
||||||
|
*x = MoveFileRequest{}
|
||||||
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[19]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *MoveFileRequest) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*MoveFileRequest) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *MoveFileRequest) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[19]
|
||||||
|
if x != nil {
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
return ms
|
||||||
|
}
|
||||||
|
return mi.MessageOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
// Deprecated: Use MoveFileRequest.ProtoReflect.Descriptor instead.
|
||||||
|
func (*MoveFileRequest) Descriptor() ([]byte, []int) {
|
||||||
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{19}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *MoveFileRequest) GetSourcePath() string {
|
||||||
|
if x != nil {
|
||||||
|
return x.SourcePath
|
||||||
|
}
|
||||||
|
return ""
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *MoveFileRequest) GetDestinationPath() string {
|
||||||
|
if x != nil {
|
||||||
|
return x.DestinationPath
|
||||||
|
}
|
||||||
|
return ""
|
||||||
|
}
|
||||||
|
|
||||||
|
type CopyFileRequest struct {
|
||||||
|
state protoimpl.MessageState `protogen:"open.v1"`
|
||||||
|
SourcePath string `protobuf:"bytes,1,opt,name=source_path,json=sourcePath,proto3" json:"source_path,omitempty"`
|
||||||
|
DestinationPath string `protobuf:"bytes,2,opt,name=destination_path,json=destinationPath,proto3" json:"destination_path,omitempty"`
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *CopyFileRequest) Reset() {
|
||||||
|
*x = CopyFileRequest{}
|
||||||
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[20]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *CopyFileRequest) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*CopyFileRequest) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *CopyFileRequest) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[20]
|
||||||
|
if x != nil {
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
return ms
|
||||||
|
}
|
||||||
|
return mi.MessageOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
// Deprecated: Use CopyFileRequest.ProtoReflect.Descriptor instead.
|
||||||
|
func (*CopyFileRequest) Descriptor() ([]byte, []int) {
|
||||||
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{20}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *CopyFileRequest) GetSourcePath() string {
|
||||||
|
if x != nil {
|
||||||
|
return x.SourcePath
|
||||||
|
}
|
||||||
|
return ""
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *CopyFileRequest) GetDestinationPath() string {
|
||||||
|
if x != nil {
|
||||||
|
return x.DestinationPath
|
||||||
|
}
|
||||||
|
return ""
|
||||||
|
}
|
||||||
|
|
||||||
type GetFileRangeRequest struct {
|
type GetFileRangeRequest struct {
|
||||||
state protoimpl.MessageState `protogen:"open.v1"`
|
state protoimpl.MessageState `protogen:"open.v1"`
|
||||||
LogicalPath string `protobuf:"bytes,1,opt,name=logical_path,json=logicalPath,proto3" json:"logical_path,omitempty"`
|
LogicalPath string `protobuf:"bytes,1,opt,name=logical_path,json=logicalPath,proto3" json:"logical_path,omitempty"`
|
||||||
@@ -794,7 +1006,7 @@ type GetFileRangeRequest struct {
|
|||||||
|
|
||||||
func (x *GetFileRangeRequest) Reset() {
|
func (x *GetFileRangeRequest) Reset() {
|
||||||
*x = GetFileRangeRequest{}
|
*x = GetFileRangeRequest{}
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[16]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[21]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
@@ -806,7 +1018,7 @@ func (x *GetFileRangeRequest) String() string {
|
|||||||
func (*GetFileRangeRequest) ProtoMessage() {}
|
func (*GetFileRangeRequest) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *GetFileRangeRequest) ProtoReflect() protoreflect.Message {
|
func (x *GetFileRangeRequest) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[16]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[21]
|
||||||
if x != nil {
|
if x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
@@ -819,7 +1031,7 @@ func (x *GetFileRangeRequest) ProtoReflect() protoreflect.Message {
|
|||||||
|
|
||||||
// Deprecated: Use GetFileRangeRequest.ProtoReflect.Descriptor instead.
|
// Deprecated: Use GetFileRangeRequest.ProtoReflect.Descriptor instead.
|
||||||
func (*GetFileRangeRequest) Descriptor() ([]byte, []int) {
|
func (*GetFileRangeRequest) Descriptor() ([]byte, []int) {
|
||||||
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{16}
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{21}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *GetFileRangeRequest) GetLogicalPath() string {
|
func (x *GetFileRangeRequest) GetLogicalPath() string {
|
||||||
@@ -852,7 +1064,7 @@ type GetFileResponse struct {
|
|||||||
|
|
||||||
func (x *GetFileResponse) Reset() {
|
func (x *GetFileResponse) Reset() {
|
||||||
*x = GetFileResponse{}
|
*x = GetFileResponse{}
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[17]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[22]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
@@ -864,7 +1076,7 @@ func (x *GetFileResponse) String() string {
|
|||||||
func (*GetFileResponse) ProtoMessage() {}
|
func (*GetFileResponse) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *GetFileResponse) ProtoReflect() protoreflect.Message {
|
func (x *GetFileResponse) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[17]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[22]
|
||||||
if x != nil {
|
if x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
@@ -877,7 +1089,7 @@ func (x *GetFileResponse) ProtoReflect() protoreflect.Message {
|
|||||||
|
|
||||||
// Deprecated: Use GetFileResponse.ProtoReflect.Descriptor instead.
|
// Deprecated: Use GetFileResponse.ProtoReflect.Descriptor instead.
|
||||||
func (*GetFileResponse) Descriptor() ([]byte, []int) {
|
func (*GetFileResponse) Descriptor() ([]byte, []int) {
|
||||||
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{17}
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{22}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *GetFileResponse) GetData() []byte {
|
func (x *GetFileResponse) GetData() []byte {
|
||||||
@@ -896,7 +1108,7 @@ type GetFileRangeResponse struct {
|
|||||||
|
|
||||||
func (x *GetFileRangeResponse) Reset() {
|
func (x *GetFileRangeResponse) Reset() {
|
||||||
*x = GetFileRangeResponse{}
|
*x = GetFileRangeResponse{}
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[18]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[23]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
@@ -908,7 +1120,7 @@ func (x *GetFileRangeResponse) String() string {
|
|||||||
func (*GetFileRangeResponse) ProtoMessage() {}
|
func (*GetFileRangeResponse) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *GetFileRangeResponse) ProtoReflect() protoreflect.Message {
|
func (x *GetFileRangeResponse) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[18]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[23]
|
||||||
if x != nil {
|
if x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
@@ -921,7 +1133,7 @@ func (x *GetFileRangeResponse) ProtoReflect() protoreflect.Message {
|
|||||||
|
|
||||||
// Deprecated: Use GetFileRangeResponse.ProtoReflect.Descriptor instead.
|
// Deprecated: Use GetFileRangeResponse.ProtoReflect.Descriptor instead.
|
||||||
func (*GetFileRangeResponse) Descriptor() ([]byte, []int) {
|
func (*GetFileRangeResponse) Descriptor() ([]byte, []int) {
|
||||||
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{18}
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{23}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *GetFileRangeResponse) GetData() []byte {
|
func (x *GetFileRangeResponse) GetData() []byte {
|
||||||
@@ -944,7 +1156,7 @@ type AddFileRequest struct {
|
|||||||
|
|
||||||
func (x *AddFileRequest) Reset() {
|
func (x *AddFileRequest) Reset() {
|
||||||
*x = AddFileRequest{}
|
*x = AddFileRequest{}
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[19]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[24]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
@@ -956,7 +1168,7 @@ func (x *AddFileRequest) String() string {
|
|||||||
func (*AddFileRequest) ProtoMessage() {}
|
func (*AddFileRequest) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *AddFileRequest) ProtoReflect() protoreflect.Message {
|
func (x *AddFileRequest) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[19]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[24]
|
||||||
if x != nil {
|
if x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
@@ -969,7 +1181,7 @@ func (x *AddFileRequest) ProtoReflect() protoreflect.Message {
|
|||||||
|
|
||||||
// Deprecated: Use AddFileRequest.ProtoReflect.Descriptor instead.
|
// Deprecated: Use AddFileRequest.ProtoReflect.Descriptor instead.
|
||||||
func (*AddFileRequest) Descriptor() ([]byte, []int) {
|
func (*AddFileRequest) Descriptor() ([]byte, []int) {
|
||||||
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{19}
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{24}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *AddFileRequest) GetPayload() isAddFileRequest_Payload {
|
func (x *AddFileRequest) GetPayload() isAddFileRequest_Payload {
|
||||||
@@ -1023,7 +1235,7 @@ type AddFileHeader struct {
|
|||||||
|
|
||||||
func (x *AddFileHeader) Reset() {
|
func (x *AddFileHeader) Reset() {
|
||||||
*x = AddFileHeader{}
|
*x = AddFileHeader{}
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[20]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[25]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
@@ -1035,7 +1247,7 @@ func (x *AddFileHeader) String() string {
|
|||||||
func (*AddFileHeader) ProtoMessage() {}
|
func (*AddFileHeader) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *AddFileHeader) ProtoReflect() protoreflect.Message {
|
func (x *AddFileHeader) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[20]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[25]
|
||||||
if x != nil {
|
if x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
@@ -1048,7 +1260,7 @@ func (x *AddFileHeader) ProtoReflect() protoreflect.Message {
|
|||||||
|
|
||||||
// Deprecated: Use AddFileHeader.ProtoReflect.Descriptor instead.
|
// Deprecated: Use AddFileHeader.ProtoReflect.Descriptor instead.
|
||||||
func (*AddFileHeader) Descriptor() ([]byte, []int) {
|
func (*AddFileHeader) Descriptor() ([]byte, []int) {
|
||||||
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{20}
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{25}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *AddFileHeader) GetLogicalPath() string {
|
func (x *AddFileHeader) GetLogicalPath() string {
|
||||||
@@ -1065,6 +1277,140 @@ func (x *AddFileHeader) GetSourceLen() uint64 {
|
|||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
|
type ReplaceFileRequest struct {
|
||||||
|
state protoimpl.MessageState `protogen:"open.v1"`
|
||||||
|
// Types that are valid to be assigned to Payload:
|
||||||
|
//
|
||||||
|
// *ReplaceFileRequest_Header
|
||||||
|
// *ReplaceFileRequest_Chunk
|
||||||
|
Payload isReplaceFileRequest_Payload `protobuf_oneof:"payload"`
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ReplaceFileRequest) Reset() {
|
||||||
|
*x = ReplaceFileRequest{}
|
||||||
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[26]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ReplaceFileRequest) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*ReplaceFileRequest) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *ReplaceFileRequest) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[26]
|
||||||
|
if x != nil {
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
return ms
|
||||||
|
}
|
||||||
|
return mi.MessageOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
// Deprecated: Use ReplaceFileRequest.ProtoReflect.Descriptor instead.
|
||||||
|
func (*ReplaceFileRequest) Descriptor() ([]byte, []int) {
|
||||||
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{26}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ReplaceFileRequest) GetPayload() isReplaceFileRequest_Payload {
|
||||||
|
if x != nil {
|
||||||
|
return x.Payload
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ReplaceFileRequest) GetHeader() *ReplaceFileHeader {
|
||||||
|
if x != nil {
|
||||||
|
if x, ok := x.Payload.(*ReplaceFileRequest_Header); ok {
|
||||||
|
return x.Header
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ReplaceFileRequest) GetChunk() []byte {
|
||||||
|
if x != nil {
|
||||||
|
if x, ok := x.Payload.(*ReplaceFileRequest_Chunk); ok {
|
||||||
|
return x.Chunk
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
type isReplaceFileRequest_Payload interface {
|
||||||
|
isReplaceFileRequest_Payload()
|
||||||
|
}
|
||||||
|
|
||||||
|
type ReplaceFileRequest_Header struct {
|
||||||
|
Header *ReplaceFileHeader `protobuf:"bytes,1,opt,name=header,proto3,oneof"`
|
||||||
|
}
|
||||||
|
|
||||||
|
type ReplaceFileRequest_Chunk struct {
|
||||||
|
Chunk []byte `protobuf:"bytes,2,opt,name=chunk,proto3,oneof"`
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*ReplaceFileRequest_Header) isReplaceFileRequest_Payload() {}
|
||||||
|
|
||||||
|
func (*ReplaceFileRequest_Chunk) isReplaceFileRequest_Payload() {}
|
||||||
|
|
||||||
|
type ReplaceFileHeader struct {
|
||||||
|
state protoimpl.MessageState `protogen:"open.v1"`
|
||||||
|
LogicalPath string `protobuf:"bytes,1,opt,name=logical_path,json=logicalPath,proto3" json:"logical_path,omitempty"`
|
||||||
|
SourceLen uint64 `protobuf:"varint,2,opt,name=source_len,json=sourceLen,proto3" json:"source_len,omitempty"`
|
||||||
|
unknownFields protoimpl.UnknownFields
|
||||||
|
sizeCache protoimpl.SizeCache
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ReplaceFileHeader) Reset() {
|
||||||
|
*x = ReplaceFileHeader{}
|
||||||
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[27]
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ReplaceFileHeader) String() string {
|
||||||
|
return protoimpl.X.MessageStringOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (*ReplaceFileHeader) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (x *ReplaceFileHeader) ProtoReflect() protoreflect.Message {
|
||||||
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[27]
|
||||||
|
if x != nil {
|
||||||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
|
if ms.LoadMessageInfo() == nil {
|
||||||
|
ms.StoreMessageInfo(mi)
|
||||||
|
}
|
||||||
|
return ms
|
||||||
|
}
|
||||||
|
return mi.MessageOf(x)
|
||||||
|
}
|
||||||
|
|
||||||
|
// Deprecated: Use ReplaceFileHeader.ProtoReflect.Descriptor instead.
|
||||||
|
func (*ReplaceFileHeader) Descriptor() ([]byte, []int) {
|
||||||
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{27}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ReplaceFileHeader) GetLogicalPath() string {
|
||||||
|
if x != nil {
|
||||||
|
return x.LogicalPath
|
||||||
|
}
|
||||||
|
return ""
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ReplaceFileHeader) GetSourceLen() uint64 {
|
||||||
|
if x != nil {
|
||||||
|
return x.SourceLen
|
||||||
|
}
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
type DeleteFileRequest struct {
|
type DeleteFileRequest struct {
|
||||||
state protoimpl.MessageState `protogen:"open.v1"`
|
state protoimpl.MessageState `protogen:"open.v1"`
|
||||||
LogicalPath string `protobuf:"bytes,1,opt,name=logical_path,json=logicalPath,proto3" json:"logical_path,omitempty"`
|
LogicalPath string `protobuf:"bytes,1,opt,name=logical_path,json=logicalPath,proto3" json:"logical_path,omitempty"`
|
||||||
@@ -1074,7 +1420,7 @@ type DeleteFileRequest struct {
|
|||||||
|
|
||||||
func (x *DeleteFileRequest) Reset() {
|
func (x *DeleteFileRequest) Reset() {
|
||||||
*x = DeleteFileRequest{}
|
*x = DeleteFileRequest{}
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[21]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[28]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
@@ -1086,7 +1432,7 @@ func (x *DeleteFileRequest) String() string {
|
|||||||
func (*DeleteFileRequest) ProtoMessage() {}
|
func (*DeleteFileRequest) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *DeleteFileRequest) ProtoReflect() protoreflect.Message {
|
func (x *DeleteFileRequest) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[21]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[28]
|
||||||
if x != nil {
|
if x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
@@ -1099,7 +1445,7 @@ func (x *DeleteFileRequest) ProtoReflect() protoreflect.Message {
|
|||||||
|
|
||||||
// Deprecated: Use DeleteFileRequest.ProtoReflect.Descriptor instead.
|
// Deprecated: Use DeleteFileRequest.ProtoReflect.Descriptor instead.
|
||||||
func (*DeleteFileRequest) Descriptor() ([]byte, []int) {
|
func (*DeleteFileRequest) Descriptor() ([]byte, []int) {
|
||||||
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{21}
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{28}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *DeleteFileRequest) GetLogicalPath() string {
|
func (x *DeleteFileRequest) GetLogicalPath() string {
|
||||||
@@ -1119,7 +1465,7 @@ type ZwErrorDetail struct {
|
|||||||
|
|
||||||
func (x *ZwErrorDetail) Reset() {
|
func (x *ZwErrorDetail) Reset() {
|
||||||
*x = ZwErrorDetail{}
|
*x = ZwErrorDetail{}
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[22]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[29]
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
ms.StoreMessageInfo(mi)
|
ms.StoreMessageInfo(mi)
|
||||||
}
|
}
|
||||||
@@ -1131,7 +1477,7 @@ func (x *ZwErrorDetail) String() string {
|
|||||||
func (*ZwErrorDetail) ProtoMessage() {}
|
func (*ZwErrorDetail) ProtoMessage() {}
|
||||||
|
|
||||||
func (x *ZwErrorDetail) ProtoReflect() protoreflect.Message {
|
func (x *ZwErrorDetail) ProtoReflect() protoreflect.Message {
|
||||||
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[22]
|
mi := &file_zw_daemon_v1_daemon_proto_msgTypes[29]
|
||||||
if x != nil {
|
if x != nil {
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||||
if ms.LoadMessageInfo() == nil {
|
if ms.LoadMessageInfo() == nil {
|
||||||
@@ -1144,7 +1490,7 @@ func (x *ZwErrorDetail) ProtoReflect() protoreflect.Message {
|
|||||||
|
|
||||||
// Deprecated: Use ZwErrorDetail.ProtoReflect.Descriptor instead.
|
// Deprecated: Use ZwErrorDetail.ProtoReflect.Descriptor instead.
|
||||||
func (*ZwErrorDetail) Descriptor() ([]byte, []int) {
|
func (*ZwErrorDetail) Descriptor() ([]byte, []int) {
|
||||||
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{22}
|
return file_zw_daemon_v1_daemon_proto_rawDescGZIP(), []int{29}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (x *ZwErrorDetail) GetCode() ZwErrorCode {
|
func (x *ZwErrorDetail) GetCode() ZwErrorCode {
|
||||||
@@ -1174,7 +1520,10 @@ const file_zw_daemon_v1_daemon_proto_rawDesc = "" +
|
|||||||
"\x0fCompactResponse\"\x10\n" +
|
"\x0fCompactResponse\"\x10\n" +
|
||||||
"\x0eCompactRequest\"\x11\n" +
|
"\x0eCompactRequest\"\x11\n" +
|
||||||
"\x0fAddFileResponse\"\x14\n" +
|
"\x0fAddFileResponse\"\x14\n" +
|
||||||
"\x12DeleteFileResponse\"x\n" +
|
"\x12DeleteFileResponse\"\x12\n" +
|
||||||
|
"\x10MoveFileResponse\"\x12\n" +
|
||||||
|
"\x10CopyFileResponse\"\x15\n" +
|
||||||
|
"\x13ReplaceFileResponse\"x\n" +
|
||||||
"\x15GetServerInfoResponse\x12\x1b\n" +
|
"\x15GetServerInfoResponse\x12\x1b\n" +
|
||||||
"\tapi_major\x18\x01 \x01(\rR\bapiMajor\x12\x1b\n" +
|
"\tapi_major\x18\x01 \x01(\rR\bapiMajor\x12\x1b\n" +
|
||||||
"\tapi_minor\x18\x02 \x01(\rR\bapiMinor\x12%\n" +
|
"\tapi_minor\x18\x02 \x01(\rR\bapiMinor\x12%\n" +
|
||||||
@@ -1199,7 +1548,15 @@ const file_zw_daemon_v1_daemon_proto_rawDesc = "" +
|
|||||||
"\flogical_path\x18\x01 \x01(\tR\vlogicalPath\x12\x12\n" +
|
"\flogical_path\x18\x01 \x01(\tR\vlogicalPath\x12\x12\n" +
|
||||||
"\x04size\x18\x02 \x01(\x04R\x04size\"3\n" +
|
"\x04size\x18\x02 \x01(\x04R\x04size\"3\n" +
|
||||||
"\x0eGetFileRequest\x12!\n" +
|
"\x0eGetFileRequest\x12!\n" +
|
||||||
"\flogical_path\x18\x01 \x01(\tR\vlogicalPath\"s\n" +
|
"\flogical_path\x18\x01 \x01(\tR\vlogicalPath\"]\n" +
|
||||||
|
"\x0fMoveFileRequest\x12\x1f\n" +
|
||||||
|
"\vsource_path\x18\x01 \x01(\tR\n" +
|
||||||
|
"sourcePath\x12)\n" +
|
||||||
|
"\x10destination_path\x18\x02 \x01(\tR\x0fdestinationPath\"]\n" +
|
||||||
|
"\x0fCopyFileRequest\x12\x1f\n" +
|
||||||
|
"\vsource_path\x18\x01 \x01(\tR\n" +
|
||||||
|
"sourcePath\x12)\n" +
|
||||||
|
"\x10destination_path\x18\x02 \x01(\tR\x0fdestinationPath\"s\n" +
|
||||||
"\x13GetFileRangeRequest\x12!\n" +
|
"\x13GetFileRangeRequest\x12!\n" +
|
||||||
"\flogical_path\x18\x01 \x01(\tR\vlogicalPath\x12\x14\n" +
|
"\flogical_path\x18\x01 \x01(\tR\vlogicalPath\x12\x14\n" +
|
||||||
"\x05start\x18\x02 \x01(\x04R\x05start\x12#\n" +
|
"\x05start\x18\x02 \x01(\x04R\x05start\x12#\n" +
|
||||||
@@ -1215,6 +1572,14 @@ const file_zw_daemon_v1_daemon_proto_rawDesc = "" +
|
|||||||
"\rAddFileHeader\x12!\n" +
|
"\rAddFileHeader\x12!\n" +
|
||||||
"\flogical_path\x18\x01 \x01(\tR\vlogicalPath\x12\x1d\n" +
|
"\flogical_path\x18\x01 \x01(\tR\vlogicalPath\x12\x1d\n" +
|
||||||
"\n" +
|
"\n" +
|
||||||
|
"source_len\x18\x02 \x01(\x04R\tsourceLen\"r\n" +
|
||||||
|
"\x12ReplaceFileRequest\x129\n" +
|
||||||
|
"\x06header\x18\x01 \x01(\v2\x1f.zw.daemon.v1.ReplaceFileHeaderH\x00R\x06header\x12\x16\n" +
|
||||||
|
"\x05chunk\x18\x02 \x01(\fH\x00R\x05chunkB\t\n" +
|
||||||
|
"\apayload\"U\n" +
|
||||||
|
"\x11ReplaceFileHeader\x12!\n" +
|
||||||
|
"\flogical_path\x18\x01 \x01(\tR\vlogicalPath\x12\x1d\n" +
|
||||||
|
"\n" +
|
||||||
"source_len\x18\x02 \x01(\x04R\tsourceLen\"6\n" +
|
"source_len\x18\x02 \x01(\x04R\tsourceLen\"6\n" +
|
||||||
"\x11DeleteFileRequest\x12!\n" +
|
"\x11DeleteFileRequest\x12!\n" +
|
||||||
"\flogical_path\x18\x01 \x01(\tR\vlogicalPath\"\\\n" +
|
"\flogical_path\x18\x01 \x01(\tR\vlogicalPath\"\\\n" +
|
||||||
@@ -1236,7 +1601,7 @@ const file_zw_daemon_v1_daemon_proto_rawDesc = "" +
|
|||||||
"\x12\x1f\n" +
|
"\x12\x1f\n" +
|
||||||
"\x1bZW_ERROR_CODE_COMMIT_FAILED\x10\v\x12!\n" +
|
"\x1bZW_ERROR_CODE_COMMIT_FAILED\x10\v\x12!\n" +
|
||||||
"\x1dZW_ERROR_CODE_INVALID_REQUEST\x10\f\x12\x1a\n" +
|
"\x1dZW_ERROR_CODE_INVALID_REQUEST\x10\f\x12\x1a\n" +
|
||||||
"\x16ZW_ERROR_CODE_INTERNAL\x10\r2\x88\x06\n" +
|
"\x16ZW_ERROR_CODE_INTERNAL\x10\r2\xf4\a\n" +
|
||||||
"\x0fZwDaemonService\x12X\n" +
|
"\x0fZwDaemonService\x12X\n" +
|
||||||
"\rGetServerInfo\x12\".zw.daemon.v1.GetServerInfoRequest\x1a#.zw.daemon.v1.GetServerInfoResponse\x12C\n" +
|
"\rGetServerInfo\x12\".zw.daemon.v1.GetServerInfoRequest\x1a#.zw.daemon.v1.GetServerInfoResponse\x12C\n" +
|
||||||
"\x06Create\x12\x1b.zw.daemon.v1.CreateRequest\x1a\x1c.zw.daemon.v1.CreateResponse\x12C\n" +
|
"\x06Create\x12\x1b.zw.daemon.v1.CreateRequest\x1a\x1c.zw.daemon.v1.CreateResponse\x12C\n" +
|
||||||
@@ -1248,7 +1613,10 @@ const file_zw_daemon_v1_daemon_proto_rawDesc = "" +
|
|||||||
"\aAddFile\x12\x1c.zw.daemon.v1.AddFileRequest\x1a\x1d.zw.daemon.v1.AddFileResponse(\x01\x12O\n" +
|
"\aAddFile\x12\x1c.zw.daemon.v1.AddFileRequest\x1a\x1d.zw.daemon.v1.AddFileResponse(\x01\x12O\n" +
|
||||||
"\n" +
|
"\n" +
|
||||||
"DeleteFile\x12\x1f.zw.daemon.v1.DeleteFileRequest\x1a .zw.daemon.v1.DeleteFileResponse\x12F\n" +
|
"DeleteFile\x12\x1f.zw.daemon.v1.DeleteFileRequest\x1a .zw.daemon.v1.DeleteFileResponse\x12F\n" +
|
||||||
"\aCompact\x12\x1c.zw.daemon.v1.CompactRequest\x1a\x1d.zw.daemon.v1.CompactResponseB5Z3git.pablu.de/pablu/zw-go/gen/zwdaemon/v1;zwdaemonv1b\x06proto3"
|
"\aCompact\x12\x1c.zw.daemon.v1.CompactRequest\x1a\x1d.zw.daemon.v1.CompactResponse\x12I\n" +
|
||||||
|
"\bMoveFile\x12\x1d.zw.daemon.v1.MoveFileRequest\x1a\x1e.zw.daemon.v1.MoveFileResponse\x12I\n" +
|
||||||
|
"\bCopyFile\x12\x1d.zw.daemon.v1.CopyFileRequest\x1a\x1e.zw.daemon.v1.CopyFileResponse\x12T\n" +
|
||||||
|
"\vReplaceFile\x12 .zw.daemon.v1.ReplaceFileRequest\x1a!.zw.daemon.v1.ReplaceFileResponse(\x01B5Z3git.pablu.de/pablu/zw-go/gen/zwdaemon/v1;zwdaemonv1b\x06proto3"
|
||||||
|
|
||||||
var (
|
var (
|
||||||
file_zw_daemon_v1_daemon_proto_rawDescOnce sync.Once
|
file_zw_daemon_v1_daemon_proto_rawDescOnce sync.Once
|
||||||
@@ -1263,7 +1631,7 @@ func file_zw_daemon_v1_daemon_proto_rawDescGZIP() []byte {
|
|||||||
}
|
}
|
||||||
|
|
||||||
var file_zw_daemon_v1_daemon_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
|
var file_zw_daemon_v1_daemon_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
|
||||||
var file_zw_daemon_v1_daemon_proto_msgTypes = make([]protoimpl.MessageInfo, 23)
|
var file_zw_daemon_v1_daemon_proto_msgTypes = make([]protoimpl.MessageInfo, 30)
|
||||||
var file_zw_daemon_v1_daemon_proto_goTypes = []any{
|
var file_zw_daemon_v1_daemon_proto_goTypes = []any{
|
||||||
(ZwErrorCode)(0), // 0: zw.daemon.v1.ZwErrorCode
|
(ZwErrorCode)(0), // 0: zw.daemon.v1.ZwErrorCode
|
||||||
(*GetServerInfoRequest)(nil), // 1: zw.daemon.v1.GetServerInfoRequest
|
(*GetServerInfoRequest)(nil), // 1: zw.daemon.v1.GetServerInfoRequest
|
||||||
@@ -1275,50 +1643,64 @@ var file_zw_daemon_v1_daemon_proto_goTypes = []any{
|
|||||||
(*CompactRequest)(nil), // 7: zw.daemon.v1.CompactRequest
|
(*CompactRequest)(nil), // 7: zw.daemon.v1.CompactRequest
|
||||||
(*AddFileResponse)(nil), // 8: zw.daemon.v1.AddFileResponse
|
(*AddFileResponse)(nil), // 8: zw.daemon.v1.AddFileResponse
|
||||||
(*DeleteFileResponse)(nil), // 9: zw.daemon.v1.DeleteFileResponse
|
(*DeleteFileResponse)(nil), // 9: zw.daemon.v1.DeleteFileResponse
|
||||||
(*GetServerInfoResponse)(nil), // 10: zw.daemon.v1.GetServerInfoResponse
|
(*MoveFileResponse)(nil), // 10: zw.daemon.v1.MoveFileResponse
|
||||||
(*CreateRequest)(nil), // 11: zw.daemon.v1.CreateRequest
|
(*CopyFileResponse)(nil), // 11: zw.daemon.v1.CopyFileResponse
|
||||||
(*UnsealRequest)(nil), // 12: zw.daemon.v1.UnsealRequest
|
(*ReplaceFileResponse)(nil), // 12: zw.daemon.v1.ReplaceFileResponse
|
||||||
(*ListFilesRequest)(nil), // 13: zw.daemon.v1.ListFilesRequest
|
(*GetServerInfoResponse)(nil), // 13: zw.daemon.v1.GetServerInfoResponse
|
||||||
(*ListFilesResponse)(nil), // 14: zw.daemon.v1.ListFilesResponse
|
(*CreateRequest)(nil), // 14: zw.daemon.v1.CreateRequest
|
||||||
(*ListedFile)(nil), // 15: zw.daemon.v1.ListedFile
|
(*UnsealRequest)(nil), // 15: zw.daemon.v1.UnsealRequest
|
||||||
(*GetFileRequest)(nil), // 16: zw.daemon.v1.GetFileRequest
|
(*ListFilesRequest)(nil), // 16: zw.daemon.v1.ListFilesRequest
|
||||||
(*GetFileRangeRequest)(nil), // 17: zw.daemon.v1.GetFileRangeRequest
|
(*ListFilesResponse)(nil), // 17: zw.daemon.v1.ListFilesResponse
|
||||||
(*GetFileResponse)(nil), // 18: zw.daemon.v1.GetFileResponse
|
(*ListedFile)(nil), // 18: zw.daemon.v1.ListedFile
|
||||||
(*GetFileRangeResponse)(nil), // 19: zw.daemon.v1.GetFileRangeResponse
|
(*GetFileRequest)(nil), // 19: zw.daemon.v1.GetFileRequest
|
||||||
(*AddFileRequest)(nil), // 20: zw.daemon.v1.AddFileRequest
|
(*MoveFileRequest)(nil), // 20: zw.daemon.v1.MoveFileRequest
|
||||||
(*AddFileHeader)(nil), // 21: zw.daemon.v1.AddFileHeader
|
(*CopyFileRequest)(nil), // 21: zw.daemon.v1.CopyFileRequest
|
||||||
(*DeleteFileRequest)(nil), // 22: zw.daemon.v1.DeleteFileRequest
|
(*GetFileRangeRequest)(nil), // 22: zw.daemon.v1.GetFileRangeRequest
|
||||||
(*ZwErrorDetail)(nil), // 23: zw.daemon.v1.ZwErrorDetail
|
(*GetFileResponse)(nil), // 23: zw.daemon.v1.GetFileResponse
|
||||||
|
(*GetFileRangeResponse)(nil), // 24: zw.daemon.v1.GetFileRangeResponse
|
||||||
|
(*AddFileRequest)(nil), // 25: zw.daemon.v1.AddFileRequest
|
||||||
|
(*AddFileHeader)(nil), // 26: zw.daemon.v1.AddFileHeader
|
||||||
|
(*ReplaceFileRequest)(nil), // 27: zw.daemon.v1.ReplaceFileRequest
|
||||||
|
(*ReplaceFileHeader)(nil), // 28: zw.daemon.v1.ReplaceFileHeader
|
||||||
|
(*DeleteFileRequest)(nil), // 29: zw.daemon.v1.DeleteFileRequest
|
||||||
|
(*ZwErrorDetail)(nil), // 30: zw.daemon.v1.ZwErrorDetail
|
||||||
}
|
}
|
||||||
var file_zw_daemon_v1_daemon_proto_depIdxs = []int32{
|
var file_zw_daemon_v1_daemon_proto_depIdxs = []int32{
|
||||||
15, // 0: zw.daemon.v1.ListFilesResponse.files:type_name -> zw.daemon.v1.ListedFile
|
18, // 0: zw.daemon.v1.ListFilesResponse.files:type_name -> zw.daemon.v1.ListedFile
|
||||||
21, // 1: zw.daemon.v1.AddFileRequest.header:type_name -> zw.daemon.v1.AddFileHeader
|
26, // 1: zw.daemon.v1.AddFileRequest.header:type_name -> zw.daemon.v1.AddFileHeader
|
||||||
0, // 2: zw.daemon.v1.ZwErrorDetail.code:type_name -> zw.daemon.v1.ZwErrorCode
|
28, // 2: zw.daemon.v1.ReplaceFileRequest.header:type_name -> zw.daemon.v1.ReplaceFileHeader
|
||||||
1, // 3: zw.daemon.v1.ZwDaemonService.GetServerInfo:input_type -> zw.daemon.v1.GetServerInfoRequest
|
0, // 3: zw.daemon.v1.ZwErrorDetail.code:type_name -> zw.daemon.v1.ZwErrorCode
|
||||||
11, // 4: zw.daemon.v1.ZwDaemonService.Create:input_type -> zw.daemon.v1.CreateRequest
|
1, // 4: zw.daemon.v1.ZwDaemonService.GetServerInfo:input_type -> zw.daemon.v1.GetServerInfoRequest
|
||||||
12, // 5: zw.daemon.v1.ZwDaemonService.Unseal:input_type -> zw.daemon.v1.UnsealRequest
|
14, // 5: zw.daemon.v1.ZwDaemonService.Create:input_type -> zw.daemon.v1.CreateRequest
|
||||||
2, // 6: zw.daemon.v1.ZwDaemonService.Seal:input_type -> zw.daemon.v1.SealRequest
|
15, // 6: zw.daemon.v1.ZwDaemonService.Unseal:input_type -> zw.daemon.v1.UnsealRequest
|
||||||
13, // 7: zw.daemon.v1.ZwDaemonService.ListFiles:input_type -> zw.daemon.v1.ListFilesRequest
|
2, // 7: zw.daemon.v1.ZwDaemonService.Seal:input_type -> zw.daemon.v1.SealRequest
|
||||||
16, // 8: zw.daemon.v1.ZwDaemonService.GetFile:input_type -> zw.daemon.v1.GetFileRequest
|
16, // 8: zw.daemon.v1.ZwDaemonService.ListFiles:input_type -> zw.daemon.v1.ListFilesRequest
|
||||||
17, // 9: zw.daemon.v1.ZwDaemonService.GetFileRange:input_type -> zw.daemon.v1.GetFileRangeRequest
|
19, // 9: zw.daemon.v1.ZwDaemonService.GetFile:input_type -> zw.daemon.v1.GetFileRequest
|
||||||
20, // 10: zw.daemon.v1.ZwDaemonService.AddFile:input_type -> zw.daemon.v1.AddFileRequest
|
22, // 10: zw.daemon.v1.ZwDaemonService.GetFileRange:input_type -> zw.daemon.v1.GetFileRangeRequest
|
||||||
22, // 11: zw.daemon.v1.ZwDaemonService.DeleteFile:input_type -> zw.daemon.v1.DeleteFileRequest
|
25, // 11: zw.daemon.v1.ZwDaemonService.AddFile:input_type -> zw.daemon.v1.AddFileRequest
|
||||||
7, // 12: zw.daemon.v1.ZwDaemonService.Compact:input_type -> zw.daemon.v1.CompactRequest
|
29, // 12: zw.daemon.v1.ZwDaemonService.DeleteFile:input_type -> zw.daemon.v1.DeleteFileRequest
|
||||||
10, // 13: zw.daemon.v1.ZwDaemonService.GetServerInfo:output_type -> zw.daemon.v1.GetServerInfoResponse
|
7, // 13: zw.daemon.v1.ZwDaemonService.Compact:input_type -> zw.daemon.v1.CompactRequest
|
||||||
4, // 14: zw.daemon.v1.ZwDaemonService.Create:output_type -> zw.daemon.v1.CreateResponse
|
20, // 14: zw.daemon.v1.ZwDaemonService.MoveFile:input_type -> zw.daemon.v1.MoveFileRequest
|
||||||
5, // 15: zw.daemon.v1.ZwDaemonService.Unseal:output_type -> zw.daemon.v1.UnsealResponse
|
21, // 15: zw.daemon.v1.ZwDaemonService.CopyFile:input_type -> zw.daemon.v1.CopyFileRequest
|
||||||
3, // 16: zw.daemon.v1.ZwDaemonService.Seal:output_type -> zw.daemon.v1.SealResponse
|
27, // 16: zw.daemon.v1.ZwDaemonService.ReplaceFile:input_type -> zw.daemon.v1.ReplaceFileRequest
|
||||||
14, // 17: zw.daemon.v1.ZwDaemonService.ListFiles:output_type -> zw.daemon.v1.ListFilesResponse
|
13, // 17: zw.daemon.v1.ZwDaemonService.GetServerInfo:output_type -> zw.daemon.v1.GetServerInfoResponse
|
||||||
18, // 18: zw.daemon.v1.ZwDaemonService.GetFile:output_type -> zw.daemon.v1.GetFileResponse
|
4, // 18: zw.daemon.v1.ZwDaemonService.Create:output_type -> zw.daemon.v1.CreateResponse
|
||||||
19, // 19: zw.daemon.v1.ZwDaemonService.GetFileRange:output_type -> zw.daemon.v1.GetFileRangeResponse
|
5, // 19: zw.daemon.v1.ZwDaemonService.Unseal:output_type -> zw.daemon.v1.UnsealResponse
|
||||||
8, // 20: zw.daemon.v1.ZwDaemonService.AddFile:output_type -> zw.daemon.v1.AddFileResponse
|
3, // 20: zw.daemon.v1.ZwDaemonService.Seal:output_type -> zw.daemon.v1.SealResponse
|
||||||
9, // 21: zw.daemon.v1.ZwDaemonService.DeleteFile:output_type -> zw.daemon.v1.DeleteFileResponse
|
17, // 21: zw.daemon.v1.ZwDaemonService.ListFiles:output_type -> zw.daemon.v1.ListFilesResponse
|
||||||
6, // 22: zw.daemon.v1.ZwDaemonService.Compact:output_type -> zw.daemon.v1.CompactResponse
|
23, // 22: zw.daemon.v1.ZwDaemonService.GetFile:output_type -> zw.daemon.v1.GetFileResponse
|
||||||
13, // [13:23] is the sub-list for method output_type
|
24, // 23: zw.daemon.v1.ZwDaemonService.GetFileRange:output_type -> zw.daemon.v1.GetFileRangeResponse
|
||||||
3, // [3:13] is the sub-list for method input_type
|
8, // 24: zw.daemon.v1.ZwDaemonService.AddFile:output_type -> zw.daemon.v1.AddFileResponse
|
||||||
3, // [3:3] is the sub-list for extension type_name
|
9, // 25: zw.daemon.v1.ZwDaemonService.DeleteFile:output_type -> zw.daemon.v1.DeleteFileResponse
|
||||||
3, // [3:3] is the sub-list for extension extendee
|
6, // 26: zw.daemon.v1.ZwDaemonService.Compact:output_type -> zw.daemon.v1.CompactResponse
|
||||||
0, // [0:3] is the sub-list for field type_name
|
10, // 27: zw.daemon.v1.ZwDaemonService.MoveFile:output_type -> zw.daemon.v1.MoveFileResponse
|
||||||
|
11, // 28: zw.daemon.v1.ZwDaemonService.CopyFile:output_type -> zw.daemon.v1.CopyFileResponse
|
||||||
|
12, // 29: zw.daemon.v1.ZwDaemonService.ReplaceFile:output_type -> zw.daemon.v1.ReplaceFileResponse
|
||||||
|
17, // [17:30] is the sub-list for method output_type
|
||||||
|
4, // [4:17] is the sub-list for method input_type
|
||||||
|
4, // [4:4] is the sub-list for extension type_name
|
||||||
|
4, // [4:4] is the sub-list for extension extendee
|
||||||
|
0, // [0:4] is the sub-list for field type_name
|
||||||
}
|
}
|
||||||
|
|
||||||
func init() { file_zw_daemon_v1_daemon_proto_init() }
|
func init() { file_zw_daemon_v1_daemon_proto_init() }
|
||||||
@@ -1326,18 +1708,22 @@ func file_zw_daemon_v1_daemon_proto_init() {
|
|||||||
if File_zw_daemon_v1_daemon_proto != nil {
|
if File_zw_daemon_v1_daemon_proto != nil {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
file_zw_daemon_v1_daemon_proto_msgTypes[12].OneofWrappers = []any{}
|
file_zw_daemon_v1_daemon_proto_msgTypes[15].OneofWrappers = []any{}
|
||||||
file_zw_daemon_v1_daemon_proto_msgTypes[19].OneofWrappers = []any{
|
file_zw_daemon_v1_daemon_proto_msgTypes[24].OneofWrappers = []any{
|
||||||
(*AddFileRequest_Header)(nil),
|
(*AddFileRequest_Header)(nil),
|
||||||
(*AddFileRequest_Chunk)(nil),
|
(*AddFileRequest_Chunk)(nil),
|
||||||
}
|
}
|
||||||
|
file_zw_daemon_v1_daemon_proto_msgTypes[26].OneofWrappers = []any{
|
||||||
|
(*ReplaceFileRequest_Header)(nil),
|
||||||
|
(*ReplaceFileRequest_Chunk)(nil),
|
||||||
|
}
|
||||||
type x struct{}
|
type x struct{}
|
||||||
out := protoimpl.TypeBuilder{
|
out := protoimpl.TypeBuilder{
|
||||||
File: protoimpl.DescBuilder{
|
File: protoimpl.DescBuilder{
|
||||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||||
RawDescriptor: unsafe.Slice(unsafe.StringData(file_zw_daemon_v1_daemon_proto_rawDesc), len(file_zw_daemon_v1_daemon_proto_rawDesc)),
|
RawDescriptor: unsafe.Slice(unsafe.StringData(file_zw_daemon_v1_daemon_proto_rawDesc), len(file_zw_daemon_v1_daemon_proto_rawDesc)),
|
||||||
NumEnums: 1,
|
NumEnums: 1,
|
||||||
NumMessages: 23,
|
NumMessages: 30,
|
||||||
NumExtensions: 0,
|
NumExtensions: 0,
|
||||||
NumServices: 1,
|
NumServices: 1,
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -29,6 +29,9 @@ const (
|
|||||||
ZwDaemonService_AddFile_FullMethodName = "/zw.daemon.v1.ZwDaemonService/AddFile"
|
ZwDaemonService_AddFile_FullMethodName = "/zw.daemon.v1.ZwDaemonService/AddFile"
|
||||||
ZwDaemonService_DeleteFile_FullMethodName = "/zw.daemon.v1.ZwDaemonService/DeleteFile"
|
ZwDaemonService_DeleteFile_FullMethodName = "/zw.daemon.v1.ZwDaemonService/DeleteFile"
|
||||||
ZwDaemonService_Compact_FullMethodName = "/zw.daemon.v1.ZwDaemonService/Compact"
|
ZwDaemonService_Compact_FullMethodName = "/zw.daemon.v1.ZwDaemonService/Compact"
|
||||||
|
ZwDaemonService_MoveFile_FullMethodName = "/zw.daemon.v1.ZwDaemonService/MoveFile"
|
||||||
|
ZwDaemonService_CopyFile_FullMethodName = "/zw.daemon.v1.ZwDaemonService/CopyFile"
|
||||||
|
ZwDaemonService_ReplaceFile_FullMethodName = "/zw.daemon.v1.ZwDaemonService/ReplaceFile"
|
||||||
)
|
)
|
||||||
|
|
||||||
// ZwDaemonServiceClient is the client API for ZwDaemonService service.
|
// ZwDaemonServiceClient is the client API for ZwDaemonService service.
|
||||||
@@ -45,6 +48,9 @@ type ZwDaemonServiceClient interface {
|
|||||||
AddFile(ctx context.Context, opts ...grpc.CallOption) (grpc.ClientStreamingClient[AddFileRequest, AddFileResponse], error)
|
AddFile(ctx context.Context, opts ...grpc.CallOption) (grpc.ClientStreamingClient[AddFileRequest, AddFileResponse], error)
|
||||||
DeleteFile(ctx context.Context, in *DeleteFileRequest, opts ...grpc.CallOption) (*DeleteFileResponse, error)
|
DeleteFile(ctx context.Context, in *DeleteFileRequest, opts ...grpc.CallOption) (*DeleteFileResponse, error)
|
||||||
Compact(ctx context.Context, in *CompactRequest, opts ...grpc.CallOption) (*CompactResponse, error)
|
Compact(ctx context.Context, in *CompactRequest, opts ...grpc.CallOption) (*CompactResponse, error)
|
||||||
|
MoveFile(ctx context.Context, in *MoveFileRequest, opts ...grpc.CallOption) (*MoveFileResponse, error)
|
||||||
|
CopyFile(ctx context.Context, in *CopyFileRequest, opts ...grpc.CallOption) (*CopyFileResponse, error)
|
||||||
|
ReplaceFile(ctx context.Context, opts ...grpc.CallOption) (grpc.ClientStreamingClient[ReplaceFileRequest, ReplaceFileResponse], error)
|
||||||
}
|
}
|
||||||
|
|
||||||
type zwDaemonServiceClient struct {
|
type zwDaemonServiceClient struct {
|
||||||
@@ -176,6 +182,39 @@ func (c *zwDaemonServiceClient) Compact(ctx context.Context, in *CompactRequest,
|
|||||||
return out, nil
|
return out, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (c *zwDaemonServiceClient) MoveFile(ctx context.Context, in *MoveFileRequest, opts ...grpc.CallOption) (*MoveFileResponse, error) {
|
||||||
|
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
||||||
|
out := new(MoveFileResponse)
|
||||||
|
err := c.cc.Invoke(ctx, ZwDaemonService_MoveFile_FullMethodName, in, out, cOpts...)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
return out, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (c *zwDaemonServiceClient) CopyFile(ctx context.Context, in *CopyFileRequest, opts ...grpc.CallOption) (*CopyFileResponse, error) {
|
||||||
|
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
||||||
|
out := new(CopyFileResponse)
|
||||||
|
err := c.cc.Invoke(ctx, ZwDaemonService_CopyFile_FullMethodName, in, out, cOpts...)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
return out, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (c *zwDaemonServiceClient) ReplaceFile(ctx context.Context, opts ...grpc.CallOption) (grpc.ClientStreamingClient[ReplaceFileRequest, ReplaceFileResponse], error) {
|
||||||
|
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
||||||
|
stream, err := c.cc.NewStream(ctx, &ZwDaemonService_ServiceDesc.Streams[3], ZwDaemonService_ReplaceFile_FullMethodName, cOpts...)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
x := &grpc.GenericClientStream[ReplaceFileRequest, ReplaceFileResponse]{ClientStream: stream}
|
||||||
|
return x, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name.
|
||||||
|
type ZwDaemonService_ReplaceFileClient = grpc.ClientStreamingClient[ReplaceFileRequest, ReplaceFileResponse]
|
||||||
|
|
||||||
// ZwDaemonServiceServer is the server API for ZwDaemonService service.
|
// ZwDaemonServiceServer is the server API for ZwDaemonService service.
|
||||||
// All implementations must embed UnimplementedZwDaemonServiceServer
|
// All implementations must embed UnimplementedZwDaemonServiceServer
|
||||||
// for forward compatibility.
|
// for forward compatibility.
|
||||||
@@ -190,6 +229,9 @@ type ZwDaemonServiceServer interface {
|
|||||||
AddFile(grpc.ClientStreamingServer[AddFileRequest, AddFileResponse]) error
|
AddFile(grpc.ClientStreamingServer[AddFileRequest, AddFileResponse]) error
|
||||||
DeleteFile(context.Context, *DeleteFileRequest) (*DeleteFileResponse, error)
|
DeleteFile(context.Context, *DeleteFileRequest) (*DeleteFileResponse, error)
|
||||||
Compact(context.Context, *CompactRequest) (*CompactResponse, error)
|
Compact(context.Context, *CompactRequest) (*CompactResponse, error)
|
||||||
|
MoveFile(context.Context, *MoveFileRequest) (*MoveFileResponse, error)
|
||||||
|
CopyFile(context.Context, *CopyFileRequest) (*CopyFileResponse, error)
|
||||||
|
ReplaceFile(grpc.ClientStreamingServer[ReplaceFileRequest, ReplaceFileResponse]) error
|
||||||
mustEmbedUnimplementedZwDaemonServiceServer()
|
mustEmbedUnimplementedZwDaemonServiceServer()
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -230,6 +272,15 @@ func (UnimplementedZwDaemonServiceServer) DeleteFile(context.Context, *DeleteFil
|
|||||||
func (UnimplementedZwDaemonServiceServer) Compact(context.Context, *CompactRequest) (*CompactResponse, error) {
|
func (UnimplementedZwDaemonServiceServer) Compact(context.Context, *CompactRequest) (*CompactResponse, error) {
|
||||||
return nil, status.Error(codes.Unimplemented, "method Compact not implemented")
|
return nil, status.Error(codes.Unimplemented, "method Compact not implemented")
|
||||||
}
|
}
|
||||||
|
func (UnimplementedZwDaemonServiceServer) MoveFile(context.Context, *MoveFileRequest) (*MoveFileResponse, error) {
|
||||||
|
return nil, status.Error(codes.Unimplemented, "method MoveFile not implemented")
|
||||||
|
}
|
||||||
|
func (UnimplementedZwDaemonServiceServer) CopyFile(context.Context, *CopyFileRequest) (*CopyFileResponse, error) {
|
||||||
|
return nil, status.Error(codes.Unimplemented, "method CopyFile not implemented")
|
||||||
|
}
|
||||||
|
func (UnimplementedZwDaemonServiceServer) ReplaceFile(grpc.ClientStreamingServer[ReplaceFileRequest, ReplaceFileResponse]) error {
|
||||||
|
return status.Error(codes.Unimplemented, "method ReplaceFile not implemented")
|
||||||
|
}
|
||||||
func (UnimplementedZwDaemonServiceServer) mustEmbedUnimplementedZwDaemonServiceServer() {}
|
func (UnimplementedZwDaemonServiceServer) mustEmbedUnimplementedZwDaemonServiceServer() {}
|
||||||
func (UnimplementedZwDaemonServiceServer) testEmbeddedByValue() {}
|
func (UnimplementedZwDaemonServiceServer) testEmbeddedByValue() {}
|
||||||
|
|
||||||
@@ -406,6 +457,49 @@ func _ZwDaemonService_Compact_Handler(srv interface{}, ctx context.Context, dec
|
|||||||
return interceptor(ctx, in, info, handler)
|
return interceptor(ctx, in, info, handler)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func _ZwDaemonService_MoveFile_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||||
|
in := new(MoveFileRequest)
|
||||||
|
if err := dec(in); err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
if interceptor == nil {
|
||||||
|
return srv.(ZwDaemonServiceServer).MoveFile(ctx, in)
|
||||||
|
}
|
||||||
|
info := &grpc.UnaryServerInfo{
|
||||||
|
Server: srv,
|
||||||
|
FullMethod: ZwDaemonService_MoveFile_FullMethodName,
|
||||||
|
}
|
||||||
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||||
|
return srv.(ZwDaemonServiceServer).MoveFile(ctx, req.(*MoveFileRequest))
|
||||||
|
}
|
||||||
|
return interceptor(ctx, in, info, handler)
|
||||||
|
}
|
||||||
|
|
||||||
|
func _ZwDaemonService_CopyFile_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||||
|
in := new(CopyFileRequest)
|
||||||
|
if err := dec(in); err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
if interceptor == nil {
|
||||||
|
return srv.(ZwDaemonServiceServer).CopyFile(ctx, in)
|
||||||
|
}
|
||||||
|
info := &grpc.UnaryServerInfo{
|
||||||
|
Server: srv,
|
||||||
|
FullMethod: ZwDaemonService_CopyFile_FullMethodName,
|
||||||
|
}
|
||||||
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||||
|
return srv.(ZwDaemonServiceServer).CopyFile(ctx, req.(*CopyFileRequest))
|
||||||
|
}
|
||||||
|
return interceptor(ctx, in, info, handler)
|
||||||
|
}
|
||||||
|
|
||||||
|
func _ZwDaemonService_ReplaceFile_Handler(srv interface{}, stream grpc.ServerStream) error {
|
||||||
|
return srv.(ZwDaemonServiceServer).ReplaceFile(&grpc.GenericServerStream[ReplaceFileRequest, ReplaceFileResponse]{ServerStream: stream})
|
||||||
|
}
|
||||||
|
|
||||||
|
// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name.
|
||||||
|
type ZwDaemonService_ReplaceFileServer = grpc.ClientStreamingServer[ReplaceFileRequest, ReplaceFileResponse]
|
||||||
|
|
||||||
// ZwDaemonService_ServiceDesc is the grpc.ServiceDesc for ZwDaemonService service.
|
// ZwDaemonService_ServiceDesc is the grpc.ServiceDesc for ZwDaemonService service.
|
||||||
// It's only intended for direct use with grpc.RegisterService,
|
// It's only intended for direct use with grpc.RegisterService,
|
||||||
// and not to be introspected or modified (even as a copy)
|
// and not to be introspected or modified (even as a copy)
|
||||||
@@ -441,6 +535,14 @@ var ZwDaemonService_ServiceDesc = grpc.ServiceDesc{
|
|||||||
MethodName: "Compact",
|
MethodName: "Compact",
|
||||||
Handler: _ZwDaemonService_Compact_Handler,
|
Handler: _ZwDaemonService_Compact_Handler,
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
MethodName: "MoveFile",
|
||||||
|
Handler: _ZwDaemonService_MoveFile_Handler,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
MethodName: "CopyFile",
|
||||||
|
Handler: _ZwDaemonService_CopyFile_Handler,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
Streams: []grpc.StreamDesc{
|
Streams: []grpc.StreamDesc{
|
||||||
{
|
{
|
||||||
@@ -458,6 +560,11 @@ var ZwDaemonService_ServiceDesc = grpc.ServiceDesc{
|
|||||||
Handler: _ZwDaemonService_AddFile_Handler,
|
Handler: _ZwDaemonService_AddFile_Handler,
|
||||||
ClientStreams: true,
|
ClientStreams: true,
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
StreamName: "ReplaceFile",
|
||||||
|
Handler: _ZwDaemonService_ReplaceFile_Handler,
|
||||||
|
ClientStreams: true,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
Metadata: "zw/daemon/v1/daemon.proto",
|
Metadata: "zw/daemon/v1/daemon.proto",
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user