From 3f92d7bfb05805216262e720651ec3bb40e532b5 Mon Sep 17 00:00:00 2001 From: Evgenii Stratonikov Date: Fri, 12 Jul 2024 17:36:40 +0300 Subject: [PATCH 01/19] [#90] proto/test: Fix proto file formatting Signed-off-by: Evgenii Stratonikov --- util/proto/test/test.proto | 44 +++++++++++++++++++------------------- 1 file changed, 22 insertions(+), 22 deletions(-) diff --git a/util/proto/test/test.proto b/util/proto/test/test.proto index 65e350f..aa980e9 100644 --- a/util/proto/test/test.proto +++ b/util/proto/test/test.proto @@ -5,30 +5,30 @@ package test; option go_package = "util/proto/test"; message Primitives { - bytes field_a = 1; - string field_b = 2; - bool field_c = 200; - int32 field_d = 201; - uint32 field_e = 202; - int64 field_f = 203; - uint64 field_g = 204; - fixed64 field_i = 205; - double field_j = 206; - fixed32 field_k = 207; + bytes field_a = 1; + string field_b = 2; + bool field_c = 200; + int32 field_d = 201; + uint32 field_e = 202; + int64 field_f = 203; + uint64 field_g = 204; + fixed64 field_i = 205; + double field_j = 206; + fixed32 field_k = 207; - enum SomeEnum { - UNKNOWN = 0; - POSITIVE = 1; - NEGATIVE = -1; - } - SomeEnum field_h = 300; + enum SomeEnum { + UNKNOWN = 0; + POSITIVE = 1; + NEGATIVE = -1; + } + SomeEnum field_h = 300; } message RepPrimitives { - repeated bytes field_a = 1; - repeated string field_b = 2; - repeated int32 field_c = 3; - repeated uint32 field_d = 4; - repeated int64 field_e = 5; - repeated uint64 field_f = 6; + repeated bytes field_a = 1; + repeated string field_b = 2; + repeated int32 field_c = 3; + repeated uint32 field_d = 4; + repeated int64 field_e = 5; + repeated uint64 field_f = 6; } From 610c450a655e812a81ee57ccc2c1f0751b273a2f Mon Sep 17 00:00:00 2001 From: Evgenii Stratonikov Date: Fri, 12 Jul 2024 17:45:29 +0300 Subject: [PATCH 02/19] [#90] proto/test: Fix go vet warnings Signed-off-by: Evgenii Stratonikov --- util/proto/marshal_test.go | 42 +++++++++++++++++++------------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/util/proto/marshal_test.go b/util/proto/marshal_test.go index 7119c8f..f23641d 100644 --- a/util/proto/marshal_test.go +++ b/util/proto/marshal_test.go @@ -439,7 +439,7 @@ func TestFixed32Marshal(t *testing.T) { }) } -func testMarshal(t *testing.T, c stablePrimitives, tr test.Primitives, wrongField bool) *test.Primitives { +func testMarshal(t *testing.T, c stablePrimitives, tr *test.Primitives, wrongField bool) *test.Primitives { var ( wire []byte err error @@ -447,7 +447,7 @@ func testMarshal(t *testing.T, c stablePrimitives, tr test.Primitives, wrongFiel wire, err = c.stableMarshal(nil, wrongField) require.NoError(t, err) - wireGen, err := goproto.Marshal(&tr) + wireGen, err := goproto.Marshal(tr) require.NoError(t, err) if !wrongField { @@ -470,7 +470,7 @@ func testBytesMarshal(t *testing.T, data []byte, wrongField bool) { transport = test.Primitives{FieldA: data} ) - result := testMarshal(t, custom, transport, wrongField) + result := testMarshal(t, custom, &transport, wrongField) if !wrongField { require.Len(t, result.FieldA, len(data)) @@ -488,7 +488,7 @@ func testStringMarshal(t *testing.T, s string, wrongField bool) { transport = test.Primitives{FieldB: s} ) - result := testMarshal(t, custom, transport, wrongField) + result := testMarshal(t, custom, &transport, wrongField) if !wrongField { require.Len(t, result.FieldB, len(s)) @@ -506,7 +506,7 @@ func testBoolMarshal(t *testing.T, b bool, wrongField bool) { transport = test.Primitives{FieldC: b} ) - result := testMarshal(t, custom, transport, wrongField) + result := testMarshal(t, custom, &transport, wrongField) if !wrongField { require.Equal(t, b, result.FieldC) @@ -521,7 +521,7 @@ func testInt32Marshal(t *testing.T, n int32, wrongField bool) { transport = test.Primitives{FieldD: n} ) - result := testMarshal(t, custom, transport, wrongField) + result := testMarshal(t, custom, &transport, wrongField) if !wrongField { require.Equal(t, n, result.FieldD) @@ -536,7 +536,7 @@ func testUInt32Marshal(t *testing.T, n uint32, wrongField bool) { transport = test.Primitives{FieldE: n} ) - result := testMarshal(t, custom, transport, wrongField) + result := testMarshal(t, custom, &transport, wrongField) if !wrongField { require.Equal(t, n, result.FieldE) @@ -551,7 +551,7 @@ func testInt64Marshal(t *testing.T, n int64, wrongField bool) { transport = test.Primitives{FieldF: n} ) - result := testMarshal(t, custom, transport, wrongField) + result := testMarshal(t, custom, &transport, wrongField) if !wrongField { require.Equal(t, n, result.FieldF) @@ -566,7 +566,7 @@ func testUInt64Marshal(t *testing.T, n uint64, wrongField bool) { transport = test.Primitives{FieldG: n} ) - result := testMarshal(t, custom, transport, wrongField) + result := testMarshal(t, custom, &transport, wrongField) if !wrongField { require.Equal(t, n, result.FieldG) @@ -581,7 +581,7 @@ func testFloat64Marshal(t *testing.T, n float64, wrongField bool) { transport = test.Primitives{FieldJ: n} ) - result := testMarshal(t, custom, transport, wrongField) + result := testMarshal(t, custom, &transport, wrongField) if !wrongField { require.Equal(t, n, result.FieldJ) @@ -596,7 +596,7 @@ func testEnumMarshal(t *testing.T, e SomeEnum, wrongField bool) { transport = test.Primitives{FieldH: test.Primitives_SomeEnum(e)} ) - result := testMarshal(t, custom, transport, wrongField) + result := testMarshal(t, custom, &transport, wrongField) if !wrongField { require.EqualValues(t, custom.FieldH, result.FieldH) @@ -605,7 +605,7 @@ func testEnumMarshal(t *testing.T, e SomeEnum, wrongField bool) { } } -func testRepMarshal(t *testing.T, c stableRepPrimitives, tr test.RepPrimitives, wrongField bool) *test.RepPrimitives { +func testRepMarshal(t *testing.T, c stableRepPrimitives, tr *test.RepPrimitives, wrongField bool) *test.RepPrimitives { var ( wire []byte err error @@ -613,7 +613,7 @@ func testRepMarshal(t *testing.T, c stableRepPrimitives, tr test.RepPrimitives, wire, err = c.stableMarshal(nil, wrongField) require.NoError(t, err) - wireGen, err := goproto.Marshal(&tr) + wireGen, err := goproto.Marshal(tr) require.NoError(t, err) if !wrongField { @@ -636,7 +636,7 @@ func testRepeatedBytesMarshal(t *testing.T, data [][]byte, wrongField bool) { transport = test.RepPrimitives{FieldA: data} ) - result := testRepMarshal(t, custom, transport, wrongField) + result := testRepMarshal(t, custom, &transport, wrongField) if !wrongField { require.Len(t, result.FieldA, len(data)) @@ -654,7 +654,7 @@ func testRepeatedStringMarshal(t *testing.T, s []string, wrongField bool) { transport = test.RepPrimitives{FieldB: s} ) - result := testRepMarshal(t, custom, transport, wrongField) + result := testRepMarshal(t, custom, &transport, wrongField) if !wrongField { require.Len(t, result.FieldB, len(s)) @@ -672,7 +672,7 @@ func testRepeatedInt32Marshal(t *testing.T, n []int32, wrongField bool) { transport = test.RepPrimitives{FieldC: n} ) - result := testRepMarshal(t, custom, transport, wrongField) + result := testRepMarshal(t, custom, &transport, wrongField) if !wrongField { require.Len(t, result.FieldC, len(n)) @@ -690,7 +690,7 @@ func testRepeatedUInt32Marshal(t *testing.T, n []uint32, wrongField bool) { transport = test.RepPrimitives{FieldD: n} ) - result := testRepMarshal(t, custom, transport, wrongField) + result := testRepMarshal(t, custom, &transport, wrongField) if !wrongField { require.Len(t, result.FieldD, len(n)) @@ -708,7 +708,7 @@ func testRepeatedInt64Marshal(t *testing.T, n []int64, wrongField bool) { transport = test.RepPrimitives{FieldE: n} ) - result := testRepMarshal(t, custom, transport, wrongField) + result := testRepMarshal(t, custom, &transport, wrongField) if !wrongField { require.Len(t, result.FieldE, len(n)) @@ -726,7 +726,7 @@ func testRepeatedUInt64Marshal(t *testing.T, n []uint64, wrongField bool) { transport = test.RepPrimitives{FieldF: n} ) - result := testRepMarshal(t, custom, transport, wrongField) + result := testRepMarshal(t, custom, &transport, wrongField) if !wrongField { require.Len(t, result.FieldF, len(n)) @@ -744,7 +744,7 @@ func testFixed64Marshal(t *testing.T, n uint64, wrongField bool) { transport = test.Primitives{FieldI: n} ) - result := testMarshal(t, custom, transport, wrongField) + result := testMarshal(t, custom, &transport, wrongField) if !wrongField { require.Equal(t, n, result.FieldI) @@ -759,7 +759,7 @@ func testFixed32Marshal(t *testing.T, n uint32, wrongField bool) { transport = test.Primitives{FieldK: n} ) - result := testMarshal(t, custom, transport, wrongField) + result := testMarshal(t, custom, &transport, wrongField) if !wrongField { require.Equal(t, n, result.FieldK) From 3639563d80684a158189e10a0522555001073240 Mon Sep 17 00:00:00 2001 From: Evgenii Stratonikov Date: Fri, 12 Jul 2024 17:46:06 +0300 Subject: [PATCH 03/19] [#90] apemanager: Run gofumpt Signed-off-by: Evgenii Stratonikov --- apemanager/types.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/apemanager/types.go b/apemanager/types.go index 6896bf1..21edf85 100644 --- a/apemanager/types.go +++ b/apemanager/types.go @@ -109,8 +109,7 @@ type RemoveChainResponse struct { session.ResponseHeaders } -type RemoveChainResponseBody struct { -} +type RemoveChainResponseBody struct{} func (r *RemoveChainResponse) SetBody(body *RemoveChainResponseBody) { r.body = body From f517e3949164d072b456c8f561b9c67012114a69 Mon Sep 17 00:00:00 2001 From: Evgenii Stratonikov Date: Mon, 15 Jul 2024 11:16:29 +0300 Subject: [PATCH 04/19] [#91] protogen: Support unpacked repeated uint64 fields Signed-off-by: Evgenii Stratonikov --- util/proto/marshal_test.go | 59 +++++++++++++++++++++++++++++++++++++- util/proto/test/test.pb.go | 32 ++++++++++++++------- util/proto/test/test.proto | 1 + util/protogen/main.go | 38 ++++++++++++++++++++---- 4 files changed, 113 insertions(+), 17 deletions(-) diff --git a/util/proto/marshal_test.go b/util/proto/marshal_test.go index f23641d..c2a0f8e 100644 --- a/util/proto/marshal_test.go +++ b/util/proto/marshal_test.go @@ -1,12 +1,14 @@ package proto_test import ( + "encoding/binary" "math" "testing" "git.frostfs.info/TrueCloudLab/frostfs-api-go/v2/util/proto" "git.frostfs.info/TrueCloudLab/frostfs-api-go/v2/util/proto/test" "github.com/stretchr/testify/require" + "google.golang.org/protobuf/encoding/protowire" goproto "google.golang.org/protobuf/proto" ) @@ -33,6 +35,8 @@ type stableRepPrimitives struct { FieldD []uint32 FieldE []int64 FieldF []uint64 + + FieldFu []uint64 } const ( @@ -185,6 +189,20 @@ func (s *stableRepPrimitives) stableMarshal(buf []byte, wrongField bool) ([]byte } i += proto.RepeatedUInt64Marshal(fieldNum, buf, s.FieldF) + fieldNum = 7 + if wrongField { + fieldNum++ + } + for j := range s.FieldFu { + { + prefix := protowire.EncodeTag( + protowire.Number(fieldNum), + protowire.VarintType) + i += binary.PutUvarint(buf[i:], uint64(prefix)) + i += binary.PutUvarint(buf[i:], s.FieldFu[j]) + } + } + return buf, nil } @@ -196,7 +214,12 @@ func (s *stableRepPrimitives) stableSize() int { f5, _ := proto.RepeatedInt64Size(5, s.FieldE) f6, _ := proto.RepeatedUInt64Size(6, s.FieldF) - return f1 + f2 + f3 + f4 + f5 + f6 + var f7 int + for i := range s.FieldFu { + f7 += protowire.SizeGroup(protowire.Number(7), protowire.SizeVarint(s.FieldFu[i])) + } + + return f1 + f2 + f3 + f4 + f5 + f6 + f7 } func TestBytesMarshal(t *testing.T) { @@ -404,6 +427,22 @@ func TestRepeatedUInt64Marshal(t *testing.T) { }) } +func TestRepeatedUInt64MarshalUnpacked(t *testing.T) { + t.Run("not empty", func(t *testing.T) { + data := []uint64{0, 1, 2, 3, 4, 5} + testRepeatedUInt64MarshalUnpacked(t, data, false) + testRepeatedUInt64MarshalUnpacked(t, data, true) + }) + + t.Run("empty", func(t *testing.T) { + testRepeatedUInt64MarshalUnpacked(t, []uint64{}, false) + }) + + t.Run("nil", func(t *testing.T) { + testRepeatedUInt64MarshalUnpacked(t, nil, false) + }) +} + func TestFixed64Marshal(t *testing.T) { t.Run("zero", func(t *testing.T) { testFixed64Marshal(t, 0, false) @@ -738,6 +777,24 @@ func testRepeatedUInt64Marshal(t *testing.T, n []uint64, wrongField bool) { } } +func testRepeatedUInt64MarshalUnpacked(t *testing.T, n []uint64, wrongField bool) { + var ( + custom = stableRepPrimitives{FieldFu: n} + transport = test.RepPrimitives{FieldFu: n} + ) + + result := testRepMarshal(t, custom, &transport, wrongField) + + if !wrongField { + require.Len(t, result.FieldFu, len(n)) + if len(n) > 0 { + require.Equal(t, n, result.FieldFu) + } + } else { + require.Len(t, result.FieldFu, 0) + } +} + func testFixed64Marshal(t *testing.T, n uint64, wrongField bool) { var ( custom = stablePrimitives{FieldI: n} diff --git a/util/proto/test/test.pb.go b/util/proto/test/test.pb.go index 0b9f43d..57f7fb0 100644 --- a/util/proto/test/test.pb.go +++ b/util/proto/test/test.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.33.0 -// protoc v4.25.3 +// protoc v5.27.2 // source: util/proto/test/test.proto package test @@ -201,12 +201,13 @@ type RepPrimitives struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - FieldA [][]byte `protobuf:"bytes,1,rep,name=field_a,json=fieldA,proto3" json:"field_a,omitempty"` - FieldB []string `protobuf:"bytes,2,rep,name=field_b,json=fieldB,proto3" json:"field_b,omitempty"` - FieldC []int32 `protobuf:"varint,3,rep,packed,name=field_c,json=fieldC,proto3" json:"field_c,omitempty"` - FieldD []uint32 `protobuf:"varint,4,rep,packed,name=field_d,json=fieldD,proto3" json:"field_d,omitempty"` - FieldE []int64 `protobuf:"varint,5,rep,packed,name=field_e,json=fieldE,proto3" json:"field_e,omitempty"` - FieldF []uint64 `protobuf:"varint,6,rep,packed,name=field_f,json=fieldF,proto3" json:"field_f,omitempty"` + FieldA [][]byte `protobuf:"bytes,1,rep,name=field_a,json=fieldA,proto3" json:"field_a,omitempty"` + FieldB []string `protobuf:"bytes,2,rep,name=field_b,json=fieldB,proto3" json:"field_b,omitempty"` + FieldC []int32 `protobuf:"varint,3,rep,packed,name=field_c,json=fieldC,proto3" json:"field_c,omitempty"` + FieldD []uint32 `protobuf:"varint,4,rep,packed,name=field_d,json=fieldD,proto3" json:"field_d,omitempty"` + FieldE []int64 `protobuf:"varint,5,rep,packed,name=field_e,json=fieldE,proto3" json:"field_e,omitempty"` + FieldF []uint64 `protobuf:"varint,6,rep,packed,name=field_f,json=fieldF,proto3" json:"field_f,omitempty"` + FieldFu []uint64 `protobuf:"varint,7,rep,name=field_fu,json=fieldFu,proto3" json:"field_fu,omitempty"` } func (x *RepPrimitives) Reset() { @@ -283,6 +284,13 @@ func (x *RepPrimitives) GetFieldF() []uint64 { return nil } +func (x *RepPrimitives) GetFieldFu() []uint64 { + if x != nil { + return x.FieldFu + } + return nil +} + var File_util_proto_test_test_proto protoreflect.FileDescriptor var file_util_proto_test_test_proto_rawDesc = []byte{ @@ -312,7 +320,7 @@ var file_util_proto_test_test_proto_rawDesc = []byte{ 0x45, 0x6e, 0x75, 0x6d, 0x12, 0x0b, 0x0a, 0x07, 0x55, 0x4e, 0x4b, 0x4e, 0x4f, 0x57, 0x4e, 0x10, 0x00, 0x12, 0x0c, 0x0a, 0x08, 0x50, 0x4f, 0x53, 0x49, 0x54, 0x49, 0x56, 0x45, 0x10, 0x01, 0x12, 0x15, 0x0a, 0x08, 0x4e, 0x45, 0x47, 0x41, 0x54, 0x49, 0x56, 0x45, 0x10, 0xff, 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x22, 0xa5, 0x01, 0x0a, 0x0d, 0x52, 0x65, 0x70, 0x50, 0x72, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x22, 0xc4, 0x01, 0x0a, 0x0d, 0x52, 0x65, 0x70, 0x50, 0x72, 0x69, 0x6d, 0x69, 0x74, 0x69, 0x76, 0x65, 0x73, 0x12, 0x17, 0x0a, 0x07, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x5f, 0x61, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0c, 0x52, 0x06, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x41, 0x12, 0x17, 0x0a, 0x07, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x5f, 0x62, 0x18, 0x02, 0x20, 0x03, @@ -322,9 +330,11 @@ var file_util_proto_test_test_proto_rawDesc = []byte{ 0x20, 0x03, 0x28, 0x0d, 0x52, 0x06, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x44, 0x12, 0x17, 0x0a, 0x07, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x5f, 0x65, 0x18, 0x05, 0x20, 0x03, 0x28, 0x03, 0x52, 0x06, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x45, 0x12, 0x17, 0x0a, 0x07, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x5f, 0x66, - 0x18, 0x06, 0x20, 0x03, 0x28, 0x04, 0x52, 0x06, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x46, 0x42, 0x11, - 0x5a, 0x0f, 0x75, 0x74, 0x69, 0x6c, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x74, 0x65, 0x73, - 0x74, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x18, 0x06, 0x20, 0x03, 0x28, 0x04, 0x52, 0x06, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x46, 0x12, 0x1d, + 0x0a, 0x08, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x5f, 0x66, 0x75, 0x18, 0x07, 0x20, 0x03, 0x28, 0x04, + 0x42, 0x02, 0x10, 0x00, 0x52, 0x07, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x46, 0x75, 0x42, 0x11, 0x5a, + 0x0f, 0x75, 0x74, 0x69, 0x6c, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x74, 0x65, 0x73, 0x74, + 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/util/proto/test/test.proto b/util/proto/test/test.proto index aa980e9..14f6ac2 100644 --- a/util/proto/test/test.proto +++ b/util/proto/test/test.proto @@ -31,4 +31,5 @@ message RepPrimitives { repeated uint32 field_d = 4; repeated int64 field_e = 5; repeated uint64 field_f = 6; + repeated uint64 field_fu = 7 [ packed = false ]; } diff --git a/util/protogen/main.go b/util/protogen/main.go index a295a28..85c6ded 100644 --- a/util/protogen/main.go +++ b/util/protogen/main.go @@ -8,6 +8,11 @@ import ( "google.golang.org/protobuf/reflect/protoreflect" ) +var ( + protowirePackage = protogen.GoImportPath("google.golang.org/protobuf/encoding/protowire") + binaryPackage = protogen.GoImportPath("encoding/binary") +) + func main() { protogen.Options{}.Run(func(gen *protogen.Plugin) error { for _, f := range gen.Files { @@ -62,7 +67,7 @@ func emitMessage(g *protogen.GeneratedFile, msg *protogen.Message) { g.P("if x == nil { return 0 }") if len(fs) != 0 { for _, f := range fs { - if f.Desc.IsList() && marshalers[f.Desc.Kind()].RepeatedDouble { + if f.Desc.IsList() && marshalers[f.Desc.Kind()].RepeatedDouble && !(f.Desc.Kind() == protoreflect.Uint64Kind && !f.Desc.IsPacked()) { g.P("var n int") break } @@ -140,9 +145,19 @@ func emitFieldSize(g *protogen.GeneratedFile, f *protogen.Field) { } switch { - case f.Desc.IsList() && f.Desc.Kind() == protoreflect.MessageKind: + case f.Desc.IsList() && (f.Desc.Kind() == protoreflect.MessageKind || f.Desc.Kind() == protoreflect.Uint64Kind && !f.Desc.IsPacked()): g.P("for i := range ", name, "{") - g.P("size += proto.NestedStructureSize(", f.Desc.Number(), ", ", name, "[i])") + if f.Desc.Kind() == protoreflect.MessageKind { + g.P("size += proto.NestedStructureSize(", f.Desc.Number(), ", ", name, "[i])") + } else { + if f.Desc.Kind() != protoreflect.Uint64Kind { + panic("only uint64 unpacked primitive is supported") + } + + g.P("size += ", protowirePackage.Ident("SizeGroup"), "(", + protowirePackage.Ident("Number"), "(", f.Desc.Number(), "), ", + protowirePackage.Ident("SizeVarint"), "(", name, "[i]))") + } g.P("}") case f.Desc.IsList(): if m.RepeatedDouble { @@ -177,9 +192,22 @@ func emitFieldMarshal(g *protogen.GeneratedFile, f *protogen.Field) { prefix = "Repeated" + m.Prefix } switch { - case f.Desc.IsList() && f.Desc.Kind() == protoreflect.MessageKind: + case f.Desc.IsList() && (f.Desc.Kind() == protoreflect.MessageKind || f.Desc.Kind() == protoreflect.Uint64Kind && !f.Desc.IsPacked()): g.P("for i := range ", name, "{") - g.P("offset += proto.NestedStructureMarshal(", f.Desc.Number(), ", buf[offset:], ", name, "[i])") + if f.Desc.Kind() == protoreflect.MessageKind { + g.P("offset += proto.NestedStructureMarshal(", f.Desc.Number(), ", buf[offset:], ", name, "[i])") + } else { + if f.Desc.Kind() != protoreflect.Uint64Kind { + panic("only uint64 unpacked primitive is supported") + } + g.P("{") + g.P("prefix := ", protowirePackage.Ident("EncodeTag"), "(", + protowirePackage.Ident("Number"), "(", f.Desc.Number(), "), ", + protowirePackage.Ident("VarintType"), ")") + g.P("offset += ", binaryPackage.Ident("PutUvarint"), "(buf[offset:], uint64(prefix))") + g.P("offset += ", binaryPackage.Ident("PutUvarint"), "(buf[offset:], ", name, "[i])") + g.P("}") + } g.P("}") case f.Desc.IsList(): g.P("offset += proto.Repeated", m.Prefix, "Marshal(", f.Desc.Number(), ", buf[offset:], ", name, ")") From 3dfa2f4fd65ed386611f06e31d16f5f755e963bc Mon Sep 17 00:00:00 2001 From: Evgenii Stratonikov Date: Fri, 26 Jul 2024 10:15:06 +0300 Subject: [PATCH 05/19] [#95] *: Regenerate proto files Remove SetExtendedEACL and AnnounceUsedSpace methods from the container package. Signed-off-by: Evgenii Stratonikov --- accounting/grpc/service.pb.go | 2 +- accounting/grpc/service_grpc.pb.go | 2 +- accounting/grpc/types.pb.go | 2 +- acl/grpc/types.pb.go | 14 +- ape/grpc/types.pb.go | 2 +- apemanager/grpc/service.pb.go | 2 +- apemanager/grpc/service_grpc.pb.go | 2 +- container/convert.go | 340 -------- container/grpc/service.go | 90 --- container/grpc/service.pb.go | 1164 +++++----------------------- container/grpc/service_grpc.pb.go | 118 +-- container/grpc/types.pb.go | 2 +- container/marshal.go | 133 ---- container/message_test.go | 7 - container/test/generate.go | 111 --- container/types.go | 168 ---- lock/grpc/types.pb.go | 2 +- netmap/grpc/service.pb.go | 2 +- netmap/grpc/service_grpc.pb.go | 2 +- netmap/grpc/types.pb.go | 2 +- object/grpc/service.pb.go | 6 +- object/grpc/service_grpc.pb.go | 2 +- object/grpc/types.pb.go | 13 +- refs/grpc/types.pb.go | 2 +- rpc/container.go | 33 - session/grpc/service.pb.go | 2 +- session/grpc/service_grpc.pb.go | 2 +- session/grpc/types.pb.go | 2 +- signature/body.go | 8 - status/grpc/types.pb.go | 5 +- tombstone/grpc/types.pb.go | 2 +- 31 files changed, 238 insertions(+), 2006 deletions(-) diff --git a/accounting/grpc/service.pb.go b/accounting/grpc/service.pb.go index fe193cd..b66bb7a 100644 --- a/accounting/grpc/service.pb.go +++ b/accounting/grpc/service.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.33.0 -// protoc v4.25.3 +// protoc v5.27.2 // source: accounting/grpc/service.proto package accounting diff --git a/accounting/grpc/service_grpc.pb.go b/accounting/grpc/service_grpc.pb.go index cd1b2e9..63207fe 100644 --- a/accounting/grpc/service_grpc.pb.go +++ b/accounting/grpc/service_grpc.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go-grpc. DO NOT EDIT. // versions: // - protoc-gen-go-grpc v1.3.0 -// - protoc v4.25.3 +// - protoc v5.27.2 // source: accounting/grpc/service.proto package accounting diff --git a/accounting/grpc/types.pb.go b/accounting/grpc/types.pb.go index 592aa8b..8be14bc 100644 --- a/accounting/grpc/types.pb.go +++ b/accounting/grpc/types.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.33.0 -// protoc v4.25.3 +// protoc v5.27.2 // source: accounting/grpc/types.proto package accounting diff --git a/acl/grpc/types.pb.go b/acl/grpc/types.pb.go index aec449c..39ab1e1 100644 --- a/acl/grpc/types.pb.go +++ b/acl/grpc/types.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.33.0 -// protoc v4.25.3 +// protoc v5.27.2 // source: acl/grpc/types.proto package acl @@ -709,7 +709,8 @@ type BearerToken_Body struct { // valid for this specific container. Otherwise, any container of the same // owner is allowed. // - // Deprecated: eACL tables are no longer relevant - `APEOverrides` should be used instead. + // Deprecated: eACL tables are no longer relevant - `APEOverrides` should be + // used instead. EaclTable *EACLTable `protobuf:"bytes,1,opt,name=eacl_table,json=eaclTable,proto3" json:"eacl_table,omitempty"` // `OwnerID` defines to whom the token was issued. It must match the request // originator's `OwnerID`. If empty, any token bearer will be accepted. @@ -859,11 +860,12 @@ func (x *BearerToken_Body_TokenLifetime) GetIat() uint64 { } // APEOverride is the list of APE chains defined for a target. -// These chains are meant to serve as overrides to the already defined (or even undefined) -// APE chains for the target (see contract `Policy`). +// These chains are meant to serve as overrides to the already defined (or +// even undefined) APE chains for the target (see contract `Policy`). // -// The server-side processing of the bearer token with set APE overrides must verify if a client is permitted -// to override chains for the target, preventing unauthorized access through the APE mechanism. +// The server-side processing of the bearer token with set APE overrides +// must verify if a client is permitted to override chains for the target, +// preventing unauthorized access through the APE mechanism. type BearerToken_Body_APEOverride struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache diff --git a/ape/grpc/types.pb.go b/ape/grpc/types.pb.go index 1da2110..ee8e0a7 100644 --- a/ape/grpc/types.pb.go +++ b/ape/grpc/types.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.33.0 -// protoc v4.25.3 +// protoc v5.27.2 // source: ape/grpc/types.proto package ape diff --git a/apemanager/grpc/service.pb.go b/apemanager/grpc/service.pb.go index 7757aad..3baf193 100644 --- a/apemanager/grpc/service.pb.go +++ b/apemanager/grpc/service.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.33.0 -// protoc v4.25.3 +// protoc v5.27.2 // source: apemanager/grpc/service.proto package apemanager diff --git a/apemanager/grpc/service_grpc.pb.go b/apemanager/grpc/service_grpc.pb.go index 484fec5..4781427 100644 --- a/apemanager/grpc/service_grpc.pb.go +++ b/apemanager/grpc/service_grpc.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go-grpc. DO NOT EDIT. // versions: // - protoc-gen-go-grpc v1.3.0 -// - protoc v4.25.3 +// - protoc v5.27.2 // source: apemanager/grpc/service.proto package apemanager diff --git a/container/convert.go b/container/convert.go index 0753755..c5f9cd7 100644 --- a/container/convert.go +++ b/container/convert.go @@ -767,151 +767,6 @@ func (r *ListResponse) FromGRPCMessage(m grpc.Message) error { return r.ResponseHeaders.FromMessage(v) } -func (r *SetExtendedACLRequestBody) ToGRPCMessage() grpc.Message { - var m *container.SetExtendedACLRequest_Body - - if r != nil { - m = new(container.SetExtendedACLRequest_Body) - - m.SetEacl(r.eacl.ToGRPCMessage().(*aclGRPC.EACLTable)) - m.SetSignature(toSignatureRFC6979(r.sig)) - } - - return m -} - -func (r *SetExtendedACLRequestBody) FromGRPCMessage(m grpc.Message) error { - v, ok := m.(*container.SetExtendedACLRequest_Body) - if !ok { - return message.NewUnexpectedMessageType(m, v) - } - - var err error - - eacl := v.GetEacl() - if eacl == nil { - r.eacl = nil - } else { - if r.eacl == nil { - r.eacl = new(acl.Table) - } - - err = r.eacl.FromGRPCMessage(eacl) - if err != nil { - return err - } - } - - sig := v.GetSignature() - if sig == nil { - r.sig = nil - } else { - if r.sig == nil { - r.sig = new(refs.Signature) - } - - r.sig.SetKey(sig.GetKey()) - r.sig.SetSign(sig.GetSign()) - } - - return err -} - -func (r *SetExtendedACLRequest) ToGRPCMessage() grpc.Message { - var m *container.SetExtendedACLRequest - - if r != nil { - m = new(container.SetExtendedACLRequest) - - m.SetBody(r.body.ToGRPCMessage().(*container.SetExtendedACLRequest_Body)) - r.RequestHeaders.ToMessage(m) - } - - return m -} - -func (r *SetExtendedACLRequest) FromGRPCMessage(m grpc.Message) error { - v, ok := m.(*container.SetExtendedACLRequest) - if !ok { - return message.NewUnexpectedMessageType(m, v) - } - - var err error - - body := v.GetBody() - if body == nil { - r.body = nil - } else { - if r.body == nil { - r.body = new(SetExtendedACLRequestBody) - } - - err = r.body.FromGRPCMessage(body) - if err != nil { - return err - } - } - - return r.RequestHeaders.FromMessage(v) -} - -func (r *SetExtendedACLResponseBody) ToGRPCMessage() grpc.Message { - var m *container.SetExtendedACLResponse_Body - - if r != nil { - m = new(container.SetExtendedACLResponse_Body) - } - - return m -} - -func (r *SetExtendedACLResponseBody) FromGRPCMessage(m grpc.Message) error { - v, ok := m.(*container.SetExtendedACLResponse_Body) - if !ok { - return message.NewUnexpectedMessageType(m, v) - } - - return nil -} - -func (r *SetExtendedACLResponse) ToGRPCMessage() grpc.Message { - var m *container.SetExtendedACLResponse - - if r != nil { - m = new(container.SetExtendedACLResponse) - - m.SetBody(r.body.ToGRPCMessage().(*container.SetExtendedACLResponse_Body)) - r.ResponseHeaders.ToMessage(m) - } - - return m -} - -func (r *SetExtendedACLResponse) FromGRPCMessage(m grpc.Message) error { - v, ok := m.(*container.SetExtendedACLResponse) - if !ok { - return message.NewUnexpectedMessageType(m, v) - } - - var err error - - body := v.GetBody() - if body == nil { - r.body = nil - } else { - if r.body == nil { - r.body = new(SetExtendedACLResponseBody) - } - - err = r.body.FromGRPCMessage(body) - if err != nil { - return err - } - } - - return r.ResponseHeaders.FromMessage(v) -} - func (r *GetExtendedACLRequestBody) ToGRPCMessage() grpc.Message { var m *container.GetExtendedACLRequest_Body @@ -1083,198 +938,3 @@ func (r *GetExtendedACLResponse) FromGRPCMessage(m grpc.Message) error { return r.ResponseHeaders.FromMessage(v) } - -func (a *UsedSpaceAnnouncement) ToGRPCMessage() grpc.Message { - var m *container.AnnounceUsedSpaceRequest_Body_Announcement - - if a != nil { - m = new(container.AnnounceUsedSpaceRequest_Body_Announcement) - - m.SetContainerId(a.cid.ToGRPCMessage().(*refsGRPC.ContainerID)) - m.SetEpoch(a.epoch) - m.SetUsedSpace(a.usedSpace) - } - - return m -} - -func (a *UsedSpaceAnnouncement) FromGRPCMessage(m grpc.Message) error { - v, ok := m.(*container.AnnounceUsedSpaceRequest_Body_Announcement) - if !ok { - return message.NewUnexpectedMessageType(m, v) - } - - var err error - - cid := v.GetContainerId() - if cid == nil { - a.cid = nil - } else { - if a.cid == nil { - a.cid = new(refs.ContainerID) - } - - err = a.cid.FromGRPCMessage(cid) - if err != nil { - return err - } - } - - a.epoch = v.GetEpoch() - a.usedSpace = v.GetUsedSpace() - - return nil -} - -func UsedSpaceAnnouncementsToGRPCMessage( - ids []UsedSpaceAnnouncement, -) (res []*container.AnnounceUsedSpaceRequest_Body_Announcement) { - if ids != nil { - res = make([]*container.AnnounceUsedSpaceRequest_Body_Announcement, 0, len(ids)) - - for i := range ids { - res = append(res, ids[i].ToGRPCMessage().(*container.AnnounceUsedSpaceRequest_Body_Announcement)) - } - } - - return -} - -func UsedSpaceAnnouncementssFromGRPCMessage( - asV2 []*container.AnnounceUsedSpaceRequest_Body_Announcement, -) (res []UsedSpaceAnnouncement, err error) { - if asV2 != nil { - res = make([]UsedSpaceAnnouncement, len(asV2)) - - for i := range asV2 { - if asV2[i] != nil { - err = res[i].FromGRPCMessage(asV2[i]) - if err != nil { - return - } - } - } - } - - return -} - -func (r *AnnounceUsedSpaceRequestBody) ToGRPCMessage() grpc.Message { - var m *container.AnnounceUsedSpaceRequest_Body - - if r != nil { - m = new(container.AnnounceUsedSpaceRequest_Body) - - m.SetAnnouncements(UsedSpaceAnnouncementsToGRPCMessage(r.announcements)) - } - - return m -} - -func (r *AnnounceUsedSpaceRequestBody) FromGRPCMessage(m grpc.Message) error { - v, ok := m.(*container.AnnounceUsedSpaceRequest_Body) - if !ok { - return message.NewUnexpectedMessageType(m, v) - } - - var err error - - r.announcements, err = UsedSpaceAnnouncementssFromGRPCMessage(v.GetAnnouncements()) - - return err -} - -func (r *AnnounceUsedSpaceRequest) ToGRPCMessage() grpc.Message { - var m *container.AnnounceUsedSpaceRequest - - if r != nil { - m = new(container.AnnounceUsedSpaceRequest) - - m.SetBody(r.body.ToGRPCMessage().(*container.AnnounceUsedSpaceRequest_Body)) - r.RequestHeaders.ToMessage(m) - } - - return m -} - -func (r *AnnounceUsedSpaceRequest) FromGRPCMessage(m grpc.Message) error { - v, ok := m.(*container.AnnounceUsedSpaceRequest) - if !ok { - return message.NewUnexpectedMessageType(m, v) - } - - var err error - - body := v.GetBody() - if body == nil { - r.body = nil - } else { - if r.body == nil { - r.body = new(AnnounceUsedSpaceRequestBody) - } - - err = r.body.FromGRPCMessage(body) - if err != nil { - return err - } - } - - return r.RequestHeaders.FromMessage(v) -} - -func (r *AnnounceUsedSpaceResponseBody) ToGRPCMessage() grpc.Message { - var m *container.AnnounceUsedSpaceResponse_Body - - if r != nil { - m = new(container.AnnounceUsedSpaceResponse_Body) - } - - return m -} - -func (r *AnnounceUsedSpaceResponseBody) FromGRPCMessage(m grpc.Message) error { - v, ok := m.(*container.AnnounceUsedSpaceResponse_Body) - if !ok { - return message.NewUnexpectedMessageType(m, v) - } - - return nil -} - -func (r *AnnounceUsedSpaceResponse) ToGRPCMessage() grpc.Message { - var m *container.AnnounceUsedSpaceResponse - - if r != nil { - m = new(container.AnnounceUsedSpaceResponse) - - m.SetBody(r.body.ToGRPCMessage().(*container.AnnounceUsedSpaceResponse_Body)) - r.ResponseHeaders.ToMessage(m) - } - - return m -} - -func (r *AnnounceUsedSpaceResponse) FromGRPCMessage(m grpc.Message) error { - v, ok := m.(*container.AnnounceUsedSpaceResponse) - if !ok { - return message.NewUnexpectedMessageType(m, v) - } - - var err error - - body := v.GetBody() - if body == nil { - r.body = nil - } else { - if r.body == nil { - r.body = new(AnnounceUsedSpaceResponseBody) - } - - err = r.body.FromGRPCMessage(body) - if err != nil { - return err - } - } - - return r.ResponseHeaders.FromMessage(v) -} diff --git a/container/grpc/service.go b/container/grpc/service.go index 050cf0b..d19add1 100644 --- a/container/grpc/service.go +++ b/container/grpc/service.go @@ -182,46 +182,6 @@ func (m *ListResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) { m.VerifyHeader = v } -// SetEacl sets eACL table structure. -func (m *SetExtendedACLRequest_Body) SetEacl(v *acl.EACLTable) { - m.Eacl = v -} - -// SetSignature sets signature of the eACL table structure. -func (m *SetExtendedACLRequest_Body) SetSignature(v *refs.SignatureRFC6979) { - m.Signature = v -} - -// SetBody sets body of the request. -func (m *SetExtendedACLRequest) SetBody(v *SetExtendedACLRequest_Body) { - m.Body = v -} - -// SetMetaHeader sets meta header of the request. -func (m *SetExtendedACLRequest) SetMetaHeader(v *session.RequestMetaHeader) { - m.MetaHeader = v -} - -// SetVerifyHeader sets verification header of the request. -func (m *SetExtendedACLRequest) SetVerifyHeader(v *session.RequestVerificationHeader) { - m.VerifyHeader = v -} - -// SetBody sets body of the response. -func (m *SetExtendedACLResponse) SetBody(v *SetExtendedACLResponse_Body) { - m.Body = v -} - -// SetMetaHeader sets meta header of the response. -func (m *SetExtendedACLResponse) SetMetaHeader(v *session.ResponseMetaHeader) { - m.MetaHeader = v -} - -// SetVerifyHeader sets verification header of the response. -func (m *SetExtendedACLResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) { - m.VerifyHeader = v -} - // SetContainerId sets identifier of the container. func (m *GetExtendedACLRequest_Body) SetContainerId(v *refs.ContainerID) { m.ContainerId = v @@ -272,53 +232,3 @@ func (m *GetExtendedACLResponse) SetMetaHeader(v *session.ResponseMetaHeader) { func (m *GetExtendedACLResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) { m.VerifyHeader = v } - -// SetEpoch sets epoch of the size estimation. -func (m *AnnounceUsedSpaceRequest_Body_Announcement) SetEpoch(v uint64) { - m.Epoch = v -} - -// SetContainerId sets identifier of the container. -func (m *AnnounceUsedSpaceRequest_Body_Announcement) SetContainerId(v *refs.ContainerID) { - m.ContainerId = v -} - -// SetUsedSpace sets used space value of the container. -func (m *AnnounceUsedSpaceRequest_Body_Announcement) SetUsedSpace(v uint64) { - m.UsedSpace = v -} - -// SetAnnouncements sets list of announcement for shared containers between nodes. -func (m *AnnounceUsedSpaceRequest_Body) SetAnnouncements(v []*AnnounceUsedSpaceRequest_Body_Announcement) { - m.Announcements = v -} - -// SetBody sets body of the request. -func (m *AnnounceUsedSpaceRequest) SetBody(v *AnnounceUsedSpaceRequest_Body) { - m.Body = v -} - -// SetMetaHeader sets meta header of the request. -func (m *AnnounceUsedSpaceRequest) SetMetaHeader(v *session.RequestMetaHeader) { - m.MetaHeader = v -} - -// SetVerifyHeader sets verification header of the request. -func (m *AnnounceUsedSpaceRequest) SetVerifyHeader(v *session.RequestVerificationHeader) { - m.VerifyHeader = v -} - -// SetBody sets body of the response. -func (m *AnnounceUsedSpaceResponse) SetBody(v *AnnounceUsedSpaceResponse_Body) { - m.Body = v -} - -// SetMetaHeader sets meta header of the response. -func (m *AnnounceUsedSpaceResponse) SetMetaHeader(v *session.ResponseMetaHeader) { - m.MetaHeader = v -} - -// SetVerifyHeader sets verification header of the response. -func (m *AnnounceUsedSpaceResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) { - m.VerifyHeader = v -} diff --git a/container/grpc/service.pb.go b/container/grpc/service.pb.go index 672e29f..3bf1e14 100644 --- a/container/grpc/service.pb.go +++ b/container/grpc/service.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.33.0 -// protoc v4.25.3 +// protoc v5.27.2 // source: container/grpc/service.proto package container @@ -584,146 +584,6 @@ func (x *ListResponse) GetVerifyHeader() *grpc.ResponseVerificationHeader { return nil } -// Set Extended ACL -type SetExtendedACLRequest struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // Body of set extended acl request message. - Body *SetExtendedACLRequest_Body `protobuf:"bytes,1,opt,name=body,proto3" json:"body,omitempty"` - // Carries request meta information. Header data is used only to regulate - // message transport and does not affect request execution. - MetaHeader *grpc.RequestMetaHeader `protobuf:"bytes,2,opt,name=meta_header,json=metaHeader,proto3" json:"meta_header,omitempty"` - // Carries request verification information. This header is used to - // authenticate the nodes of the message route and check the correctness of - // transmission. - VerifyHeader *grpc.RequestVerificationHeader `protobuf:"bytes,3,opt,name=verify_header,json=verifyHeader,proto3" json:"verify_header,omitempty"` -} - -func (x *SetExtendedACLRequest) Reset() { - *x = SetExtendedACLRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_container_grpc_service_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *SetExtendedACLRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SetExtendedACLRequest) ProtoMessage() {} - -func (x *SetExtendedACLRequest) ProtoReflect() protoreflect.Message { - mi := &file_container_grpc_service_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SetExtendedACLRequest.ProtoReflect.Descriptor instead. -func (*SetExtendedACLRequest) Descriptor() ([]byte, []int) { - return file_container_grpc_service_proto_rawDescGZIP(), []int{8} -} - -func (x *SetExtendedACLRequest) GetBody() *SetExtendedACLRequest_Body { - if x != nil { - return x.Body - } - return nil -} - -func (x *SetExtendedACLRequest) GetMetaHeader() *grpc.RequestMetaHeader { - if x != nil { - return x.MetaHeader - } - return nil -} - -func (x *SetExtendedACLRequest) GetVerifyHeader() *grpc.RequestVerificationHeader { - if x != nil { - return x.VerifyHeader - } - return nil -} - -// Set Extended ACL -type SetExtendedACLResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // Body of set extended acl response message. - Body *SetExtendedACLResponse_Body `protobuf:"bytes,1,opt,name=body,proto3" json:"body,omitempty"` - // Carries response meta information. Header data is used only to regulate - // message transport and does not affect request execution. - MetaHeader *grpc.ResponseMetaHeader `protobuf:"bytes,2,opt,name=meta_header,json=metaHeader,proto3" json:"meta_header,omitempty"` - // Carries response verification information. This header is used to - // authenticate the nodes of the message route and check the correctness of - // transmission. - VerifyHeader *grpc.ResponseVerificationHeader `protobuf:"bytes,3,opt,name=verify_header,json=verifyHeader,proto3" json:"verify_header,omitempty"` -} - -func (x *SetExtendedACLResponse) Reset() { - *x = SetExtendedACLResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_container_grpc_service_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *SetExtendedACLResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SetExtendedACLResponse) ProtoMessage() {} - -func (x *SetExtendedACLResponse) ProtoReflect() protoreflect.Message { - mi := &file_container_grpc_service_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SetExtendedACLResponse.ProtoReflect.Descriptor instead. -func (*SetExtendedACLResponse) Descriptor() ([]byte, []int) { - return file_container_grpc_service_proto_rawDescGZIP(), []int{9} -} - -func (x *SetExtendedACLResponse) GetBody() *SetExtendedACLResponse_Body { - if x != nil { - return x.Body - } - return nil -} - -func (x *SetExtendedACLResponse) GetMetaHeader() *grpc.ResponseMetaHeader { - if x != nil { - return x.MetaHeader - } - return nil -} - -func (x *SetExtendedACLResponse) GetVerifyHeader() *grpc.ResponseVerificationHeader { - if x != nil { - return x.VerifyHeader - } - return nil -} - // Get Extended ACL type GetExtendedACLRequest struct { state protoimpl.MessageState @@ -744,7 +604,7 @@ type GetExtendedACLRequest struct { func (x *GetExtendedACLRequest) Reset() { *x = GetExtendedACLRequest{} if protoimpl.UnsafeEnabled { - mi := &file_container_grpc_service_proto_msgTypes[10] + mi := &file_container_grpc_service_proto_msgTypes[8] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -757,7 +617,7 @@ func (x *GetExtendedACLRequest) String() string { func (*GetExtendedACLRequest) ProtoMessage() {} func (x *GetExtendedACLRequest) ProtoReflect() protoreflect.Message { - mi := &file_container_grpc_service_proto_msgTypes[10] + mi := &file_container_grpc_service_proto_msgTypes[8] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -770,7 +630,7 @@ func (x *GetExtendedACLRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetExtendedACLRequest.ProtoReflect.Descriptor instead. func (*GetExtendedACLRequest) Descriptor() ([]byte, []int) { - return file_container_grpc_service_proto_rawDescGZIP(), []int{10} + return file_container_grpc_service_proto_rawDescGZIP(), []int{8} } func (x *GetExtendedACLRequest) GetBody() *GetExtendedACLRequest_Body { @@ -814,7 +674,7 @@ type GetExtendedACLResponse struct { func (x *GetExtendedACLResponse) Reset() { *x = GetExtendedACLResponse{} if protoimpl.UnsafeEnabled { - mi := &file_container_grpc_service_proto_msgTypes[11] + mi := &file_container_grpc_service_proto_msgTypes[9] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -827,7 +687,7 @@ func (x *GetExtendedACLResponse) String() string { func (*GetExtendedACLResponse) ProtoMessage() {} func (x *GetExtendedACLResponse) ProtoReflect() protoreflect.Message { - mi := &file_container_grpc_service_proto_msgTypes[11] + mi := &file_container_grpc_service_proto_msgTypes[9] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -840,7 +700,7 @@ func (x *GetExtendedACLResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetExtendedACLResponse.ProtoReflect.Descriptor instead. func (*GetExtendedACLResponse) Descriptor() ([]byte, []int) { - return file_container_grpc_service_proto_rawDescGZIP(), []int{11} + return file_container_grpc_service_proto_rawDescGZIP(), []int{9} } func (x *GetExtendedACLResponse) GetBody() *GetExtendedACLResponse_Body { @@ -864,146 +724,6 @@ func (x *GetExtendedACLResponse) GetVerifyHeader() *grpc.ResponseVerificationHea return nil } -// Announce container used space -type AnnounceUsedSpaceRequest struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // Body of announce used space request message. - Body *AnnounceUsedSpaceRequest_Body `protobuf:"bytes,1,opt,name=body,proto3" json:"body,omitempty"` - // Carries request meta information. Header data is used only to regulate - // message transport and does not affect request execution. - MetaHeader *grpc.RequestMetaHeader `protobuf:"bytes,2,opt,name=meta_header,json=metaHeader,proto3" json:"meta_header,omitempty"` - // Carries request verification information. This header is used to - // authenticate the nodes of the message route and check the correctness of - // transmission. - VerifyHeader *grpc.RequestVerificationHeader `protobuf:"bytes,3,opt,name=verify_header,json=verifyHeader,proto3" json:"verify_header,omitempty"` -} - -func (x *AnnounceUsedSpaceRequest) Reset() { - *x = AnnounceUsedSpaceRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_container_grpc_service_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *AnnounceUsedSpaceRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*AnnounceUsedSpaceRequest) ProtoMessage() {} - -func (x *AnnounceUsedSpaceRequest) ProtoReflect() protoreflect.Message { - mi := &file_container_grpc_service_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use AnnounceUsedSpaceRequest.ProtoReflect.Descriptor instead. -func (*AnnounceUsedSpaceRequest) Descriptor() ([]byte, []int) { - return file_container_grpc_service_proto_rawDescGZIP(), []int{12} -} - -func (x *AnnounceUsedSpaceRequest) GetBody() *AnnounceUsedSpaceRequest_Body { - if x != nil { - return x.Body - } - return nil -} - -func (x *AnnounceUsedSpaceRequest) GetMetaHeader() *grpc.RequestMetaHeader { - if x != nil { - return x.MetaHeader - } - return nil -} - -func (x *AnnounceUsedSpaceRequest) GetVerifyHeader() *grpc.RequestVerificationHeader { - if x != nil { - return x.VerifyHeader - } - return nil -} - -// Announce container used space -type AnnounceUsedSpaceResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // Body of announce used space response message. - Body *AnnounceUsedSpaceResponse_Body `protobuf:"bytes,1,opt,name=body,proto3" json:"body,omitempty"` - // Carries response meta information. Header data is used only to regulate - // message transport and does not affect request execution. - MetaHeader *grpc.ResponseMetaHeader `protobuf:"bytes,2,opt,name=meta_header,json=metaHeader,proto3" json:"meta_header,omitempty"` - // Carries response verification information. This header is used to - // authenticate the nodes of the message route and check the correctness of - // transmission. - VerifyHeader *grpc.ResponseVerificationHeader `protobuf:"bytes,3,opt,name=verify_header,json=verifyHeader,proto3" json:"verify_header,omitempty"` -} - -func (x *AnnounceUsedSpaceResponse) Reset() { - *x = AnnounceUsedSpaceResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_container_grpc_service_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *AnnounceUsedSpaceResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*AnnounceUsedSpaceResponse) ProtoMessage() {} - -func (x *AnnounceUsedSpaceResponse) ProtoReflect() protoreflect.Message { - mi := &file_container_grpc_service_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use AnnounceUsedSpaceResponse.ProtoReflect.Descriptor instead. -func (*AnnounceUsedSpaceResponse) Descriptor() ([]byte, []int) { - return file_container_grpc_service_proto_rawDescGZIP(), []int{13} -} - -func (x *AnnounceUsedSpaceResponse) GetBody() *AnnounceUsedSpaceResponse_Body { - if x != nil { - return x.Body - } - return nil -} - -func (x *AnnounceUsedSpaceResponse) GetMetaHeader() *grpc.ResponseMetaHeader { - if x != nil { - return x.MetaHeader - } - return nil -} - -func (x *AnnounceUsedSpaceResponse) GetVerifyHeader() *grpc.ResponseVerificationHeader { - if x != nil { - return x.VerifyHeader - } - return nil -} - // Container creation request has container structure's signature as a // separate field. It's not stored in sidechain, just verified on container // creation by `Container` smart contract. `ContainerID` is a SHA256 hash of @@ -1023,7 +743,7 @@ type PutRequest_Body struct { func (x *PutRequest_Body) Reset() { *x = PutRequest_Body{} if protoimpl.UnsafeEnabled { - mi := &file_container_grpc_service_proto_msgTypes[14] + mi := &file_container_grpc_service_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1036,7 +756,7 @@ func (x *PutRequest_Body) String() string { func (*PutRequest_Body) ProtoMessage() {} func (x *PutRequest_Body) ProtoReflect() protoreflect.Message { - mi := &file_container_grpc_service_proto_msgTypes[14] + mi := &file_container_grpc_service_proto_msgTypes[10] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1082,7 +802,7 @@ type PutResponse_Body struct { func (x *PutResponse_Body) Reset() { *x = PutResponse_Body{} if protoimpl.UnsafeEnabled { - mi := &file_container_grpc_service_proto_msgTypes[15] + mi := &file_container_grpc_service_proto_msgTypes[11] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1095,7 +815,7 @@ func (x *PutResponse_Body) String() string { func (*PutResponse_Body) ProtoMessage() {} func (x *PutResponse_Body) ProtoReflect() protoreflect.Message { - mi := &file_container_grpc_service_proto_msgTypes[15] + mi := &file_container_grpc_service_proto_msgTypes[11] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1136,7 +856,7 @@ type DeleteRequest_Body struct { func (x *DeleteRequest_Body) Reset() { *x = DeleteRequest_Body{} if protoimpl.UnsafeEnabled { - mi := &file_container_grpc_service_proto_msgTypes[16] + mi := &file_container_grpc_service_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1149,7 +869,7 @@ func (x *DeleteRequest_Body) String() string { func (*DeleteRequest_Body) ProtoMessage() {} func (x *DeleteRequest_Body) ProtoReflect() protoreflect.Message { - mi := &file_container_grpc_service_proto_msgTypes[16] + mi := &file_container_grpc_service_proto_msgTypes[12] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1190,7 +910,7 @@ type DeleteResponse_Body struct { func (x *DeleteResponse_Body) Reset() { *x = DeleteResponse_Body{} if protoimpl.UnsafeEnabled { - mi := &file_container_grpc_service_proto_msgTypes[17] + mi := &file_container_grpc_service_proto_msgTypes[13] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1203,7 +923,7 @@ func (x *DeleteResponse_Body) String() string { func (*DeleteResponse_Body) ProtoMessage() {} func (x *DeleteResponse_Body) ProtoReflect() protoreflect.Message { - mi := &file_container_grpc_service_proto_msgTypes[17] + mi := &file_container_grpc_service_proto_msgTypes[13] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1232,7 +952,7 @@ type GetRequest_Body struct { func (x *GetRequest_Body) Reset() { *x = GetRequest_Body{} if protoimpl.UnsafeEnabled { - mi := &file_container_grpc_service_proto_msgTypes[18] + mi := &file_container_grpc_service_proto_msgTypes[14] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1245,7 +965,7 @@ func (x *GetRequest_Body) String() string { func (*GetRequest_Body) ProtoMessage() {} func (x *GetRequest_Body) ProtoReflect() protoreflect.Message { - mi := &file_container_grpc_service_proto_msgTypes[18] + mi := &file_container_grpc_service_proto_msgTypes[14] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1286,7 +1006,7 @@ type GetResponse_Body struct { func (x *GetResponse_Body) Reset() { *x = GetResponse_Body{} if protoimpl.UnsafeEnabled { - mi := &file_container_grpc_service_proto_msgTypes[19] + mi := &file_container_grpc_service_proto_msgTypes[15] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1299,7 +1019,7 @@ func (x *GetResponse_Body) String() string { func (*GetResponse_Body) ProtoMessage() {} func (x *GetResponse_Body) ProtoReflect() protoreflect.Message { - mi := &file_container_grpc_service_proto_msgTypes[19] + mi := &file_container_grpc_service_proto_msgTypes[15] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1349,7 +1069,7 @@ type ListRequest_Body struct { func (x *ListRequest_Body) Reset() { *x = ListRequest_Body{} if protoimpl.UnsafeEnabled { - mi := &file_container_grpc_service_proto_msgTypes[20] + mi := &file_container_grpc_service_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1362,7 +1082,7 @@ func (x *ListRequest_Body) String() string { func (*ListRequest_Body) ProtoMessage() {} func (x *ListRequest_Body) ProtoReflect() protoreflect.Message { - mi := &file_container_grpc_service_proto_msgTypes[20] + mi := &file_container_grpc_service_proto_msgTypes[16] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1398,7 +1118,7 @@ type ListResponse_Body struct { func (x *ListResponse_Body) Reset() { *x = ListResponse_Body{} if protoimpl.UnsafeEnabled { - mi := &file_container_grpc_service_proto_msgTypes[21] + mi := &file_container_grpc_service_proto_msgTypes[17] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1411,7 +1131,7 @@ func (x *ListResponse_Body) String() string { func (*ListResponse_Body) ProtoMessage() {} func (x *ListResponse_Body) ProtoReflect() protoreflect.Message { - mi := &file_container_grpc_service_proto_msgTypes[21] + mi := &file_container_grpc_service_proto_msgTypes[17] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1434,106 +1154,6 @@ func (x *ListResponse_Body) GetContainerIds() []*grpc1.ContainerID { return nil } -// Set Extended ACL request body does not have separate `ContainerID` -// reference. It will be taken from `EACLTable.container_id` field. -type SetExtendedACLRequest_Body struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // Extended ACL table to set for the container - Eacl *grpc2.EACLTable `protobuf:"bytes,1,opt,name=eacl,proto3" json:"eacl,omitempty"` - // Signature of stable-marshalled Extended ACL table according to RFC-6979. - Signature *grpc1.SignatureRFC6979 `protobuf:"bytes,2,opt,name=signature,proto3" json:"signature,omitempty"` -} - -func (x *SetExtendedACLRequest_Body) Reset() { - *x = SetExtendedACLRequest_Body{} - if protoimpl.UnsafeEnabled { - mi := &file_container_grpc_service_proto_msgTypes[22] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *SetExtendedACLRequest_Body) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SetExtendedACLRequest_Body) ProtoMessage() {} - -func (x *SetExtendedACLRequest_Body) ProtoReflect() protoreflect.Message { - mi := &file_container_grpc_service_proto_msgTypes[22] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SetExtendedACLRequest_Body.ProtoReflect.Descriptor instead. -func (*SetExtendedACLRequest_Body) Descriptor() ([]byte, []int) { - return file_container_grpc_service_proto_rawDescGZIP(), []int{8, 0} -} - -func (x *SetExtendedACLRequest_Body) GetEacl() *grpc2.EACLTable { - if x != nil { - return x.Eacl - } - return nil -} - -func (x *SetExtendedACLRequest_Body) GetSignature() *grpc1.SignatureRFC6979 { - if x != nil { - return x.Signature - } - return nil -} - -// `SetExtendedACLResponse` has an empty body because the operation is -// asynchronous and the update should be reflected in `Container` smart -// contract's storage after next block is issued in sidechain. -type SetExtendedACLResponse_Body struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields -} - -func (x *SetExtendedACLResponse_Body) Reset() { - *x = SetExtendedACLResponse_Body{} - if protoimpl.UnsafeEnabled { - mi := &file_container_grpc_service_proto_msgTypes[23] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *SetExtendedACLResponse_Body) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SetExtendedACLResponse_Body) ProtoMessage() {} - -func (x *SetExtendedACLResponse_Body) ProtoReflect() protoreflect.Message { - mi := &file_container_grpc_service_proto_msgTypes[23] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SetExtendedACLResponse_Body.ProtoReflect.Descriptor instead. -func (*SetExtendedACLResponse_Body) Descriptor() ([]byte, []int) { - return file_container_grpc_service_proto_rawDescGZIP(), []int{9, 0} -} - // Get Extended ACL request body type GetExtendedACLRequest_Body struct { state protoimpl.MessageState @@ -1547,7 +1167,7 @@ type GetExtendedACLRequest_Body struct { func (x *GetExtendedACLRequest_Body) Reset() { *x = GetExtendedACLRequest_Body{} if protoimpl.UnsafeEnabled { - mi := &file_container_grpc_service_proto_msgTypes[24] + mi := &file_container_grpc_service_proto_msgTypes[18] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1560,7 +1180,7 @@ func (x *GetExtendedACLRequest_Body) String() string { func (*GetExtendedACLRequest_Body) ProtoMessage() {} func (x *GetExtendedACLRequest_Body) ProtoReflect() protoreflect.Message { - mi := &file_container_grpc_service_proto_msgTypes[24] + mi := &file_container_grpc_service_proto_msgTypes[18] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1573,7 +1193,7 @@ func (x *GetExtendedACLRequest_Body) ProtoReflect() protoreflect.Message { // Deprecated: Use GetExtendedACLRequest_Body.ProtoReflect.Descriptor instead. func (*GetExtendedACLRequest_Body) Descriptor() ([]byte, []int) { - return file_container_grpc_service_proto_rawDescGZIP(), []int{10, 0} + return file_container_grpc_service_proto_rawDescGZIP(), []int{8, 0} } func (x *GetExtendedACLRequest_Body) GetContainerId() *grpc1.ContainerID { @@ -1602,7 +1222,7 @@ type GetExtendedACLResponse_Body struct { func (x *GetExtendedACLResponse_Body) Reset() { *x = GetExtendedACLResponse_Body{} if protoimpl.UnsafeEnabled { - mi := &file_container_grpc_service_proto_msgTypes[25] + mi := &file_container_grpc_service_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1615,7 +1235,7 @@ func (x *GetExtendedACLResponse_Body) String() string { func (*GetExtendedACLResponse_Body) ProtoMessage() {} func (x *GetExtendedACLResponse_Body) ProtoReflect() protoreflect.Message { - mi := &file_container_grpc_service_proto_msgTypes[25] + mi := &file_container_grpc_service_proto_msgTypes[19] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1628,7 +1248,7 @@ func (x *GetExtendedACLResponse_Body) ProtoReflect() protoreflect.Message { // Deprecated: Use GetExtendedACLResponse_Body.ProtoReflect.Descriptor instead. func (*GetExtendedACLResponse_Body) Descriptor() ([]byte, []int) { - return file_container_grpc_service_proto_rawDescGZIP(), []int{11, 0} + return file_container_grpc_service_proto_rawDescGZIP(), []int{9, 0} } func (x *GetExtendedACLResponse_Body) GetEacl() *grpc2.EACLTable { @@ -1652,164 +1272,6 @@ func (x *GetExtendedACLResponse_Body) GetSessionToken() *grpc.SessionToken { return nil } -// Container used space announcement body. -type AnnounceUsedSpaceRequest_Body struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // List of announcements. If nodes share several containers, - // announcements are transferred in a batch. - Announcements []*AnnounceUsedSpaceRequest_Body_Announcement `protobuf:"bytes,1,rep,name=announcements,proto3" json:"announcements,omitempty"` -} - -func (x *AnnounceUsedSpaceRequest_Body) Reset() { - *x = AnnounceUsedSpaceRequest_Body{} - if protoimpl.UnsafeEnabled { - mi := &file_container_grpc_service_proto_msgTypes[26] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *AnnounceUsedSpaceRequest_Body) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*AnnounceUsedSpaceRequest_Body) ProtoMessage() {} - -func (x *AnnounceUsedSpaceRequest_Body) ProtoReflect() protoreflect.Message { - mi := &file_container_grpc_service_proto_msgTypes[26] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use AnnounceUsedSpaceRequest_Body.ProtoReflect.Descriptor instead. -func (*AnnounceUsedSpaceRequest_Body) Descriptor() ([]byte, []int) { - return file_container_grpc_service_proto_rawDescGZIP(), []int{12, 0} -} - -func (x *AnnounceUsedSpaceRequest_Body) GetAnnouncements() []*AnnounceUsedSpaceRequest_Body_Announcement { - if x != nil { - return x.Announcements - } - return nil -} - -// Announcement contains used space information for a single container. -type AnnounceUsedSpaceRequest_Body_Announcement struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // Epoch number for which the container size estimation was produced. - Epoch uint64 `protobuf:"varint,1,opt,name=epoch,proto3" json:"epoch,omitempty"` - // Identifier of the container. - ContainerId *grpc1.ContainerID `protobuf:"bytes,2,opt,name=container_id,json=containerId,proto3" json:"container_id,omitempty"` - // Used space is a sum of object payload sizes of a specified - // container, stored in the node. It must not include inhumed objects. - UsedSpace uint64 `protobuf:"varint,3,opt,name=used_space,json=usedSpace,proto3" json:"used_space,omitempty"` -} - -func (x *AnnounceUsedSpaceRequest_Body_Announcement) Reset() { - *x = AnnounceUsedSpaceRequest_Body_Announcement{} - if protoimpl.UnsafeEnabled { - mi := &file_container_grpc_service_proto_msgTypes[27] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *AnnounceUsedSpaceRequest_Body_Announcement) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*AnnounceUsedSpaceRequest_Body_Announcement) ProtoMessage() {} - -func (x *AnnounceUsedSpaceRequest_Body_Announcement) ProtoReflect() protoreflect.Message { - mi := &file_container_grpc_service_proto_msgTypes[27] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use AnnounceUsedSpaceRequest_Body_Announcement.ProtoReflect.Descriptor instead. -func (*AnnounceUsedSpaceRequest_Body_Announcement) Descriptor() ([]byte, []int) { - return file_container_grpc_service_proto_rawDescGZIP(), []int{12, 0, 0} -} - -func (x *AnnounceUsedSpaceRequest_Body_Announcement) GetEpoch() uint64 { - if x != nil { - return x.Epoch - } - return 0 -} - -func (x *AnnounceUsedSpaceRequest_Body_Announcement) GetContainerId() *grpc1.ContainerID { - if x != nil { - return x.ContainerId - } - return nil -} - -func (x *AnnounceUsedSpaceRequest_Body_Announcement) GetUsedSpace() uint64 { - if x != nil { - return x.UsedSpace - } - return 0 -} - -// `AnnounceUsedSpaceResponse` has an empty body because announcements are -// one way communication. -type AnnounceUsedSpaceResponse_Body struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields -} - -func (x *AnnounceUsedSpaceResponse_Body) Reset() { - *x = AnnounceUsedSpaceResponse_Body{} - if protoimpl.UnsafeEnabled { - mi := &file_container_grpc_service_proto_msgTypes[28] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *AnnounceUsedSpaceResponse_Body) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*AnnounceUsedSpaceResponse_Body) ProtoMessage() {} - -func (x *AnnounceUsedSpaceResponse_Body) ProtoReflect() protoreflect.Message { - mi := &file_container_grpc_service_proto_msgTypes[28] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use AnnounceUsedSpaceResponse_Body.ProtoReflect.Descriptor instead. -func (*AnnounceUsedSpaceResponse_Body) Descriptor() ([]byte, []int) { - return file_container_grpc_service_proto_rawDescGZIP(), []int{13, 0} -} - var File_container_grpc_service_proto protoreflect.FileDescriptor var file_container_grpc_service_proto_rawDesc = []byte{ @@ -1985,11 +1447,11 @@ var file_container_grpc_service_proto_rawDesc = []byte{ 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x69, 0x64, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, 0x65, 0x66, 0x73, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x52, 0x0c, 0x63, 0x6f, 0x6e, - 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x49, 0x64, 0x73, 0x22, 0xec, 0x02, 0x0a, 0x15, 0x53, 0x65, + 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x49, 0x64, 0x73, 0x22, 0xbe, 0x02, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x64, 0x65, 0x64, 0x41, 0x43, 0x4c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x43, 0x0a, 0x04, 0x62, 0x6f, 0x64, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2f, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, - 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x53, 0x65, 0x74, 0x45, 0x78, 0x74, 0x65, 0x6e, + 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x47, 0x65, 0x74, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x64, 0x65, 0x64, 0x41, 0x43, 0x4c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x2e, 0x42, 0x6f, 0x64, 0x79, 0x52, 0x04, 0x62, 0x6f, 0x64, 0x79, 0x12, 0x45, 0x0a, 0x0b, 0x6d, 0x65, 0x74, 0x61, 0x5f, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, @@ -2001,174 +1463,73 @@ var file_container_grpc_service_proto_rawDesc = []byte{ 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x56, 0x65, 0x72, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x0c, 0x76, 0x65, 0x72, 0x69, 0x66, 0x79, 0x48, 0x65, 0x61, 0x64, - 0x65, 0x72, 0x1a, 0x74, 0x0a, 0x04, 0x42, 0x6f, 0x64, 0x79, 0x12, 0x2c, 0x0a, 0x04, 0x65, 0x61, - 0x63, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, - 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x61, 0x63, 0x6c, 0x2e, 0x45, 0x41, 0x43, 0x4c, 0x54, 0x61, 0x62, - 0x6c, 0x65, 0x52, 0x04, 0x65, 0x61, 0x63, 0x6c, 0x12, 0x3e, 0x0a, 0x09, 0x73, 0x69, 0x67, 0x6e, - 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x6e, 0x65, - 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, 0x65, 0x66, 0x73, 0x2e, 0x53, 0x69, 0x67, - 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x46, 0x43, 0x36, 0x39, 0x37, 0x39, 0x52, 0x09, 0x73, - 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x22, 0x82, 0x02, 0x0a, 0x16, 0x53, 0x65, 0x74, - 0x45, 0x78, 0x74, 0x65, 0x6e, 0x64, 0x65, 0x64, 0x41, 0x43, 0x4c, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x12, 0x44, 0x0a, 0x04, 0x62, 0x6f, 0x64, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x30, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, - 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x53, 0x65, 0x74, 0x45, 0x78, 0x74, 0x65, 0x6e, - 0x64, 0x65, 0x64, 0x41, 0x43, 0x4c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2e, 0x42, - 0x6f, 0x64, 0x79, 0x52, 0x04, 0x62, 0x6f, 0x64, 0x79, 0x12, 0x46, 0x0a, 0x0b, 0x6d, 0x65, 0x74, - 0x61, 0x5f, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x25, - 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, - 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x48, - 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x0a, 0x6d, 0x65, 0x74, 0x61, 0x48, 0x65, 0x61, 0x64, 0x65, - 0x72, 0x12, 0x52, 0x0a, 0x0d, 0x76, 0x65, 0x72, 0x69, 0x66, 0x79, 0x5f, 0x68, 0x65, 0x61, 0x64, - 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2d, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, - 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x56, 0x65, 0x72, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x0c, 0x76, 0x65, 0x72, 0x69, 0x66, 0x79, 0x48, - 0x65, 0x61, 0x64, 0x65, 0x72, 0x1a, 0x06, 0x0a, 0x04, 0x42, 0x6f, 0x64, 0x79, 0x22, 0xbe, 0x02, - 0x0a, 0x15, 0x47, 0x65, 0x74, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x64, 0x65, 0x64, 0x41, 0x43, 0x4c, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x43, 0x0a, 0x04, 0x62, 0x6f, 0x64, 0x79, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2f, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, - 0x32, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x47, 0x65, 0x74, 0x45, - 0x78, 0x74, 0x65, 0x6e, 0x64, 0x65, 0x64, 0x41, 0x43, 0x4c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x2e, 0x42, 0x6f, 0x64, 0x79, 0x52, 0x04, 0x62, 0x6f, 0x64, 0x79, 0x12, 0x45, 0x0a, 0x0b, - 0x6d, 0x65, 0x74, 0x61, 0x5f, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x24, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, - 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x4d, 0x65, 0x74, + 0x65, 0x72, 0x1a, 0x46, 0x0a, 0x04, 0x42, 0x6f, 0x64, 0x79, 0x12, 0x3e, 0x0a, 0x0c, 0x63, 0x6f, + 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x1b, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, 0x65, 0x66, + 0x73, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x52, 0x0b, 0x63, + 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x49, 0x64, 0x22, 0xb7, 0x03, 0x0a, 0x16, 0x47, + 0x65, 0x74, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x64, 0x65, 0x64, 0x41, 0x43, 0x4c, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x44, 0x0a, 0x04, 0x62, 0x6f, 0x64, 0x79, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x30, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, + 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x47, 0x65, 0x74, 0x45, 0x78, 0x74, + 0x65, 0x6e, 0x64, 0x65, 0x64, 0x41, 0x43, 0x4c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x2e, 0x42, 0x6f, 0x64, 0x79, 0x52, 0x04, 0x62, 0x6f, 0x64, 0x79, 0x12, 0x46, 0x0a, 0x0b, 0x6d, + 0x65, 0x74, 0x61, 0x5f, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x25, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, + 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x0a, 0x6d, 0x65, 0x74, 0x61, 0x48, 0x65, 0x61, - 0x64, 0x65, 0x72, 0x12, 0x51, 0x0a, 0x0d, 0x76, 0x65, 0x72, 0x69, 0x66, 0x79, 0x5f, 0x68, 0x65, - 0x61, 0x64, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2c, 0x2e, 0x6e, 0x65, 0x6f, + 0x64, 0x65, 0x72, 0x12, 0x52, 0x0a, 0x0d, 0x76, 0x65, 0x72, 0x69, 0x66, 0x79, 0x5f, 0x68, 0x65, + 0x61, 0x64, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2d, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x56, 0x65, 0x72, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x0c, 0x76, 0x65, 0x72, 0x69, 0x66, 0x79, - 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x1a, 0x46, 0x0a, 0x04, 0x42, 0x6f, 0x64, 0x79, 0x12, 0x3e, - 0x0a, 0x0c, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, - 0x2e, 0x72, 0x65, 0x66, 0x73, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x49, - 0x44, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x49, 0x64, 0x22, 0xb7, - 0x03, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x64, 0x65, 0x64, 0x41, 0x43, - 0x4c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x44, 0x0a, 0x04, 0x62, 0x6f, 0x64, - 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x30, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, - 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x47, 0x65, - 0x74, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x64, 0x65, 0x64, 0x41, 0x43, 0x4c, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x2e, 0x42, 0x6f, 0x64, 0x79, 0x52, 0x04, 0x62, 0x6f, 0x64, 0x79, 0x12, - 0x46, 0x0a, 0x0b, 0x6d, 0x65, 0x74, 0x61, 0x5f, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, - 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x4d, 0x65, 0x74, 0x61, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x0a, 0x6d, 0x65, 0x74, - 0x61, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x12, 0x52, 0x0a, 0x0d, 0x76, 0x65, 0x72, 0x69, 0x66, - 0x79, 0x5f, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2d, - 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, - 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x56, 0x65, 0x72, 0x69, 0x66, - 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x0c, 0x76, - 0x65, 0x72, 0x69, 0x66, 0x79, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x1a, 0xba, 0x01, 0x0a, 0x04, - 0x42, 0x6f, 0x64, 0x79, 0x12, 0x2c, 0x0a, 0x04, 0x65, 0x61, 0x63, 0x6c, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x61, - 0x63, 0x6c, 0x2e, 0x45, 0x41, 0x43, 0x4c, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x52, 0x04, 0x65, 0x61, - 0x63, 0x6c, 0x12, 0x3e, 0x0a, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, - 0x32, 0x2e, 0x72, 0x65, 0x66, 0x73, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, - 0x52, 0x46, 0x43, 0x36, 0x39, 0x37, 0x39, 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, - 0x72, 0x65, 0x12, 0x44, 0x0a, 0x0d, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x5f, 0x74, 0x6f, - 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, - 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x53, 0x65, - 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x0c, 0x73, 0x65, 0x73, 0x73, - 0x69, 0x6f, 0x6e, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x22, 0xf2, 0x03, 0x0a, 0x18, 0x41, 0x6e, 0x6e, - 0x6f, 0x75, 0x6e, 0x63, 0x65, 0x55, 0x73, 0x65, 0x64, 0x53, 0x70, 0x61, 0x63, 0x65, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x46, 0x0a, 0x04, 0x62, 0x6f, 0x64, 0x79, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x0b, 0x32, 0x32, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, - 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x41, 0x6e, 0x6e, 0x6f, 0x75, 0x6e, - 0x63, 0x65, 0x55, 0x73, 0x65, 0x64, 0x53, 0x70, 0x61, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x2e, 0x42, 0x6f, 0x64, 0x79, 0x52, 0x04, 0x62, 0x6f, 0x64, 0x79, 0x12, 0x45, 0x0a, - 0x0b, 0x6d, 0x65, 0x74, 0x61, 0x5f, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, - 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x4d, 0x65, - 0x74, 0x61, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x0a, 0x6d, 0x65, 0x74, 0x61, 0x48, 0x65, - 0x61, 0x64, 0x65, 0x72, 0x12, 0x51, 0x0a, 0x0d, 0x76, 0x65, 0x72, 0x69, 0x66, 0x79, 0x5f, 0x68, - 0x65, 0x61, 0x64, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2c, 0x2e, 0x6e, 0x65, - 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x56, 0x65, 0x72, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x56, 0x65, 0x72, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x0c, 0x76, 0x65, 0x72, 0x69, 0x66, - 0x79, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x1a, 0xf3, 0x01, 0x0a, 0x04, 0x42, 0x6f, 0x64, 0x79, - 0x12, 0x65, 0x0a, 0x0d, 0x61, 0x6e, 0x6e, 0x6f, 0x75, 0x6e, 0x63, 0x65, 0x6d, 0x65, 0x6e, 0x74, - 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x3f, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, - 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x41, 0x6e, - 0x6e, 0x6f, 0x75, 0x6e, 0x63, 0x65, 0x55, 0x73, 0x65, 0x64, 0x53, 0x70, 0x61, 0x63, 0x65, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x2e, 0x42, 0x6f, 0x64, 0x79, 0x2e, 0x41, 0x6e, 0x6e, 0x6f, - 0x75, 0x6e, 0x63, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x52, 0x0d, 0x61, 0x6e, 0x6e, 0x6f, 0x75, 0x6e, - 0x63, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x1a, 0x83, 0x01, 0x0a, 0x0c, 0x41, 0x6e, 0x6e, 0x6f, - 0x75, 0x6e, 0x63, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x70, 0x6f, 0x63, - 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x65, 0x70, 0x6f, 0x63, 0x68, 0x12, 0x3e, - 0x0a, 0x0c, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, - 0x2e, 0x72, 0x65, 0x66, 0x73, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x49, - 0x44, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x49, 0x64, 0x12, 0x1d, - 0x0a, 0x0a, 0x75, 0x73, 0x65, 0x64, 0x5f, 0x73, 0x70, 0x61, 0x63, 0x65, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x04, 0x52, 0x09, 0x75, 0x73, 0x65, 0x64, 0x53, 0x70, 0x61, 0x63, 0x65, 0x22, 0x88, 0x02, - 0x0a, 0x19, 0x41, 0x6e, 0x6e, 0x6f, 0x75, 0x6e, 0x63, 0x65, 0x55, 0x73, 0x65, 0x64, 0x53, 0x70, - 0x61, 0x63, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x04, 0x62, - 0x6f, 0x64, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x33, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, - 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2e, - 0x41, 0x6e, 0x6e, 0x6f, 0x75, 0x6e, 0x63, 0x65, 0x55, 0x73, 0x65, 0x64, 0x53, 0x70, 0x61, 0x63, - 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2e, 0x42, 0x6f, 0x64, 0x79, 0x52, 0x04, - 0x62, 0x6f, 0x64, 0x79, 0x12, 0x46, 0x0a, 0x0b, 0x6d, 0x65, 0x74, 0x61, 0x5f, 0x68, 0x65, 0x61, - 0x64, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, - 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, - 0x52, 0x0a, 0x6d, 0x65, 0x74, 0x61, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x12, 0x52, 0x0a, 0x0d, - 0x76, 0x65, 0x72, 0x69, 0x66, 0x79, 0x5f, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x0b, 0x32, 0x2d, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, - 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x56, 0x65, 0x72, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x48, 0x65, 0x61, 0x64, - 0x65, 0x72, 0x52, 0x0c, 0x76, 0x65, 0x72, 0x69, 0x66, 0x79, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, - 0x1a, 0x06, 0x0a, 0x04, 0x42, 0x6f, 0x64, 0x79, 0x32, 0x90, 0x05, 0x0a, 0x10, 0x43, 0x6f, 0x6e, - 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x48, 0x0a, - 0x03, 0x50, 0x75, 0x74, 0x12, 0x1f, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, - 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x50, 0x75, 0x74, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, - 0x32, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x50, 0x75, 0x74, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x51, 0x0a, 0x06, 0x44, 0x65, 0x6c, 0x65, 0x74, - 0x65, 0x12, 0x22, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, + 0x79, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x1a, 0xba, 0x01, 0x0a, 0x04, 0x42, 0x6f, 0x64, 0x79, + 0x12, 0x2c, 0x0a, 0x04, 0x65, 0x61, 0x63, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x18, + 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x61, 0x63, 0x6c, 0x2e, 0x45, + 0x41, 0x43, 0x4c, 0x54, 0x61, 0x62, 0x6c, 0x65, 0x52, 0x04, 0x65, 0x61, 0x63, 0x6c, 0x12, 0x3e, + 0x0a, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x20, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, 0x65, + 0x66, 0x73, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x46, 0x43, 0x36, + 0x39, 0x37, 0x39, 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x44, + 0x0a, 0x0d, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, + 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, + 0x6e, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x0c, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x54, + 0x6f, 0x6b, 0x65, 0x6e, 0x32, 0xb1, 0x03, 0x0a, 0x10, 0x43, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, + 0x65, 0x72, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x48, 0x0a, 0x03, 0x50, 0x75, 0x74, + 0x12, 0x1f, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, 0x6e, + 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x50, 0x75, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x20, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, + 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x50, 0x75, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x12, 0x51, 0x0a, 0x06, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x12, 0x22, 0x2e, + 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, + 0x6e, 0x65, 0x72, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x23, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x23, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, - 0x32, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x44, 0x65, 0x6c, 0x65, - 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x48, 0x0a, 0x03, 0x47, 0x65, - 0x74, 0x12, 0x1f, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, - 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x63, - 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x4b, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x20, 0x2e, 0x6e, - 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, - 0x65, 0x72, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x21, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x48, 0x0a, 0x03, 0x47, 0x65, 0x74, 0x12, 0x1f, 0x2e, + 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, + 0x6e, 0x65, 0x72, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, - 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x12, 0x69, 0x0a, 0x0e, 0x53, 0x65, 0x74, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x64, 0x65, 0x64, - 0x41, 0x43, 0x4c, 0x12, 0x2a, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, - 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x53, 0x65, 0x74, 0x45, 0x78, 0x74, - 0x65, 0x6e, 0x64, 0x65, 0x64, 0x41, 0x43, 0x4c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, - 0x2b, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, 0x6e, 0x74, - 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x53, 0x65, 0x74, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x64, 0x65, - 0x64, 0x41, 0x43, 0x4c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x69, 0x0a, 0x0e, - 0x47, 0x65, 0x74, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x64, 0x65, 0x64, 0x41, 0x43, 0x4c, 0x12, 0x2a, - 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, - 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x47, 0x65, 0x74, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x64, 0x65, 0x64, - 0x41, 0x43, 0x4c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x6e, 0x65, 0x6f, + 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x4b, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x20, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, + 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x4c, + 0x69, 0x73, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x21, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, - 0x2e, 0x47, 0x65, 0x74, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x64, 0x65, 0x64, 0x41, 0x43, 0x4c, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x72, 0x0a, 0x11, 0x41, 0x6e, 0x6e, 0x6f, 0x75, - 0x6e, 0x63, 0x65, 0x55, 0x73, 0x65, 0x64, 0x53, 0x70, 0x61, 0x63, 0x65, 0x12, 0x2d, 0x2e, 0x6e, - 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, - 0x65, 0x72, 0x2e, 0x41, 0x6e, 0x6e, 0x6f, 0x75, 0x6e, 0x63, 0x65, 0x55, 0x73, 0x65, 0x64, 0x53, - 0x70, 0x61, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2e, 0x2e, 0x6e, 0x65, + 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x69, 0x0a, + 0x0e, 0x47, 0x65, 0x74, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x64, 0x65, 0x64, 0x41, 0x43, 0x4c, 0x12, + 0x2a, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, 0x6e, 0x74, + 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2e, 0x47, 0x65, 0x74, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x64, 0x65, + 0x64, 0x41, 0x43, 0x4c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2b, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, - 0x72, 0x2e, 0x41, 0x6e, 0x6e, 0x6f, 0x75, 0x6e, 0x63, 0x65, 0x55, 0x73, 0x65, 0x64, 0x53, 0x70, - 0x61, 0x63, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x6a, 0x5a, 0x48, 0x67, - 0x69, 0x74, 0x2e, 0x66, 0x72, 0x6f, 0x73, 0x74, 0x66, 0x73, 0x2e, 0x69, 0x6e, 0x66, 0x6f, 0x2f, - 0x54, 0x72, 0x75, 0x65, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x4c, 0x61, 0x62, 0x2f, 0x66, 0x72, 0x6f, - 0x73, 0x74, 0x66, 0x73, 0x2d, 0x61, 0x70, 0x69, 0x2d, 0x67, 0x6f, 0x2f, 0x76, 0x32, 0x2f, 0x63, - 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2f, 0x67, 0x72, 0x70, 0x63, 0x3b, 0x63, 0x6f, - 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0xaa, 0x02, 0x1d, 0x4e, 0x65, 0x6f, 0x2e, 0x46, 0x69, - 0x6c, 0x65, 0x53, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x2e, 0x41, 0x50, 0x49, 0x2e, 0x43, 0x6f, - 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x72, 0x2e, 0x47, 0x65, 0x74, 0x45, 0x78, 0x74, 0x65, 0x6e, 0x64, 0x65, 0x64, 0x41, 0x43, 0x4c, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x6a, 0x5a, 0x48, 0x67, 0x69, 0x74, 0x2e, + 0x66, 0x72, 0x6f, 0x73, 0x74, 0x66, 0x73, 0x2e, 0x69, 0x6e, 0x66, 0x6f, 0x2f, 0x54, 0x72, 0x75, + 0x65, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x4c, 0x61, 0x62, 0x2f, 0x66, 0x72, 0x6f, 0x73, 0x74, 0x66, + 0x73, 0x2d, 0x61, 0x70, 0x69, 0x2d, 0x67, 0x6f, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x74, + 0x61, 0x69, 0x6e, 0x65, 0x72, 0x2f, 0x67, 0x72, 0x70, 0x63, 0x3b, 0x63, 0x6f, 0x6e, 0x74, 0x61, + 0x69, 0x6e, 0x65, 0x72, 0xaa, 0x02, 0x1d, 0x4e, 0x65, 0x6f, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, + 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x2e, 0x41, 0x50, 0x49, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x61, + 0x69, 0x6e, 0x65, 0x72, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -2183,129 +1544,100 @@ func file_container_grpc_service_proto_rawDescGZIP() []byte { return file_container_grpc_service_proto_rawDescData } -var file_container_grpc_service_proto_msgTypes = make([]protoimpl.MessageInfo, 29) +var file_container_grpc_service_proto_msgTypes = make([]protoimpl.MessageInfo, 20) var file_container_grpc_service_proto_goTypes = []interface{}{ - (*PutRequest)(nil), // 0: neo.fs.v2.container.PutRequest - (*PutResponse)(nil), // 1: neo.fs.v2.container.PutResponse - (*DeleteRequest)(nil), // 2: neo.fs.v2.container.DeleteRequest - (*DeleteResponse)(nil), // 3: neo.fs.v2.container.DeleteResponse - (*GetRequest)(nil), // 4: neo.fs.v2.container.GetRequest - (*GetResponse)(nil), // 5: neo.fs.v2.container.GetResponse - (*ListRequest)(nil), // 6: neo.fs.v2.container.ListRequest - (*ListResponse)(nil), // 7: neo.fs.v2.container.ListResponse - (*SetExtendedACLRequest)(nil), // 8: neo.fs.v2.container.SetExtendedACLRequest - (*SetExtendedACLResponse)(nil), // 9: neo.fs.v2.container.SetExtendedACLResponse - (*GetExtendedACLRequest)(nil), // 10: neo.fs.v2.container.GetExtendedACLRequest - (*GetExtendedACLResponse)(nil), // 11: neo.fs.v2.container.GetExtendedACLResponse - (*AnnounceUsedSpaceRequest)(nil), // 12: neo.fs.v2.container.AnnounceUsedSpaceRequest - (*AnnounceUsedSpaceResponse)(nil), // 13: neo.fs.v2.container.AnnounceUsedSpaceResponse - (*PutRequest_Body)(nil), // 14: neo.fs.v2.container.PutRequest.Body - (*PutResponse_Body)(nil), // 15: neo.fs.v2.container.PutResponse.Body - (*DeleteRequest_Body)(nil), // 16: neo.fs.v2.container.DeleteRequest.Body - (*DeleteResponse_Body)(nil), // 17: neo.fs.v2.container.DeleteResponse.Body - (*GetRequest_Body)(nil), // 18: neo.fs.v2.container.GetRequest.Body - (*GetResponse_Body)(nil), // 19: neo.fs.v2.container.GetResponse.Body - (*ListRequest_Body)(nil), // 20: neo.fs.v2.container.ListRequest.Body - (*ListResponse_Body)(nil), // 21: neo.fs.v2.container.ListResponse.Body - (*SetExtendedACLRequest_Body)(nil), // 22: neo.fs.v2.container.SetExtendedACLRequest.Body - (*SetExtendedACLResponse_Body)(nil), // 23: neo.fs.v2.container.SetExtendedACLResponse.Body - (*GetExtendedACLRequest_Body)(nil), // 24: neo.fs.v2.container.GetExtendedACLRequest.Body - (*GetExtendedACLResponse_Body)(nil), // 25: neo.fs.v2.container.GetExtendedACLResponse.Body - (*AnnounceUsedSpaceRequest_Body)(nil), // 26: neo.fs.v2.container.AnnounceUsedSpaceRequest.Body - (*AnnounceUsedSpaceRequest_Body_Announcement)(nil), // 27: neo.fs.v2.container.AnnounceUsedSpaceRequest.Body.Announcement - (*AnnounceUsedSpaceResponse_Body)(nil), // 28: neo.fs.v2.container.AnnounceUsedSpaceResponse.Body - (*grpc.RequestMetaHeader)(nil), // 29: neo.fs.v2.session.RequestMetaHeader - (*grpc.RequestVerificationHeader)(nil), // 30: neo.fs.v2.session.RequestVerificationHeader - (*grpc.ResponseMetaHeader)(nil), // 31: neo.fs.v2.session.ResponseMetaHeader - (*grpc.ResponseVerificationHeader)(nil), // 32: neo.fs.v2.session.ResponseVerificationHeader - (*Container)(nil), // 33: neo.fs.v2.container.Container - (*grpc1.SignatureRFC6979)(nil), // 34: neo.fs.v2.refs.SignatureRFC6979 - (*grpc1.ContainerID)(nil), // 35: neo.fs.v2.refs.ContainerID - (*grpc.SessionToken)(nil), // 36: neo.fs.v2.session.SessionToken - (*grpc1.OwnerID)(nil), // 37: neo.fs.v2.refs.OwnerID - (*grpc2.EACLTable)(nil), // 38: neo.fs.v2.acl.EACLTable + (*PutRequest)(nil), // 0: neo.fs.v2.container.PutRequest + (*PutResponse)(nil), // 1: neo.fs.v2.container.PutResponse + (*DeleteRequest)(nil), // 2: neo.fs.v2.container.DeleteRequest + (*DeleteResponse)(nil), // 3: neo.fs.v2.container.DeleteResponse + (*GetRequest)(nil), // 4: neo.fs.v2.container.GetRequest + (*GetResponse)(nil), // 5: neo.fs.v2.container.GetResponse + (*ListRequest)(nil), // 6: neo.fs.v2.container.ListRequest + (*ListResponse)(nil), // 7: neo.fs.v2.container.ListResponse + (*GetExtendedACLRequest)(nil), // 8: neo.fs.v2.container.GetExtendedACLRequest + (*GetExtendedACLResponse)(nil), // 9: neo.fs.v2.container.GetExtendedACLResponse + (*PutRequest_Body)(nil), // 10: neo.fs.v2.container.PutRequest.Body + (*PutResponse_Body)(nil), // 11: neo.fs.v2.container.PutResponse.Body + (*DeleteRequest_Body)(nil), // 12: neo.fs.v2.container.DeleteRequest.Body + (*DeleteResponse_Body)(nil), // 13: neo.fs.v2.container.DeleteResponse.Body + (*GetRequest_Body)(nil), // 14: neo.fs.v2.container.GetRequest.Body + (*GetResponse_Body)(nil), // 15: neo.fs.v2.container.GetResponse.Body + (*ListRequest_Body)(nil), // 16: neo.fs.v2.container.ListRequest.Body + (*ListResponse_Body)(nil), // 17: neo.fs.v2.container.ListResponse.Body + (*GetExtendedACLRequest_Body)(nil), // 18: neo.fs.v2.container.GetExtendedACLRequest.Body + (*GetExtendedACLResponse_Body)(nil), // 19: neo.fs.v2.container.GetExtendedACLResponse.Body + (*grpc.RequestMetaHeader)(nil), // 20: neo.fs.v2.session.RequestMetaHeader + (*grpc.RequestVerificationHeader)(nil), // 21: neo.fs.v2.session.RequestVerificationHeader + (*grpc.ResponseMetaHeader)(nil), // 22: neo.fs.v2.session.ResponseMetaHeader + (*grpc.ResponseVerificationHeader)(nil), // 23: neo.fs.v2.session.ResponseVerificationHeader + (*Container)(nil), // 24: neo.fs.v2.container.Container + (*grpc1.SignatureRFC6979)(nil), // 25: neo.fs.v2.refs.SignatureRFC6979 + (*grpc1.ContainerID)(nil), // 26: neo.fs.v2.refs.ContainerID + (*grpc.SessionToken)(nil), // 27: neo.fs.v2.session.SessionToken + (*grpc1.OwnerID)(nil), // 28: neo.fs.v2.refs.OwnerID + (*grpc2.EACLTable)(nil), // 29: neo.fs.v2.acl.EACLTable } var file_container_grpc_service_proto_depIdxs = []int32{ - 14, // 0: neo.fs.v2.container.PutRequest.body:type_name -> neo.fs.v2.container.PutRequest.Body - 29, // 1: neo.fs.v2.container.PutRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader - 30, // 2: neo.fs.v2.container.PutRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader - 15, // 3: neo.fs.v2.container.PutResponse.body:type_name -> neo.fs.v2.container.PutResponse.Body - 31, // 4: neo.fs.v2.container.PutResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader - 32, // 5: neo.fs.v2.container.PutResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader - 16, // 6: neo.fs.v2.container.DeleteRequest.body:type_name -> neo.fs.v2.container.DeleteRequest.Body - 29, // 7: neo.fs.v2.container.DeleteRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader - 30, // 8: neo.fs.v2.container.DeleteRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader - 17, // 9: neo.fs.v2.container.DeleteResponse.body:type_name -> neo.fs.v2.container.DeleteResponse.Body - 31, // 10: neo.fs.v2.container.DeleteResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader - 32, // 11: neo.fs.v2.container.DeleteResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader - 18, // 12: neo.fs.v2.container.GetRequest.body:type_name -> neo.fs.v2.container.GetRequest.Body - 29, // 13: neo.fs.v2.container.GetRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader - 30, // 14: neo.fs.v2.container.GetRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader - 19, // 15: neo.fs.v2.container.GetResponse.body:type_name -> neo.fs.v2.container.GetResponse.Body - 31, // 16: neo.fs.v2.container.GetResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader - 32, // 17: neo.fs.v2.container.GetResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader - 20, // 18: neo.fs.v2.container.ListRequest.body:type_name -> neo.fs.v2.container.ListRequest.Body - 29, // 19: neo.fs.v2.container.ListRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader - 30, // 20: neo.fs.v2.container.ListRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader - 21, // 21: neo.fs.v2.container.ListResponse.body:type_name -> neo.fs.v2.container.ListResponse.Body - 31, // 22: neo.fs.v2.container.ListResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader - 32, // 23: neo.fs.v2.container.ListResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader - 22, // 24: neo.fs.v2.container.SetExtendedACLRequest.body:type_name -> neo.fs.v2.container.SetExtendedACLRequest.Body - 29, // 25: neo.fs.v2.container.SetExtendedACLRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader - 30, // 26: neo.fs.v2.container.SetExtendedACLRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader - 23, // 27: neo.fs.v2.container.SetExtendedACLResponse.body:type_name -> neo.fs.v2.container.SetExtendedACLResponse.Body - 31, // 28: neo.fs.v2.container.SetExtendedACLResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader - 32, // 29: neo.fs.v2.container.SetExtendedACLResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader - 24, // 30: neo.fs.v2.container.GetExtendedACLRequest.body:type_name -> neo.fs.v2.container.GetExtendedACLRequest.Body - 29, // 31: neo.fs.v2.container.GetExtendedACLRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader - 30, // 32: neo.fs.v2.container.GetExtendedACLRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader - 25, // 33: neo.fs.v2.container.GetExtendedACLResponse.body:type_name -> neo.fs.v2.container.GetExtendedACLResponse.Body - 31, // 34: neo.fs.v2.container.GetExtendedACLResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader - 32, // 35: neo.fs.v2.container.GetExtendedACLResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader - 26, // 36: neo.fs.v2.container.AnnounceUsedSpaceRequest.body:type_name -> neo.fs.v2.container.AnnounceUsedSpaceRequest.Body - 29, // 37: neo.fs.v2.container.AnnounceUsedSpaceRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader - 30, // 38: neo.fs.v2.container.AnnounceUsedSpaceRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader - 28, // 39: neo.fs.v2.container.AnnounceUsedSpaceResponse.body:type_name -> neo.fs.v2.container.AnnounceUsedSpaceResponse.Body - 31, // 40: neo.fs.v2.container.AnnounceUsedSpaceResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader - 32, // 41: neo.fs.v2.container.AnnounceUsedSpaceResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader - 33, // 42: neo.fs.v2.container.PutRequest.Body.container:type_name -> neo.fs.v2.container.Container - 34, // 43: neo.fs.v2.container.PutRequest.Body.signature:type_name -> neo.fs.v2.refs.SignatureRFC6979 - 35, // 44: neo.fs.v2.container.PutResponse.Body.container_id:type_name -> neo.fs.v2.refs.ContainerID - 35, // 45: neo.fs.v2.container.DeleteRequest.Body.container_id:type_name -> neo.fs.v2.refs.ContainerID - 34, // 46: neo.fs.v2.container.DeleteRequest.Body.signature:type_name -> neo.fs.v2.refs.SignatureRFC6979 - 35, // 47: neo.fs.v2.container.GetRequest.Body.container_id:type_name -> neo.fs.v2.refs.ContainerID - 33, // 48: neo.fs.v2.container.GetResponse.Body.container:type_name -> neo.fs.v2.container.Container - 34, // 49: neo.fs.v2.container.GetResponse.Body.signature:type_name -> neo.fs.v2.refs.SignatureRFC6979 - 36, // 50: neo.fs.v2.container.GetResponse.Body.session_token:type_name -> neo.fs.v2.session.SessionToken - 37, // 51: neo.fs.v2.container.ListRequest.Body.owner_id:type_name -> neo.fs.v2.refs.OwnerID - 35, // 52: neo.fs.v2.container.ListResponse.Body.container_ids:type_name -> neo.fs.v2.refs.ContainerID - 38, // 53: neo.fs.v2.container.SetExtendedACLRequest.Body.eacl:type_name -> neo.fs.v2.acl.EACLTable - 34, // 54: neo.fs.v2.container.SetExtendedACLRequest.Body.signature:type_name -> neo.fs.v2.refs.SignatureRFC6979 - 35, // 55: neo.fs.v2.container.GetExtendedACLRequest.Body.container_id:type_name -> neo.fs.v2.refs.ContainerID - 38, // 56: neo.fs.v2.container.GetExtendedACLResponse.Body.eacl:type_name -> neo.fs.v2.acl.EACLTable - 34, // 57: neo.fs.v2.container.GetExtendedACLResponse.Body.signature:type_name -> neo.fs.v2.refs.SignatureRFC6979 - 36, // 58: neo.fs.v2.container.GetExtendedACLResponse.Body.session_token:type_name -> neo.fs.v2.session.SessionToken - 27, // 59: neo.fs.v2.container.AnnounceUsedSpaceRequest.Body.announcements:type_name -> neo.fs.v2.container.AnnounceUsedSpaceRequest.Body.Announcement - 35, // 60: neo.fs.v2.container.AnnounceUsedSpaceRequest.Body.Announcement.container_id:type_name -> neo.fs.v2.refs.ContainerID - 0, // 61: neo.fs.v2.container.ContainerService.Put:input_type -> neo.fs.v2.container.PutRequest - 2, // 62: neo.fs.v2.container.ContainerService.Delete:input_type -> neo.fs.v2.container.DeleteRequest - 4, // 63: neo.fs.v2.container.ContainerService.Get:input_type -> neo.fs.v2.container.GetRequest - 6, // 64: neo.fs.v2.container.ContainerService.List:input_type -> neo.fs.v2.container.ListRequest - 8, // 65: neo.fs.v2.container.ContainerService.SetExtendedACL:input_type -> neo.fs.v2.container.SetExtendedACLRequest - 10, // 66: neo.fs.v2.container.ContainerService.GetExtendedACL:input_type -> neo.fs.v2.container.GetExtendedACLRequest - 12, // 67: neo.fs.v2.container.ContainerService.AnnounceUsedSpace:input_type -> neo.fs.v2.container.AnnounceUsedSpaceRequest - 1, // 68: neo.fs.v2.container.ContainerService.Put:output_type -> neo.fs.v2.container.PutResponse - 3, // 69: neo.fs.v2.container.ContainerService.Delete:output_type -> neo.fs.v2.container.DeleteResponse - 5, // 70: neo.fs.v2.container.ContainerService.Get:output_type -> neo.fs.v2.container.GetResponse - 7, // 71: neo.fs.v2.container.ContainerService.List:output_type -> neo.fs.v2.container.ListResponse - 9, // 72: neo.fs.v2.container.ContainerService.SetExtendedACL:output_type -> neo.fs.v2.container.SetExtendedACLResponse - 11, // 73: neo.fs.v2.container.ContainerService.GetExtendedACL:output_type -> neo.fs.v2.container.GetExtendedACLResponse - 13, // 74: neo.fs.v2.container.ContainerService.AnnounceUsedSpace:output_type -> neo.fs.v2.container.AnnounceUsedSpaceResponse - 68, // [68:75] is the sub-list for method output_type - 61, // [61:68] is the sub-list for method input_type - 61, // [61:61] is the sub-list for extension type_name - 61, // [61:61] is the sub-list for extension extendee - 0, // [0:61] is the sub-list for field type_name + 10, // 0: neo.fs.v2.container.PutRequest.body:type_name -> neo.fs.v2.container.PutRequest.Body + 20, // 1: neo.fs.v2.container.PutRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader + 21, // 2: neo.fs.v2.container.PutRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader + 11, // 3: neo.fs.v2.container.PutResponse.body:type_name -> neo.fs.v2.container.PutResponse.Body + 22, // 4: neo.fs.v2.container.PutResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader + 23, // 5: neo.fs.v2.container.PutResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader + 12, // 6: neo.fs.v2.container.DeleteRequest.body:type_name -> neo.fs.v2.container.DeleteRequest.Body + 20, // 7: neo.fs.v2.container.DeleteRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader + 21, // 8: neo.fs.v2.container.DeleteRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader + 13, // 9: neo.fs.v2.container.DeleteResponse.body:type_name -> neo.fs.v2.container.DeleteResponse.Body + 22, // 10: neo.fs.v2.container.DeleteResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader + 23, // 11: neo.fs.v2.container.DeleteResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader + 14, // 12: neo.fs.v2.container.GetRequest.body:type_name -> neo.fs.v2.container.GetRequest.Body + 20, // 13: neo.fs.v2.container.GetRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader + 21, // 14: neo.fs.v2.container.GetRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader + 15, // 15: neo.fs.v2.container.GetResponse.body:type_name -> neo.fs.v2.container.GetResponse.Body + 22, // 16: neo.fs.v2.container.GetResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader + 23, // 17: neo.fs.v2.container.GetResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader + 16, // 18: neo.fs.v2.container.ListRequest.body:type_name -> neo.fs.v2.container.ListRequest.Body + 20, // 19: neo.fs.v2.container.ListRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader + 21, // 20: neo.fs.v2.container.ListRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader + 17, // 21: neo.fs.v2.container.ListResponse.body:type_name -> neo.fs.v2.container.ListResponse.Body + 22, // 22: neo.fs.v2.container.ListResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader + 23, // 23: neo.fs.v2.container.ListResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader + 18, // 24: neo.fs.v2.container.GetExtendedACLRequest.body:type_name -> neo.fs.v2.container.GetExtendedACLRequest.Body + 20, // 25: neo.fs.v2.container.GetExtendedACLRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader + 21, // 26: neo.fs.v2.container.GetExtendedACLRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader + 19, // 27: neo.fs.v2.container.GetExtendedACLResponse.body:type_name -> neo.fs.v2.container.GetExtendedACLResponse.Body + 22, // 28: neo.fs.v2.container.GetExtendedACLResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader + 23, // 29: neo.fs.v2.container.GetExtendedACLResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader + 24, // 30: neo.fs.v2.container.PutRequest.Body.container:type_name -> neo.fs.v2.container.Container + 25, // 31: neo.fs.v2.container.PutRequest.Body.signature:type_name -> neo.fs.v2.refs.SignatureRFC6979 + 26, // 32: neo.fs.v2.container.PutResponse.Body.container_id:type_name -> neo.fs.v2.refs.ContainerID + 26, // 33: neo.fs.v2.container.DeleteRequest.Body.container_id:type_name -> neo.fs.v2.refs.ContainerID + 25, // 34: neo.fs.v2.container.DeleteRequest.Body.signature:type_name -> neo.fs.v2.refs.SignatureRFC6979 + 26, // 35: neo.fs.v2.container.GetRequest.Body.container_id:type_name -> neo.fs.v2.refs.ContainerID + 24, // 36: neo.fs.v2.container.GetResponse.Body.container:type_name -> neo.fs.v2.container.Container + 25, // 37: neo.fs.v2.container.GetResponse.Body.signature:type_name -> neo.fs.v2.refs.SignatureRFC6979 + 27, // 38: neo.fs.v2.container.GetResponse.Body.session_token:type_name -> neo.fs.v2.session.SessionToken + 28, // 39: neo.fs.v2.container.ListRequest.Body.owner_id:type_name -> neo.fs.v2.refs.OwnerID + 26, // 40: neo.fs.v2.container.ListResponse.Body.container_ids:type_name -> neo.fs.v2.refs.ContainerID + 26, // 41: neo.fs.v2.container.GetExtendedACLRequest.Body.container_id:type_name -> neo.fs.v2.refs.ContainerID + 29, // 42: neo.fs.v2.container.GetExtendedACLResponse.Body.eacl:type_name -> neo.fs.v2.acl.EACLTable + 25, // 43: neo.fs.v2.container.GetExtendedACLResponse.Body.signature:type_name -> neo.fs.v2.refs.SignatureRFC6979 + 27, // 44: neo.fs.v2.container.GetExtendedACLResponse.Body.session_token:type_name -> neo.fs.v2.session.SessionToken + 0, // 45: neo.fs.v2.container.ContainerService.Put:input_type -> neo.fs.v2.container.PutRequest + 2, // 46: neo.fs.v2.container.ContainerService.Delete:input_type -> neo.fs.v2.container.DeleteRequest + 4, // 47: neo.fs.v2.container.ContainerService.Get:input_type -> neo.fs.v2.container.GetRequest + 6, // 48: neo.fs.v2.container.ContainerService.List:input_type -> neo.fs.v2.container.ListRequest + 8, // 49: neo.fs.v2.container.ContainerService.GetExtendedACL:input_type -> neo.fs.v2.container.GetExtendedACLRequest + 1, // 50: neo.fs.v2.container.ContainerService.Put:output_type -> neo.fs.v2.container.PutResponse + 3, // 51: neo.fs.v2.container.ContainerService.Delete:output_type -> neo.fs.v2.container.DeleteResponse + 5, // 52: neo.fs.v2.container.ContainerService.Get:output_type -> neo.fs.v2.container.GetResponse + 7, // 53: neo.fs.v2.container.ContainerService.List:output_type -> neo.fs.v2.container.ListResponse + 9, // 54: neo.fs.v2.container.ContainerService.GetExtendedACL:output_type -> neo.fs.v2.container.GetExtendedACLResponse + 50, // [50:55] is the sub-list for method output_type + 45, // [45:50] is the sub-list for method input_type + 45, // [45:45] is the sub-list for extension type_name + 45, // [45:45] is the sub-list for extension extendee + 0, // [0:45] is the sub-list for field type_name } func init() { file_container_grpc_service_proto_init() } @@ -2412,30 +1744,6 @@ func file_container_grpc_service_proto_init() { } } file_container_grpc_service_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SetExtendedACLRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_container_grpc_service_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SetExtendedACLResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_container_grpc_service_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*GetExtendedACLRequest); i { case 0: return &v.state @@ -2447,7 +1755,7 @@ func file_container_grpc_service_proto_init() { return nil } } - file_container_grpc_service_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { + file_container_grpc_service_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*GetExtendedACLResponse); i { case 0: return &v.state @@ -2459,31 +1767,7 @@ func file_container_grpc_service_proto_init() { return nil } } - file_container_grpc_service_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*AnnounceUsedSpaceRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_container_grpc_service_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*AnnounceUsedSpaceResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_container_grpc_service_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { + file_container_grpc_service_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*PutRequest_Body); i { case 0: return &v.state @@ -2495,7 +1779,7 @@ func file_container_grpc_service_proto_init() { return nil } } - file_container_grpc_service_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { + file_container_grpc_service_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*PutResponse_Body); i { case 0: return &v.state @@ -2507,7 +1791,7 @@ func file_container_grpc_service_proto_init() { return nil } } - file_container_grpc_service_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { + file_container_grpc_service_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DeleteRequest_Body); i { case 0: return &v.state @@ -2519,7 +1803,7 @@ func file_container_grpc_service_proto_init() { return nil } } - file_container_grpc_service_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { + file_container_grpc_service_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DeleteResponse_Body); i { case 0: return &v.state @@ -2531,7 +1815,7 @@ func file_container_grpc_service_proto_init() { return nil } } - file_container_grpc_service_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { + file_container_grpc_service_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*GetRequest_Body); i { case 0: return &v.state @@ -2543,7 +1827,7 @@ func file_container_grpc_service_proto_init() { return nil } } - file_container_grpc_service_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { + file_container_grpc_service_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*GetResponse_Body); i { case 0: return &v.state @@ -2555,7 +1839,7 @@ func file_container_grpc_service_proto_init() { return nil } } - file_container_grpc_service_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { + file_container_grpc_service_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*ListRequest_Body); i { case 0: return &v.state @@ -2567,7 +1851,7 @@ func file_container_grpc_service_proto_init() { return nil } } - file_container_grpc_service_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { + file_container_grpc_service_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*ListResponse_Body); i { case 0: return &v.state @@ -2579,31 +1863,7 @@ func file_container_grpc_service_proto_init() { return nil } } - file_container_grpc_service_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SetExtendedACLRequest_Body); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_container_grpc_service_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SetExtendedACLResponse_Body); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_container_grpc_service_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { + file_container_grpc_service_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*GetExtendedACLRequest_Body); i { case 0: return &v.state @@ -2615,7 +1875,7 @@ func file_container_grpc_service_proto_init() { return nil } } - file_container_grpc_service_proto_msgTypes[25].Exporter = func(v interface{}, i int) interface{} { + file_container_grpc_service_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*GetExtendedACLResponse_Body); i { case 0: return &v.state @@ -2627,42 +1887,6 @@ func file_container_grpc_service_proto_init() { return nil } } - file_container_grpc_service_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*AnnounceUsedSpaceRequest_Body); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_container_grpc_service_proto_msgTypes[27].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*AnnounceUsedSpaceRequest_Body_Announcement); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_container_grpc_service_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*AnnounceUsedSpaceResponse_Body); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } } type x struct{} out := protoimpl.TypeBuilder{ @@ -2670,7 +1894,7 @@ func file_container_grpc_service_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_container_grpc_service_proto_rawDesc, NumEnums: 0, - NumMessages: 29, + NumMessages: 20, NumExtensions: 0, NumServices: 1, }, diff --git a/container/grpc/service_grpc.pb.go b/container/grpc/service_grpc.pb.go index 6ae8ade..939a978 100644 --- a/container/grpc/service_grpc.pb.go +++ b/container/grpc/service_grpc.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go-grpc. DO NOT EDIT. // versions: // - protoc-gen-go-grpc v1.3.0 -// - protoc v4.25.3 +// - protoc v5.27.2 // source: container/grpc/service.proto package container @@ -19,13 +19,11 @@ import ( const _ = grpc.SupportPackageIsVersion7 const ( - ContainerService_Put_FullMethodName = "/neo.fs.v2.container.ContainerService/Put" - ContainerService_Delete_FullMethodName = "/neo.fs.v2.container.ContainerService/Delete" - ContainerService_Get_FullMethodName = "/neo.fs.v2.container.ContainerService/Get" - ContainerService_List_FullMethodName = "/neo.fs.v2.container.ContainerService/List" - ContainerService_SetExtendedACL_FullMethodName = "/neo.fs.v2.container.ContainerService/SetExtendedACL" - ContainerService_GetExtendedACL_FullMethodName = "/neo.fs.v2.container.ContainerService/GetExtendedACL" - ContainerService_AnnounceUsedSpace_FullMethodName = "/neo.fs.v2.container.ContainerService/AnnounceUsedSpace" + ContainerService_Put_FullMethodName = "/neo.fs.v2.container.ContainerService/Put" + ContainerService_Delete_FullMethodName = "/neo.fs.v2.container.ContainerService/Delete" + ContainerService_Get_FullMethodName = "/neo.fs.v2.container.ContainerService/Get" + ContainerService_List_FullMethodName = "/neo.fs.v2.container.ContainerService/List" + ContainerService_GetExtendedACL_FullMethodName = "/neo.fs.v2.container.ContainerService/GetExtendedACL" ) // ContainerServiceClient is the client API for ContainerService service. @@ -76,17 +74,6 @@ type ContainerServiceClient interface { // - **CONTAINER_ACCESS_DENIED** (3074, SECTION_CONTAINER): \ // container list access denied. List(ctx context.Context, in *ListRequest, opts ...grpc.CallOption) (*ListResponse, error) - // Invokes 'SetEACL' method of 'Container` smart contract and returns response - // immediately. After one more block in sidechain, changes in an Extended ACL - // are added into smart contract storage. - // - // Statuses: - // - **OK** (0, SECTION_SUCCESS): \ - // request to save container eACL has been sent to the sidechain; - // - Common failures (SECTION_FAILURE_COMMON); - // - **CONTAINER_ACCESS_DENIED** (3074, SECTION_CONTAINER): \ - // set container eACL access denied. - SetExtendedACL(ctx context.Context, in *SetExtendedACLRequest, opts ...grpc.CallOption) (*SetExtendedACLResponse, error) // Returns Extended ACL table and signature from `Container` smart contract // storage. // @@ -101,13 +88,6 @@ type ContainerServiceClient interface { // - **CONTAINER_ACCESS_DENIED** (3074, SECTION_CONTAINER): \ // access to container eACL is denied. GetExtendedACL(ctx context.Context, in *GetExtendedACLRequest, opts ...grpc.CallOption) (*GetExtendedACLResponse, error) - // Announces the space values used by the container for P2P synchronization. - // - // Statuses: - // - **OK** (0, SECTION_SUCCESS): \ - // estimation of used space has been successfully announced; - // - Common failures (SECTION_FAILURE_COMMON). - AnnounceUsedSpace(ctx context.Context, in *AnnounceUsedSpaceRequest, opts ...grpc.CallOption) (*AnnounceUsedSpaceResponse, error) } type containerServiceClient struct { @@ -154,15 +134,6 @@ func (c *containerServiceClient) List(ctx context.Context, in *ListRequest, opts return out, nil } -func (c *containerServiceClient) SetExtendedACL(ctx context.Context, in *SetExtendedACLRequest, opts ...grpc.CallOption) (*SetExtendedACLResponse, error) { - out := new(SetExtendedACLResponse) - err := c.cc.Invoke(ctx, ContainerService_SetExtendedACL_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - func (c *containerServiceClient) GetExtendedACL(ctx context.Context, in *GetExtendedACLRequest, opts ...grpc.CallOption) (*GetExtendedACLResponse, error) { out := new(GetExtendedACLResponse) err := c.cc.Invoke(ctx, ContainerService_GetExtendedACL_FullMethodName, in, out, opts...) @@ -172,15 +143,6 @@ func (c *containerServiceClient) GetExtendedACL(ctx context.Context, in *GetExte return out, nil } -func (c *containerServiceClient) AnnounceUsedSpace(ctx context.Context, in *AnnounceUsedSpaceRequest, opts ...grpc.CallOption) (*AnnounceUsedSpaceResponse, error) { - out := new(AnnounceUsedSpaceResponse) - err := c.cc.Invoke(ctx, ContainerService_AnnounceUsedSpace_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - // ContainerServiceServer is the server API for ContainerService service. // All implementations should embed UnimplementedContainerServiceServer // for forward compatibility @@ -229,17 +191,6 @@ type ContainerServiceServer interface { // - **CONTAINER_ACCESS_DENIED** (3074, SECTION_CONTAINER): \ // container list access denied. List(context.Context, *ListRequest) (*ListResponse, error) - // Invokes 'SetEACL' method of 'Container` smart contract and returns response - // immediately. After one more block in sidechain, changes in an Extended ACL - // are added into smart contract storage. - // - // Statuses: - // - **OK** (0, SECTION_SUCCESS): \ - // request to save container eACL has been sent to the sidechain; - // - Common failures (SECTION_FAILURE_COMMON); - // - **CONTAINER_ACCESS_DENIED** (3074, SECTION_CONTAINER): \ - // set container eACL access denied. - SetExtendedACL(context.Context, *SetExtendedACLRequest) (*SetExtendedACLResponse, error) // Returns Extended ACL table and signature from `Container` smart contract // storage. // @@ -254,13 +205,6 @@ type ContainerServiceServer interface { // - **CONTAINER_ACCESS_DENIED** (3074, SECTION_CONTAINER): \ // access to container eACL is denied. GetExtendedACL(context.Context, *GetExtendedACLRequest) (*GetExtendedACLResponse, error) - // Announces the space values used by the container for P2P synchronization. - // - // Statuses: - // - **OK** (0, SECTION_SUCCESS): \ - // estimation of used space has been successfully announced; - // - Common failures (SECTION_FAILURE_COMMON). - AnnounceUsedSpace(context.Context, *AnnounceUsedSpaceRequest) (*AnnounceUsedSpaceResponse, error) } // UnimplementedContainerServiceServer should be embedded to have forward compatible implementations. @@ -279,15 +223,9 @@ func (UnimplementedContainerServiceServer) Get(context.Context, *GetRequest) (*G func (UnimplementedContainerServiceServer) List(context.Context, *ListRequest) (*ListResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method List not implemented") } -func (UnimplementedContainerServiceServer) SetExtendedACL(context.Context, *SetExtendedACLRequest) (*SetExtendedACLResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method SetExtendedACL not implemented") -} func (UnimplementedContainerServiceServer) GetExtendedACL(context.Context, *GetExtendedACLRequest) (*GetExtendedACLResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method GetExtendedACL not implemented") } -func (UnimplementedContainerServiceServer) AnnounceUsedSpace(context.Context, *AnnounceUsedSpaceRequest) (*AnnounceUsedSpaceResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method AnnounceUsedSpace not implemented") -} // UnsafeContainerServiceServer may be embedded to opt out of forward compatibility for this service. // Use of this interface is not recommended, as added methods to ContainerServiceServer will @@ -372,24 +310,6 @@ func _ContainerService_List_Handler(srv interface{}, ctx context.Context, dec fu return interceptor(ctx, in, info, handler) } -func _ContainerService_SetExtendedACL_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(SetExtendedACLRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(ContainerServiceServer).SetExtendedACL(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: ContainerService_SetExtendedACL_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ContainerServiceServer).SetExtendedACL(ctx, req.(*SetExtendedACLRequest)) - } - return interceptor(ctx, in, info, handler) -} - func _ContainerService_GetExtendedACL_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(GetExtendedACLRequest) if err := dec(in); err != nil { @@ -408,24 +328,6 @@ func _ContainerService_GetExtendedACL_Handler(srv interface{}, ctx context.Conte return interceptor(ctx, in, info, handler) } -func _ContainerService_AnnounceUsedSpace_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(AnnounceUsedSpaceRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(ContainerServiceServer).AnnounceUsedSpace(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: ContainerService_AnnounceUsedSpace_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ContainerServiceServer).AnnounceUsedSpace(ctx, req.(*AnnounceUsedSpaceRequest)) - } - return interceptor(ctx, in, info, handler) -} - // ContainerService_ServiceDesc is the grpc.ServiceDesc for ContainerService service. // It's only intended for direct use with grpc.RegisterService, // and not to be introspected or modified (even as a copy) @@ -449,18 +351,10 @@ var ContainerService_ServiceDesc = grpc.ServiceDesc{ MethodName: "List", Handler: _ContainerService_List_Handler, }, - { - MethodName: "SetExtendedACL", - Handler: _ContainerService_SetExtendedACL_Handler, - }, { MethodName: "GetExtendedACL", Handler: _ContainerService_GetExtendedACL_Handler, }, - { - MethodName: "AnnounceUsedSpace", - Handler: _ContainerService_AnnounceUsedSpace_Handler, - }, }, Streams: []grpc.StreamDesc{}, Metadata: "container/grpc/service.proto", diff --git a/container/grpc/types.pb.go b/container/grpc/types.pb.go index c484a0d..d0e19ec 100644 --- a/container/grpc/types.pb.go +++ b/container/grpc/types.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.33.0 -// protoc v4.25.3 +// protoc v5.27.2 // source: container/grpc/types.proto package container diff --git a/container/marshal.go b/container/marshal.go index a7c57aa..ff17150 100644 --- a/container/marshal.go +++ b/container/marshal.go @@ -35,20 +35,11 @@ const ( listRespBodyIDsField = 1 - setEACLReqBodyTableField = 1 - setEACLReqBodySignatureField = 2 - getEACLReqBodyIDField = 1 getEACLRespBodyTableField = 1 getEACLRespBodySignatureField = 2 getEACLRespBodyTokenField = 3 - - usedSpaceAnnounceEpochField = 1 - usedSpaceAnnounceCIDField = 2 - usedSpaceAnnounceUsedSpaceField = 3 - - usedSpaceReqBodyAnnouncementsField = 1 ) func (a *Attribute) StableMarshal(buf []byte) []byte { @@ -359,50 +350,6 @@ func (r *ListResponseBody) Unmarshal(data []byte) error { return message.Unmarshal(r, data, new(container.ListResponse_Body)) } -func (r *SetExtendedACLRequestBody) StableMarshal(buf []byte) []byte { - if r == nil { - return []byte{} - } - - if buf == nil { - buf = make([]byte, r.StableSize()) - } - - var offset int - - offset += protoutil.NestedStructureMarshal(setEACLReqBodyTableField, buf[offset:], r.eacl) - protoutil.NestedStructureMarshal(setEACLReqBodySignatureField, buf[offset:], r.sig) - - return buf -} - -func (r *SetExtendedACLRequestBody) StableSize() (size int) { - if r == nil { - return 0 - } - - size += protoutil.NestedStructureSize(setEACLReqBodyTableField, r.eacl) - size += protoutil.NestedStructureSize(setEACLReqBodySignatureField, r.sig) - - return size -} - -func (r *SetExtendedACLRequestBody) Unmarshal(data []byte) error { - return message.Unmarshal(r, data, new(container.SetExtendedACLRequest_Body)) -} - -func (r *SetExtendedACLResponseBody) StableMarshal(_ []byte) []byte { - return nil -} - -func (r *SetExtendedACLResponseBody) StableSize() (size int) { - return 0 -} - -func (r *SetExtendedACLResponseBody) Unmarshal([]byte) error { - return nil -} - func (r *GetExtendedACLRequestBody) StableMarshal(buf []byte) []byte { if r == nil { return []byte{} @@ -464,83 +411,3 @@ func (r *GetExtendedACLResponseBody) StableSize() (size int) { func (r *GetExtendedACLResponseBody) Unmarshal(data []byte) error { return message.Unmarshal(r, data, new(container.GetExtendedACLResponse_Body)) } - -func (a *UsedSpaceAnnouncement) StableMarshal(buf []byte) []byte { - if a == nil { - return []byte{} - } - - if buf == nil { - buf = make([]byte, a.StableSize()) - } - - var offset int - - offset += protoutil.UInt64Marshal(usedSpaceAnnounceEpochField, buf[offset:], a.epoch) - offset += protoutil.NestedStructureMarshal(usedSpaceAnnounceCIDField, buf[offset:], a.cid) - protoutil.UInt64Marshal(usedSpaceAnnounceUsedSpaceField, buf[offset:], a.usedSpace) - - return buf -} - -func (a *UsedSpaceAnnouncement) StableSize() (size int) { - if a == nil { - return 0 - } - - size += protoutil.UInt64Size(usedSpaceAnnounceEpochField, a.epoch) - size += protoutil.NestedStructureSize(usedSpaceAnnounceCIDField, a.cid) - size += protoutil.UInt64Size(usedSpaceAnnounceUsedSpaceField, a.usedSpace) - - return size -} - -func (a *UsedSpaceAnnouncement) Unmarshal(data []byte) error { - return message.Unmarshal(a, data, new(container.AnnounceUsedSpaceRequest_Body_Announcement)) -} - -func (r *AnnounceUsedSpaceRequestBody) StableMarshal(buf []byte) []byte { - if r == nil { - return []byte{} - } - - if buf == nil { - buf = make([]byte, r.StableSize()) - } - - var offset int - - for i := range r.announcements { - offset += protoutil.NestedStructureMarshal(usedSpaceReqBodyAnnouncementsField, buf[offset:], &r.announcements[i]) - } - - return buf -} - -func (r *AnnounceUsedSpaceRequestBody) StableSize() (size int) { - if r == nil { - return 0 - } - - for i := range r.announcements { - size += protoutil.NestedStructureSize(usedSpaceReqBodyAnnouncementsField, &r.announcements[i]) - } - - return size -} - -func (r *AnnounceUsedSpaceRequestBody) Unmarshal(data []byte) error { - return message.Unmarshal(r, data, new(container.AnnounceUsedSpaceRequest_Body)) -} - -func (r *AnnounceUsedSpaceResponseBody) StableMarshal(_ []byte) []byte { - return nil -} - -func (r *AnnounceUsedSpaceResponseBody) StableSize() (size int) { - return 0 -} - -func (r *AnnounceUsedSpaceResponseBody) Unmarshal([]byte) error { - return nil -} diff --git a/container/message_test.go b/container/message_test.go index 869ccb2..6558e25 100644 --- a/container/message_test.go +++ b/container/message_test.go @@ -28,8 +28,6 @@ func TestMessageConvert(t *testing.T) { func(empty bool) message.Message { return containertest.GenerateListRequest(empty) }, func(empty bool) message.Message { return containertest.GenerateListResponseBody(empty) }, func(empty bool) message.Message { return containertest.GenerateListResponse(empty) }, - func(empty bool) message.Message { return containertest.GenerateSetExtendedACLRequestBody(empty) }, - func(empty bool) message.Message { return containertest.GenerateSetExtendedACLRequest(empty) }, func(empty bool) message.Message { return containertest.GenerateGetRequestBody(empty) }, func(empty bool) message.Message { return containertest.GenerateGetRequest(empty) }, func(empty bool) message.Message { return containertest.GenerateGetResponseBody(empty) }, @@ -38,10 +36,5 @@ func TestMessageConvert(t *testing.T) { func(empty bool) message.Message { return containertest.GenerateGetExtendedACLRequest(empty) }, func(empty bool) message.Message { return containertest.GenerateGetExtendedACLResponseBody(empty) }, func(empty bool) message.Message { return containertest.GenerateGetExtendedACLResponse(empty) }, - func(empty bool) message.Message { return containertest.GenerateUsedSpaceAnnouncement(empty) }, - func(empty bool) message.Message { return containertest.GenerateAnnounceUsedSpaceRequestBody(empty) }, - func(empty bool) message.Message { return containertest.GenerateAnnounceUsedSpaceRequest(empty) }, - func(empty bool) message.Message { return containertest.GenerateAnnounceUsedSpaceResponseBody(empty) }, - func(empty bool) message.Message { return containertest.GenerateAnnounceUsedSpaceResponse(empty) }, ) } diff --git a/container/test/generate.go b/container/test/generate.go index 2b2afdf..b94347b 100644 --- a/container/test/generate.go +++ b/container/test/generate.go @@ -235,50 +235,6 @@ func GenerateListResponse(empty bool) *container.ListResponse { return m } -func GenerateSetExtendedACLRequestBody(empty bool) *container.SetExtendedACLRequestBody { - m := new(container.SetExtendedACLRequestBody) - - if !empty { - m.SetEACL(acltest.GenerateTable(false)) - } - - m.SetSignature(refstest.GenerateSignature(empty)) - - return m -} - -func GenerateSetExtendedACLRequest(empty bool) *container.SetExtendedACLRequest { - m := new(container.SetExtendedACLRequest) - - if !empty { - m.SetBody(GenerateSetExtendedACLRequestBody(false)) - } - - m.SetMetaHeader(sessiontest.GenerateRequestMetaHeader(empty)) - m.SetVerificationHeader(sessiontest.GenerateRequestVerificationHeader(empty)) - - return m -} - -func GenerateSetExtendedACLResponseBody(_ bool) *container.SetExtendedACLResponseBody { - m := new(container.SetExtendedACLResponseBody) - - return m -} - -func GenerateSetExtendedACLResponse(empty bool) *container.SetExtendedACLResponse { - m := new(container.SetExtendedACLResponse) - - if !empty { - m.SetBody(GenerateSetExtendedACLResponseBody(false)) - } - - m.SetMetaHeader(sessiontest.GenerateResponseMetaHeader(empty)) - m.SetVerificationHeader(sessiontest.GenerateResponseVerificationHeader(empty)) - - return m -} - func GenerateGetExtendedACLRequestBody(empty bool) *container.GetExtendedACLRequestBody { m := new(container.GetExtendedACLRequestBody) @@ -327,70 +283,3 @@ func GenerateGetExtendedACLResponse(empty bool) *container.GetExtendedACLRespons return m } - -func GenerateUsedSpaceAnnouncement(empty bool) *container.UsedSpaceAnnouncement { - m := new(container.UsedSpaceAnnouncement) - - if !empty { - m.SetContainerID(refstest.GenerateContainerID(false)) - m.SetEpoch(1) - m.SetUsedSpace(2) - } - - return m -} - -func GenerateUsedSpaceAnnouncements(empty bool) []container.UsedSpaceAnnouncement { - var res []container.UsedSpaceAnnouncement - - if !empty { - res = append(res, - *GenerateUsedSpaceAnnouncement(false), - *GenerateUsedSpaceAnnouncement(false), - ) - } - - return res -} - -func GenerateAnnounceUsedSpaceRequestBody(empty bool) *container.AnnounceUsedSpaceRequestBody { - m := new(container.AnnounceUsedSpaceRequestBody) - - if !empty { - m.SetAnnouncements(GenerateUsedSpaceAnnouncements(false)) - } - - return m -} - -func GenerateAnnounceUsedSpaceRequest(empty bool) *container.AnnounceUsedSpaceRequest { - m := new(container.AnnounceUsedSpaceRequest) - - if !empty { - m.SetBody(GenerateAnnounceUsedSpaceRequestBody(false)) - } - - m.SetMetaHeader(sessiontest.GenerateRequestMetaHeader(empty)) - m.SetVerificationHeader(sessiontest.GenerateRequestVerificationHeader(empty)) - - return m -} - -func GenerateAnnounceUsedSpaceResponseBody(_ bool) *container.AnnounceUsedSpaceResponseBody { - m := new(container.AnnounceUsedSpaceResponseBody) - - return m -} - -func GenerateAnnounceUsedSpaceResponse(empty bool) *container.AnnounceUsedSpaceResponse { - m := new(container.AnnounceUsedSpaceResponse) - - if !empty { - m.SetBody(GenerateAnnounceUsedSpaceResponseBody(false)) - } - - m.SetMetaHeader(sessiontest.GenerateResponseMetaHeader(empty)) - m.SetVerificationHeader(sessiontest.GenerateResponseVerificationHeader(empty)) - - return m -} diff --git a/container/types.go b/container/types.go index 948580d..3a9e915 100644 --- a/container/types.go +++ b/container/types.go @@ -110,26 +110,6 @@ type ListResponse struct { session.ResponseHeaders } -type SetExtendedACLRequestBody struct { - eacl *acl.Table - - sig *refs.Signature -} - -type SetExtendedACLRequest struct { - body *SetExtendedACLRequestBody - - session.RequestHeaders -} - -type SetExtendedACLResponseBody struct{} - -type SetExtendedACLResponse struct { - body *SetExtendedACLResponseBody - - session.ResponseHeaders -} - type GetExtendedACLRequestBody struct { cid *refs.ContainerID } @@ -154,32 +134,6 @@ type GetExtendedACLResponse struct { session.ResponseHeaders } -type UsedSpaceAnnouncement struct { - epoch uint64 - - cid *refs.ContainerID - - usedSpace uint64 -} - -type AnnounceUsedSpaceRequestBody struct { - announcements []UsedSpaceAnnouncement -} - -type AnnounceUsedSpaceRequest struct { - body *AnnounceUsedSpaceRequestBody - - session.RequestHeaders -} - -type AnnounceUsedSpaceResponseBody struct{} - -type AnnounceUsedSpaceResponse struct { - body *AnnounceUsedSpaceResponseBody - - session.ResponseHeaders -} - func (a *Attribute) GetKey() string { if a != nil { return a.key @@ -516,56 +470,6 @@ func (r *ListResponse) SetBody(v *ListResponseBody) { r.body = v } -func (r *SetExtendedACLRequestBody) GetEACL() *acl.Table { - if r != nil { - return r.eacl - } - - return nil -} - -func (r *SetExtendedACLRequestBody) SetEACL(v *acl.Table) { - r.eacl = v -} - -func (r *SetExtendedACLRequestBody) GetSignature() *refs.Signature { - if r != nil { - return r.sig - } - - return nil -} - -func (r *SetExtendedACLRequestBody) SetSignature(v *refs.Signature) { - // TODO: (neofs-api-go#381) avoid this hack (e.g. create refs.SignatureRFC6979 type) - v.SetScheme(0) - r.sig = v -} - -func (r *SetExtendedACLRequest) GetBody() *SetExtendedACLRequestBody { - if r != nil { - return r.body - } - - return nil -} - -func (r *SetExtendedACLRequest) SetBody(v *SetExtendedACLRequestBody) { - r.body = v -} - -func (r *SetExtendedACLResponse) GetBody() *SetExtendedACLResponseBody { - if r != nil { - return r.body - } - - return nil -} - -func (r *SetExtendedACLResponse) SetBody(v *SetExtendedACLResponseBody) { - r.body = v -} - func (r *GetExtendedACLRequestBody) GetContainerID() *refs.ContainerID { if r != nil { return r.cid @@ -643,75 +547,3 @@ func (r *GetExtendedACLResponse) GetBody() *GetExtendedACLResponseBody { func (r *GetExtendedACLResponse) SetBody(v *GetExtendedACLResponseBody) { r.body = v } - -func (a *UsedSpaceAnnouncement) GetEpoch() uint64 { - if a != nil { - return a.epoch - } - - return 0 -} - -func (a *UsedSpaceAnnouncement) SetEpoch(v uint64) { - a.epoch = v -} - -func (a *UsedSpaceAnnouncement) GetUsedSpace() uint64 { - if a != nil { - return a.usedSpace - } - - return 0 -} - -func (a *UsedSpaceAnnouncement) SetUsedSpace(v uint64) { - a.usedSpace = v -} - -func (a *UsedSpaceAnnouncement) GetContainerID() *refs.ContainerID { - if a != nil { - return a.cid - } - - return nil -} - -func (a *UsedSpaceAnnouncement) SetContainerID(v *refs.ContainerID) { - a.cid = v -} - -func (r *AnnounceUsedSpaceRequestBody) GetAnnouncements() []UsedSpaceAnnouncement { - if r != nil { - return r.announcements - } - - return nil -} - -func (r *AnnounceUsedSpaceRequestBody) SetAnnouncements(v []UsedSpaceAnnouncement) { - r.announcements = v -} - -func (r *AnnounceUsedSpaceRequest) GetBody() *AnnounceUsedSpaceRequestBody { - if r != nil { - return r.body - } - - return nil -} - -func (r *AnnounceUsedSpaceRequest) SetBody(v *AnnounceUsedSpaceRequestBody) { - r.body = v -} - -func (r *AnnounceUsedSpaceResponse) GetBody() *AnnounceUsedSpaceResponseBody { - if r != nil { - return r.body - } - - return nil -} - -func (r *AnnounceUsedSpaceResponse) SetBody(v *AnnounceUsedSpaceResponseBody) { - r.body = v -} diff --git a/lock/grpc/types.pb.go b/lock/grpc/types.pb.go index c2d66f1..38b62fe 100644 --- a/lock/grpc/types.pb.go +++ b/lock/grpc/types.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.33.0 -// protoc v4.25.3 +// protoc v5.27.2 // source: lock/grpc/types.proto package lock diff --git a/netmap/grpc/service.pb.go b/netmap/grpc/service.pb.go index 7694f3f..eb91862 100644 --- a/netmap/grpc/service.pb.go +++ b/netmap/grpc/service.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.33.0 -// protoc v4.25.3 +// protoc v5.27.2 // source: netmap/grpc/service.proto package netmap diff --git a/netmap/grpc/service_grpc.pb.go b/netmap/grpc/service_grpc.pb.go index 00cb8de..7881cd6 100644 --- a/netmap/grpc/service_grpc.pb.go +++ b/netmap/grpc/service_grpc.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go-grpc. DO NOT EDIT. // versions: // - protoc-gen-go-grpc v1.3.0 -// - protoc v4.25.3 +// - protoc v5.27.2 // source: netmap/grpc/service.proto package netmap diff --git a/netmap/grpc/types.pb.go b/netmap/grpc/types.pb.go index 59f8612..8924213 100644 --- a/netmap/grpc/types.pb.go +++ b/netmap/grpc/types.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.33.0 -// protoc v4.25.3 +// protoc v5.27.2 // source: netmap/grpc/types.proto package netmap diff --git a/object/grpc/service.pb.go b/object/grpc/service.pb.go index 75d359e..01ba86f 100644 --- a/object/grpc/service.pb.go +++ b/object/grpc/service.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.33.0 -// protoc v4.25.3 +// protoc v5.27.2 // source: object/grpc/service.proto package object @@ -2114,8 +2114,8 @@ func (x *SearchRequest_Body) GetFilters() []*SearchRequest_Body_Filter { // - $Object:split.splitID \ // 16 byte UUIDv4 used to identify the split object hierarchy parts // - $Object:ec.parent \ -// If the object is stored according to EC policy, then ec_parent attribute -// is set to return an id list of all related EC chunks. +// If the object is stored according to EC policy, then ec_parent +// attribute is set to return an id list of all related EC chunks. // // There are some well-known filter aliases to match objects by certain // properties: diff --git a/object/grpc/service_grpc.pb.go b/object/grpc/service_grpc.pb.go index 16af44a..11d132f 100644 --- a/object/grpc/service_grpc.pb.go +++ b/object/grpc/service_grpc.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go-grpc. DO NOT EDIT. // versions: // - protoc-gen-go-grpc v1.3.0 -// - protoc v4.25.3 +// - protoc v5.27.2 // source: object/grpc/service.proto package object diff --git a/object/grpc/types.pb.go b/object/grpc/types.pb.go index 16736e9..2a5a2f9 100644 --- a/object/grpc/types.pb.go +++ b/object/grpc/types.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.33.0 -// protoc v4.25.3 +// protoc v5.27.2 // source: object/grpc/types.proto package object @@ -824,12 +824,13 @@ type Header_EC struct { // Chunk of a parent header. Header []byte `protobuf:"bytes,5,opt,name=header,proto3" json:"header,omitempty"` // As the origin object is EC-splitted its identifier is known to all - // chunks as parent. But parent itself can be a part of Split (does not relate to EC-split). - // In this case parent_split_id should be set. + // chunks as parent. But parent itself can be a part of Split (does not + // relate to EC-split). In this case parent_split_id should be set. ParentSplitId []byte `protobuf:"bytes,6,opt,name=parent_split_id,json=parentSplitID,proto3" json:"parent_split_id,omitempty"` - // EC-parent's parent ID. parent_split_parent_id is set if EC-parent, itself, is a part of Split and - // if an object ID of its parent is presented. The field allows to determine how EC-chunk is placed - // in Split hierarchy. + // EC-parent's parent ID. parent_split_parent_id is set if EC-parent, + // itself, is a part of Split and if an object ID of its parent is + // presented. The field allows to determine how EC-chunk is placed in Split + // hierarchy. ParentSplitParentId *grpc.ObjectID `protobuf:"bytes,7,opt,name=parent_split_parent_id,json=parentSplitParentID,proto3" json:"parent_split_parent_id,omitempty"` // EC parent's attributes. ParentAttributes []*Header_Attribute `protobuf:"bytes,8,rep,name=parent_attributes,json=parentAttributes,proto3" json:"parent_attributes,omitempty"` diff --git a/refs/grpc/types.pb.go b/refs/grpc/types.pb.go index 681bb0d..ab3ae42 100644 --- a/refs/grpc/types.pb.go +++ b/refs/grpc/types.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.33.0 -// protoc v4.25.3 +// protoc v5.27.2 // source: refs/grpc/types.proto package refs diff --git a/rpc/container.go b/rpc/container.go index 1292c22..39213f6 100644 --- a/rpc/container.go +++ b/rpc/container.go @@ -13,7 +13,6 @@ const ( rpcContainerGet = "Get" rpcContainerDel = "Delete" rpcContainerList = "List" - rpcContainerSetEACL = "SetExtendedACL" rpcContainerGetEACL = "GetExtendedACL" rpcContainerUsedSpace = "AnnounceUsedSpace" ) @@ -82,22 +81,6 @@ func ListContainers( return resp, nil } -// SetEACL executes ContainerService.SetExtendedACL RPC. -func SetEACL( - cli *client.Client, - req *container.SetExtendedACLRequest, - opts ...client.CallOption, -) (*container.PutResponse, error) { - resp := new(container.PutResponse) - - err := client.SendUnary(cli, common.CallMethodInfoUnary(serviceContainer, rpcContainerSetEACL), req, resp, opts...) - if err != nil { - return nil, err - } - - return resp, nil -} - // GetEACL executes ContainerService.GetExtendedACL RPC. func GetEACL( cli *client.Client, @@ -113,19 +96,3 @@ func GetEACL( return resp, nil } - -// AnnounceUsedSpace executes ContainerService.AnnounceUsedSpace RPC. -func AnnounceUsedSpace( - cli *client.Client, - req *container.AnnounceUsedSpaceRequest, - opts ...client.CallOption, -) (*container.PutResponse, error) { - resp := new(container.PutResponse) - - err := client.SendUnary(cli, common.CallMethodInfoUnary(serviceContainer, rpcContainerUsedSpace), req, resp, opts...) - if err != nil { - return nil, err - } - - return resp, nil -} diff --git a/session/grpc/service.pb.go b/session/grpc/service.pb.go index a6fa504..b5e999f 100644 --- a/session/grpc/service.pb.go +++ b/session/grpc/service.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.33.0 -// protoc v4.25.3 +// protoc v5.27.2 // source: session/grpc/service.proto package session diff --git a/session/grpc/service_grpc.pb.go b/session/grpc/service_grpc.pb.go index bdcc3ba..adf6fc1 100644 --- a/session/grpc/service_grpc.pb.go +++ b/session/grpc/service_grpc.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go-grpc. DO NOT EDIT. // versions: // - protoc-gen-go-grpc v1.3.0 -// - protoc v4.25.3 +// - protoc v5.27.2 // source: session/grpc/service.proto package session diff --git a/session/grpc/types.pb.go b/session/grpc/types.pb.go index e16a7c6..924df45 100644 --- a/session/grpc/types.pb.go +++ b/session/grpc/types.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.33.0 -// protoc v4.25.3 +// protoc v5.27.2 // source: session/grpc/types.proto package session diff --git a/signature/body.go b/signature/body.go index 3362e95..53b5d6b 100644 --- a/signature/body.go +++ b/signature/body.go @@ -46,18 +46,10 @@ func serviceMessageBody(req any) stableMarshaler { return v.GetBody() case *container.ListResponse: return v.GetBody() - case *container.SetExtendedACLRequest: - return v.GetBody() - case *container.SetExtendedACLResponse: - return v.GetBody() case *container.GetExtendedACLRequest: return v.GetBody() case *container.GetExtendedACLResponse: return v.GetBody() - case *container.AnnounceUsedSpaceRequest: - return v.GetBody() - case *container.AnnounceUsedSpaceResponse: - return v.GetBody() /* Object */ case *object.PutRequest: diff --git a/status/grpc/types.pb.go b/status/grpc/types.pb.go index 31f6373..b6b081b 100644 --- a/status/grpc/types.pb.go +++ b/status/grpc/types.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.33.0 -// protoc v4.25.3 +// protoc v5.27.2 // source: status/grpc/types.proto package status @@ -150,7 +150,8 @@ const ( // [**1027**] Node is under maintenance. CommonFail_NODE_UNDER_MAINTENANCE CommonFail = 3 // [**1028**] Invalid argument error. If the server fails on validation of a - // request parameter as the client sent it incorrectly, then this code should be used. + // request parameter as the client sent it incorrectly, then this code should + // be used. CommonFail_INVALID_ARGUMENT CommonFail = 4 ) diff --git a/tombstone/grpc/types.pb.go b/tombstone/grpc/types.pb.go index 6a064dc..7d416fe 100644 --- a/tombstone/grpc/types.pb.go +++ b/tombstone/grpc/types.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.33.0 -// protoc v4.25.3 +// protoc v5.27.2 // source: tombstone/grpc/types.proto package tombstone From 9b90d139c5f030d7c7f0be1bddb00f31cab5f404 Mon Sep 17 00:00:00 2001 From: Airat Arifullin Date: Wed, 24 Jul 2024 17:40:47 +0300 Subject: [PATCH 06/19] [#94] object: Generate protobufs for `Patch` method * Generate protobufs for patch method; * Create marshalers, unmarshalers, converters for gererated types; * Add unit-tests. Signed-off-by: Airat Arifullin --- object/convert.go | 214 ++++++++ object/grpc/service.go | 52 ++ object/grpc/service.pb.go | 955 ++++++++++++++++++++++++--------- object/grpc/service_grpc.pb.go | 157 ++++++ object/marshal.go | 112 ++++ object/message_test.go | 5 + object/test/generate.go | 57 ++ object/types.go | 32 ++ util/proto/test/test.pb.go | 2 +- 9 files changed, 1341 insertions(+), 245 deletions(-) diff --git a/object/convert.go b/object/convert.go index 6e8ecff..1abfb5e 100644 --- a/object/convert.go +++ b/object/convert.go @@ -2345,3 +2345,217 @@ func (r *PutSingleResponse) FromGRPCMessage(m grpc.Message) error { return r.ResponseHeaders.FromMessage(v) } + +func (r *PatchRequestBodyPatch) ToGRPCMessage() grpc.Message { + var m *object.PatchRequest_Body_Patch + + if r != nil { + m = new(object.PatchRequest_Body_Patch) + + m.SetSourceRange(r.Range.ToGRPCMessage().(*object.Range)) + m.SetChunk(r.Chunk) + } + + return m +} + +func (r *PatchRequestBodyPatch) FromGRPCMessage(m grpc.Message) error { + v, ok := m.(*object.PatchRequest_Body_Patch) + if !ok { + return message.NewUnexpectedMessageType(m, v) + } + + var err error + + srcRange := v.GetSourceRange() + if srcRange == nil { + r.Range = nil + } else { + if r.Range == nil { + r.Range = new(Range) + } + + err = r.Range.FromGRPCMessage(srcRange) + if err != nil { + return err + } + } + + r.Chunk = v.GetChunk() + + return nil +} + +func (r *PatchRequestBody) ToGRPCMessage() grpc.Message { + var m *object.PatchRequest_Body + + if r != nil { + m = new(object.PatchRequest_Body) + + m.SetAddress(r.Address.ToGRPCMessage().(*refsGRPC.Address)) + m.SetNewAttributes(AttributesToGRPC(r.NewAttributes)) + m.SetReplaceAttributes(r.ReplaceAttributes) + m.SetPatch(r.Patch.ToGRPCMessage().(*object.PatchRequest_Body_Patch)) + } + + return m +} + +func (r *PatchRequestBody) FromGRPCMessage(m grpc.Message) error { + v, ok := m.(*object.PatchRequest_Body) + if !ok { + return message.NewUnexpectedMessageType(m, v) + } + + var err error + + addr := v.GetAddress() + if addr == nil { + r.Address = nil + } else { + if r.Address == nil { + r.Address = new(refs.Address) + } + + err = r.Address.FromGRPCMessage(addr) + if err != nil { + return err + } + } + + r.NewAttributes, err = AttributesFromGRPC(v.GetNewAttributes()) + if err != nil { + return err + } + + r.ReplaceAttributes = v.GetReplaceAttributes() + + patch := v.GetPatch() + if patch == nil { + r.Patch = nil + } else { + if r.Patch == nil { + r.Patch = new(PatchRequestBodyPatch) + } + + err = r.Patch.FromGRPCMessage(patch) + if err != nil { + return err + } + } + + return nil +} + +func (r *PatchRequest) ToGRPCMessage() grpc.Message { + var m *object.PatchRequest + + if r != nil { + m = new(object.PatchRequest) + + m.SetBody(r.Body.ToGRPCMessage().(*object.PatchRequest_Body)) + r.RequestHeaders.ToMessage(m) + } + + return m +} + +func (r *PatchRequest) FromGRPCMessage(m grpc.Message) error { + v, ok := m.(*object.PatchRequest) + if !ok { + return message.NewUnexpectedMessageType(m, v) + } + + var err error + + body := v.GetBody() + if body == nil { + r.Body = nil + } else { + if r.Body == nil { + r.Body = new(PatchRequestBody) + } + + err = r.Body.FromGRPCMessage(body) + if err != nil { + return err + } + } + + return r.RequestHeaders.FromMessage(v) +} + +func (r *PatchResponseBody) ToGRPCMessage() grpc.Message { + var m *object.PatchResponse_Body + + if r != nil { + m = new(object.PatchResponse_Body) + + m.SetObjectID(r.ObjectID.ToGRPCMessage().(*refsGRPC.ObjectID)) + } + + return m +} + +func (r *PatchResponseBody) FromGRPCMessage(m grpc.Message) error { + v, ok := m.(*object.PatchResponse_Body) + if !ok { + return message.NewUnexpectedMessageType(m, v) + } + + var err error + + objID := v.GetObjectId() + if objID == nil { + r.ObjectID = nil + } else { + if r.ObjectID == nil { + r.ObjectID = new(refs.ObjectID) + } + + err = r.ObjectID.FromGRPCMessage(objID) + if err != nil { + return err + } + } + + return nil +} + +func (r *PatchResponse) ToGRPCMessage() grpc.Message { + var m *object.PatchResponse + + if r != nil { + m = new(object.PatchResponse) + + m.SetBody(r.Body.ToGRPCMessage().(*object.PatchResponse_Body)) + r.ResponseHeaders.ToMessage(m) + } + + return m +} + +func (r *PatchResponse) FromGRPCMessage(m grpc.Message) error { + v, ok := m.(*object.PatchResponse) + if !ok { + return message.NewUnexpectedMessageType(m, v) + } + + var err error + + body := v.GetBody() + if body == nil { + r.Body = nil + } else { + if r.Body == nil { + r.Body = new(PatchResponseBody) + } + + err = r.Body.FromGRPCMessage(body) + if err != nil { + return err + } + } + + return r.ResponseHeaders.FromMessage(v) +} diff --git a/object/grpc/service.go b/object/grpc/service.go index 3ff1f3a..ef6422e 100644 --- a/object/grpc/service.go +++ b/object/grpc/service.go @@ -556,3 +556,55 @@ func (m *PutSingleResponse) SetMetaHeader(v *session.ResponseMetaHeader) { func (m *PutSingleResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) { m.VerifyHeader = v } + +func (m *PatchRequest_Body) SetAddress(addr *refs.Address) { + m.Address = addr +} + +func (m *PatchRequest_Body) SetNewAttributes(attrs []*Header_Attribute) { + m.NewAttributes = attrs +} + +func (m *PatchRequest_Body) SetReplaceAttributes(replaceAttributes bool) { + m.ReplaceAttributes = replaceAttributes +} + +func (m *PatchRequest_Body) SetPatch(patch *PatchRequest_Body_Patch) { + m.Patch = patch +} + +func (m *PatchRequest_Body_Patch) SetSourceRange(r *Range) { + m.SourceRange = r +} + +func (m *PatchRequest_Body_Patch) SetChunk(chunk []byte) { + m.Chunk = chunk +} + +func (m *PatchRequest) SetBody(b *PatchRequest_Body) { + m.Body = b +} + +func (m *PatchRequest) SetMetaHeader(v *session.RequestMetaHeader) { + m.MetaHeader = v +} + +func (m *PatchRequest) SetVerifyHeader(v *session.RequestVerificationHeader) { + m.VerifyHeader = v +} + +func (m *PatchResponse_Body) SetObjectID(objectID *refs.ObjectID) { + m.ObjectId = objectID +} + +func (m *PatchResponse) SetBody(b *PatchResponse_Body) { + m.Body = b +} + +func (m *PatchResponse) SetMetaHeader(v *session.ResponseMetaHeader) { + m.MetaHeader = v +} + +func (m *PatchResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) { + m.VerifyHeader = v +} diff --git a/object/grpc/service.pb.go b/object/grpc/service.pb.go index 01ba86f..979c932 100644 --- a/object/grpc/service.pb.go +++ b/object/grpc/service.pb.go @@ -1265,6 +1265,145 @@ func (x *PutSingleResponse) GetVerifyHeader() *grpc.ResponseVerificationHeader { return nil } +// Object PATCH request +type PatchRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // Body for patch request message. + Body *PatchRequest_Body `protobuf:"bytes,1,opt,name=body,proto3" json:"body,omitempty"` + // Carries request meta information. Header data is used only to regulate + // message transport and does not affect request execution. + MetaHeader *grpc.RequestMetaHeader `protobuf:"bytes,2,opt,name=meta_header,json=metaHeader,proto3" json:"meta_header,omitempty"` + // Carries request verification information. This header is used to + // authenticate the nodes of the message route and check the correctness of + // transmission. + VerifyHeader *grpc.RequestVerificationHeader `protobuf:"bytes,3,opt,name=verify_header,json=verifyHeader,proto3" json:"verify_header,omitempty"` +} + +func (x *PatchRequest) Reset() { + *x = PatchRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_object_grpc_service_proto_msgTypes[18] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *PatchRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*PatchRequest) ProtoMessage() {} + +func (x *PatchRequest) ProtoReflect() protoreflect.Message { + mi := &file_object_grpc_service_proto_msgTypes[18] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use PatchRequest.ProtoReflect.Descriptor instead. +func (*PatchRequest) Descriptor() ([]byte, []int) { + return file_object_grpc_service_proto_rawDescGZIP(), []int{18} +} + +func (x *PatchRequest) GetBody() *PatchRequest_Body { + if x != nil { + return x.Body + } + return nil +} + +func (x *PatchRequest) GetMetaHeader() *grpc.RequestMetaHeader { + if x != nil { + return x.MetaHeader + } + return nil +} + +func (x *PatchRequest) GetVerifyHeader() *grpc.RequestVerificationHeader { + if x != nil { + return x.VerifyHeader + } + return nil +} + +// Object PATCH response +type PatchResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // Body for patch response message. + Body *PatchResponse_Body `protobuf:"bytes,1,opt,name=body,proto3" json:"body,omitempty"` + // Carries response meta information. Header data is used only to regulate + // message transport and does not affect request execution. + MetaHeader *grpc.ResponseMetaHeader `protobuf:"bytes,2,opt,name=meta_header,json=metaHeader,proto3" json:"meta_header,omitempty"` + // Carries response verification information. This header is used to authenticate + // the nodes of the message route and check the correctness of transmission. + VerifyHeader *grpc.ResponseVerificationHeader `protobuf:"bytes,3,opt,name=verify_header,json=verifyHeader,proto3" json:"verify_header,omitempty"` +} + +func (x *PatchResponse) Reset() { + *x = PatchResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_object_grpc_service_proto_msgTypes[19] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *PatchResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*PatchResponse) ProtoMessage() {} + +func (x *PatchResponse) ProtoReflect() protoreflect.Message { + mi := &file_object_grpc_service_proto_msgTypes[19] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use PatchResponse.ProtoReflect.Descriptor instead. +func (*PatchResponse) Descriptor() ([]byte, []int) { + return file_object_grpc_service_proto_rawDescGZIP(), []int{19} +} + +func (x *PatchResponse) GetBody() *PatchResponse_Body { + if x != nil { + return x.Body + } + return nil +} + +func (x *PatchResponse) GetMetaHeader() *grpc.ResponseMetaHeader { + if x != nil { + return x.MetaHeader + } + return nil +} + +func (x *PatchResponse) GetVerifyHeader() *grpc.ResponseVerificationHeader { + if x != nil { + return x.VerifyHeader + } + return nil +} + // GET Object request body type GetRequest_Body struct { state protoimpl.MessageState @@ -1281,7 +1420,7 @@ type GetRequest_Body struct { func (x *GetRequest_Body) Reset() { *x = GetRequest_Body{} if protoimpl.UnsafeEnabled { - mi := &file_object_grpc_service_proto_msgTypes[18] + mi := &file_object_grpc_service_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1294,7 +1433,7 @@ func (x *GetRequest_Body) String() string { func (*GetRequest_Body) ProtoMessage() {} func (x *GetRequest_Body) ProtoReflect() protoreflect.Message { - mi := &file_object_grpc_service_proto_msgTypes[18] + mi := &file_object_grpc_service_proto_msgTypes[20] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1344,7 +1483,7 @@ type GetResponse_Body struct { func (x *GetResponse_Body) Reset() { *x = GetResponse_Body{} if protoimpl.UnsafeEnabled { - mi := &file_object_grpc_service_proto_msgTypes[19] + mi := &file_object_grpc_service_proto_msgTypes[21] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1357,7 +1496,7 @@ func (x *GetResponse_Body) String() string { func (*GetResponse_Body) ProtoMessage() {} func (x *GetResponse_Body) ProtoReflect() protoreflect.Message { - mi := &file_object_grpc_service_proto_msgTypes[19] + mi := &file_object_grpc_service_proto_msgTypes[21] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1458,7 +1597,7 @@ type GetResponse_Body_Init struct { func (x *GetResponse_Body_Init) Reset() { *x = GetResponse_Body_Init{} if protoimpl.UnsafeEnabled { - mi := &file_object_grpc_service_proto_msgTypes[20] + mi := &file_object_grpc_service_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1471,7 +1610,7 @@ func (x *GetResponse_Body_Init) String() string { func (*GetResponse_Body_Init) ProtoMessage() {} func (x *GetResponse_Body_Init) ProtoReflect() protoreflect.Message { - mi := &file_object_grpc_service_proto_msgTypes[20] + mi := &file_object_grpc_service_proto_msgTypes[22] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1526,7 +1665,7 @@ type PutRequest_Body struct { func (x *PutRequest_Body) Reset() { *x = PutRequest_Body{} if protoimpl.UnsafeEnabled { - mi := &file_object_grpc_service_proto_msgTypes[21] + mi := &file_object_grpc_service_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1539,7 +1678,7 @@ func (x *PutRequest_Body) String() string { func (*PutRequest_Body) ProtoMessage() {} func (x *PutRequest_Body) ProtoReflect() protoreflect.Message { - mi := &file_object_grpc_service_proto_msgTypes[21] + mi := &file_object_grpc_service_proto_msgTypes[23] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1623,7 +1762,7 @@ type PutRequest_Body_Init struct { func (x *PutRequest_Body_Init) Reset() { *x = PutRequest_Body_Init{} if protoimpl.UnsafeEnabled { - mi := &file_object_grpc_service_proto_msgTypes[22] + mi := &file_object_grpc_service_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1636,7 +1775,7 @@ func (x *PutRequest_Body_Init) String() string { func (*PutRequest_Body_Init) ProtoMessage() {} func (x *PutRequest_Body_Init) ProtoReflect() protoreflect.Message { - mi := &file_object_grpc_service_proto_msgTypes[22] + mi := &file_object_grpc_service_proto_msgTypes[24] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1693,7 +1832,7 @@ type PutResponse_Body struct { func (x *PutResponse_Body) Reset() { *x = PutResponse_Body{} if protoimpl.UnsafeEnabled { - mi := &file_object_grpc_service_proto_msgTypes[23] + mi := &file_object_grpc_service_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1706,7 +1845,7 @@ func (x *PutResponse_Body) String() string { func (*PutResponse_Body) ProtoMessage() {} func (x *PutResponse_Body) ProtoReflect() protoreflect.Message { - mi := &file_object_grpc_service_proto_msgTypes[23] + mi := &file_object_grpc_service_proto_msgTypes[25] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1742,7 +1881,7 @@ type DeleteRequest_Body struct { func (x *DeleteRequest_Body) Reset() { *x = DeleteRequest_Body{} if protoimpl.UnsafeEnabled { - mi := &file_object_grpc_service_proto_msgTypes[24] + mi := &file_object_grpc_service_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1755,7 +1894,7 @@ func (x *DeleteRequest_Body) String() string { func (*DeleteRequest_Body) ProtoMessage() {} func (x *DeleteRequest_Body) ProtoReflect() protoreflect.Message { - mi := &file_object_grpc_service_proto_msgTypes[24] + mi := &file_object_grpc_service_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1791,7 +1930,7 @@ type DeleteResponse_Body struct { func (x *DeleteResponse_Body) Reset() { *x = DeleteResponse_Body{} if protoimpl.UnsafeEnabled { - mi := &file_object_grpc_service_proto_msgTypes[25] + mi := &file_object_grpc_service_proto_msgTypes[27] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1804,7 +1943,7 @@ func (x *DeleteResponse_Body) String() string { func (*DeleteResponse_Body) ProtoMessage() {} func (x *DeleteResponse_Body) ProtoReflect() protoreflect.Message { - mi := &file_object_grpc_service_proto_msgTypes[25] + mi := &file_object_grpc_service_proto_msgTypes[27] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1845,7 +1984,7 @@ type HeadRequest_Body struct { func (x *HeadRequest_Body) Reset() { *x = HeadRequest_Body{} if protoimpl.UnsafeEnabled { - mi := &file_object_grpc_service_proto_msgTypes[26] + mi := &file_object_grpc_service_proto_msgTypes[28] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1858,7 +1997,7 @@ func (x *HeadRequest_Body) String() string { func (*HeadRequest_Body) ProtoMessage() {} func (x *HeadRequest_Body) ProtoReflect() protoreflect.Message { - mi := &file_object_grpc_service_proto_msgTypes[26] + mi := &file_object_grpc_service_proto_msgTypes[28] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1916,7 +2055,7 @@ type HeadResponse_Body struct { func (x *HeadResponse_Body) Reset() { *x = HeadResponse_Body{} if protoimpl.UnsafeEnabled { - mi := &file_object_grpc_service_proto_msgTypes[27] + mi := &file_object_grpc_service_proto_msgTypes[29] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1929,7 +2068,7 @@ func (x *HeadResponse_Body) String() string { func (*HeadResponse_Body) ProtoMessage() {} func (x *HeadResponse_Body) ProtoReflect() protoreflect.Message { - mi := &file_object_grpc_service_proto_msgTypes[27] + mi := &file_object_grpc_service_proto_msgTypes[29] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2029,7 +2168,7 @@ type SearchRequest_Body struct { func (x *SearchRequest_Body) Reset() { *x = SearchRequest_Body{} if protoimpl.UnsafeEnabled { - mi := &file_object_grpc_service_proto_msgTypes[28] + mi := &file_object_grpc_service_proto_msgTypes[30] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2042,7 +2181,7 @@ func (x *SearchRequest_Body) String() string { func (*SearchRequest_Body) ProtoMessage() {} func (x *SearchRequest_Body) ProtoReflect() protoreflect.Message { - mi := &file_object_grpc_service_proto_msgTypes[28] + mi := &file_object_grpc_service_proto_msgTypes[30] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2152,7 +2291,7 @@ type SearchRequest_Body_Filter struct { func (x *SearchRequest_Body_Filter) Reset() { *x = SearchRequest_Body_Filter{} if protoimpl.UnsafeEnabled { - mi := &file_object_grpc_service_proto_msgTypes[29] + mi := &file_object_grpc_service_proto_msgTypes[31] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2165,7 +2304,7 @@ func (x *SearchRequest_Body_Filter) String() string { func (*SearchRequest_Body_Filter) ProtoMessage() {} func (x *SearchRequest_Body_Filter) ProtoReflect() protoreflect.Message { - mi := &file_object_grpc_service_proto_msgTypes[29] + mi := &file_object_grpc_service_proto_msgTypes[31] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2215,7 +2354,7 @@ type SearchResponse_Body struct { func (x *SearchResponse_Body) Reset() { *x = SearchResponse_Body{} if protoimpl.UnsafeEnabled { - mi := &file_object_grpc_service_proto_msgTypes[30] + mi := &file_object_grpc_service_proto_msgTypes[32] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2228,7 +2367,7 @@ func (x *SearchResponse_Body) String() string { func (*SearchResponse_Body) ProtoMessage() {} func (x *SearchResponse_Body) ProtoReflect() protoreflect.Message { - mi := &file_object_grpc_service_proto_msgTypes[30] + mi := &file_object_grpc_service_proto_msgTypes[32] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2269,7 +2408,7 @@ type GetRangeRequest_Body struct { func (x *GetRangeRequest_Body) Reset() { *x = GetRangeRequest_Body{} if protoimpl.UnsafeEnabled { - mi := &file_object_grpc_service_proto_msgTypes[31] + mi := &file_object_grpc_service_proto_msgTypes[33] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2282,7 +2421,7 @@ func (x *GetRangeRequest_Body) String() string { func (*GetRangeRequest_Body) ProtoMessage() {} func (x *GetRangeRequest_Body) ProtoReflect() protoreflect.Message { - mi := &file_object_grpc_service_proto_msgTypes[31] + mi := &file_object_grpc_service_proto_msgTypes[33] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2341,7 +2480,7 @@ type GetRangeResponse_Body struct { func (x *GetRangeResponse_Body) Reset() { *x = GetRangeResponse_Body{} if protoimpl.UnsafeEnabled { - mi := &file_object_grpc_service_proto_msgTypes[32] + mi := &file_object_grpc_service_proto_msgTypes[34] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2354,7 +2493,7 @@ func (x *GetRangeResponse_Body) String() string { func (*GetRangeResponse_Body) ProtoMessage() {} func (x *GetRangeResponse_Body) ProtoReflect() protoreflect.Message { - mi := &file_object_grpc_service_proto_msgTypes[32] + mi := &file_object_grpc_service_proto_msgTypes[34] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2442,7 +2581,7 @@ type GetRangeHashRequest_Body struct { func (x *GetRangeHashRequest_Body) Reset() { *x = GetRangeHashRequest_Body{} if protoimpl.UnsafeEnabled { - mi := &file_object_grpc_service_proto_msgTypes[33] + mi := &file_object_grpc_service_proto_msgTypes[35] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2455,7 +2594,7 @@ func (x *GetRangeHashRequest_Body) String() string { func (*GetRangeHashRequest_Body) ProtoMessage() {} func (x *GetRangeHashRequest_Body) ProtoReflect() protoreflect.Message { - mi := &file_object_grpc_service_proto_msgTypes[33] + mi := &file_object_grpc_service_proto_msgTypes[35] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2514,7 +2653,7 @@ type GetRangeHashResponse_Body struct { func (x *GetRangeHashResponse_Body) Reset() { *x = GetRangeHashResponse_Body{} if protoimpl.UnsafeEnabled { - mi := &file_object_grpc_service_proto_msgTypes[34] + mi := &file_object_grpc_service_proto_msgTypes[36] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2527,7 +2666,7 @@ func (x *GetRangeHashResponse_Body) String() string { func (*GetRangeHashResponse_Body) ProtoMessage() {} func (x *GetRangeHashResponse_Body) ProtoReflect() protoreflect.Message { - mi := &file_object_grpc_service_proto_msgTypes[34] + mi := &file_object_grpc_service_proto_msgTypes[36] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2577,7 +2716,7 @@ type PutSingleRequest_Body struct { func (x *PutSingleRequest_Body) Reset() { *x = PutSingleRequest_Body{} if protoimpl.UnsafeEnabled { - mi := &file_object_grpc_service_proto_msgTypes[35] + mi := &file_object_grpc_service_proto_msgTypes[37] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2590,7 +2729,7 @@ func (x *PutSingleRequest_Body) String() string { func (*PutSingleRequest_Body) ProtoMessage() {} func (x *PutSingleRequest_Body) ProtoReflect() protoreflect.Message { - mi := &file_object_grpc_service_proto_msgTypes[35] + mi := &file_object_grpc_service_proto_msgTypes[37] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2630,7 +2769,7 @@ type PutSingleResponse_Body struct { func (x *PutSingleResponse_Body) Reset() { *x = PutSingleResponse_Body{} if protoimpl.UnsafeEnabled { - mi := &file_object_grpc_service_proto_msgTypes[36] + mi := &file_object_grpc_service_proto_msgTypes[38] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2643,7 +2782,7 @@ func (x *PutSingleResponse_Body) String() string { func (*PutSingleResponse_Body) ProtoMessage() {} func (x *PutSingleResponse_Body) ProtoReflect() protoreflect.Message { - mi := &file_object_grpc_service_proto_msgTypes[36] + mi := &file_object_grpc_service_proto_msgTypes[38] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2659,6 +2798,196 @@ func (*PutSingleResponse_Body) Descriptor() ([]byte, []int) { return file_object_grpc_service_proto_rawDescGZIP(), []int{17, 0} } +// PATCH request body +type PatchRequest_Body struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The address of the object that is requested to get patched. + Address *grpc1.Address `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` + // New attributes for the object. See `replace_attributes` flag usage to define how + // new attributes should be set. + NewAttributes []*Header_Attribute `protobuf:"bytes,2,rep,name=new_attributes,json=newAttributes,proto3" json:"new_attributes,omitempty"` + // If this flag is set, then the object's attributes will be entirely replaced by `new_attributes` list. + // The empty `new_attributes` list with `replace_attributes = true` just resets attributes list for the object. + // + // Default `false` value for this flag means the attributes will be just merged. If the incoming `new_attributes` + // list contains already existing key, then it just replaces it while merging the lists. + ReplaceAttributes bool `protobuf:"varint,3,opt,name=replace_attributes,json=replaceAttributes,proto3" json:"replace_attributes,omitempty"` + // The patch that is applied for the object. + Patch *PatchRequest_Body_Patch `protobuf:"bytes,4,opt,name=patch,proto3" json:"patch,omitempty"` +} + +func (x *PatchRequest_Body) Reset() { + *x = PatchRequest_Body{} + if protoimpl.UnsafeEnabled { + mi := &file_object_grpc_service_proto_msgTypes[39] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *PatchRequest_Body) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*PatchRequest_Body) ProtoMessage() {} + +func (x *PatchRequest_Body) ProtoReflect() protoreflect.Message { + mi := &file_object_grpc_service_proto_msgTypes[39] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use PatchRequest_Body.ProtoReflect.Descriptor instead. +func (*PatchRequest_Body) Descriptor() ([]byte, []int) { + return file_object_grpc_service_proto_rawDescGZIP(), []int{18, 0} +} + +func (x *PatchRequest_Body) GetAddress() *grpc1.Address { + if x != nil { + return x.Address + } + return nil +} + +func (x *PatchRequest_Body) GetNewAttributes() []*Header_Attribute { + if x != nil { + return x.NewAttributes + } + return nil +} + +func (x *PatchRequest_Body) GetReplaceAttributes() bool { + if x != nil { + return x.ReplaceAttributes + } + return false +} + +func (x *PatchRequest_Body) GetPatch() *PatchRequest_Body_Patch { + if x != nil { + return x.Patch + } + return nil +} + +// The patch for the object's payload. +type PatchRequest_Body_Patch struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The range of the source object for which the payload is replaced by the patch's chunk. + // If the range's `length = 0`, then the patch's chunk is just appended to the original payload + // starting from the `offest` without any replace. + SourceRange *Range `protobuf:"bytes,1,opt,name=source_range,json=sourceRange,proto3" json:"source_range,omitempty"` + // The chunk that is being appended to or that replaces the original payload on the given range. + Chunk []byte `protobuf:"bytes,2,opt,name=chunk,proto3" json:"chunk,omitempty"` +} + +func (x *PatchRequest_Body_Patch) Reset() { + *x = PatchRequest_Body_Patch{} + if protoimpl.UnsafeEnabled { + mi := &file_object_grpc_service_proto_msgTypes[40] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *PatchRequest_Body_Patch) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*PatchRequest_Body_Patch) ProtoMessage() {} + +func (x *PatchRequest_Body_Patch) ProtoReflect() protoreflect.Message { + mi := &file_object_grpc_service_proto_msgTypes[40] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use PatchRequest_Body_Patch.ProtoReflect.Descriptor instead. +func (*PatchRequest_Body_Patch) Descriptor() ([]byte, []int) { + return file_object_grpc_service_proto_rawDescGZIP(), []int{18, 0, 0} +} + +func (x *PatchRequest_Body_Patch) GetSourceRange() *Range { + if x != nil { + return x.SourceRange + } + return nil +} + +func (x *PatchRequest_Body_Patch) GetChunk() []byte { + if x != nil { + return x.Chunk + } + return nil +} + +// PATCH response body +type PatchResponse_Body struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The object ID of the saved patched object. + ObjectId *grpc1.ObjectID `protobuf:"bytes,1,opt,name=object_id,json=objectId,proto3" json:"object_id,omitempty"` +} + +func (x *PatchResponse_Body) Reset() { + *x = PatchResponse_Body{} + if protoimpl.UnsafeEnabled { + mi := &file_object_grpc_service_proto_msgTypes[41] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *PatchResponse_Body) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*PatchResponse_Body) ProtoMessage() {} + +func (x *PatchResponse_Body) ProtoReflect() protoreflect.Message { + mi := &file_object_grpc_service_proto_msgTypes[41] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use PatchResponse_Body.ProtoReflect.Descriptor instead. +func (*PatchResponse_Body) Descriptor() ([]byte, []int) { + return file_object_grpc_service_proto_rawDescGZIP(), []int{19, 0} +} + +func (x *PatchResponse_Body) GetObjectId() *grpc1.ObjectID { + if x != nil { + return x.ObjectId + } + return nil +} + var File_object_grpc_service_proto protoreflect.FileDescriptor var file_object_grpc_service_proto_rawDesc = []byte{ @@ -3060,54 +3389,113 @@ var file_object_grpc_service_proto_rawDesc = []byte{ 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x56, 0x65, 0x72, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x0c, 0x76, 0x65, 0x72, 0x69, 0x66, 0x79, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x1a, 0x06, 0x0a, - 0x04, 0x42, 0x6f, 0x64, 0x79, 0x32, 0x88, 0x05, 0x0a, 0x0d, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x44, 0x0a, 0x03, 0x47, 0x65, 0x74, 0x12, 0x1c, - 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1d, 0x2e, 0x6e, - 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, - 0x47, 0x65, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x30, 0x01, 0x12, 0x44, 0x0a, - 0x03, 0x50, 0x75, 0x74, 0x12, 0x1c, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, - 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x50, 0x75, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x1d, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x50, 0x75, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x28, 0x01, 0x12, 0x4b, 0x0a, 0x06, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x12, 0x1f, 0x2e, + 0x04, 0x42, 0x6f, 0x64, 0x79, 0x22, 0xb3, 0x04, 0x0a, 0x0c, 0x50, 0x61, 0x74, 0x63, 0x68, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x37, 0x0a, 0x04, 0x62, 0x6f, 0x64, 0x79, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, + 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x50, 0x61, 0x74, 0x63, 0x68, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x2e, 0x42, 0x6f, 0x64, 0x79, 0x52, 0x04, 0x62, 0x6f, 0x64, 0x79, 0x12, + 0x45, 0x0a, 0x0b, 0x6d, 0x65, 0x74, 0x61, 0x5f, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, + 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x4d, 0x65, 0x74, 0x61, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x0a, 0x6d, 0x65, 0x74, 0x61, + 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x12, 0x51, 0x0a, 0x0d, 0x76, 0x65, 0x72, 0x69, 0x66, 0x79, + 0x5f, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2c, 0x2e, + 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, + 0x6e, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x56, 0x65, 0x72, 0x69, 0x66, 0x69, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x0c, 0x76, 0x65, 0x72, + 0x69, 0x66, 0x79, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x1a, 0xcf, 0x02, 0x0a, 0x04, 0x42, 0x6f, + 0x64, 0x79, 0x12, 0x31, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, + 0x72, 0x65, 0x66, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x52, 0x07, 0x61, 0x64, + 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x49, 0x0a, 0x0e, 0x6e, 0x65, 0x77, 0x5f, 0x61, 0x74, 0x74, + 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, + 0x2e, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x2e, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, + 0x65, 0x52, 0x0d, 0x6e, 0x65, 0x77, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, + 0x12, 0x2d, 0x0a, 0x12, 0x72, 0x65, 0x70, 0x6c, 0x61, 0x63, 0x65, 0x5f, 0x61, 0x74, 0x74, 0x72, + 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x11, 0x72, 0x65, + 0x70, 0x6c, 0x61, 0x63, 0x65, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, + 0x3f, 0x0a, 0x05, 0x70, 0x61, 0x74, 0x63, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x29, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x12, 0x45, 0x0a, 0x04, 0x48, 0x65, 0x61, 0x64, 0x12, 0x1d, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, - 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x48, 0x65, 0x61, 0x64, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, - 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x48, 0x65, 0x61, 0x64, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x4d, 0x0a, 0x06, 0x53, 0x65, 0x61, 0x72, 0x63, - 0x68, 0x12, 0x1f, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x30, 0x01, 0x12, 0x53, 0x0a, 0x08, 0x47, 0x65, 0x74, 0x52, 0x61, 0x6e, - 0x67, 0x65, 0x12, 0x21, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, - 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x61, 0x6e, 0x67, - 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x30, 0x01, 0x12, 0x5d, 0x0a, 0x0c, 0x47, - 0x65, 0x74, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x25, 0x2e, 0x6e, 0x65, - 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x47, - 0x65, 0x74, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x48, 0x61, - 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x54, 0x0a, 0x09, 0x50, 0x75, - 0x74, 0x53, 0x69, 0x6e, 0x67, 0x6c, 0x65, 0x12, 0x22, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, - 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x50, 0x75, 0x74, 0x53, 0x69, - 0x6e, 0x67, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x23, 0x2e, 0x6e, 0x65, + 0x74, 0x2e, 0x50, 0x61, 0x74, 0x63, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x2e, 0x42, + 0x6f, 0x64, 0x79, 0x2e, 0x50, 0x61, 0x74, 0x63, 0x68, 0x52, 0x05, 0x70, 0x61, 0x74, 0x63, 0x68, + 0x1a, 0x59, 0x0a, 0x05, 0x50, 0x61, 0x74, 0x63, 0x68, 0x12, 0x3a, 0x0a, 0x0c, 0x73, 0x6f, 0x75, + 0x72, 0x63, 0x65, 0x5f, 0x72, 0x61, 0x6e, 0x67, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x17, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, + 0x63, 0x74, 0x2e, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x0b, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, + 0x52, 0x61, 0x6e, 0x67, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x63, 0x68, 0x75, 0x6e, 0x6b, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x63, 0x68, 0x75, 0x6e, 0x6b, 0x22, 0xa4, 0x02, 0x0a, 0x0d, + 0x50, 0x61, 0x74, 0x63, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x38, 0x0a, + 0x04, 0x62, 0x6f, 0x64, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x50, - 0x75, 0x74, 0x53, 0x69, 0x6e, 0x67, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x42, 0x61, 0x5a, 0x42, 0x67, 0x69, 0x74, 0x2e, 0x66, 0x72, 0x6f, 0x73, 0x74, 0x66, 0x73, 0x2e, - 0x69, 0x6e, 0x66, 0x6f, 0x2f, 0x54, 0x72, 0x75, 0x65, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x4c, 0x61, - 0x62, 0x2f, 0x66, 0x72, 0x6f, 0x73, 0x74, 0x66, 0x73, 0x2d, 0x61, 0x70, 0x69, 0x2d, 0x67, 0x6f, - 0x2f, 0x76, 0x32, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2f, 0x67, 0x72, 0x70, 0x63, 0x3b, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0xaa, 0x02, 0x1a, 0x4e, 0x65, 0x6f, 0x2e, 0x46, 0x69, 0x6c, - 0x65, 0x53, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x2e, 0x41, 0x50, 0x49, 0x2e, 0x4f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x61, 0x74, 0x63, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2e, 0x42, 0x6f, 0x64, + 0x79, 0x52, 0x04, 0x62, 0x6f, 0x64, 0x79, 0x12, 0x46, 0x0a, 0x0b, 0x6d, 0x65, 0x74, 0x61, 0x5f, + 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x6e, + 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, + 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x48, 0x65, 0x61, + 0x64, 0x65, 0x72, 0x52, 0x0a, 0x6d, 0x65, 0x74, 0x61, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x12, + 0x52, 0x0a, 0x0d, 0x76, 0x65, 0x72, 0x69, 0x66, 0x79, 0x5f, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2d, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, + 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x56, 0x65, 0x72, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x48, + 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x0c, 0x76, 0x65, 0x72, 0x69, 0x66, 0x79, 0x48, 0x65, 0x61, + 0x64, 0x65, 0x72, 0x1a, 0x3d, 0x0a, 0x04, 0x42, 0x6f, 0x64, 0x79, 0x12, 0x35, 0x0a, 0x09, 0x6f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x18, + 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, 0x65, 0x66, 0x73, 0x2e, + 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x49, 0x44, 0x52, 0x08, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, + 0x49, 0x64, 0x32, 0xd4, 0x05, 0x0a, 0x0d, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x53, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x12, 0x44, 0x0a, 0x03, 0x47, 0x65, 0x74, 0x12, 0x1c, 0x2e, 0x6e, 0x65, + 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x47, + 0x65, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1d, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, + 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x47, 0x65, 0x74, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x30, 0x01, 0x12, 0x44, 0x0a, 0x03, 0x50, 0x75, + 0x74, 0x12, 0x1c, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x50, 0x75, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x1d, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, + 0x63, 0x74, 0x2e, 0x50, 0x75, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x28, 0x01, + 0x12, 0x4b, 0x0a, 0x06, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x12, 0x1f, 0x2e, 0x6e, 0x65, 0x6f, + 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x44, 0x65, + 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x6e, 0x65, + 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x44, + 0x65, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x45, 0x0a, + 0x04, 0x48, 0x65, 0x61, 0x64, 0x12, 0x1d, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, + 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x48, 0x65, 0x61, 0x64, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, + 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x48, 0x65, 0x61, 0x64, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x4d, 0x0a, 0x06, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x12, 0x1f, + 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, + 0x74, 0x2e, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x20, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, + 0x63, 0x74, 0x2e, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x30, 0x01, 0x12, 0x53, 0x0a, 0x08, 0x47, 0x65, 0x74, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x12, + 0x21, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, + 0x63, 0x74, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x30, 0x01, 0x12, 0x5d, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x52, + 0x61, 0x6e, 0x67, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x25, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, + 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x47, 0x65, 0x74, 0x52, + 0x61, 0x6e, 0x67, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x26, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, + 0x63, 0x74, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x48, 0x61, 0x73, 0x68, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x54, 0x0a, 0x09, 0x50, 0x75, 0x74, 0x53, 0x69, + 0x6e, 0x67, 0x6c, 0x65, 0x12, 0x22, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, + 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x50, 0x75, 0x74, 0x53, 0x69, 0x6e, 0x67, 0x6c, + 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x23, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, + 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x50, 0x75, 0x74, 0x53, + 0x69, 0x6e, 0x67, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x4a, 0x0a, + 0x05, 0x50, 0x61, 0x74, 0x63, 0x68, 0x12, 0x1e, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, + 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x50, 0x61, 0x74, 0x63, 0x68, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, + 0x76, 0x32, 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x50, 0x61, 0x74, 0x63, 0x68, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x28, 0x01, 0x42, 0x61, 0x5a, 0x42, 0x67, 0x69, 0x74, + 0x2e, 0x66, 0x72, 0x6f, 0x73, 0x74, 0x66, 0x73, 0x2e, 0x69, 0x6e, 0x66, 0x6f, 0x2f, 0x54, 0x72, + 0x75, 0x65, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x4c, 0x61, 0x62, 0x2f, 0x66, 0x72, 0x6f, 0x73, 0x74, + 0x66, 0x73, 0x2d, 0x61, 0x70, 0x69, 0x2d, 0x67, 0x6f, 0x2f, 0x76, 0x32, 0x2f, 0x6f, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x2f, 0x67, 0x72, 0x70, 0x63, 0x3b, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0xaa, + 0x02, 0x1a, 0x4e, 0x65, 0x6f, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x6f, 0x72, 0x61, 0x67, + 0x65, 0x2e, 0x41, 0x50, 0x49, 0x2e, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x62, 0x06, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -3122,7 +3510,7 @@ func file_object_grpc_service_proto_rawDescGZIP() []byte { return file_object_grpc_service_proto_rawDescData } -var file_object_grpc_service_proto_msgTypes = make([]protoimpl.MessageInfo, 37) +var file_object_grpc_service_proto_msgTypes = make([]protoimpl.MessageInfo, 42) var file_object_grpc_service_proto_goTypes = []interface{}{ (*GetRequest)(nil), // 0: neo.fs.v2.object.GetRequest (*GetResponse)(nil), // 1: neo.fs.v2.object.GetResponse @@ -3142,145 +3530,164 @@ var file_object_grpc_service_proto_goTypes = []interface{}{ (*GetRangeHashResponse)(nil), // 15: neo.fs.v2.object.GetRangeHashResponse (*PutSingleRequest)(nil), // 16: neo.fs.v2.object.PutSingleRequest (*PutSingleResponse)(nil), // 17: neo.fs.v2.object.PutSingleResponse - (*GetRequest_Body)(nil), // 18: neo.fs.v2.object.GetRequest.Body - (*GetResponse_Body)(nil), // 19: neo.fs.v2.object.GetResponse.Body - (*GetResponse_Body_Init)(nil), // 20: neo.fs.v2.object.GetResponse.Body.Init - (*PutRequest_Body)(nil), // 21: neo.fs.v2.object.PutRequest.Body - (*PutRequest_Body_Init)(nil), // 22: neo.fs.v2.object.PutRequest.Body.Init - (*PutResponse_Body)(nil), // 23: neo.fs.v2.object.PutResponse.Body - (*DeleteRequest_Body)(nil), // 24: neo.fs.v2.object.DeleteRequest.Body - (*DeleteResponse_Body)(nil), // 25: neo.fs.v2.object.DeleteResponse.Body - (*HeadRequest_Body)(nil), // 26: neo.fs.v2.object.HeadRequest.Body - (*HeadResponse_Body)(nil), // 27: neo.fs.v2.object.HeadResponse.Body - (*SearchRequest_Body)(nil), // 28: neo.fs.v2.object.SearchRequest.Body - (*SearchRequest_Body_Filter)(nil), // 29: neo.fs.v2.object.SearchRequest.Body.Filter - (*SearchResponse_Body)(nil), // 30: neo.fs.v2.object.SearchResponse.Body - (*GetRangeRequest_Body)(nil), // 31: neo.fs.v2.object.GetRangeRequest.Body - (*GetRangeResponse_Body)(nil), // 32: neo.fs.v2.object.GetRangeResponse.Body - (*GetRangeHashRequest_Body)(nil), // 33: neo.fs.v2.object.GetRangeHashRequest.Body - (*GetRangeHashResponse_Body)(nil), // 34: neo.fs.v2.object.GetRangeHashResponse.Body - (*PutSingleRequest_Body)(nil), // 35: neo.fs.v2.object.PutSingleRequest.Body - (*PutSingleResponse_Body)(nil), // 36: neo.fs.v2.object.PutSingleResponse.Body - (*grpc.RequestMetaHeader)(nil), // 37: neo.fs.v2.session.RequestMetaHeader - (*grpc.RequestVerificationHeader)(nil), // 38: neo.fs.v2.session.RequestVerificationHeader - (*grpc.ResponseMetaHeader)(nil), // 39: neo.fs.v2.session.ResponseMetaHeader - (*grpc.ResponseVerificationHeader)(nil), // 40: neo.fs.v2.session.ResponseVerificationHeader - (*Header)(nil), // 41: neo.fs.v2.object.Header - (*grpc1.Signature)(nil), // 42: neo.fs.v2.refs.Signature - (*grpc1.Address)(nil), // 43: neo.fs.v2.refs.Address - (*SplitInfo)(nil), // 44: neo.fs.v2.object.SplitInfo - (*ECInfo)(nil), // 45: neo.fs.v2.object.ECInfo - (*grpc1.ObjectID)(nil), // 46: neo.fs.v2.refs.ObjectID - (*ShortHeader)(nil), // 47: neo.fs.v2.object.ShortHeader - (*grpc1.ContainerID)(nil), // 48: neo.fs.v2.refs.ContainerID - (MatchType)(0), // 49: neo.fs.v2.object.MatchType - (grpc1.ChecksumType)(0), // 50: neo.fs.v2.refs.ChecksumType - (*Object)(nil), // 51: neo.fs.v2.object.Object + (*PatchRequest)(nil), // 18: neo.fs.v2.object.PatchRequest + (*PatchResponse)(nil), // 19: neo.fs.v2.object.PatchResponse + (*GetRequest_Body)(nil), // 20: neo.fs.v2.object.GetRequest.Body + (*GetResponse_Body)(nil), // 21: neo.fs.v2.object.GetResponse.Body + (*GetResponse_Body_Init)(nil), // 22: neo.fs.v2.object.GetResponse.Body.Init + (*PutRequest_Body)(nil), // 23: neo.fs.v2.object.PutRequest.Body + (*PutRequest_Body_Init)(nil), // 24: neo.fs.v2.object.PutRequest.Body.Init + (*PutResponse_Body)(nil), // 25: neo.fs.v2.object.PutResponse.Body + (*DeleteRequest_Body)(nil), // 26: neo.fs.v2.object.DeleteRequest.Body + (*DeleteResponse_Body)(nil), // 27: neo.fs.v2.object.DeleteResponse.Body + (*HeadRequest_Body)(nil), // 28: neo.fs.v2.object.HeadRequest.Body + (*HeadResponse_Body)(nil), // 29: neo.fs.v2.object.HeadResponse.Body + (*SearchRequest_Body)(nil), // 30: neo.fs.v2.object.SearchRequest.Body + (*SearchRequest_Body_Filter)(nil), // 31: neo.fs.v2.object.SearchRequest.Body.Filter + (*SearchResponse_Body)(nil), // 32: neo.fs.v2.object.SearchResponse.Body + (*GetRangeRequest_Body)(nil), // 33: neo.fs.v2.object.GetRangeRequest.Body + (*GetRangeResponse_Body)(nil), // 34: neo.fs.v2.object.GetRangeResponse.Body + (*GetRangeHashRequest_Body)(nil), // 35: neo.fs.v2.object.GetRangeHashRequest.Body + (*GetRangeHashResponse_Body)(nil), // 36: neo.fs.v2.object.GetRangeHashResponse.Body + (*PutSingleRequest_Body)(nil), // 37: neo.fs.v2.object.PutSingleRequest.Body + (*PutSingleResponse_Body)(nil), // 38: neo.fs.v2.object.PutSingleResponse.Body + (*PatchRequest_Body)(nil), // 39: neo.fs.v2.object.PatchRequest.Body + (*PatchRequest_Body_Patch)(nil), // 40: neo.fs.v2.object.PatchRequest.Body.Patch + (*PatchResponse_Body)(nil), // 41: neo.fs.v2.object.PatchResponse.Body + (*grpc.RequestMetaHeader)(nil), // 42: neo.fs.v2.session.RequestMetaHeader + (*grpc.RequestVerificationHeader)(nil), // 43: neo.fs.v2.session.RequestVerificationHeader + (*grpc.ResponseMetaHeader)(nil), // 44: neo.fs.v2.session.ResponseMetaHeader + (*grpc.ResponseVerificationHeader)(nil), // 45: neo.fs.v2.session.ResponseVerificationHeader + (*Header)(nil), // 46: neo.fs.v2.object.Header + (*grpc1.Signature)(nil), // 47: neo.fs.v2.refs.Signature + (*grpc1.Address)(nil), // 48: neo.fs.v2.refs.Address + (*SplitInfo)(nil), // 49: neo.fs.v2.object.SplitInfo + (*ECInfo)(nil), // 50: neo.fs.v2.object.ECInfo + (*grpc1.ObjectID)(nil), // 51: neo.fs.v2.refs.ObjectID + (*ShortHeader)(nil), // 52: neo.fs.v2.object.ShortHeader + (*grpc1.ContainerID)(nil), // 53: neo.fs.v2.refs.ContainerID + (MatchType)(0), // 54: neo.fs.v2.object.MatchType + (grpc1.ChecksumType)(0), // 55: neo.fs.v2.refs.ChecksumType + (*Object)(nil), // 56: neo.fs.v2.object.Object + (*Header_Attribute)(nil), // 57: neo.fs.v2.object.Header.Attribute } var file_object_grpc_service_proto_depIdxs = []int32{ - 18, // 0: neo.fs.v2.object.GetRequest.body:type_name -> neo.fs.v2.object.GetRequest.Body - 37, // 1: neo.fs.v2.object.GetRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader - 38, // 2: neo.fs.v2.object.GetRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader - 19, // 3: neo.fs.v2.object.GetResponse.body:type_name -> neo.fs.v2.object.GetResponse.Body - 39, // 4: neo.fs.v2.object.GetResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader - 40, // 5: neo.fs.v2.object.GetResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader - 21, // 6: neo.fs.v2.object.PutRequest.body:type_name -> neo.fs.v2.object.PutRequest.Body - 37, // 7: neo.fs.v2.object.PutRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader - 38, // 8: neo.fs.v2.object.PutRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader - 23, // 9: neo.fs.v2.object.PutResponse.body:type_name -> neo.fs.v2.object.PutResponse.Body - 39, // 10: neo.fs.v2.object.PutResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader - 40, // 11: neo.fs.v2.object.PutResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader - 24, // 12: neo.fs.v2.object.DeleteRequest.body:type_name -> neo.fs.v2.object.DeleteRequest.Body - 37, // 13: neo.fs.v2.object.DeleteRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader - 38, // 14: neo.fs.v2.object.DeleteRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader - 25, // 15: neo.fs.v2.object.DeleteResponse.body:type_name -> neo.fs.v2.object.DeleteResponse.Body - 39, // 16: neo.fs.v2.object.DeleteResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader - 40, // 17: neo.fs.v2.object.DeleteResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader - 26, // 18: neo.fs.v2.object.HeadRequest.body:type_name -> neo.fs.v2.object.HeadRequest.Body - 37, // 19: neo.fs.v2.object.HeadRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader - 38, // 20: neo.fs.v2.object.HeadRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader - 41, // 21: neo.fs.v2.object.HeaderWithSignature.header:type_name -> neo.fs.v2.object.Header - 42, // 22: neo.fs.v2.object.HeaderWithSignature.signature:type_name -> neo.fs.v2.refs.Signature - 27, // 23: neo.fs.v2.object.HeadResponse.body:type_name -> neo.fs.v2.object.HeadResponse.Body - 39, // 24: neo.fs.v2.object.HeadResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader - 40, // 25: neo.fs.v2.object.HeadResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader - 28, // 26: neo.fs.v2.object.SearchRequest.body:type_name -> neo.fs.v2.object.SearchRequest.Body - 37, // 27: neo.fs.v2.object.SearchRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader - 38, // 28: neo.fs.v2.object.SearchRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader - 30, // 29: neo.fs.v2.object.SearchResponse.body:type_name -> neo.fs.v2.object.SearchResponse.Body - 39, // 30: neo.fs.v2.object.SearchResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader - 40, // 31: neo.fs.v2.object.SearchResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader - 31, // 32: neo.fs.v2.object.GetRangeRequest.body:type_name -> neo.fs.v2.object.GetRangeRequest.Body - 37, // 33: neo.fs.v2.object.GetRangeRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader - 38, // 34: neo.fs.v2.object.GetRangeRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader - 32, // 35: neo.fs.v2.object.GetRangeResponse.body:type_name -> neo.fs.v2.object.GetRangeResponse.Body - 39, // 36: neo.fs.v2.object.GetRangeResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader - 40, // 37: neo.fs.v2.object.GetRangeResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader - 33, // 38: neo.fs.v2.object.GetRangeHashRequest.body:type_name -> neo.fs.v2.object.GetRangeHashRequest.Body - 37, // 39: neo.fs.v2.object.GetRangeHashRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader - 38, // 40: neo.fs.v2.object.GetRangeHashRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader - 34, // 41: neo.fs.v2.object.GetRangeHashResponse.body:type_name -> neo.fs.v2.object.GetRangeHashResponse.Body - 39, // 42: neo.fs.v2.object.GetRangeHashResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader - 40, // 43: neo.fs.v2.object.GetRangeHashResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader - 35, // 44: neo.fs.v2.object.PutSingleRequest.body:type_name -> neo.fs.v2.object.PutSingleRequest.Body - 37, // 45: neo.fs.v2.object.PutSingleRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader - 38, // 46: neo.fs.v2.object.PutSingleRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader - 36, // 47: neo.fs.v2.object.PutSingleResponse.body:type_name -> neo.fs.v2.object.PutSingleResponse.Body - 39, // 48: neo.fs.v2.object.PutSingleResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader - 40, // 49: neo.fs.v2.object.PutSingleResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader - 43, // 50: neo.fs.v2.object.GetRequest.Body.address:type_name -> neo.fs.v2.refs.Address - 20, // 51: neo.fs.v2.object.GetResponse.Body.init:type_name -> neo.fs.v2.object.GetResponse.Body.Init - 44, // 52: neo.fs.v2.object.GetResponse.Body.split_info:type_name -> neo.fs.v2.object.SplitInfo - 45, // 53: neo.fs.v2.object.GetResponse.Body.ec_info:type_name -> neo.fs.v2.object.ECInfo - 46, // 54: neo.fs.v2.object.GetResponse.Body.Init.object_id:type_name -> neo.fs.v2.refs.ObjectID - 42, // 55: neo.fs.v2.object.GetResponse.Body.Init.signature:type_name -> neo.fs.v2.refs.Signature - 41, // 56: neo.fs.v2.object.GetResponse.Body.Init.header:type_name -> neo.fs.v2.object.Header - 22, // 57: neo.fs.v2.object.PutRequest.Body.init:type_name -> neo.fs.v2.object.PutRequest.Body.Init - 46, // 58: neo.fs.v2.object.PutRequest.Body.Init.object_id:type_name -> neo.fs.v2.refs.ObjectID - 42, // 59: neo.fs.v2.object.PutRequest.Body.Init.signature:type_name -> neo.fs.v2.refs.Signature - 41, // 60: neo.fs.v2.object.PutRequest.Body.Init.header:type_name -> neo.fs.v2.object.Header - 46, // 61: neo.fs.v2.object.PutResponse.Body.object_id:type_name -> neo.fs.v2.refs.ObjectID - 43, // 62: neo.fs.v2.object.DeleteRequest.Body.address:type_name -> neo.fs.v2.refs.Address - 43, // 63: neo.fs.v2.object.DeleteResponse.Body.tombstone:type_name -> neo.fs.v2.refs.Address - 43, // 64: neo.fs.v2.object.HeadRequest.Body.address:type_name -> neo.fs.v2.refs.Address - 7, // 65: neo.fs.v2.object.HeadResponse.Body.header:type_name -> neo.fs.v2.object.HeaderWithSignature - 47, // 66: neo.fs.v2.object.HeadResponse.Body.short_header:type_name -> neo.fs.v2.object.ShortHeader - 44, // 67: neo.fs.v2.object.HeadResponse.Body.split_info:type_name -> neo.fs.v2.object.SplitInfo - 45, // 68: neo.fs.v2.object.HeadResponse.Body.ec_info:type_name -> neo.fs.v2.object.ECInfo - 48, // 69: neo.fs.v2.object.SearchRequest.Body.container_id:type_name -> neo.fs.v2.refs.ContainerID - 29, // 70: neo.fs.v2.object.SearchRequest.Body.filters:type_name -> neo.fs.v2.object.SearchRequest.Body.Filter - 49, // 71: neo.fs.v2.object.SearchRequest.Body.Filter.match_type:type_name -> neo.fs.v2.object.MatchType - 46, // 72: neo.fs.v2.object.SearchResponse.Body.id_list:type_name -> neo.fs.v2.refs.ObjectID - 43, // 73: neo.fs.v2.object.GetRangeRequest.Body.address:type_name -> neo.fs.v2.refs.Address - 11, // 74: neo.fs.v2.object.GetRangeRequest.Body.range:type_name -> neo.fs.v2.object.Range - 44, // 75: neo.fs.v2.object.GetRangeResponse.Body.split_info:type_name -> neo.fs.v2.object.SplitInfo - 45, // 76: neo.fs.v2.object.GetRangeResponse.Body.ec_info:type_name -> neo.fs.v2.object.ECInfo - 43, // 77: neo.fs.v2.object.GetRangeHashRequest.Body.address:type_name -> neo.fs.v2.refs.Address - 11, // 78: neo.fs.v2.object.GetRangeHashRequest.Body.ranges:type_name -> neo.fs.v2.object.Range - 50, // 79: neo.fs.v2.object.GetRangeHashRequest.Body.type:type_name -> neo.fs.v2.refs.ChecksumType - 50, // 80: neo.fs.v2.object.GetRangeHashResponse.Body.type:type_name -> neo.fs.v2.refs.ChecksumType - 51, // 81: neo.fs.v2.object.PutSingleRequest.Body.object:type_name -> neo.fs.v2.object.Object - 0, // 82: neo.fs.v2.object.ObjectService.Get:input_type -> neo.fs.v2.object.GetRequest - 2, // 83: neo.fs.v2.object.ObjectService.Put:input_type -> neo.fs.v2.object.PutRequest - 4, // 84: neo.fs.v2.object.ObjectService.Delete:input_type -> neo.fs.v2.object.DeleteRequest - 6, // 85: neo.fs.v2.object.ObjectService.Head:input_type -> neo.fs.v2.object.HeadRequest - 9, // 86: neo.fs.v2.object.ObjectService.Search:input_type -> neo.fs.v2.object.SearchRequest - 12, // 87: neo.fs.v2.object.ObjectService.GetRange:input_type -> neo.fs.v2.object.GetRangeRequest - 14, // 88: neo.fs.v2.object.ObjectService.GetRangeHash:input_type -> neo.fs.v2.object.GetRangeHashRequest - 16, // 89: neo.fs.v2.object.ObjectService.PutSingle:input_type -> neo.fs.v2.object.PutSingleRequest - 1, // 90: neo.fs.v2.object.ObjectService.Get:output_type -> neo.fs.v2.object.GetResponse - 3, // 91: neo.fs.v2.object.ObjectService.Put:output_type -> neo.fs.v2.object.PutResponse - 5, // 92: neo.fs.v2.object.ObjectService.Delete:output_type -> neo.fs.v2.object.DeleteResponse - 8, // 93: neo.fs.v2.object.ObjectService.Head:output_type -> neo.fs.v2.object.HeadResponse - 10, // 94: neo.fs.v2.object.ObjectService.Search:output_type -> neo.fs.v2.object.SearchResponse - 13, // 95: neo.fs.v2.object.ObjectService.GetRange:output_type -> neo.fs.v2.object.GetRangeResponse - 15, // 96: neo.fs.v2.object.ObjectService.GetRangeHash:output_type -> neo.fs.v2.object.GetRangeHashResponse - 17, // 97: neo.fs.v2.object.ObjectService.PutSingle:output_type -> neo.fs.v2.object.PutSingleResponse - 90, // [90:98] is the sub-list for method output_type - 82, // [82:90] is the sub-list for method input_type - 82, // [82:82] is the sub-list for extension type_name - 82, // [82:82] is the sub-list for extension extendee - 0, // [0:82] is the sub-list for field type_name + 20, // 0: neo.fs.v2.object.GetRequest.body:type_name -> neo.fs.v2.object.GetRequest.Body + 42, // 1: neo.fs.v2.object.GetRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader + 43, // 2: neo.fs.v2.object.GetRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader + 21, // 3: neo.fs.v2.object.GetResponse.body:type_name -> neo.fs.v2.object.GetResponse.Body + 44, // 4: neo.fs.v2.object.GetResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader + 45, // 5: neo.fs.v2.object.GetResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader + 23, // 6: neo.fs.v2.object.PutRequest.body:type_name -> neo.fs.v2.object.PutRequest.Body + 42, // 7: neo.fs.v2.object.PutRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader + 43, // 8: neo.fs.v2.object.PutRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader + 25, // 9: neo.fs.v2.object.PutResponse.body:type_name -> neo.fs.v2.object.PutResponse.Body + 44, // 10: neo.fs.v2.object.PutResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader + 45, // 11: neo.fs.v2.object.PutResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader + 26, // 12: neo.fs.v2.object.DeleteRequest.body:type_name -> neo.fs.v2.object.DeleteRequest.Body + 42, // 13: neo.fs.v2.object.DeleteRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader + 43, // 14: neo.fs.v2.object.DeleteRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader + 27, // 15: neo.fs.v2.object.DeleteResponse.body:type_name -> neo.fs.v2.object.DeleteResponse.Body + 44, // 16: neo.fs.v2.object.DeleteResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader + 45, // 17: neo.fs.v2.object.DeleteResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader + 28, // 18: neo.fs.v2.object.HeadRequest.body:type_name -> neo.fs.v2.object.HeadRequest.Body + 42, // 19: neo.fs.v2.object.HeadRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader + 43, // 20: neo.fs.v2.object.HeadRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader + 46, // 21: neo.fs.v2.object.HeaderWithSignature.header:type_name -> neo.fs.v2.object.Header + 47, // 22: neo.fs.v2.object.HeaderWithSignature.signature:type_name -> neo.fs.v2.refs.Signature + 29, // 23: neo.fs.v2.object.HeadResponse.body:type_name -> neo.fs.v2.object.HeadResponse.Body + 44, // 24: neo.fs.v2.object.HeadResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader + 45, // 25: neo.fs.v2.object.HeadResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader + 30, // 26: neo.fs.v2.object.SearchRequest.body:type_name -> neo.fs.v2.object.SearchRequest.Body + 42, // 27: neo.fs.v2.object.SearchRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader + 43, // 28: neo.fs.v2.object.SearchRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader + 32, // 29: neo.fs.v2.object.SearchResponse.body:type_name -> neo.fs.v2.object.SearchResponse.Body + 44, // 30: neo.fs.v2.object.SearchResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader + 45, // 31: neo.fs.v2.object.SearchResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader + 33, // 32: neo.fs.v2.object.GetRangeRequest.body:type_name -> neo.fs.v2.object.GetRangeRequest.Body + 42, // 33: neo.fs.v2.object.GetRangeRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader + 43, // 34: neo.fs.v2.object.GetRangeRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader + 34, // 35: neo.fs.v2.object.GetRangeResponse.body:type_name -> neo.fs.v2.object.GetRangeResponse.Body + 44, // 36: neo.fs.v2.object.GetRangeResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader + 45, // 37: neo.fs.v2.object.GetRangeResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader + 35, // 38: neo.fs.v2.object.GetRangeHashRequest.body:type_name -> neo.fs.v2.object.GetRangeHashRequest.Body + 42, // 39: neo.fs.v2.object.GetRangeHashRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader + 43, // 40: neo.fs.v2.object.GetRangeHashRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader + 36, // 41: neo.fs.v2.object.GetRangeHashResponse.body:type_name -> neo.fs.v2.object.GetRangeHashResponse.Body + 44, // 42: neo.fs.v2.object.GetRangeHashResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader + 45, // 43: neo.fs.v2.object.GetRangeHashResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader + 37, // 44: neo.fs.v2.object.PutSingleRequest.body:type_name -> neo.fs.v2.object.PutSingleRequest.Body + 42, // 45: neo.fs.v2.object.PutSingleRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader + 43, // 46: neo.fs.v2.object.PutSingleRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader + 38, // 47: neo.fs.v2.object.PutSingleResponse.body:type_name -> neo.fs.v2.object.PutSingleResponse.Body + 44, // 48: neo.fs.v2.object.PutSingleResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader + 45, // 49: neo.fs.v2.object.PutSingleResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader + 39, // 50: neo.fs.v2.object.PatchRequest.body:type_name -> neo.fs.v2.object.PatchRequest.Body + 42, // 51: neo.fs.v2.object.PatchRequest.meta_header:type_name -> neo.fs.v2.session.RequestMetaHeader + 43, // 52: neo.fs.v2.object.PatchRequest.verify_header:type_name -> neo.fs.v2.session.RequestVerificationHeader + 41, // 53: neo.fs.v2.object.PatchResponse.body:type_name -> neo.fs.v2.object.PatchResponse.Body + 44, // 54: neo.fs.v2.object.PatchResponse.meta_header:type_name -> neo.fs.v2.session.ResponseMetaHeader + 45, // 55: neo.fs.v2.object.PatchResponse.verify_header:type_name -> neo.fs.v2.session.ResponseVerificationHeader + 48, // 56: neo.fs.v2.object.GetRequest.Body.address:type_name -> neo.fs.v2.refs.Address + 22, // 57: neo.fs.v2.object.GetResponse.Body.init:type_name -> neo.fs.v2.object.GetResponse.Body.Init + 49, // 58: neo.fs.v2.object.GetResponse.Body.split_info:type_name -> neo.fs.v2.object.SplitInfo + 50, // 59: neo.fs.v2.object.GetResponse.Body.ec_info:type_name -> neo.fs.v2.object.ECInfo + 51, // 60: neo.fs.v2.object.GetResponse.Body.Init.object_id:type_name -> neo.fs.v2.refs.ObjectID + 47, // 61: neo.fs.v2.object.GetResponse.Body.Init.signature:type_name -> neo.fs.v2.refs.Signature + 46, // 62: neo.fs.v2.object.GetResponse.Body.Init.header:type_name -> neo.fs.v2.object.Header + 24, // 63: neo.fs.v2.object.PutRequest.Body.init:type_name -> neo.fs.v2.object.PutRequest.Body.Init + 51, // 64: neo.fs.v2.object.PutRequest.Body.Init.object_id:type_name -> neo.fs.v2.refs.ObjectID + 47, // 65: neo.fs.v2.object.PutRequest.Body.Init.signature:type_name -> neo.fs.v2.refs.Signature + 46, // 66: neo.fs.v2.object.PutRequest.Body.Init.header:type_name -> neo.fs.v2.object.Header + 51, // 67: neo.fs.v2.object.PutResponse.Body.object_id:type_name -> neo.fs.v2.refs.ObjectID + 48, // 68: neo.fs.v2.object.DeleteRequest.Body.address:type_name -> neo.fs.v2.refs.Address + 48, // 69: neo.fs.v2.object.DeleteResponse.Body.tombstone:type_name -> neo.fs.v2.refs.Address + 48, // 70: neo.fs.v2.object.HeadRequest.Body.address:type_name -> neo.fs.v2.refs.Address + 7, // 71: neo.fs.v2.object.HeadResponse.Body.header:type_name -> neo.fs.v2.object.HeaderWithSignature + 52, // 72: neo.fs.v2.object.HeadResponse.Body.short_header:type_name -> neo.fs.v2.object.ShortHeader + 49, // 73: neo.fs.v2.object.HeadResponse.Body.split_info:type_name -> neo.fs.v2.object.SplitInfo + 50, // 74: neo.fs.v2.object.HeadResponse.Body.ec_info:type_name -> neo.fs.v2.object.ECInfo + 53, // 75: neo.fs.v2.object.SearchRequest.Body.container_id:type_name -> neo.fs.v2.refs.ContainerID + 31, // 76: neo.fs.v2.object.SearchRequest.Body.filters:type_name -> neo.fs.v2.object.SearchRequest.Body.Filter + 54, // 77: neo.fs.v2.object.SearchRequest.Body.Filter.match_type:type_name -> neo.fs.v2.object.MatchType + 51, // 78: neo.fs.v2.object.SearchResponse.Body.id_list:type_name -> neo.fs.v2.refs.ObjectID + 48, // 79: neo.fs.v2.object.GetRangeRequest.Body.address:type_name -> neo.fs.v2.refs.Address + 11, // 80: neo.fs.v2.object.GetRangeRequest.Body.range:type_name -> neo.fs.v2.object.Range + 49, // 81: neo.fs.v2.object.GetRangeResponse.Body.split_info:type_name -> neo.fs.v2.object.SplitInfo + 50, // 82: neo.fs.v2.object.GetRangeResponse.Body.ec_info:type_name -> neo.fs.v2.object.ECInfo + 48, // 83: neo.fs.v2.object.GetRangeHashRequest.Body.address:type_name -> neo.fs.v2.refs.Address + 11, // 84: neo.fs.v2.object.GetRangeHashRequest.Body.ranges:type_name -> neo.fs.v2.object.Range + 55, // 85: neo.fs.v2.object.GetRangeHashRequest.Body.type:type_name -> neo.fs.v2.refs.ChecksumType + 55, // 86: neo.fs.v2.object.GetRangeHashResponse.Body.type:type_name -> neo.fs.v2.refs.ChecksumType + 56, // 87: neo.fs.v2.object.PutSingleRequest.Body.object:type_name -> neo.fs.v2.object.Object + 48, // 88: neo.fs.v2.object.PatchRequest.Body.address:type_name -> neo.fs.v2.refs.Address + 57, // 89: neo.fs.v2.object.PatchRequest.Body.new_attributes:type_name -> neo.fs.v2.object.Header.Attribute + 40, // 90: neo.fs.v2.object.PatchRequest.Body.patch:type_name -> neo.fs.v2.object.PatchRequest.Body.Patch + 11, // 91: neo.fs.v2.object.PatchRequest.Body.Patch.source_range:type_name -> neo.fs.v2.object.Range + 51, // 92: neo.fs.v2.object.PatchResponse.Body.object_id:type_name -> neo.fs.v2.refs.ObjectID + 0, // 93: neo.fs.v2.object.ObjectService.Get:input_type -> neo.fs.v2.object.GetRequest + 2, // 94: neo.fs.v2.object.ObjectService.Put:input_type -> neo.fs.v2.object.PutRequest + 4, // 95: neo.fs.v2.object.ObjectService.Delete:input_type -> neo.fs.v2.object.DeleteRequest + 6, // 96: neo.fs.v2.object.ObjectService.Head:input_type -> neo.fs.v2.object.HeadRequest + 9, // 97: neo.fs.v2.object.ObjectService.Search:input_type -> neo.fs.v2.object.SearchRequest + 12, // 98: neo.fs.v2.object.ObjectService.GetRange:input_type -> neo.fs.v2.object.GetRangeRequest + 14, // 99: neo.fs.v2.object.ObjectService.GetRangeHash:input_type -> neo.fs.v2.object.GetRangeHashRequest + 16, // 100: neo.fs.v2.object.ObjectService.PutSingle:input_type -> neo.fs.v2.object.PutSingleRequest + 18, // 101: neo.fs.v2.object.ObjectService.Patch:input_type -> neo.fs.v2.object.PatchRequest + 1, // 102: neo.fs.v2.object.ObjectService.Get:output_type -> neo.fs.v2.object.GetResponse + 3, // 103: neo.fs.v2.object.ObjectService.Put:output_type -> neo.fs.v2.object.PutResponse + 5, // 104: neo.fs.v2.object.ObjectService.Delete:output_type -> neo.fs.v2.object.DeleteResponse + 8, // 105: neo.fs.v2.object.ObjectService.Head:output_type -> neo.fs.v2.object.HeadResponse + 10, // 106: neo.fs.v2.object.ObjectService.Search:output_type -> neo.fs.v2.object.SearchResponse + 13, // 107: neo.fs.v2.object.ObjectService.GetRange:output_type -> neo.fs.v2.object.GetRangeResponse + 15, // 108: neo.fs.v2.object.ObjectService.GetRangeHash:output_type -> neo.fs.v2.object.GetRangeHashResponse + 17, // 109: neo.fs.v2.object.ObjectService.PutSingle:output_type -> neo.fs.v2.object.PutSingleResponse + 19, // 110: neo.fs.v2.object.ObjectService.Patch:output_type -> neo.fs.v2.object.PatchResponse + 102, // [102:111] is the sub-list for method output_type + 93, // [93:102] is the sub-list for method input_type + 93, // [93:93] is the sub-list for extension type_name + 93, // [93:93] is the sub-list for extension extendee + 0, // [0:93] is the sub-list for field type_name } func init() { file_object_grpc_service_proto_init() } @@ -3507,7 +3914,7 @@ func file_object_grpc_service_proto_init() { } } file_object_grpc_service_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetRequest_Body); i { + switch v := v.(*PatchRequest); i { case 0: return &v.state case 1: @@ -3519,7 +3926,7 @@ func file_object_grpc_service_proto_init() { } } file_object_grpc_service_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetResponse_Body); i { + switch v := v.(*PatchResponse); i { case 0: return &v.state case 1: @@ -3531,7 +3938,7 @@ func file_object_grpc_service_proto_init() { } } file_object_grpc_service_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetResponse_Body_Init); i { + switch v := v.(*GetRequest_Body); i { case 0: return &v.state case 1: @@ -3543,7 +3950,7 @@ func file_object_grpc_service_proto_init() { } } file_object_grpc_service_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*PutRequest_Body); i { + switch v := v.(*GetResponse_Body); i { case 0: return &v.state case 1: @@ -3555,7 +3962,7 @@ func file_object_grpc_service_proto_init() { } } file_object_grpc_service_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*PutRequest_Body_Init); i { + switch v := v.(*GetResponse_Body_Init); i { case 0: return &v.state case 1: @@ -3567,7 +3974,7 @@ func file_object_grpc_service_proto_init() { } } file_object_grpc_service_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*PutResponse_Body); i { + switch v := v.(*PutRequest_Body); i { case 0: return &v.state case 1: @@ -3579,7 +3986,7 @@ func file_object_grpc_service_proto_init() { } } file_object_grpc_service_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DeleteRequest_Body); i { + switch v := v.(*PutRequest_Body_Init); i { case 0: return &v.state case 1: @@ -3591,7 +3998,7 @@ func file_object_grpc_service_proto_init() { } } file_object_grpc_service_proto_msgTypes[25].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DeleteResponse_Body); i { + switch v := v.(*PutResponse_Body); i { case 0: return &v.state case 1: @@ -3603,7 +4010,7 @@ func file_object_grpc_service_proto_init() { } } file_object_grpc_service_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*HeadRequest_Body); i { + switch v := v.(*DeleteRequest_Body); i { case 0: return &v.state case 1: @@ -3615,7 +4022,7 @@ func file_object_grpc_service_proto_init() { } } file_object_grpc_service_proto_msgTypes[27].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*HeadResponse_Body); i { + switch v := v.(*DeleteResponse_Body); i { case 0: return &v.state case 1: @@ -3627,7 +4034,7 @@ func file_object_grpc_service_proto_init() { } } file_object_grpc_service_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SearchRequest_Body); i { + switch v := v.(*HeadRequest_Body); i { case 0: return &v.state case 1: @@ -3639,7 +4046,7 @@ func file_object_grpc_service_proto_init() { } } file_object_grpc_service_proto_msgTypes[29].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SearchRequest_Body_Filter); i { + switch v := v.(*HeadResponse_Body); i { case 0: return &v.state case 1: @@ -3651,7 +4058,7 @@ func file_object_grpc_service_proto_init() { } } file_object_grpc_service_proto_msgTypes[30].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SearchResponse_Body); i { + switch v := v.(*SearchRequest_Body); i { case 0: return &v.state case 1: @@ -3663,7 +4070,7 @@ func file_object_grpc_service_proto_init() { } } file_object_grpc_service_proto_msgTypes[31].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetRangeRequest_Body); i { + switch v := v.(*SearchRequest_Body_Filter); i { case 0: return &v.state case 1: @@ -3675,7 +4082,7 @@ func file_object_grpc_service_proto_init() { } } file_object_grpc_service_proto_msgTypes[32].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetRangeResponse_Body); i { + switch v := v.(*SearchResponse_Body); i { case 0: return &v.state case 1: @@ -3687,7 +4094,7 @@ func file_object_grpc_service_proto_init() { } } file_object_grpc_service_proto_msgTypes[33].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetRangeHashRequest_Body); i { + switch v := v.(*GetRangeRequest_Body); i { case 0: return &v.state case 1: @@ -3699,7 +4106,7 @@ func file_object_grpc_service_proto_init() { } } file_object_grpc_service_proto_msgTypes[34].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetRangeHashResponse_Body); i { + switch v := v.(*GetRangeResponse_Body); i { case 0: return &v.state case 1: @@ -3711,7 +4118,7 @@ func file_object_grpc_service_proto_init() { } } file_object_grpc_service_proto_msgTypes[35].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*PutSingleRequest_Body); i { + switch v := v.(*GetRangeHashRequest_Body); i { case 0: return &v.state case 1: @@ -3723,6 +4130,30 @@ func file_object_grpc_service_proto_init() { } } file_object_grpc_service_proto_msgTypes[36].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GetRangeHashResponse_Body); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_object_grpc_service_proto_msgTypes[37].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*PutSingleRequest_Body); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_object_grpc_service_proto_msgTypes[38].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*PutSingleResponse_Body); i { case 0: return &v.state @@ -3734,24 +4165,60 @@ func file_object_grpc_service_proto_init() { return nil } } + file_object_grpc_service_proto_msgTypes[39].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*PatchRequest_Body); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_object_grpc_service_proto_msgTypes[40].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*PatchRequest_Body_Patch); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_object_grpc_service_proto_msgTypes[41].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*PatchResponse_Body); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } } - file_object_grpc_service_proto_msgTypes[19].OneofWrappers = []interface{}{ + file_object_grpc_service_proto_msgTypes[21].OneofWrappers = []interface{}{ (*GetResponse_Body_Init_)(nil), (*GetResponse_Body_Chunk)(nil), (*GetResponse_Body_SplitInfo)(nil), (*GetResponse_Body_EcInfo)(nil), } - file_object_grpc_service_proto_msgTypes[21].OneofWrappers = []interface{}{ + file_object_grpc_service_proto_msgTypes[23].OneofWrappers = []interface{}{ (*PutRequest_Body_Init_)(nil), (*PutRequest_Body_Chunk)(nil), } - file_object_grpc_service_proto_msgTypes[27].OneofWrappers = []interface{}{ + file_object_grpc_service_proto_msgTypes[29].OneofWrappers = []interface{}{ (*HeadResponse_Body_Header)(nil), (*HeadResponse_Body_ShortHeader)(nil), (*HeadResponse_Body_SplitInfo)(nil), (*HeadResponse_Body_EcInfo)(nil), } - file_object_grpc_service_proto_msgTypes[32].OneofWrappers = []interface{}{ + file_object_grpc_service_proto_msgTypes[34].OneofWrappers = []interface{}{ (*GetRangeResponse_Body_Chunk)(nil), (*GetRangeResponse_Body_SplitInfo)(nil), (*GetRangeResponse_Body_EcInfo)(nil), @@ -3762,7 +4229,7 @@ func file_object_grpc_service_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_object_grpc_service_proto_rawDesc, NumEnums: 0, - NumMessages: 37, + NumMessages: 42, NumExtensions: 0, NumServices: 1, }, diff --git a/object/grpc/service_grpc.pb.go b/object/grpc/service_grpc.pb.go index 11d132f..2494be9 100644 --- a/object/grpc/service_grpc.pb.go +++ b/object/grpc/service_grpc.pb.go @@ -27,6 +27,7 @@ const ( ObjectService_GetRange_FullMethodName = "/neo.fs.v2.object.ObjectService/GetRange" ObjectService_GetRangeHash_FullMethodName = "/neo.fs.v2.object.ObjectService/GetRangeHash" ObjectService_PutSingle_FullMethodName = "/neo.fs.v2.object.ObjectService/PutSingle" + ObjectService_Patch_FullMethodName = "/neo.fs.v2.object.ObjectService/Patch" ) // ObjectServiceClient is the client API for ObjectService service. @@ -299,6 +300,50 @@ type ObjectServiceClient interface { // - **TOKEN_EXPIRED** (4097, SECTION_SESSION): \ // provided session token has expired. PutSingle(ctx context.Context, in *PutSingleRequest, opts ...grpc.CallOption) (*PutSingleResponse, error) + // Patch the object. Request uses gRPC stream. First message must set + // the address of the object that is going to get patched. If the object's attributes + // are patched, then these attrubutes must be set only within the first stream message. + // + // If the patch request is performed by NOT the object's owner but if the actor has the permission + // to perform the patch, then `OwnerID` of the object is changed. In this case the object's owner + // loses the object's ownership after the patch request is successfully done. + // + // As objects are content-addressable the patching causes new object ID generation for the patched object. + // This object id is set witihn `PatchResponse`. But the object id may remain unchanged in such cases: + // 1. The chunk of the applying patch contains the same value as the object's payload within the same range; + // 2. The patch that reverts the changes applied by preceding patch; + // 3. The application of the same patches for the object a few times. + // + // Extended headers can change `Patch` behaviour: + // - [ __SYSTEM__NETMAP_EPOCH \ + // (`__NEOFS__NETMAP_EPOCH` is deprecated) \ + // Will use the requsted version of Network Map for object placement + // calculation. + // + // Please refer to detailed `XHeader` description. + // + // Statuses: + // - **OK** (0, SECTION_SUCCESS): \ + // object has been successfully patched and saved in the container; + // - Common failures (SECTION_FAILURE_COMMON); + // - **ACCESS_DENIED** (2048, SECTION_OBJECT): \ + // write access to the container is denied; + // - **OBJECT_NOT_FOUND** (2049, SECTION_OBJECT): \ + // object not found in container; + // - **OBJECT_ALREADY_REMOVED** (2052, SECTION_OBJECT): \ + // the requested object has been marked as deleted; + // - **OUT_OF_RANGE** (2053, SECTION_OBJECT): \ + // the requested range is out of bounds; + // - **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER): \ + // object storage container not found; + // - **CONTAINER_ACCESS_DENIED** (3074, SECTION_CONTAINER): \ + // access to container is denied; + // - **TOKEN_NOT_FOUND** (4096, SECTION_SESSION): \ + // (for trusted object preparation) session private key does not exist or + // has been deleted; + // - **TOKEN_EXPIRED** (4097, SECTION_SESSION): \ + // provided session token has expired. + Patch(ctx context.Context, opts ...grpc.CallOption) (ObjectService_PatchClient, error) } type objectServiceClient struct { @@ -475,6 +520,40 @@ func (c *objectServiceClient) PutSingle(ctx context.Context, in *PutSingleReques return out, nil } +func (c *objectServiceClient) Patch(ctx context.Context, opts ...grpc.CallOption) (ObjectService_PatchClient, error) { + stream, err := c.cc.NewStream(ctx, &ObjectService_ServiceDesc.Streams[4], ObjectService_Patch_FullMethodName, opts...) + if err != nil { + return nil, err + } + x := &objectServicePatchClient{stream} + return x, nil +} + +type ObjectService_PatchClient interface { + Send(*PatchRequest) error + CloseAndRecv() (*PatchResponse, error) + grpc.ClientStream +} + +type objectServicePatchClient struct { + grpc.ClientStream +} + +func (x *objectServicePatchClient) Send(m *PatchRequest) error { + return x.ClientStream.SendMsg(m) +} + +func (x *objectServicePatchClient) CloseAndRecv() (*PatchResponse, error) { + if err := x.ClientStream.CloseSend(); err != nil { + return nil, err + } + m := new(PatchResponse) + if err := x.ClientStream.RecvMsg(m); err != nil { + return nil, err + } + return m, nil +} + // ObjectServiceServer is the server API for ObjectService service. // All implementations should embed UnimplementedObjectServiceServer // for forward compatibility @@ -745,6 +824,50 @@ type ObjectServiceServer interface { // - **TOKEN_EXPIRED** (4097, SECTION_SESSION): \ // provided session token has expired. PutSingle(context.Context, *PutSingleRequest) (*PutSingleResponse, error) + // Patch the object. Request uses gRPC stream. First message must set + // the address of the object that is going to get patched. If the object's attributes + // are patched, then these attrubutes must be set only within the first stream message. + // + // If the patch request is performed by NOT the object's owner but if the actor has the permission + // to perform the patch, then `OwnerID` of the object is changed. In this case the object's owner + // loses the object's ownership after the patch request is successfully done. + // + // As objects are content-addressable the patching causes new object ID generation for the patched object. + // This object id is set witihn `PatchResponse`. But the object id may remain unchanged in such cases: + // 1. The chunk of the applying patch contains the same value as the object's payload within the same range; + // 2. The patch that reverts the changes applied by preceding patch; + // 3. The application of the same patches for the object a few times. + // + // Extended headers can change `Patch` behaviour: + // - [ __SYSTEM__NETMAP_EPOCH \ + // (`__NEOFS__NETMAP_EPOCH` is deprecated) \ + // Will use the requsted version of Network Map for object placement + // calculation. + // + // Please refer to detailed `XHeader` description. + // + // Statuses: + // - **OK** (0, SECTION_SUCCESS): \ + // object has been successfully patched and saved in the container; + // - Common failures (SECTION_FAILURE_COMMON); + // - **ACCESS_DENIED** (2048, SECTION_OBJECT): \ + // write access to the container is denied; + // - **OBJECT_NOT_FOUND** (2049, SECTION_OBJECT): \ + // object not found in container; + // - **OBJECT_ALREADY_REMOVED** (2052, SECTION_OBJECT): \ + // the requested object has been marked as deleted; + // - **OUT_OF_RANGE** (2053, SECTION_OBJECT): \ + // the requested range is out of bounds; + // - **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER): \ + // object storage container not found; + // - **CONTAINER_ACCESS_DENIED** (3074, SECTION_CONTAINER): \ + // access to container is denied; + // - **TOKEN_NOT_FOUND** (4096, SECTION_SESSION): \ + // (for trusted object preparation) session private key does not exist or + // has been deleted; + // - **TOKEN_EXPIRED** (4097, SECTION_SESSION): \ + // provided session token has expired. + Patch(ObjectService_PatchServer) error } // UnimplementedObjectServiceServer should be embedded to have forward compatible implementations. @@ -775,6 +898,9 @@ func (UnimplementedObjectServiceServer) GetRangeHash(context.Context, *GetRangeH func (UnimplementedObjectServiceServer) PutSingle(context.Context, *PutSingleRequest) (*PutSingleResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method PutSingle not implemented") } +func (UnimplementedObjectServiceServer) Patch(ObjectService_PatchServer) error { + return status.Errorf(codes.Unimplemented, "method Patch not implemented") +} // UnsafeObjectServiceServer may be embedded to opt out of forward compatibility for this service. // Use of this interface is not recommended, as added methods to ObjectServiceServer will @@ -948,6 +1074,32 @@ func _ObjectService_PutSingle_Handler(srv interface{}, ctx context.Context, dec return interceptor(ctx, in, info, handler) } +func _ObjectService_Patch_Handler(srv interface{}, stream grpc.ServerStream) error { + return srv.(ObjectServiceServer).Patch(&objectServicePatchServer{stream}) +} + +type ObjectService_PatchServer interface { + SendAndClose(*PatchResponse) error + Recv() (*PatchRequest, error) + grpc.ServerStream +} + +type objectServicePatchServer struct { + grpc.ServerStream +} + +func (x *objectServicePatchServer) SendAndClose(m *PatchResponse) error { + return x.ServerStream.SendMsg(m) +} + +func (x *objectServicePatchServer) Recv() (*PatchRequest, error) { + m := new(PatchRequest) + if err := x.ServerStream.RecvMsg(m); err != nil { + return nil, err + } + return m, nil +} + // ObjectService_ServiceDesc is the grpc.ServiceDesc for ObjectService service. // It's only intended for direct use with grpc.RegisterService, // and not to be introspected or modified (even as a copy) @@ -993,6 +1145,11 @@ var ObjectService_ServiceDesc = grpc.ServiceDesc{ Handler: _ObjectService_GetRange_Handler, ServerStreams: true, }, + { + StreamName: "Patch", + Handler: _ObjectService_Patch_Handler, + ClientStreams: true, + }, }, Metadata: "object/grpc/service.proto", } diff --git a/object/marshal.go b/object/marshal.go index f96b098..a0b82df 100644 --- a/object/marshal.go +++ b/object/marshal.go @@ -132,6 +132,16 @@ const ( putSingleReqObjectField = 1 putSingleReqCopiesNumberField = 2 + + patchRequestBodyPatchRangeField = 1 + patchRequestBodyPatchChunkField = 2 + + patchRequestBodyAddrField = 1 + patchRequestBodyNewAttrsField = 2 + patchRequestBodyReplaceAttrField = 3 + patchRequestBodyPatchField = 4 + + patchResponseBodyObjectIDField = 1 ) func (h *ShortHeader) StableMarshal(buf []byte) []byte { @@ -1314,3 +1324,105 @@ func (r *PutSingleResponseBody) StableSize() int { func (r *PutSingleResponseBody) Unmarshal(data []byte) error { return message.Unmarshal(r, data, new(object.PutSingleResponse_Body)) } + +func (r *PatchRequestBodyPatch) StableMarshal(buf []byte) []byte { + if r == nil { + return []byte{} + } + + if buf == nil { + buf = make([]byte, r.StableSize()) + } + + var offset int + offset += proto.NestedStructureMarshal(patchRequestBodyPatchRangeField, buf[offset:], r.Range) + offset += proto.BytesMarshal(patchRequestBodyPatchChunkField, buf[offset:], r.Chunk) + + return buf +} + +func (r *PatchRequestBodyPatch) StableSize() int { + if r == nil { + return 0 + } + + var size int + size += proto.NestedStructureSize(patchRequestBodyPatchRangeField, r.Range) + size += proto.BytesSize(patchRequestBodyPatchChunkField, r.Chunk) + + return size +} + +func (r *PatchRequestBodyPatch) Unmarshal(data []byte) error { + return message.Unmarshal(r, data, new(object.PatchRequest_Body_Patch)) +} + +func (r *PatchRequestBody) StableMarshal(buf []byte) []byte { + if r == nil { + return []byte{} + } + + if buf == nil { + buf = make([]byte, r.StableSize()) + } + + var offset int + offset += proto.NestedStructureMarshal(patchRequestBodyAddrField, buf[offset:], r.Address) + for i := range r.NewAttributes { + offset += proto.NestedStructureMarshal(patchRequestBodyNewAttrsField, buf[offset:], &r.NewAttributes[i]) + } + offset += proto.BoolMarshal(patchRequestBodyReplaceAttrField, buf[offset:], r.ReplaceAttributes) + offset += proto.NestedStructureMarshal(patchRequestBodyPatchField, buf[offset:], r.Patch) + + return buf +} + +func (r *PatchRequestBody) StableSize() int { + if r == nil { + return 0 + } + + var size int + size += proto.NestedStructureSize(patchRequestBodyAddrField, r.Address) + for i := range r.NewAttributes { + size += proto.NestedStructureSize(patchRequestBodyNewAttrsField, &r.NewAttributes[i]) + } + size += proto.BoolSize(patchRequestBodyReplaceAttrField, r.ReplaceAttributes) + size += proto.NestedStructureSize(patchRequestBodyPatchField, r.Patch) + + return size +} + +func (r *PatchRequestBody) Unmarshal(data []byte) error { + return message.Unmarshal(r, data, new(object.PatchRequest_Body)) +} + +func (r *PatchResponseBody) StableSize() int { + if r == nil { + return 0 + } + + var size int + size += proto.NestedStructureSize(patchResponseBodyObjectIDField, r.ObjectID) + + return size +} + +func (r *PatchResponseBody) StableMarshal(buf []byte) []byte { + if r == nil { + return []byte{} + } + + if buf == nil { + buf = make([]byte, r.StableSize()) + } + + var offset int + offset += proto.NestedStructureMarshal(patchResponseBodyObjectIDField, buf[offset:], r.ObjectID) + + return buf +} + +func (r *PatchResponseBody) Unmarshal(data []byte) error { + return message.Unmarshal(r, data, new(object.PatchResponse_Body)) +} diff --git a/object/message_test.go b/object/message_test.go index 749c373..d4e95b3 100644 --- a/object/message_test.go +++ b/object/message_test.go @@ -56,5 +56,10 @@ func TestMessageConvert(t *testing.T) { func(empty bool) message.Message { return objecttest.GenerateLock(empty) }, func(empty bool) message.Message { return objecttest.GeneratePutSingleRequest(empty) }, func(empty bool) message.Message { return objecttest.GeneratePutSingleResponse(empty) }, + func(empty bool) message.Message { return objecttest.GeneratePatchRequestBodyPatch(empty) }, + func(empty bool) message.Message { return objecttest.GeneratePatchRequestBody(empty) }, + func(empty bool) message.Message { return objecttest.GeneratePatchRequest(empty) }, + func(empty bool) message.Message { return objecttest.GeneratePatchResponseBody(empty) }, + func(empty bool) message.Message { return objecttest.GeneratePatchResponse(empty) }, ) } diff --git a/object/test/generate.go b/object/test/generate.go index b1931fc..f45941f 100644 --- a/object/test/generate.go +++ b/object/test/generate.go @@ -691,6 +691,63 @@ func GeneratePutSingleResponse(empty bool) *object.PutSingleResponse { return m } +func GeneratePatchRequestBodyPatch(empty bool) *object.PatchRequestBodyPatch { + m := new(object.PatchRequestBodyPatch) + + if !empty { + m.Range = GenerateRange(false) + m.Chunk = []byte("GeneratePatchRequestBodyPatch") + } + + return m +} + +func GeneratePatchRequestBody(empty bool) *object.PatchRequestBody { + m := new(object.PatchRequestBody) + + if !empty { + m.Address = refstest.GenerateAddress(empty) + m.NewAttributes = GenerateAttributes(empty) + m.ReplaceAttributes = false + m.Patch = GeneratePatchRequestBodyPatch(empty) + } + + return m +} + +func GeneratePatchRequest(empty bool) *object.PatchRequest { + m := new(object.PatchRequest) + + if !empty { + m.Body = GeneratePatchRequestBody(empty) + } + + m.SetMetaHeader(sessiontest.GenerateRequestMetaHeader(empty)) + m.SetVerificationHeader(sessiontest.GenerateRequestVerificationHeader(empty)) + + return m +} + +func GeneratePatchResponseBody(empty bool) *object.PatchResponseBody { + m := new(object.PatchResponseBody) + + if !empty { + m.ObjectID = refstest.GenerateObjectID(empty) + } + + return m +} + +func GeneratePatchResponse(empty bool) *object.PatchResponse { + m := new(object.PatchResponse) + + if !empty { + m.Body = GeneratePatchResponseBody(empty) + } + + return m +} + func randomInt(n int) int { return rand.New(rand.NewSource(time.Now().UnixNano())).Intn(n) } diff --git a/object/types.go b/object/types.go index 43caf80..d0cac37 100644 --- a/object/types.go +++ b/object/types.go @@ -349,6 +349,38 @@ type PutSingleResponse struct { session.ResponseHeaders } +type PatchRequestBodyPatch struct { + Range *Range + + Chunk []byte +} + +type PatchRequestBody struct { + Address *refs.Address + + NewAttributes []Attribute + + ReplaceAttributes bool + + Patch *PatchRequestBodyPatch +} + +type PatchRequest struct { + Body *PatchRequestBody + + session.RequestHeaders +} + +type PatchResponseBody struct { + ObjectID *refs.ObjectID +} + +type PatchResponse struct { + Body *PatchResponseBody + + session.ResponseHeaders +} + const ( TypeRegular Type = iota TypeTombstone diff --git a/util/proto/test/test.pb.go b/util/proto/test/test.pb.go index 57f7fb0..199fe2f 100644 --- a/util/proto/test/test.pb.go +++ b/util/proto/test/test.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.33.0 -// protoc v5.27.2 +// protoc v4.25.3 // source: util/proto/test/test.proto package test From 8580b49c8d65a78126444ef49df1bbb18a849a42 Mon Sep 17 00:00:00 2001 From: Airat Arifullin Date: Wed, 24 Jul 2024 17:45:30 +0300 Subject: [PATCH 07/19] [#94] rpc: Introduce `ObjectService.Patch` method Signed-off-by: Airat Arifullin --- object/marshal.go | 6 +++--- rpc/object.go | 36 ++++++++++++++++++++++++++++++++++++ 2 files changed, 39 insertions(+), 3 deletions(-) diff --git a/object/marshal.go b/object/marshal.go index a0b82df..00bafc9 100644 --- a/object/marshal.go +++ b/object/marshal.go @@ -1336,7 +1336,7 @@ func (r *PatchRequestBodyPatch) StableMarshal(buf []byte) []byte { var offset int offset += proto.NestedStructureMarshal(patchRequestBodyPatchRangeField, buf[offset:], r.Range) - offset += proto.BytesMarshal(patchRequestBodyPatchChunkField, buf[offset:], r.Chunk) + proto.BytesMarshal(patchRequestBodyPatchChunkField, buf[offset:], r.Chunk) return buf } @@ -1372,7 +1372,7 @@ func (r *PatchRequestBody) StableMarshal(buf []byte) []byte { offset += proto.NestedStructureMarshal(patchRequestBodyNewAttrsField, buf[offset:], &r.NewAttributes[i]) } offset += proto.BoolMarshal(patchRequestBodyReplaceAttrField, buf[offset:], r.ReplaceAttributes) - offset += proto.NestedStructureMarshal(patchRequestBodyPatchField, buf[offset:], r.Patch) + proto.NestedStructureMarshal(patchRequestBodyPatchField, buf[offset:], r.Patch) return buf } @@ -1418,7 +1418,7 @@ func (r *PatchResponseBody) StableMarshal(buf []byte) []byte { } var offset int - offset += proto.NestedStructureMarshal(patchResponseBodyObjectIDField, buf[offset:], r.ObjectID) + proto.NestedStructureMarshal(patchResponseBodyObjectIDField, buf[offset:], r.ObjectID) return buf } diff --git a/rpc/object.go b/rpc/object.go index 1eca922..6d7af31 100644 --- a/rpc/object.go +++ b/rpc/object.go @@ -18,6 +18,7 @@ const ( rpcObjectHead = "Head" rpcObjectDelete = "Delete" rpcObjectPutSingle = "PutSingle" + rpcObjectPatch = "Patch" ) // PutRequestWriter is an object.PutRequest @@ -205,3 +206,38 @@ func PutSingleObject( return resp, nil } + +// PatchRequestWriter is an object.PatchRequest +// message streaming component. +type PatchRequestWriter struct { + wc client.MessageWriterCloser + + resp message.Message +} + +// Write writes req to the stream. +func (w *PatchRequestWriter) Write(req *object.PatchRequest) error { + return w.wc.WriteMessage(req) +} + +// Close closes the stream. +func (w *PatchRequestWriter) Close() error { + return w.wc.Close() +} + +// Patch executes ObjectService.Patch RPC. +func Patch( + cli *client.Client, + resp *object.PatchResponse, + opts ...client.CallOption, +) (*PatchRequestWriter, error) { + wc, err := client.OpenClientStream(cli, common.CallMethodInfoClientStream(serviceObject, rpcObjectPatch), resp, opts...) + if err != nil { + return nil, err + } + + return &PatchRequestWriter{ + wc: wc, + resp: resp, + }, nil +} From 8ce8cd6ec272d947a29c8d180d8d6feabfb934ad Mon Sep 17 00:00:00 2001 From: Evgenii Stratonikov Date: Mon, 29 Jul 2024 15:40:43 +0300 Subject: [PATCH 08/19] [#96] .golangci.yml: Fix deprecated config options ``` WARN [config_reader] The configuration option `run.skip-files` is deprecated, please use `issues.exclude-files`. WARN [config_reader] The configuration option `output.format` is deprecated, please use `output.formats` ``` Signed-off-by: Evgenii Stratonikov --- .golangci.yml | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/.golangci.yml b/.golangci.yml index db94146..c6f4308 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -9,13 +9,11 @@ run: # include test files or not, default is true tests: false - skip-files: - - (^|.*/)grpc/(.*) - # output configuration options output: # colored-line-number|line-number|json|tab|checkstyle|code-climate, default is "colored-line-number" - format: tab + formats: + - format: tab # all available settings of specific linters linters-settings: @@ -67,6 +65,9 @@ linters: fast: false issues: + exclude-files: + - (^|.*/)grpc/(.*) + # Excluding configuration per-path, per-linter, per-text and per-source exclude-rules: - path: v2 # ignore stutters in universal structures due to protobuf compatibility From 8609f29a6019d2a09722b2bde69bcf30b772f426 Mon Sep 17 00:00:00 2001 From: Airat Arifullin Date: Tue, 30 Jul 2024 17:49:45 +0300 Subject: [PATCH 09/19] [#97] object: Refactor Patch related structs * Add getters and setters for related types; * Fix unit-tests. Signed-off-by: Airat Arifullin --- object/convert.go | 38 +++++++++---------- object/marshal.go | 20 +++++----- object/test/generate.go | 10 ++--- object/types.go | 82 ++++++++++++++++++++++++++++++++++++++--- 4 files changed, 111 insertions(+), 39 deletions(-) diff --git a/object/convert.go b/object/convert.go index 1abfb5e..5c9e20a 100644 --- a/object/convert.go +++ b/object/convert.go @@ -2392,10 +2392,10 @@ func (r *PatchRequestBody) ToGRPCMessage() grpc.Message { if r != nil { m = new(object.PatchRequest_Body) - m.SetAddress(r.Address.ToGRPCMessage().(*refsGRPC.Address)) - m.SetNewAttributes(AttributesToGRPC(r.NewAttributes)) - m.SetReplaceAttributes(r.ReplaceAttributes) - m.SetPatch(r.Patch.ToGRPCMessage().(*object.PatchRequest_Body_Patch)) + m.SetAddress(r.address.ToGRPCMessage().(*refsGRPC.Address)) + m.SetNewAttributes(AttributesToGRPC(r.newAttributes)) + m.SetReplaceAttributes(r.replaceAttributes) + m.SetPatch(r.patch.ToGRPCMessage().(*object.PatchRequest_Body_Patch)) } return m @@ -2411,34 +2411,34 @@ func (r *PatchRequestBody) FromGRPCMessage(m grpc.Message) error { addr := v.GetAddress() if addr == nil { - r.Address = nil + r.address = nil } else { - if r.Address == nil { - r.Address = new(refs.Address) + if r.address == nil { + r.address = new(refs.Address) } - err = r.Address.FromGRPCMessage(addr) + err = r.address.FromGRPCMessage(addr) if err != nil { return err } } - r.NewAttributes, err = AttributesFromGRPC(v.GetNewAttributes()) + r.newAttributes, err = AttributesFromGRPC(v.GetNewAttributes()) if err != nil { return err } - r.ReplaceAttributes = v.GetReplaceAttributes() + r.replaceAttributes = v.GetReplaceAttributes() patch := v.GetPatch() if patch == nil { - r.Patch = nil + r.patch = nil } else { - if r.Patch == nil { - r.Patch = new(PatchRequestBodyPatch) + if r.patch == nil { + r.patch = new(PatchRequestBodyPatch) } - err = r.Patch.FromGRPCMessage(patch) + err = r.patch.FromGRPCMessage(patch) if err != nil { return err } @@ -2453,7 +2453,7 @@ func (r *PatchRequest) ToGRPCMessage() grpc.Message { if r != nil { m = new(object.PatchRequest) - m.SetBody(r.Body.ToGRPCMessage().(*object.PatchRequest_Body)) + m.SetBody(r.body.ToGRPCMessage().(*object.PatchRequest_Body)) r.RequestHeaders.ToMessage(m) } @@ -2470,13 +2470,13 @@ func (r *PatchRequest) FromGRPCMessage(m grpc.Message) error { body := v.GetBody() if body == nil { - r.Body = nil + r.body = nil } else { - if r.Body == nil { - r.Body = new(PatchRequestBody) + if r.body == nil { + r.body = new(PatchRequestBody) } - err = r.Body.FromGRPCMessage(body) + err = r.body.FromGRPCMessage(body) if err != nil { return err } diff --git a/object/marshal.go b/object/marshal.go index 00bafc9..f337502 100644 --- a/object/marshal.go +++ b/object/marshal.go @@ -1367,12 +1367,12 @@ func (r *PatchRequestBody) StableMarshal(buf []byte) []byte { } var offset int - offset += proto.NestedStructureMarshal(patchRequestBodyAddrField, buf[offset:], r.Address) - for i := range r.NewAttributes { - offset += proto.NestedStructureMarshal(patchRequestBodyNewAttrsField, buf[offset:], &r.NewAttributes[i]) + offset += proto.NestedStructureMarshal(patchRequestBodyAddrField, buf[offset:], r.address) + for i := range r.newAttributes { + offset += proto.NestedStructureMarshal(patchRequestBodyNewAttrsField, buf[offset:], &r.newAttributes[i]) } - offset += proto.BoolMarshal(patchRequestBodyReplaceAttrField, buf[offset:], r.ReplaceAttributes) - proto.NestedStructureMarshal(patchRequestBodyPatchField, buf[offset:], r.Patch) + offset += proto.BoolMarshal(patchRequestBodyReplaceAttrField, buf[offset:], r.replaceAttributes) + proto.NestedStructureMarshal(patchRequestBodyPatchField, buf[offset:], r.patch) return buf } @@ -1383,12 +1383,12 @@ func (r *PatchRequestBody) StableSize() int { } var size int - size += proto.NestedStructureSize(patchRequestBodyAddrField, r.Address) - for i := range r.NewAttributes { - size += proto.NestedStructureSize(patchRequestBodyNewAttrsField, &r.NewAttributes[i]) + size += proto.NestedStructureSize(patchRequestBodyAddrField, r.address) + for i := range r.newAttributes { + size += proto.NestedStructureSize(patchRequestBodyNewAttrsField, &r.newAttributes[i]) } - size += proto.BoolSize(patchRequestBodyReplaceAttrField, r.ReplaceAttributes) - size += proto.NestedStructureSize(patchRequestBodyPatchField, r.Patch) + size += proto.BoolSize(patchRequestBodyReplaceAttrField, r.replaceAttributes) + size += proto.NestedStructureSize(patchRequestBodyPatchField, r.patch) return size } diff --git a/object/test/generate.go b/object/test/generate.go index f45941f..87ad64e 100644 --- a/object/test/generate.go +++ b/object/test/generate.go @@ -706,10 +706,10 @@ func GeneratePatchRequestBody(empty bool) *object.PatchRequestBody { m := new(object.PatchRequestBody) if !empty { - m.Address = refstest.GenerateAddress(empty) - m.NewAttributes = GenerateAttributes(empty) - m.ReplaceAttributes = false - m.Patch = GeneratePatchRequestBodyPatch(empty) + m.SetAddress(refstest.GenerateAddress(empty)) + m.SetNewAttributes(GenerateAttributes(empty)) + m.SetReplaceAttributes(false) + m.SetPatch(GeneratePatchRequestBodyPatch(empty)) } return m @@ -719,7 +719,7 @@ func GeneratePatchRequest(empty bool) *object.PatchRequest { m := new(object.PatchRequest) if !empty { - m.Body = GeneratePatchRequestBody(empty) + m.SetBody(GeneratePatchRequestBody(empty)) } m.SetMetaHeader(sessiontest.GenerateRequestMetaHeader(empty)) diff --git a/object/types.go b/object/types.go index d0cac37..c1a8b87 100644 --- a/object/types.go +++ b/object/types.go @@ -356,17 +356,17 @@ type PatchRequestBodyPatch struct { } type PatchRequestBody struct { - Address *refs.Address + address *refs.Address - NewAttributes []Attribute + newAttributes []Attribute - ReplaceAttributes bool + replaceAttributes bool - Patch *PatchRequestBodyPatch + patch *PatchRequestBodyPatch } type PatchRequest struct { - Body *PatchRequestBody + body *PatchRequestBody session.RequestHeaders } @@ -1543,6 +1543,78 @@ func (r *PutSingleResponse) SetBody(v *PutSingleResponseBody) { r.body = v } +func (r *PatchRequest) GetBody() *PatchRequestBody { + if r != nil { + return r.body + } + + return nil +} + +func (r *PatchRequest) SetBody(v *PatchRequestBody) { + r.body = v +} + +func (r *PatchRequestBody) GetAddress() *refs.Address { + if r != nil { + return r.address + } + + return nil +} + +func (r *PatchRequestBody) SetAddress(addr *refs.Address) { + r.address = addr +} + +func (r *PatchRequestBody) GetNewAttributes() []Attribute { + if r != nil { + return r.newAttributes + } + + return nil +} + +func (r *PatchRequestBody) SetNewAttributes(attrs []Attribute) { + r.newAttributes = attrs +} + +func (r *PatchRequestBody) GetReplaceAttributes() bool { + if r != nil { + return r.replaceAttributes + } + + return false +} + +func (r *PatchRequestBody) SetReplaceAttributes(replace bool) { + r.replaceAttributes = replace +} + +func (r *PatchRequestBody) GetPatch() *PatchRequestBodyPatch { + if r != nil { + return r.patch + } + + return nil +} + +func (r *PatchRequestBody) SetPatch(patch *PatchRequestBodyPatch) { + r.patch = patch +} + +func (r *PatchResponse) GetBody() *PatchResponseBody { + if r != nil { + return r.Body + } + + return nil +} + +func (r *PatchResponse) SetBody(v *PatchResponseBody) { + r.Body = v +} + func (s *ECInfo) getObjectPart() {} func (s *ECInfo) getHeaderPart() {} From c27b978770a334a964ce682888b7d08dd2a4a627 Mon Sep 17 00:00:00 2001 From: Airat Arifullin Date: Tue, 30 Jul 2024 17:50:26 +0300 Subject: [PATCH 10/19] [#97] signature: Add Patch messages to `serviceMessageBody` Signed-off-by: Airat Arifullin --- signature/body.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/signature/body.go b/signature/body.go index 53b5d6b..4b43b84 100644 --- a/signature/body.go +++ b/signature/body.go @@ -84,6 +84,10 @@ func serviceMessageBody(req any) stableMarshaler { return v.GetBody() case *object.PutSingleResponse: return v.GetBody() + case *object.PatchRequest: + return v.GetBody() + case *object.PatchResponse: + return v.GetBody() /* Netmap */ case *netmap.LocalNodeInfoRequest: From 1473fa588f8a0bab0806c2fae380ee2512174652 Mon Sep 17 00:00:00 2001 From: Evgenii Stratonikov Date: Wed, 31 Jul 2024 15:34:44 +0300 Subject: [PATCH 11/19] [#98] rpc: Accept interface in place of ClientConn gRPC client load-balancing API is ugly as f: 1. It is configured by pre-registering a balancer and the providing JSON configuration. 2. It doesn't allow different credentials for different endpoints (consider using "insecure" localhost and external endpoint). 3. To support frostfs usecase we also need to implement a resolver, which has its own difficulties. 4. https://github.com/grpc/grpc-go/issues/239#issuecomment-264548415 Using interface in place of grpc.ClientConn allows us to provide custom implentation for it (load-balancing, circuit breaker etc.). Refs TrueCloudLab/frostfs-node#1268 Signed-off-by: Evgenii Stratonikov --- rpc/client/conn.go | 8 ++++++++ rpc/client/options.go | 4 ++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/rpc/client/conn.go b/rpc/client/conn.go index 9fc7a51..f208413 100644 --- a/rpc/client/conn.go +++ b/rpc/client/conn.go @@ -2,8 +2,16 @@ package client import ( "io" + + "google.golang.org/grpc" ) +// Conn is an interface for grpc client connection. +type Conn interface { + grpc.ClientConnInterface + io.Closer +} + // Conn returns underlying connection. // // Returns non-nil result after the first Init() call diff --git a/rpc/client/options.go b/rpc/client/options.go index 0575dfc..22358a3 100644 --- a/rpc/client/options.go +++ b/rpc/client/options.go @@ -25,7 +25,7 @@ type cfg struct { tlsCfg *tls.Config grpcDialOpts []grpc.DialOption - conn *grpc.ClientConn + conn Conn } const ( @@ -114,7 +114,7 @@ func WithTLSCfg(v *tls.Config) Option { // WithGRPCConn returns option to specify // gRPC virtual connection. -func WithGRPCConn(v *grpc.ClientConn) Option { +func WithGRPCConn(v Conn) Option { return func(c *cfg) { if v != nil { c.conn = v From ebaf78c8faab21031b50ba546d25052b84d7d482 Mon Sep 17 00:00:00 2001 From: Airat Arifullin Date: Mon, 5 Aug 2024 20:52:47 +0300 Subject: [PATCH 12/19] [#100] session: Introduce `ObjectPatch` verb Signed-off-by: Airat Arifullin --- session/convert.go | 4 + session/grpc/types.pb.go | 289 ++++++++++++++++++++------------------- session/types.go | 1 + 3 files changed, 152 insertions(+), 142 deletions(-) diff --git a/session/convert.go b/session/convert.go index bbfe070..4197935 100644 --- a/session/convert.go +++ b/session/convert.go @@ -641,6 +641,8 @@ func ObjectSessionVerbToGRPCField(v ObjectSessionVerb) session.ObjectSessionCont return session.ObjectSessionContext_RANGE case ObjectVerbRangeHash: return session.ObjectSessionContext_RANGEHASH + case ObjectVerbPatch: + return session.ObjectSessionContext_PATCH default: return session.ObjectSessionContext_VERB_UNSPECIFIED } @@ -662,6 +664,8 @@ func ObjectSessionVerbFromGRPCField(v session.ObjectSessionContext_Verb) ObjectS return ObjectVerbRange case session.ObjectSessionContext_RANGEHASH: return ObjectVerbRangeHash + case session.ObjectSessionContext_PATCH: + return ObjectVerbPatch default: return ObjectVerbUnknown } diff --git a/session/grpc/types.pb.go b/session/grpc/types.pb.go index 924df45..9f51743 100644 --- a/session/grpc/types.pb.go +++ b/session/grpc/types.pb.go @@ -43,6 +43,8 @@ const ( ObjectSessionContext_RANGE ObjectSessionContext_Verb = 6 // Refers to object.GetRangeHash RPC call ObjectSessionContext_RANGEHASH ObjectSessionContext_Verb = 7 + // Refers to object.Patch RPC call + ObjectSessionContext_PATCH ObjectSessionContext_Verb = 8 ) // Enum value maps for ObjectSessionContext_Verb. @@ -56,6 +58,7 @@ var ( 5: "DELETE", 6: "RANGE", 7: "RANGEHASH", + 8: "PATCH", } ObjectSessionContext_Verb_value = map[string]int32{ "VERB_UNSPECIFIED": 0, @@ -66,6 +69,7 @@ var ( "DELETE": 5, "RANGE": 6, "RANGEHASH": 7, + "PATCH": 8, } ) @@ -1040,7 +1044,7 @@ var file_session_grpc_types_proto_rawDesc = []byte{ 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x61, 0x63, 0x6c, 0x2f, 0x67, 0x72, 0x70, 0x63, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x17, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x2f, 0x67, 0x72, 0x70, 0x63, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x22, 0x85, 0x03, 0x0a, 0x14, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x53, 0x65, + 0x6f, 0x74, 0x6f, 0x22, 0x90, 0x03, 0x0a, 0x14, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x12, 0x40, 0x0a, 0x04, 0x76, 0x65, 0x72, 0x62, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x2c, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x4f, @@ -1058,154 +1062,155 @@ var file_session_grpc_types_proto_rawDesc = []byte{ 0x62, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, 0x65, 0x66, 0x73, 0x2e, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x49, 0x44, 0x52, 0x07, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x22, - 0x6a, 0x0a, 0x04, 0x56, 0x65, 0x72, 0x62, 0x12, 0x14, 0x0a, 0x10, 0x56, 0x45, 0x52, 0x42, 0x5f, + 0x75, 0x0a, 0x04, 0x56, 0x65, 0x72, 0x62, 0x12, 0x14, 0x0a, 0x10, 0x56, 0x45, 0x52, 0x42, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x07, 0x0a, 0x03, 0x50, 0x55, 0x54, 0x10, 0x01, 0x12, 0x07, 0x0a, 0x03, 0x47, 0x45, 0x54, 0x10, 0x02, 0x12, 0x08, 0x0a, 0x04, 0x48, 0x45, 0x41, 0x44, 0x10, 0x03, 0x12, 0x0a, 0x0a, 0x06, 0x53, 0x45, 0x41, 0x52, 0x43, 0x48, 0x10, 0x04, 0x12, 0x0a, 0x0a, 0x06, 0x44, 0x45, 0x4c, 0x45, 0x54, 0x45, 0x10, 0x05, 0x12, 0x09, 0x0a, 0x05, 0x52, 0x41, 0x4e, 0x47, 0x45, 0x10, 0x06, 0x12, 0x0d, 0x0a, 0x09, - 0x52, 0x41, 0x4e, 0x47, 0x45, 0x48, 0x41, 0x53, 0x48, 0x10, 0x07, 0x22, 0xfa, 0x01, 0x0a, 0x17, - 0x43, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, - 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x12, 0x43, 0x0a, 0x04, 0x76, 0x65, 0x72, 0x62, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x2f, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, - 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x61, 0x69, - 0x6e, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, - 0x74, 0x2e, 0x56, 0x65, 0x72, 0x62, 0x52, 0x04, 0x76, 0x65, 0x72, 0x62, 0x12, 0x1a, 0x0a, 0x08, - 0x77, 0x69, 0x6c, 0x64, 0x63, 0x61, 0x72, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x08, - 0x77, 0x69, 0x6c, 0x64, 0x63, 0x61, 0x72, 0x64, 0x12, 0x3e, 0x0a, 0x0c, 0x63, 0x6f, 0x6e, 0x74, - 0x61, 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, - 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, 0x65, 0x66, 0x73, 0x2e, - 0x43, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x52, 0x0b, 0x63, 0x6f, 0x6e, - 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x22, 0x3e, 0x0a, 0x04, 0x56, 0x65, 0x72, 0x62, - 0x12, 0x14, 0x0a, 0x10, 0x56, 0x45, 0x52, 0x42, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, - 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x07, 0x0a, 0x03, 0x50, 0x55, 0x54, 0x10, 0x01, 0x12, - 0x0a, 0x0a, 0x06, 0x44, 0x45, 0x4c, 0x45, 0x54, 0x45, 0x10, 0x02, 0x12, 0x0b, 0x0a, 0x07, 0x53, - 0x45, 0x54, 0x45, 0x41, 0x43, 0x4c, 0x10, 0x03, 0x22, 0xa0, 0x04, 0x0a, 0x0c, 0x53, 0x65, 0x73, - 0x73, 0x69, 0x6f, 0x6e, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x38, 0x0a, 0x04, 0x62, 0x6f, 0x64, - 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, - 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x53, 0x65, 0x73, 0x73, - 0x69, 0x6f, 0x6e, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x2e, 0x42, 0x6f, 0x64, 0x79, 0x52, 0x04, 0x62, - 0x6f, 0x64, 0x79, 0x12, 0x37, 0x0a, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, - 0x76, 0x32, 0x2e, 0x72, 0x65, 0x66, 0x73, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, - 0x65, 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x1a, 0x9c, 0x03, 0x0a, - 0x04, 0x42, 0x6f, 0x64, 0x79, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x0c, 0x52, 0x02, 0x69, 0x64, 0x12, 0x32, 0x0a, 0x08, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x5f, 0x69, - 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, - 0x2e, 0x76, 0x32, 0x2e, 0x72, 0x65, 0x66, 0x73, 0x2e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, - 0x52, 0x07, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x12, 0x4e, 0x0a, 0x08, 0x6c, 0x69, 0x66, - 0x65, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x32, 0x2e, 0x6e, 0x65, - 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, - 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x2e, 0x42, 0x6f, 0x64, - 0x79, 0x2e, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x4c, 0x69, 0x66, 0x65, 0x74, 0x69, 0x6d, 0x65, 0x52, - 0x08, 0x6c, 0x69, 0x66, 0x65, 0x74, 0x69, 0x6d, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x73, 0x65, 0x73, - 0x73, 0x69, 0x6f, 0x6e, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, - 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x4b, 0x65, 0x79, 0x12, 0x41, 0x0a, 0x06, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x6e, 0x65, 0x6f, - 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x4f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x43, 0x6f, 0x6e, 0x74, - 0x65, 0x78, 0x74, 0x48, 0x00, 0x52, 0x06, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x4a, 0x0a, - 0x09, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x2a, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, + 0x52, 0x41, 0x4e, 0x47, 0x45, 0x48, 0x41, 0x53, 0x48, 0x10, 0x07, 0x12, 0x09, 0x0a, 0x05, 0x50, + 0x41, 0x54, 0x43, 0x48, 0x10, 0x08, 0x22, 0xfa, 0x01, 0x0a, 0x17, 0x43, 0x6f, 0x6e, 0x74, 0x61, + 0x69, 0x6e, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x43, 0x6f, 0x6e, 0x74, 0x65, + 0x78, 0x74, 0x12, 0x43, 0x0a, 0x04, 0x76, 0x65, 0x72, 0x62, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, + 0x32, 0x2f, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x53, 0x65, - 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x48, 0x00, 0x52, 0x09, - 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x1a, 0x45, 0x0a, 0x0d, 0x54, 0x6f, 0x6b, - 0x65, 0x6e, 0x4c, 0x69, 0x66, 0x65, 0x74, 0x69, 0x6d, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x65, 0x78, - 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x03, 0x65, 0x78, 0x70, 0x12, 0x10, 0x0a, 0x03, - 0x6e, 0x62, 0x66, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x03, 0x6e, 0x62, 0x66, 0x12, 0x10, - 0x0a, 0x03, 0x69, 0x61, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x52, 0x03, 0x69, 0x61, 0x74, - 0x42, 0x09, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x22, 0x31, 0x0a, 0x07, 0x58, - 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, - 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x8d, - 0x03, 0x0a, 0x11, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x48, 0x65, - 0x61, 0x64, 0x65, 0x72, 0x12, 0x31, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, - 0x32, 0x2e, 0x72, 0x65, 0x66, 0x73, 0x2e, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x07, - 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x70, 0x6f, 0x63, 0x68, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x65, 0x70, 0x6f, 0x63, 0x68, 0x12, 0x10, 0x0a, - 0x03, 0x74, 0x74, 0x6c, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x03, 0x74, 0x74, 0x6c, 0x12, - 0x37, 0x0a, 0x09, 0x78, 0x5f, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x73, 0x18, 0x04, 0x20, 0x03, - 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, - 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x58, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x08, - 0x78, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x73, 0x12, 0x44, 0x0a, 0x0d, 0x73, 0x65, 0x73, 0x73, - 0x69, 0x6f, 0x6e, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x1f, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, - 0x69, 0x6f, 0x6e, 0x2e, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x54, 0x6f, 0x6b, 0x65, 0x6e, - 0x52, 0x0c, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x3d, - 0x0a, 0x0c, 0x62, 0x65, 0x61, 0x72, 0x65, 0x72, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x06, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, - 0x2e, 0x61, 0x63, 0x6c, 0x2e, 0x42, 0x65, 0x61, 0x72, 0x65, 0x72, 0x54, 0x6f, 0x6b, 0x65, 0x6e, - 0x52, 0x0b, 0x62, 0x65, 0x61, 0x72, 0x65, 0x72, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x3c, 0x0a, - 0x06, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, - 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, - 0x6e, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x48, 0x65, 0x61, - 0x64, 0x65, 0x72, 0x52, 0x06, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x12, 0x21, 0x0a, 0x0c, 0x6d, - 0x61, 0x67, 0x69, 0x63, 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x08, 0x20, 0x01, 0x28, - 0x04, 0x52, 0x0b, 0x6d, 0x61, 0x67, 0x69, 0x63, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x22, 0x99, - 0x02, 0x0a, 0x12, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x48, - 0x65, 0x61, 0x64, 0x65, 0x72, 0x12, 0x31, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, - 0x76, 0x32, 0x2e, 0x72, 0x65, 0x66, 0x73, 0x2e, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x52, - 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x70, 0x6f, 0x63, - 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x65, 0x70, 0x6f, 0x63, 0x68, 0x12, 0x10, - 0x0a, 0x03, 0x74, 0x74, 0x6c, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x03, 0x74, 0x74, 0x6c, - 0x12, 0x37, 0x0a, 0x09, 0x78, 0x5f, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x73, 0x18, 0x04, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, - 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x58, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, - 0x08, 0x78, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x73, 0x12, 0x3d, 0x0a, 0x06, 0x6f, 0x72, 0x69, - 0x67, 0x69, 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, - 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, - 0x52, 0x06, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x12, 0x30, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, - 0x75, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, - 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x2e, 0x53, 0x74, 0x61, 0x74, - 0x75, 0x73, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x22, 0xab, 0x02, 0x0a, 0x19, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x56, 0x65, 0x72, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x12, 0x40, 0x0a, 0x0e, 0x62, 0x6f, 0x64, 0x79, - 0x5f, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x19, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, 0x65, 0x66, - 0x73, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x0d, 0x62, 0x6f, 0x64, - 0x79, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x40, 0x0a, 0x0e, 0x6d, 0x65, - 0x74, 0x61, 0x5f, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, - 0x65, 0x66, 0x73, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x0d, 0x6d, - 0x65, 0x74, 0x61, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x44, 0x0a, 0x10, - 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x5f, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, - 0x76, 0x32, 0x2e, 0x72, 0x65, 0x66, 0x73, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, - 0x65, 0x52, 0x0f, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, - 0x72, 0x65, 0x12, 0x44, 0x0a, 0x06, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x18, 0x04, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x2c, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, - 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x56, 0x65, - 0x72, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, - 0x52, 0x06, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x22, 0xad, 0x02, 0x0a, 0x1a, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x56, 0x65, 0x72, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x12, 0x40, 0x0a, 0x0e, 0x62, 0x6f, 0x64, 0x79, 0x5f, - 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x19, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, 0x65, 0x66, 0x73, - 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x0d, 0x62, 0x6f, 0x64, 0x79, - 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x40, 0x0a, 0x0e, 0x6d, 0x65, 0x74, - 0x61, 0x5f, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x2e, 0x56, 0x65, 0x72, + 0x62, 0x52, 0x04, 0x76, 0x65, 0x72, 0x62, 0x12, 0x1a, 0x0a, 0x08, 0x77, 0x69, 0x6c, 0x64, 0x63, + 0x61, 0x72, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x08, 0x77, 0x69, 0x6c, 0x64, 0x63, + 0x61, 0x72, 0x64, 0x12, 0x3e, 0x0a, 0x0c, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, + 0x5f, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, + 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, 0x65, 0x66, 0x73, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x61, + 0x69, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, + 0x72, 0x49, 0x44, 0x22, 0x3e, 0x0a, 0x04, 0x56, 0x65, 0x72, 0x62, 0x12, 0x14, 0x0a, 0x10, 0x56, + 0x45, 0x52, 0x42, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, + 0x00, 0x12, 0x07, 0x0a, 0x03, 0x50, 0x55, 0x54, 0x10, 0x01, 0x12, 0x0a, 0x0a, 0x06, 0x44, 0x45, + 0x4c, 0x45, 0x54, 0x45, 0x10, 0x02, 0x12, 0x0b, 0x0a, 0x07, 0x53, 0x45, 0x54, 0x45, 0x41, 0x43, + 0x4c, 0x10, 0x03, 0x22, 0xa0, 0x04, 0x0a, 0x0c, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x54, + 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x38, 0x0a, 0x04, 0x62, 0x6f, 0x64, 0x79, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, + 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x54, 0x6f, + 0x6b, 0x65, 0x6e, 0x2e, 0x42, 0x6f, 0x64, 0x79, 0x52, 0x04, 0x62, 0x6f, 0x64, 0x79, 0x12, 0x37, + 0x0a, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, 0x65, - 0x66, 0x73, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x0d, 0x6d, 0x65, - 0x74, 0x61, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x44, 0x0a, 0x10, 0x6f, - 0x72, 0x69, 0x67, 0x69, 0x6e, 0x5f, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, - 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, - 0x32, 0x2e, 0x72, 0x65, 0x66, 0x73, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, - 0x52, 0x0f, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, - 0x65, 0x12, 0x45, 0x0a, 0x06, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x2d, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, - 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x56, 0x65, - 0x72, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, - 0x52, 0x06, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x42, 0x64, 0x5a, 0x44, 0x67, 0x69, 0x74, 0x2e, - 0x66, 0x72, 0x6f, 0x73, 0x74, 0x66, 0x73, 0x2e, 0x69, 0x6e, 0x66, 0x6f, 0x2f, 0x54, 0x72, 0x75, - 0x65, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x4c, 0x61, 0x62, 0x2f, 0x66, 0x72, 0x6f, 0x73, 0x74, 0x66, - 0x73, 0x2d, 0x61, 0x70, 0x69, 0x2d, 0x67, 0x6f, 0x2f, 0x76, 0x32, 0x2f, 0x73, 0x65, 0x73, 0x73, - 0x69, 0x6f, 0x6e, 0x2f, 0x67, 0x72, 0x70, 0x63, 0x3b, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, - 0xaa, 0x02, 0x1b, 0x4e, 0x65, 0x6f, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x6f, 0x72, 0x61, - 0x67, 0x65, 0x2e, 0x41, 0x50, 0x49, 0x2e, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x62, 0x06, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x66, 0x73, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x09, 0x73, 0x69, + 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x1a, 0x9c, 0x03, 0x0a, 0x04, 0x42, 0x6f, 0x64, 0x79, + 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x02, 0x69, 0x64, + 0x12, 0x32, 0x0a, 0x08, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, + 0x65, 0x66, 0x73, 0x2e, 0x4f, 0x77, 0x6e, 0x65, 0x72, 0x49, 0x44, 0x52, 0x07, 0x6f, 0x77, 0x6e, + 0x65, 0x72, 0x49, 0x44, 0x12, 0x4e, 0x0a, 0x08, 0x6c, 0x69, 0x66, 0x65, 0x74, 0x69, 0x6d, 0x65, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x32, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, + 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x53, 0x65, 0x73, 0x73, 0x69, + 0x6f, 0x6e, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x2e, 0x42, 0x6f, 0x64, 0x79, 0x2e, 0x54, 0x6f, 0x6b, + 0x65, 0x6e, 0x4c, 0x69, 0x66, 0x65, 0x74, 0x69, 0x6d, 0x65, 0x52, 0x08, 0x6c, 0x69, 0x66, 0x65, + 0x74, 0x69, 0x6d, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x5f, + 0x6b, 0x65, 0x79, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x73, 0x65, 0x73, 0x73, 0x69, + 0x6f, 0x6e, 0x4b, 0x65, 0x79, 0x12, 0x41, 0x0a, 0x06, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x18, + 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, + 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, + 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x48, 0x00, + 0x52, 0x06, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x4a, 0x0a, 0x09, 0x63, 0x6f, 0x6e, 0x74, + 0x61, 0x69, 0x6e, 0x65, 0x72, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2a, 0x2e, 0x6e, 0x65, + 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, + 0x43, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, + 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x48, 0x00, 0x52, 0x09, 0x63, 0x6f, 0x6e, 0x74, 0x61, + 0x69, 0x6e, 0x65, 0x72, 0x1a, 0x45, 0x0a, 0x0d, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x4c, 0x69, 0x66, + 0x65, 0x74, 0x69, 0x6d, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x65, 0x78, 0x70, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x04, 0x52, 0x03, 0x65, 0x78, 0x70, 0x12, 0x10, 0x0a, 0x03, 0x6e, 0x62, 0x66, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x04, 0x52, 0x03, 0x6e, 0x62, 0x66, 0x12, 0x10, 0x0a, 0x03, 0x69, 0x61, 0x74, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x52, 0x03, 0x69, 0x61, 0x74, 0x42, 0x09, 0x0a, 0x07, 0x63, + 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x22, 0x31, 0x0a, 0x07, 0x58, 0x48, 0x65, 0x61, 0x64, 0x65, + 0x72, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, + 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x8d, 0x03, 0x0a, 0x11, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x12, + 0x31, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x17, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, 0x65, 0x66, + 0x73, 0x2e, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, + 0x6f, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x70, 0x6f, 0x63, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x04, 0x52, 0x05, 0x65, 0x70, 0x6f, 0x63, 0x68, 0x12, 0x10, 0x0a, 0x03, 0x74, 0x74, 0x6c, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x03, 0x74, 0x74, 0x6c, 0x12, 0x37, 0x0a, 0x09, 0x78, 0x5f, + 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, + 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, + 0x6e, 0x2e, 0x58, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x08, 0x78, 0x48, 0x65, 0x61, 0x64, + 0x65, 0x72, 0x73, 0x12, 0x44, 0x0a, 0x0d, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x5f, 0x74, + 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x6e, 0x65, 0x6f, + 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x53, + 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x0c, 0x73, 0x65, 0x73, + 0x73, 0x69, 0x6f, 0x6e, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x3d, 0x0a, 0x0c, 0x62, 0x65, 0x61, + 0x72, 0x65, 0x72, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x1a, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x61, 0x63, 0x6c, 0x2e, + 0x42, 0x65, 0x61, 0x72, 0x65, 0x72, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x52, 0x0b, 0x62, 0x65, 0x61, + 0x72, 0x65, 0x72, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x3c, 0x0a, 0x06, 0x6f, 0x72, 0x69, 0x67, + 0x69, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, + 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x06, + 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x12, 0x21, 0x0a, 0x0c, 0x6d, 0x61, 0x67, 0x69, 0x63, 0x5f, + 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x08, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0b, 0x6d, 0x61, + 0x67, 0x69, 0x63, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x22, 0x99, 0x02, 0x0a, 0x12, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, + 0x12, 0x31, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x17, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, 0x65, + 0x66, 0x73, 0x2e, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x07, 0x76, 0x65, 0x72, 0x73, + 0x69, 0x6f, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x70, 0x6f, 0x63, 0x68, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x04, 0x52, 0x05, 0x65, 0x70, 0x6f, 0x63, 0x68, 0x12, 0x10, 0x0a, 0x03, 0x74, 0x74, 0x6c, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x03, 0x74, 0x74, 0x6c, 0x12, 0x37, 0x0a, 0x09, 0x78, + 0x5f, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, + 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, + 0x6f, 0x6e, 0x2e, 0x58, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x08, 0x78, 0x48, 0x65, 0x61, + 0x64, 0x65, 0x72, 0x73, 0x12, 0x3d, 0x0a, 0x06, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x18, 0x05, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, + 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x4d, 0x65, 0x74, 0x61, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x06, 0x6f, 0x72, 0x69, + 0x67, 0x69, 0x6e, 0x12, 0x30, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x06, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, + 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x06, 0x73, + 0x74, 0x61, 0x74, 0x75, 0x73, 0x22, 0xab, 0x02, 0x0a, 0x19, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x56, 0x65, 0x72, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x48, 0x65, 0x61, + 0x64, 0x65, 0x72, 0x12, 0x40, 0x0a, 0x0e, 0x62, 0x6f, 0x64, 0x79, 0x5f, 0x73, 0x69, 0x67, 0x6e, + 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x6e, 0x65, + 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, 0x65, 0x66, 0x73, 0x2e, 0x53, 0x69, 0x67, + 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x0d, 0x62, 0x6f, 0x64, 0x79, 0x53, 0x69, 0x67, 0x6e, + 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x40, 0x0a, 0x0e, 0x6d, 0x65, 0x74, 0x61, 0x5f, 0x73, 0x69, + 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, + 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, 0x65, 0x66, 0x73, 0x2e, 0x53, + 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x0d, 0x6d, 0x65, 0x74, 0x61, 0x53, 0x69, + 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x44, 0x0a, 0x10, 0x6f, 0x72, 0x69, 0x67, 0x69, + 0x6e, 0x5f, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x19, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, 0x65, + 0x66, 0x73, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x0f, 0x6f, 0x72, + 0x69, 0x67, 0x69, 0x6e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x44, 0x0a, + 0x06, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2c, 0x2e, + 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, + 0x6e, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x56, 0x65, 0x72, 0x69, 0x66, 0x69, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x06, 0x6f, 0x72, 0x69, + 0x67, 0x69, 0x6e, 0x22, 0xad, 0x02, 0x0a, 0x1a, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x56, 0x65, 0x72, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x48, 0x65, 0x61, 0x64, + 0x65, 0x72, 0x12, 0x40, 0x0a, 0x0e, 0x62, 0x6f, 0x64, 0x79, 0x5f, 0x73, 0x69, 0x67, 0x6e, 0x61, + 0x74, 0x75, 0x72, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x6e, 0x65, 0x6f, + 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, 0x65, 0x66, 0x73, 0x2e, 0x53, 0x69, 0x67, 0x6e, + 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x0d, 0x62, 0x6f, 0x64, 0x79, 0x53, 0x69, 0x67, 0x6e, 0x61, + 0x74, 0x75, 0x72, 0x65, 0x12, 0x40, 0x0a, 0x0e, 0x6d, 0x65, 0x74, 0x61, 0x5f, 0x73, 0x69, 0x67, + 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x6e, + 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, 0x65, 0x66, 0x73, 0x2e, 0x53, 0x69, + 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x0d, 0x6d, 0x65, 0x74, 0x61, 0x53, 0x69, 0x67, + 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x44, 0x0a, 0x10, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, + 0x5f, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x19, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x72, 0x65, 0x66, + 0x73, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x0f, 0x6f, 0x72, 0x69, + 0x67, 0x69, 0x6e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x45, 0x0a, 0x06, + 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2d, 0x2e, 0x6e, + 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, + 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x56, 0x65, 0x72, 0x69, 0x66, 0x69, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x06, 0x6f, 0x72, 0x69, + 0x67, 0x69, 0x6e, 0x42, 0x64, 0x5a, 0x44, 0x67, 0x69, 0x74, 0x2e, 0x66, 0x72, 0x6f, 0x73, 0x74, + 0x66, 0x73, 0x2e, 0x69, 0x6e, 0x66, 0x6f, 0x2f, 0x54, 0x72, 0x75, 0x65, 0x43, 0x6c, 0x6f, 0x75, + 0x64, 0x4c, 0x61, 0x62, 0x2f, 0x66, 0x72, 0x6f, 0x73, 0x74, 0x66, 0x73, 0x2d, 0x61, 0x70, 0x69, + 0x2d, 0x67, 0x6f, 0x2f, 0x76, 0x32, 0x2f, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2f, 0x67, + 0x72, 0x70, 0x63, 0x3b, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0xaa, 0x02, 0x1b, 0x4e, 0x65, + 0x6f, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x2e, 0x41, 0x50, + 0x49, 0x2e, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x33, } var ( diff --git a/session/types.go b/session/types.go index 5732b29..d2df9c5 100644 --- a/session/types.go +++ b/session/types.go @@ -175,6 +175,7 @@ const ( ObjectVerbDelete ObjectVerbRange ObjectVerbRangeHash + ObjectVerbPatch ) func (c *CreateRequestBody) GetOwnerID() *refs.OwnerID { From 611355510cfafeba0d604be2022b75b74cc9661e Mon Sep 17 00:00:00 2001 From: Anton Nikiforov Date: Mon, 24 Jun 2024 11:22:49 +0300 Subject: [PATCH 13/19] [#87] go.mod: Update `google.golang.org/grpc` to `v1.63.2` Signed-off-by: Anton Nikiforov --- go.mod | 13 ++++++------- go.sum | 33 +++++++++++++-------------------- 2 files changed, 19 insertions(+), 27 deletions(-) diff --git a/go.mod b/go.mod index 0315850..e00f012 100644 --- a/go.mod +++ b/go.mod @@ -5,22 +5,21 @@ go 1.20 require ( git.frostfs.info/TrueCloudLab/frostfs-crypto v0.6.0 github.com/stretchr/testify v1.8.3 - golang.org/x/sync v0.2.0 - google.golang.org/grpc v1.55.0 + golang.org/x/sync v0.6.0 + google.golang.org/grpc v1.63.2 google.golang.org/protobuf v1.33.0 ) require ( git.frostfs.info/TrueCloudLab/rfc6979 v0.4.0 // indirect github.com/davecgh/go-spew v1.1.1 // indirect - github.com/golang/protobuf v1.5.3 // indirect github.com/kr/pretty v0.1.0 // indirect github.com/mr-tron/base58 v1.2.0 // indirect github.com/pmezard/go-difflib v1.0.0 // indirect - golang.org/x/net v0.10.0 // indirect - golang.org/x/sys v0.8.0 // indirect - golang.org/x/text v0.9.0 // indirect - google.golang.org/genproto v0.0.0-20230410155749-daa745c078e1 // indirect + golang.org/x/net v0.21.0 // indirect + golang.org/x/sys v0.17.0 // indirect + golang.org/x/text v0.14.0 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240227224415-6ceb2ff114de // indirect gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect ) diff --git a/go.sum b/go.sum index 56fc5d0..6ce46f7 100644 --- a/go.sum +++ b/go.sum @@ -5,11 +5,7 @@ git.frostfs.info/TrueCloudLab/rfc6979 v0.4.0/go.mod h1:okpbKfVYf/BpejtfFTfhZqFP+ github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= -github.com/golang/protobuf v1.5.3 h1:KhyjKVUg7Usr/dYsdSqoFveMYd5ko72D+zANwlG1mmg= -github.com/golang/protobuf v1.5.3/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= -github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= +github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/kr/pretty v0.1.0 h1:L/CwN0zerZDmRFUapSPitk6f+Q3+0za1rQkzVuMiMFI= github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= @@ -23,21 +19,18 @@ github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+ github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.8.3 h1:RP3t2pwF7cMEbC1dqtB6poj3niw/9gnV4Cjg5oW5gtY= github.com/stretchr/testify v1.8.3/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= -golang.org/x/net v0.10.0 h1:X2//UzNDwYmtCLn7To6G58Wr6f5ahEAQgKNzv9Y951M= -golang.org/x/net v0.10.0/go.mod h1:0qNGK6F8kojg2nk9dLZ2mShWaEBan6FAoqfSigmmuDg= -golang.org/x/sync v0.2.0 h1:PUR+T4wwASmuSTYdKjYHI5TD22Wy5ogLU5qZCOLxBrI= -golang.org/x/sync v0.2.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sys v0.8.0 h1:EBmGv8NaZBZTWvrbjNoL6HVt+IVy3QDQpJs7VRIw3tU= -golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/text v0.9.0 h1:2sjJmO8cDvYveuX97RDLsxlyUxLl+GHoLxBiRdHllBE= -golang.org/x/text v0.9.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8= -golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -google.golang.org/genproto v0.0.0-20230410155749-daa745c078e1 h1:KpwkzHKEF7B9Zxg18WzOa7djJ+Ha5DzthMyZYQfEn2A= -google.golang.org/genproto v0.0.0-20230410155749-daa745c078e1/go.mod h1:nKE/iIaLqn2bQwXBg8f1g2Ylh6r5MN5CmZvuzZCgsCU= -google.golang.org/grpc v1.55.0 h1:3Oj82/tFSCeUrRTg/5E/7d/W5A1tj6Ky1ABAuZuv5ag= -google.golang.org/grpc v1.55.0/go.mod h1:iYEXKGkEBhg1PjZQvoYEVPTDkHo1/bjTnfwTeGONTY8= -google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= -google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= +golang.org/x/net v0.21.0 h1:AQyQV4dYCvJ7vGmJyKki9+PBdyvhkSd8EIx/qb0AYv4= +golang.org/x/net v0.21.0/go.mod h1:bIjVDfnllIU7BJ2DNgfnXvpSvtn8VRwhlsaeUTyUS44= +golang.org/x/sync v0.6.0 h1:5BMeUDZ7vkXGfEr1x9B4bRcTH4lpkTkpdh0T/J+qjbQ= +golang.org/x/sync v0.6.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= +golang.org/x/sys v0.17.0 h1:25cE3gD+tdBA7lp7QfhuV+rJiE9YXTcS3VG1SqssI/Y= +golang.org/x/sys v0.17.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/text v0.14.0 h1:ScX5w1eTa3QqT8oi6+ziP7dTV1S2+ALU0bI+0zXKWiQ= +golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240227224415-6ceb2ff114de h1:cZGRis4/ot9uVm639a+rHCUaG0JJHEsdyzSQTMX+suY= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240227224415-6ceb2ff114de/go.mod h1:H4O17MA/PE9BsGx3w+a+W2VOLLD1Qf7oJneAoU6WktY= +google.golang.org/grpc v1.63.2 h1:MUeiw1B2maTVZthpU5xvASfTh3LDbxHd6IJ6QQVU+xM= +google.golang.org/grpc v1.63.2/go.mod h1:WAX/8DgncnokcFUldAxq7GeB5DXHDbMF+lLvDomNkRA= google.golang.org/protobuf v1.33.0 h1:uNO2rsAINq/JlFpSdYEKIZ0uKD/R9cpdv0T+yoGwGmI= google.golang.org/protobuf v1.33.0/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= From 42e50c963327afecad227f90a1fff787340121af Mon Sep 17 00:00:00 2001 From: Anton Nikiforov Date: Mon, 24 Jun 2024 12:58:37 +0300 Subject: [PATCH 14/19] [#87] Makefile: Add target `protoc-install` Signed-off-by: Anton Nikiforov --- Makefile | 34 +++++++++++++++++++++++++++++----- 1 file changed, 29 insertions(+), 5 deletions(-) diff --git a/Makefile b/Makefile index 239565b..7789692 100755 --- a/Makefile +++ b/Makefile @@ -2,6 +2,17 @@ SHELL = bash VERSION ?= $(shell git describe --tags --match "v*" --abbrev=8 --dirty --always) +PROTOC_VERSION ?= 27.2 +PROTOC_GEN_GO_VERSION ?= $(shell go list -f '{{.Version}}' -m google.golang.org/protobuf) +PROTOC_OS_VERSION=osx-x86_64 +ifeq ($(shell uname), Linux) + PROTOC_OS_VERSION=linux-x86_64 +endif + +BIN = bin +PROTOBUF_DIR ?= $(abspath $(BIN))/protobuf +PROTOC_DIR ?= $(PROTOBUF_DIR)/protoc-v$(PROTOC_VERSION) +PROTOC_GEN_GO_DIR ?= $(PROTOBUF_DIR)/protoc-gen-go-$(PROTOC_GEN_GO_VERSION) .PHONY: dep fmts fumpt imports protoc test lint version help @@ -32,16 +43,29 @@ fumpt: @echo "⇒ Processing gofumpt check" @gofumpt -l -w . +# Install protoc +protoc-install: + @rm -rf $(PROTOBUF_DIR) + @mkdir -p $(PROTOBUF_DIR) + @echo "⇒ Installing protoc... " + @wget -q -O $(PROTOBUF_DIR)/protoc-$(PROTOC_VERSION).zip 'https://github.com/protocolbuffers/protobuf/releases/download/v$(PROTOC_VERSION)/protoc-$(PROTOC_VERSION)-$(PROTOC_OS_VERSION).zip' + @unzip -q -o $(PROTOBUF_DIR)/protoc-$(PROTOC_VERSION).zip -d $(PROTOC_DIR) + @rm $(PROTOBUF_DIR)/protoc-$(PROTOC_VERSION).zip + @echo "⇒ Installing protoc-gen-go..." + @GOBIN=$(PROTOC_GEN_GO_DIR) go install -v google.golang.org/protobuf/...@$(PROTOC_GEN_GO_VERSION) + + # Regenerate code for proto files protoc: - @GOPRIVATE=github.com/TrueCloudLab go mod vendor - # Install specific version for protobuf lib - @go list -f '{{.Path}}/...@{{.Version}}' -m google.golang.org/protobuf | xargs go install -v + @if [ ! -d "$(PROTOC_DIR)" ] || [ ! -d "$(PROTOC_GEN_GO_DIR)" ]; then \ + make protoc-install; \ + fi # Protoc generate - @for f in `find . -type f -name '*.proto' -not -path './vendor/*'`; do \ + @for f in `find . -type f -name '*.proto'`; do \ echo "⇒ Processing $$f "; \ - protoc \ + $(PROTOC_DIR)/bin/protoc \ --proto_path=.:./vendor:/usr/local/include \ + --plugin=protoc-gen-go=$(PROTOC_GEN_GO_DIR)/protoc-gen-go \ --go_out=. --go_opt=paths=source_relative \ --go-grpc_opt=require_unimplemented_servers=false \ --go-grpc_out=. --go-grpc_opt=paths=source_relative $$f; \ From b72aa14bab97f3fd6c12705391b70d0ea03e84b6 Mon Sep 17 00:00:00 2001 From: Anton Nikiforov Date: Mon, 24 Jun 2024 13:50:21 +0300 Subject: [PATCH 15/19] [#87] proto: Process files with `protoc` version `27.2` Signed-off-by: Anton Nikiforov --- util/proto/test/test.pb.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/util/proto/test/test.pb.go b/util/proto/test/test.pb.go index 199fe2f..57f7fb0 100644 --- a/util/proto/test/test.pb.go +++ b/util/proto/test/test.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.33.0 -// protoc v4.25.3 +// protoc v5.27.2 // source: util/proto/test/test.proto package test From 174773454ec41756199666be94b6886bc075cbad Mon Sep 17 00:00:00 2001 From: Anton Nikiforov Date: Mon, 24 Jun 2024 13:53:27 +0300 Subject: [PATCH 16/19] [#87] netmap: Regenerate to add `LIKE` operation for `filter` Signed-off-by: Anton Nikiforov --- netmap/grpc/types.pb.go | 49 +++++++++++++++++++++++------------------ 1 file changed, 27 insertions(+), 22 deletions(-) diff --git a/netmap/grpc/types.pb.go b/netmap/grpc/types.pb.go index 8924213..ae1f55f 100644 --- a/netmap/grpc/types.pb.go +++ b/netmap/grpc/types.pb.go @@ -44,21 +44,24 @@ const ( Operation_AND Operation = 8 // Logical negation Operation_NOT Operation = 9 + // Matches pattern + Operation_LIKE Operation = 10 ) // Enum value maps for Operation. var ( Operation_name = map[int32]string{ - 0: "OPERATION_UNSPECIFIED", - 1: "EQ", - 2: "NE", - 3: "GT", - 4: "GE", - 5: "LT", - 6: "LE", - 7: "OR", - 8: "AND", - 9: "NOT", + 0: "OPERATION_UNSPECIFIED", + 1: "EQ", + 2: "NE", + 3: "GT", + 4: "GE", + 5: "LT", + 6: "LE", + 7: "OR", + 8: "AND", + 9: "NOT", + 10: "LIKE", } Operation_value = map[string]int32{ "OPERATION_UNSPECIFIED": 0, @@ -71,6 +74,7 @@ var ( "OR": 7, "AND": 8, "NOT": 9, + "LIKE": 10, } ) @@ -1149,24 +1153,25 @@ var file_netmap_grpc_types_proto_rawDesc = []byte{ 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x6e, 0x65, 0x6f, 0x2e, 0x66, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x2e, 0x4e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x0d, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, - 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x2a, 0x70, 0x0a, 0x09, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, + 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x2a, 0x7a, 0x0a, 0x09, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x19, 0x0a, 0x15, 0x4f, 0x50, 0x45, 0x52, 0x41, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x06, 0x0a, 0x02, 0x45, 0x51, 0x10, 0x01, 0x12, 0x06, 0x0a, 0x02, 0x4e, 0x45, 0x10, 0x02, 0x12, 0x06, 0x0a, 0x02, 0x47, 0x54, 0x10, 0x03, 0x12, 0x06, 0x0a, 0x02, 0x47, 0x45, 0x10, 0x04, 0x12, 0x06, 0x0a, 0x02, 0x4c, 0x54, 0x10, 0x05, 0x12, 0x06, 0x0a, 0x02, 0x4c, 0x45, 0x10, 0x06, 0x12, 0x06, 0x0a, 0x02, 0x4f, 0x52, 0x10, 0x07, 0x12, 0x07, 0x0a, 0x03, 0x41, 0x4e, 0x44, 0x10, 0x08, 0x12, - 0x07, 0x0a, 0x03, 0x4e, 0x4f, 0x54, 0x10, 0x09, 0x2a, 0x38, 0x0a, 0x06, 0x43, 0x6c, 0x61, 0x75, - 0x73, 0x65, 0x12, 0x16, 0x0a, 0x12, 0x43, 0x4c, 0x41, 0x55, 0x53, 0x45, 0x5f, 0x55, 0x4e, 0x53, - 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x08, 0x0a, 0x04, 0x53, 0x41, - 0x4d, 0x45, 0x10, 0x01, 0x12, 0x0c, 0x0a, 0x08, 0x44, 0x49, 0x53, 0x54, 0x49, 0x4e, 0x43, 0x54, - 0x10, 0x02, 0x42, 0x61, 0x5a, 0x42, 0x67, 0x69, 0x74, 0x2e, 0x66, 0x72, 0x6f, 0x73, 0x74, 0x66, - 0x73, 0x2e, 0x69, 0x6e, 0x66, 0x6f, 0x2f, 0x54, 0x72, 0x75, 0x65, 0x43, 0x6c, 0x6f, 0x75, 0x64, - 0x4c, 0x61, 0x62, 0x2f, 0x66, 0x72, 0x6f, 0x73, 0x74, 0x66, 0x73, 0x2d, 0x61, 0x70, 0x69, 0x2d, - 0x67, 0x6f, 0x2f, 0x76, 0x32, 0x2f, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x2f, 0x67, 0x72, 0x70, - 0x63, 0x3b, 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0xaa, 0x02, 0x1a, 0x4e, 0x65, 0x6f, 0x2e, 0x46, - 0x69, 0x6c, 0x65, 0x53, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x2e, 0x41, 0x50, 0x49, 0x2e, 0x4e, - 0x65, 0x74, 0x6d, 0x61, 0x70, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x07, 0x0a, 0x03, 0x4e, 0x4f, 0x54, 0x10, 0x09, 0x12, 0x08, 0x0a, 0x04, 0x4c, 0x49, 0x4b, 0x45, + 0x10, 0x0a, 0x2a, 0x38, 0x0a, 0x06, 0x43, 0x6c, 0x61, 0x75, 0x73, 0x65, 0x12, 0x16, 0x0a, 0x12, + 0x43, 0x4c, 0x41, 0x55, 0x53, 0x45, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, + 0x45, 0x44, 0x10, 0x00, 0x12, 0x08, 0x0a, 0x04, 0x53, 0x41, 0x4d, 0x45, 0x10, 0x01, 0x12, 0x0c, + 0x0a, 0x08, 0x44, 0x49, 0x53, 0x54, 0x49, 0x4e, 0x43, 0x54, 0x10, 0x02, 0x42, 0x61, 0x5a, 0x42, + 0x67, 0x69, 0x74, 0x2e, 0x66, 0x72, 0x6f, 0x73, 0x74, 0x66, 0x73, 0x2e, 0x69, 0x6e, 0x66, 0x6f, + 0x2f, 0x54, 0x72, 0x75, 0x65, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x4c, 0x61, 0x62, 0x2f, 0x66, 0x72, + 0x6f, 0x73, 0x74, 0x66, 0x73, 0x2d, 0x61, 0x70, 0x69, 0x2d, 0x67, 0x6f, 0x2f, 0x76, 0x32, 0x2f, + 0x6e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x2f, 0x67, 0x72, 0x70, 0x63, 0x3b, 0x6e, 0x65, 0x74, 0x6d, + 0x61, 0x70, 0xaa, 0x02, 0x1a, 0x4e, 0x65, 0x6f, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x53, 0x74, 0x6f, + 0x72, 0x61, 0x67, 0x65, 0x2e, 0x41, 0x50, 0x49, 0x2e, 0x4e, 0x65, 0x74, 0x6d, 0x61, 0x70, 0x62, + 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( From 35e7397d48d77423a7c53662b3446a3fd1a2e348 Mon Sep 17 00:00:00 2001 From: Anton Nikiforov Date: Mon, 24 Jun 2024 13:55:23 +0300 Subject: [PATCH 17/19] [#87] netmap: Extend enum `Operation` Signed-off-by: Anton Nikiforov --- netmap/types.go | 1 + 1 file changed, 1 insertion(+) diff --git a/netmap/types.go b/netmap/types.go index dd5db68..1fcdc6e 100644 --- a/netmap/types.go +++ b/netmap/types.go @@ -111,6 +111,7 @@ const ( OR AND NOT + LIKE ) const ( From 280d052cefa0bb00134fff80fb1c6aed31e7e934 Mon Sep 17 00:00:00 2001 From: Anton Nikiforov Date: Thu, 8 Aug 2024 17:31:58 +0300 Subject: [PATCH 18/19] [#101] Remove usage of folder `vendor` Signed-off-by: Anton Nikiforov --- .gitignore | 1 - Makefile | 5 ++--- prepare.sh | 4 ++-- 3 files changed, 4 insertions(+), 6 deletions(-) diff --git a/.gitignore b/.gitignore index 354a562..30476bd 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,3 @@ .idea bin temp -/vendor/ diff --git a/Makefile b/Makefile index 7789692..30d599d 100755 --- a/Makefile +++ b/Makefile @@ -34,7 +34,7 @@ fmts: fumpt imports # Reformat imports imports: @echo "⇒ Processing goimports check" - @for f in `find . -type f -name '*.go' -not -path './vendor/*' -not -name '*.pb.go' -prune`; do \ + @for f in `find . -type f -name '*.go' -not -name '*.pb.go' -prune`; do \ goimports -w $$f; \ done @@ -64,13 +64,12 @@ protoc: @for f in `find . -type f -name '*.proto'`; do \ echo "⇒ Processing $$f "; \ $(PROTOC_DIR)/bin/protoc \ - --proto_path=.:./vendor:/usr/local/include \ + --proto_path=.:/usr/local/include \ --plugin=protoc-gen-go=$(PROTOC_GEN_GO_DIR)/protoc-gen-go \ --go_out=. --go_opt=paths=source_relative \ --go-grpc_opt=require_unimplemented_servers=false \ --go-grpc_out=. --go-grpc_opt=paths=source_relative $$f; \ done - rm -rf vendor # Run Unit Test with go test test: GOFLAGS ?= "-count=1" diff --git a/prepare.sh b/prepare.sh index 32048b3..4b8b125 100755 --- a/prepare.sh +++ b/prepare.sh @@ -10,7 +10,7 @@ API_PATH=$1 # MOVE FILES FROM API REPO cd "$API_PATH" || exit 1 -ARGS=$(find ./ -name '*.proto' -not -path './vendor/*') +ARGS=$(find ./ -name '*.proto') for file in $ARGS; do dir=$(dirname "$file") mkdir -p "$API_GO_PATH/$dir/grpc" @@ -30,7 +30,7 @@ cd "$API_GO_PATH" || exit 1 make protoc # REMOVE PROTO DEFINITIONS -ARGS=$(find ./$prefix -name '*.proto' -not -path './vendor/*' -not -path './util/*') +ARGS=$(find ./$prefix -name '*.proto' -not -path './util/*') for file in $ARGS; do rm "$file" done From a0a9b765f3a56423b1c6f1fef1d1b413da0e03ef Mon Sep 17 00:00:00 2001 From: Anton Nikiforov Date: Thu, 8 Aug 2024 18:02:30 +0300 Subject: [PATCH 19/19] [#101] Fix `make test` Signed-off-by: Anton Nikiforov --- Makefile | 4 ++-- prepare.sh | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Makefile b/Makefile index 30d599d..db1cc2d 100755 --- a/Makefile +++ b/Makefile @@ -61,10 +61,10 @@ protoc: make protoc-install; \ fi # Protoc generate - @for f in `find . -type f -name '*.proto'`; do \ + @for f in `find . -type f -name '*.proto' -not -path './bin/*'`; do \ echo "⇒ Processing $$f "; \ $(PROTOC_DIR)/bin/protoc \ - --proto_path=.:/usr/local/include \ + --proto_path=.:$(PROTOC_DIR)/include:/usr/local/include \ --plugin=protoc-gen-go=$(PROTOC_GEN_GO_DIR)/protoc-gen-go \ --go_out=. --go_opt=paths=source_relative \ --go-grpc_opt=require_unimplemented_servers=false \ diff --git a/prepare.sh b/prepare.sh index 4b8b125..1d00954 100755 --- a/prepare.sh +++ b/prepare.sh @@ -10,7 +10,7 @@ API_PATH=$1 # MOVE FILES FROM API REPO cd "$API_PATH" || exit 1 -ARGS=$(find ./ -name '*.proto') +ARGS=$(find ./ -name '*.proto' -not -path './bin/*') for file in $ARGS; do dir=$(dirname "$file") mkdir -p "$API_GO_PATH/$dir/grpc" @@ -19,7 +19,7 @@ done # MODIFY FILES cd "$API_GO_PATH" || exit 1 -ARGS2=$(find ./ -name '*.proto') +ARGS2=$(find ./ -name '*.proto' -not -path './bin/*') for file in $ARGS2; do echo "$file" sed -i "s/import\ \"\(.*\)\/\(.*\)\.proto\";/import\ \"\1\/grpc\/\2\.proto\";/" $file @@ -30,7 +30,7 @@ cd "$API_GO_PATH" || exit 1 make protoc # REMOVE PROTO DEFINITIONS -ARGS=$(find ./$prefix -name '*.proto' -not -path './util/*') +ARGS=$(find ./$prefix -name '*.proto' -not -path './util/*' -not -path './bin/*') for file in $ARGS; do rm "$file" done