From 2d068cb76d1bb27321e8d2536ed90a52ef262deb Mon Sep 17 00:00:00 2001 From: Daniil Forshev Date: Fri, 24 Jul 2026 13:49:29 +0500 Subject: [PATCH] feat(async search): add export async search docs method --- api/seqproxyapi/v1/seq_proxy_api.proto | 14 + asyncsearcher/metrics.go | 23 + pkg/seqproxyapi/v1/seq_proxy_api.pb.go | 450 ++++++++++------- pkg/seqproxyapi/v1/seq_proxy_api.pb.gw.go | 46 ++ .../v1/seq_proxy_api_vtproto.pb.go | 475 ++++++++++++++++++ pkg/storeapi/store_api.pb.go | 2 +- proxyapi/grpc_async_search.go | 57 +++ proxyapi/grpc_async_search_test.go | 249 +++++++++ proxyapi/grpc_v1.go | 4 + proxyapi/mock/grpc_v1.go | 119 +++++ 10 files changed, 1252 insertions(+), 187 deletions(-) create mode 100644 proxyapi/grpc_async_search_test.go diff --git a/api/seqproxyapi/v1/seq_proxy_api.proto b/api/seqproxyapi/v1/seq_proxy_api.proto index 934de8589..c261ea360 100644 --- a/api/seqproxyapi/v1/seq_proxy_api.proto +++ b/api/seqproxyapi/v1/seq_proxy_api.proto @@ -112,6 +112,14 @@ service SeqProxyApi { body: "*" }; } + + // Stream documents for given async search ID. + rpc ExportAsyncSearch(ExportAsyncSearchRequest) returns (stream ExportResponse) { + option (google.api.http) = { + post: "/async-searches/export" + body: "*" + }; + } } // Custom error code, returned by seq-db proxy. @@ -419,6 +427,12 @@ message ExportRequest { int64 offset = 3; // Search offset. } +message ExportAsyncSearchRequest { + string search_id = 1; + int64 size = 2; + int64 offset = 3; +} + message ExportResponse { Document doc = 1; // Response document. } diff --git a/asyncsearcher/metrics.go b/asyncsearcher/metrics.go index d1b122f3b..ae6e2e75a 100644 --- a/asyncsearcher/metrics.go +++ b/asyncsearcher/metrics.go @@ -3,6 +3,8 @@ package asyncsearcher import ( "github.com/prometheus/client_golang/prometheus" "github.com/prometheus/client_golang/prometheus/promauto" + + "github.com/ozontech/seq-db/metric" ) var ( @@ -48,4 +50,25 @@ var ( Name: "panics_total", Help: "Number of panics in async search", }) + + ExportDuration = promauto.NewHistogramVec(prometheus.HistogramOpts{ + Namespace: "seq_db_ingestor", + Subsystem: "async_search", + Name: "export_duration_seconds", + Help: "Time taken to export data by protocol in seconds", + Buckets: metric.SecondsBucketsDoublePrecision, + }, []string{"protocol"}) + ExportSize = promauto.NewHistogramVec(prometheus.HistogramOpts{ + Namespace: "seq_db_ingestor", + Subsystem: "async_search", + Name: "export_size_bytes", + Help: "Size of exported data by protocol in bytes", + Buckets: prometheus.ExponentialBuckets(10, 3, 20), + }, []string{"protocol"}) + CurrentExportersCount = promauto.NewGaugeVec(prometheus.GaugeOpts{ + Namespace: "seq_db_ingestor", + Subsystem: "async_search", + Name: "export_current_exporters_in_progress", + Help: "Current number of active exporters in progress by protocol", + }, []string{"protocol"}) ) diff --git a/pkg/seqproxyapi/v1/seq_proxy_api.pb.go b/pkg/seqproxyapi/v1/seq_proxy_api.pb.go index 9eb79211a..f96268ecd 100644 --- a/pkg/seqproxyapi/v1/seq_proxy_api.pb.go +++ b/pkg/seqproxyapi/v1/seq_proxy_api.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.36.5 -// protoc v7.35.0 +// protoc v5.29.3 // source: seqproxyapi/v1/seq_proxy_api.proto package seqproxyapi @@ -2417,6 +2417,66 @@ func (x *ExportRequest) GetOffset() int64 { return 0 } +type ExportAsyncSearchRequest struct { + state protoimpl.MessageState `protogen:"open.v1"` + SearchId string `protobuf:"bytes,1,opt,name=search_id,json=searchId,proto3" json:"search_id,omitempty"` + Size int64 `protobuf:"varint,2,opt,name=size,proto3" json:"size,omitempty"` + Offset int64 `protobuf:"varint,3,opt,name=offset,proto3" json:"offset,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *ExportAsyncSearchRequest) Reset() { + *x = ExportAsyncSearchRequest{} + mi := &file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[35] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *ExportAsyncSearchRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ExportAsyncSearchRequest) ProtoMessage() {} + +func (x *ExportAsyncSearchRequest) ProtoReflect() protoreflect.Message { + mi := &file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[35] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ExportAsyncSearchRequest.ProtoReflect.Descriptor instead. +func (*ExportAsyncSearchRequest) Descriptor() ([]byte, []int) { + return file_seqproxyapi_v1_seq_proxy_api_proto_rawDescGZIP(), []int{35} +} + +func (x *ExportAsyncSearchRequest) GetSearchId() string { + if x != nil { + return x.SearchId + } + return "" +} + +func (x *ExportAsyncSearchRequest) GetSize() int64 { + if x != nil { + return x.Size + } + return 0 +} + +func (x *ExportAsyncSearchRequest) GetOffset() int64 { + if x != nil { + return x.Offset + } + return 0 +} + type ExportResponse struct { state protoimpl.MessageState `protogen:"open.v1"` Doc *Document `protobuf:"bytes,1,opt,name=doc,proto3" json:"doc,omitempty"` // Response document. @@ -2426,7 +2486,7 @@ type ExportResponse struct { func (x *ExportResponse) Reset() { *x = ExportResponse{} - mi := &file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[35] + mi := &file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[36] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2438,7 +2498,7 @@ func (x *ExportResponse) String() string { func (*ExportResponse) ProtoMessage() {} func (x *ExportResponse) ProtoReflect() protoreflect.Message { - mi := &file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[35] + mi := &file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[36] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2451,7 +2511,7 @@ func (x *ExportResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ExportResponse.ProtoReflect.Descriptor instead. func (*ExportResponse) Descriptor() ([]byte, []int) { - return file_seqproxyapi_v1_seq_proxy_api_proto_rawDescGZIP(), []int{35} + return file_seqproxyapi_v1_seq_proxy_api_proto_rawDescGZIP(), []int{36} } func (x *ExportResponse) GetDoc() *Document { @@ -2475,7 +2535,7 @@ type Aggregation_Bucket struct { func (x *Aggregation_Bucket) Reset() { *x = Aggregation_Bucket{} - mi := &file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[36] + mi := &file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[37] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2487,7 +2547,7 @@ func (x *Aggregation_Bucket) String() string { func (*Aggregation_Bucket) ProtoMessage() {} func (x *Aggregation_Bucket) ProtoReflect() protoreflect.Message { - mi := &file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[36] + mi := &file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[37] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2549,7 +2609,7 @@ type Histogram_Bucket struct { func (x *Histogram_Bucket) Reset() { *x = Histogram_Bucket{} - mi := &file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[37] + mi := &file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[38] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2561,7 +2621,7 @@ func (x *Histogram_Bucket) String() string { func (*Histogram_Bucket) ProtoMessage() {} func (x *Histogram_Bucket) ProtoReflect() protoreflect.Message { - mi := &file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[37] + mi := &file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[38] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2606,7 +2666,7 @@ type FetchRequest_FieldsFilter struct { func (x *FetchRequest_FieldsFilter) Reset() { *x = FetchRequest_FieldsFilter{} - mi := &file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[38] + mi := &file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[39] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2618,7 +2678,7 @@ func (x *FetchRequest_FieldsFilter) String() string { func (*FetchRequest_FieldsFilter) ProtoMessage() {} func (x *FetchRequest_FieldsFilter) ProtoReflect() protoreflect.Message { - mi := &file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[38] + mi := &file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[39] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3018,143 +3078,158 @@ var file_seqproxyapi_v1_seq_proxy_api_proto_rawDesc = string([]byte{ 0x71, 0x75, 0x65, 0x72, 0x79, 0x12, 0x12, 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x6f, 0x66, 0x66, 0x73, 0x65, - 0x74, 0x22, 0x3c, 0x0a, 0x0e, 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x12, 0x2a, 0x0a, 0x03, 0x64, 0x6f, 0x63, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x18, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, - 0x31, 0x2e, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x52, 0x03, 0x64, 0x6f, 0x63, 0x2a, - 0x82, 0x01, 0x0a, 0x09, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x1a, 0x0a, - 0x16, 0x45, 0x52, 0x52, 0x4f, 0x52, 0x5f, 0x43, 0x4f, 0x44, 0x45, 0x5f, 0x55, 0x4e, 0x53, 0x50, - 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x11, 0x0a, 0x0d, 0x45, 0x52, 0x52, - 0x4f, 0x52, 0x5f, 0x43, 0x4f, 0x44, 0x45, 0x5f, 0x4e, 0x4f, 0x10, 0x01, 0x12, 0x1f, 0x0a, 0x1b, - 0x45, 0x52, 0x52, 0x4f, 0x52, 0x5f, 0x43, 0x4f, 0x44, 0x45, 0x5f, 0x50, 0x41, 0x52, 0x54, 0x49, - 0x41, 0x4c, 0x5f, 0x52, 0x45, 0x53, 0x50, 0x4f, 0x4e, 0x53, 0x45, 0x10, 0x02, 0x12, 0x25, 0x0a, - 0x21, 0x45, 0x52, 0x52, 0x4f, 0x52, 0x5f, 0x43, 0x4f, 0x44, 0x45, 0x5f, 0x54, 0x4f, 0x4f, 0x5f, - 0x4d, 0x41, 0x4e, 0x59, 0x5f, 0x46, 0x52, 0x41, 0x43, 0x54, 0x49, 0x4f, 0x4e, 0x53, 0x5f, 0x48, - 0x49, 0x54, 0x10, 0x03, 0x2a, 0xac, 0x01, 0x0a, 0x07, 0x41, 0x67, 0x67, 0x46, 0x75, 0x6e, 0x63, - 0x12, 0x12, 0x0a, 0x0e, 0x41, 0x47, 0x47, 0x5f, 0x46, 0x55, 0x4e, 0x43, 0x5f, 0x43, 0x4f, 0x55, - 0x4e, 0x54, 0x10, 0x00, 0x12, 0x10, 0x0a, 0x0c, 0x41, 0x47, 0x47, 0x5f, 0x46, 0x55, 0x4e, 0x43, - 0x5f, 0x53, 0x55, 0x4d, 0x10, 0x01, 0x12, 0x10, 0x0a, 0x0c, 0x41, 0x47, 0x47, 0x5f, 0x46, 0x55, - 0x4e, 0x43, 0x5f, 0x4d, 0x49, 0x4e, 0x10, 0x02, 0x12, 0x10, 0x0a, 0x0c, 0x41, 0x47, 0x47, 0x5f, - 0x46, 0x55, 0x4e, 0x43, 0x5f, 0x4d, 0x41, 0x58, 0x10, 0x03, 0x12, 0x10, 0x0a, 0x0c, 0x41, 0x47, - 0x47, 0x5f, 0x46, 0x55, 0x4e, 0x43, 0x5f, 0x41, 0x56, 0x47, 0x10, 0x04, 0x12, 0x15, 0x0a, 0x11, - 0x41, 0x47, 0x47, 0x5f, 0x46, 0x55, 0x4e, 0x43, 0x5f, 0x51, 0x55, 0x41, 0x4e, 0x54, 0x49, 0x4c, - 0x45, 0x10, 0x05, 0x12, 0x13, 0x0a, 0x0f, 0x41, 0x47, 0x47, 0x5f, 0x46, 0x55, 0x4e, 0x43, 0x5f, - 0x55, 0x4e, 0x49, 0x51, 0x55, 0x45, 0x10, 0x06, 0x12, 0x19, 0x0a, 0x15, 0x41, 0x47, 0x47, 0x5f, - 0x46, 0x55, 0x4e, 0x43, 0x5f, 0x55, 0x4e, 0x49, 0x51, 0x55, 0x45, 0x5f, 0x43, 0x4f, 0x55, 0x4e, - 0x54, 0x10, 0x07, 0x2a, 0x26, 0x0a, 0x05, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x12, 0x0e, 0x0a, 0x0a, - 0x4f, 0x52, 0x44, 0x45, 0x52, 0x5f, 0x44, 0x45, 0x53, 0x43, 0x10, 0x00, 0x12, 0x0d, 0x0a, 0x09, - 0x4f, 0x52, 0x44, 0x45, 0x52, 0x5f, 0x41, 0x53, 0x43, 0x10, 0x01, 0x2a, 0x8a, 0x01, 0x0a, 0x11, - 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x53, 0x74, 0x61, 0x74, 0x75, - 0x73, 0x12, 0x1f, 0x0a, 0x1b, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, - 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x49, 0x6e, 0x50, 0x72, 0x6f, 0x67, 0x72, 0x65, 0x73, 0x73, - 0x10, 0x00, 0x12, 0x19, 0x0a, 0x15, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, - 0x68, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x44, 0x6f, 0x6e, 0x65, 0x10, 0x01, 0x12, 0x1d, 0x0a, - 0x19, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x53, 0x74, 0x61, 0x74, - 0x75, 0x73, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x65, 0x64, 0x10, 0x02, 0x12, 0x1a, 0x0a, 0x16, - 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x53, 0x74, 0x61, 0x74, 0x75, - 0x73, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x10, 0x03, 0x32, 0x98, 0x0c, 0x0a, 0x0b, 0x53, 0x65, 0x71, - 0x50, 0x72, 0x6f, 0x78, 0x79, 0x41, 0x70, 0x69, 0x12, 0x5b, 0x0a, 0x06, 0x53, 0x65, 0x61, 0x72, - 0x63, 0x68, 0x12, 0x1d, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, - 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x1e, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, - 0x76, 0x31, 0x2e, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x12, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x0c, 0x3a, 0x01, 0x2a, 0x22, 0x07, 0x2f, 0x73, - 0x65, 0x61, 0x72, 0x63, 0x68, 0x12, 0x78, 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x70, 0x6c, 0x65, 0x78, - 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x12, 0x24, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, - 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x70, 0x6c, 0x65, 0x78, 0x53, - 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x25, 0x2e, 0x73, - 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, - 0x6d, 0x70, 0x6c, 0x65, 0x78, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x1a, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x14, 0x3a, 0x01, 0x2a, 0x22, 0x0f, - 0x2f, 0x63, 0x6f, 0x6d, 0x70, 0x6c, 0x65, 0x78, 0x2d, 0x73, 0x65, 0x61, 0x72, 0x63, 0x68, 0x12, - 0x76, 0x0a, 0x0e, 0x47, 0x65, 0x74, 0x41, 0x67, 0x67, 0x72, 0x65, 0x67, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x12, 0x25, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, - 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x67, 0x67, 0x72, 0x65, 0x67, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, - 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x67, 0x67, - 0x72, 0x65, 0x67, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x22, 0x15, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x0f, 0x3a, 0x01, 0x2a, 0x22, 0x0a, 0x2f, 0x61, 0x67, - 0x67, 0x72, 0x65, 0x67, 0x61, 0x74, 0x65, 0x12, 0x70, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x48, 0x69, - 0x73, 0x74, 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x12, 0x23, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, - 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x48, 0x69, 0x73, 0x74, - 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x24, 0x2e, 0x73, + 0x74, 0x22, 0x63, 0x0a, 0x18, 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x41, 0x73, 0x79, 0x6e, 0x63, + 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1b, 0x0a, + 0x09, 0x73, 0x65, 0x61, 0x72, 0x63, 0x68, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x08, 0x73, 0x65, 0x61, 0x72, 0x63, 0x68, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x73, 0x69, + 0x7a, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x12, 0x16, + 0x0a, 0x06, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, + 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x22, 0x3c, 0x0a, 0x0e, 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2a, 0x0a, 0x03, 0x64, 0x6f, 0x63, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, + 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x52, + 0x03, 0x64, 0x6f, 0x63, 0x2a, 0x82, 0x01, 0x0a, 0x09, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x43, 0x6f, + 0x64, 0x65, 0x12, 0x1a, 0x0a, 0x16, 0x45, 0x52, 0x52, 0x4f, 0x52, 0x5f, 0x43, 0x4f, 0x44, 0x45, + 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x11, + 0x0a, 0x0d, 0x45, 0x52, 0x52, 0x4f, 0x52, 0x5f, 0x43, 0x4f, 0x44, 0x45, 0x5f, 0x4e, 0x4f, 0x10, + 0x01, 0x12, 0x1f, 0x0a, 0x1b, 0x45, 0x52, 0x52, 0x4f, 0x52, 0x5f, 0x43, 0x4f, 0x44, 0x45, 0x5f, + 0x50, 0x41, 0x52, 0x54, 0x49, 0x41, 0x4c, 0x5f, 0x52, 0x45, 0x53, 0x50, 0x4f, 0x4e, 0x53, 0x45, + 0x10, 0x02, 0x12, 0x25, 0x0a, 0x21, 0x45, 0x52, 0x52, 0x4f, 0x52, 0x5f, 0x43, 0x4f, 0x44, 0x45, + 0x5f, 0x54, 0x4f, 0x4f, 0x5f, 0x4d, 0x41, 0x4e, 0x59, 0x5f, 0x46, 0x52, 0x41, 0x43, 0x54, 0x49, + 0x4f, 0x4e, 0x53, 0x5f, 0x48, 0x49, 0x54, 0x10, 0x03, 0x2a, 0xac, 0x01, 0x0a, 0x07, 0x41, 0x67, + 0x67, 0x46, 0x75, 0x6e, 0x63, 0x12, 0x12, 0x0a, 0x0e, 0x41, 0x47, 0x47, 0x5f, 0x46, 0x55, 0x4e, + 0x43, 0x5f, 0x43, 0x4f, 0x55, 0x4e, 0x54, 0x10, 0x00, 0x12, 0x10, 0x0a, 0x0c, 0x41, 0x47, 0x47, + 0x5f, 0x46, 0x55, 0x4e, 0x43, 0x5f, 0x53, 0x55, 0x4d, 0x10, 0x01, 0x12, 0x10, 0x0a, 0x0c, 0x41, + 0x47, 0x47, 0x5f, 0x46, 0x55, 0x4e, 0x43, 0x5f, 0x4d, 0x49, 0x4e, 0x10, 0x02, 0x12, 0x10, 0x0a, + 0x0c, 0x41, 0x47, 0x47, 0x5f, 0x46, 0x55, 0x4e, 0x43, 0x5f, 0x4d, 0x41, 0x58, 0x10, 0x03, 0x12, + 0x10, 0x0a, 0x0c, 0x41, 0x47, 0x47, 0x5f, 0x46, 0x55, 0x4e, 0x43, 0x5f, 0x41, 0x56, 0x47, 0x10, + 0x04, 0x12, 0x15, 0x0a, 0x11, 0x41, 0x47, 0x47, 0x5f, 0x46, 0x55, 0x4e, 0x43, 0x5f, 0x51, 0x55, + 0x41, 0x4e, 0x54, 0x49, 0x4c, 0x45, 0x10, 0x05, 0x12, 0x13, 0x0a, 0x0f, 0x41, 0x47, 0x47, 0x5f, + 0x46, 0x55, 0x4e, 0x43, 0x5f, 0x55, 0x4e, 0x49, 0x51, 0x55, 0x45, 0x10, 0x06, 0x12, 0x19, 0x0a, + 0x15, 0x41, 0x47, 0x47, 0x5f, 0x46, 0x55, 0x4e, 0x43, 0x5f, 0x55, 0x4e, 0x49, 0x51, 0x55, 0x45, + 0x5f, 0x43, 0x4f, 0x55, 0x4e, 0x54, 0x10, 0x07, 0x2a, 0x26, 0x0a, 0x05, 0x4f, 0x72, 0x64, 0x65, + 0x72, 0x12, 0x0e, 0x0a, 0x0a, 0x4f, 0x52, 0x44, 0x45, 0x52, 0x5f, 0x44, 0x45, 0x53, 0x43, 0x10, + 0x00, 0x12, 0x0d, 0x0a, 0x09, 0x4f, 0x52, 0x44, 0x45, 0x52, 0x5f, 0x41, 0x53, 0x43, 0x10, 0x01, + 0x2a, 0x8a, 0x01, 0x0a, 0x11, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, + 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x1f, 0x0a, 0x1b, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, + 0x65, 0x61, 0x72, 0x63, 0x68, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x49, 0x6e, 0x50, 0x72, 0x6f, + 0x67, 0x72, 0x65, 0x73, 0x73, 0x10, 0x00, 0x12, 0x19, 0x0a, 0x15, 0x41, 0x73, 0x79, 0x6e, 0x63, + 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x44, 0x6f, 0x6e, 0x65, + 0x10, 0x01, 0x12, 0x1d, 0x0a, 0x19, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, + 0x68, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x65, 0x64, 0x10, + 0x02, 0x12, 0x1a, 0x0a, 0x16, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, + 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x10, 0x03, 0x32, 0x9d, 0x0d, + 0x0a, 0x0b, 0x53, 0x65, 0x71, 0x50, 0x72, 0x6f, 0x78, 0x79, 0x41, 0x70, 0x69, 0x12, 0x5b, 0x0a, + 0x06, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x12, 0x1d, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, + 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, + 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x12, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x0c, 0x3a, 0x01, + 0x2a, 0x22, 0x07, 0x2f, 0x73, 0x65, 0x61, 0x72, 0x63, 0x68, 0x12, 0x78, 0x0a, 0x0d, 0x43, 0x6f, + 0x6d, 0x70, 0x6c, 0x65, 0x78, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x12, 0x24, 0x2e, 0x73, 0x65, + 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, + 0x70, 0x6c, 0x65, 0x78, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x25, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, + 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x70, 0x6c, 0x65, 0x78, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x1a, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x14, + 0x3a, 0x01, 0x2a, 0x22, 0x0f, 0x2f, 0x63, 0x6f, 0x6d, 0x70, 0x6c, 0x65, 0x78, 0x2d, 0x73, 0x65, + 0x61, 0x72, 0x63, 0x68, 0x12, 0x76, 0x0a, 0x0e, 0x47, 0x65, 0x74, 0x41, 0x67, 0x67, 0x72, 0x65, + 0x67, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x25, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, + 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x67, 0x67, 0x72, 0x65, + 0x67, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, + 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x47, + 0x65, 0x74, 0x41, 0x67, 0x67, 0x72, 0x65, 0x67, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x15, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x0f, 0x3a, 0x01, 0x2a, + 0x22, 0x0a, 0x2f, 0x61, 0x67, 0x67, 0x72, 0x65, 0x67, 0x61, 0x74, 0x65, 0x12, 0x70, 0x0a, 0x0c, + 0x47, 0x65, 0x74, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x12, 0x23, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, - 0x74, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x22, 0x15, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x0f, 0x3a, 0x01, 0x2a, 0x22, 0x0a, 0x2f, - 0x68, 0x69, 0x73, 0x74, 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x12, 0x54, 0x0a, 0x05, 0x46, 0x65, 0x74, - 0x63, 0x68, 0x12, 0x1c, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, - 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x65, 0x74, 0x63, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x1a, 0x18, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, - 0x31, 0x2e, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x22, 0x11, 0x82, 0xd3, 0xe4, 0x93, - 0x02, 0x0b, 0x3a, 0x01, 0x2a, 0x22, 0x06, 0x2f, 0x66, 0x65, 0x74, 0x63, 0x68, 0x30, 0x01, 0x12, - 0x5d, 0x0a, 0x07, 0x4d, 0x61, 0x70, 0x70, 0x69, 0x6e, 0x67, 0x12, 0x1e, 0x2e, 0x73, 0x65, 0x71, - 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x61, 0x70, 0x70, - 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x73, 0x65, 0x71, - 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x61, 0x70, 0x70, - 0x69, 0x6e, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x11, 0x82, 0xd3, 0xe4, - 0x93, 0x02, 0x0b, 0x12, 0x09, 0x2f, 0x6d, 0x61, 0x70, 0x70, 0x69, 0x6e, 0x67, 0x73, 0x12, 0x58, - 0x0a, 0x06, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x1d, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, - 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, - 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x0f, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x09, 0x12, - 0x07, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x5d, 0x0a, 0x06, 0x45, 0x78, 0x70, 0x6f, - 0x72, 0x74, 0x12, 0x1d, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, - 0x2e, 0x76, 0x31, 0x2e, 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x1e, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, - 0x76, 0x31, 0x2e, 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x12, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x0c, 0x3a, 0x01, 0x2a, 0x22, 0x07, 0x2f, 0x65, - 0x78, 0x70, 0x6f, 0x72, 0x74, 0x30, 0x01, 0x12, 0x81, 0x01, 0x0a, 0x10, 0x53, 0x74, 0x61, 0x72, - 0x74, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x12, 0x27, 0x2e, 0x73, + 0x74, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x24, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, + 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x15, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x0f, 0x3a, + 0x01, 0x2a, 0x22, 0x0a, 0x2f, 0x68, 0x69, 0x73, 0x74, 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x12, 0x54, + 0x0a, 0x05, 0x46, 0x65, 0x74, 0x63, 0x68, 0x12, 0x1c, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, + 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x65, 0x74, 0x63, 0x68, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x18, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, + 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x22, + 0x11, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x0b, 0x3a, 0x01, 0x2a, 0x22, 0x06, 0x2f, 0x66, 0x65, 0x74, + 0x63, 0x68, 0x30, 0x01, 0x12, 0x5d, 0x0a, 0x07, 0x4d, 0x61, 0x70, 0x70, 0x69, 0x6e, 0x67, 0x12, + 0x1e, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, + 0x2e, 0x4d, 0x61, 0x70, 0x70, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x1f, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, + 0x2e, 0x4d, 0x61, 0x70, 0x70, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x11, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x0b, 0x12, 0x09, 0x2f, 0x6d, 0x61, 0x70, 0x70, 0x69, + 0x6e, 0x67, 0x73, 0x12, 0x58, 0x0a, 0x06, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x1d, 0x2e, + 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x53, + 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x74, - 0x61, 0x72, 0x74, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, - 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x74, 0x61, 0x72, 0x74, 0x41, 0x73, 0x79, 0x6e, - 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x1a, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x14, 0x3a, 0x01, 0x2a, 0x22, 0x0f, 0x2f, 0x61, 0x73, 0x79, - 0x6e, 0x63, 0x2d, 0x73, 0x65, 0x61, 0x72, 0x63, 0x68, 0x65, 0x73, 0x12, 0x99, 0x01, 0x0a, 0x16, - 0x46, 0x65, 0x74, 0x63, 0x68, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, - 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x2d, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, - 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x65, 0x74, 0x63, 0x68, 0x41, 0x73, 0x79, - 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2e, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, - 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x65, 0x74, 0x63, 0x68, 0x41, 0x73, 0x79, 0x6e, - 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x20, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1a, 0x3a, 0x01, 0x2a, - 0x22, 0x15, 0x2f, 0x61, 0x73, 0x79, 0x6e, 0x63, 0x2d, 0x73, 0x65, 0x61, 0x72, 0x63, 0x68, 0x65, - 0x73, 0x2f, 0x66, 0x65, 0x74, 0x63, 0x68, 0x12, 0x94, 0x01, 0x0a, 0x11, 0x43, 0x61, 0x6e, 0x63, - 0x65, 0x6c, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x12, 0x28, 0x2e, - 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x43, - 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, - 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x41, - 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x22, 0x2a, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x24, 0x22, 0x22, 0x2f, 0x61, 0x73, 0x79, - 0x6e, 0x63, 0x2d, 0x73, 0x65, 0x61, 0x72, 0x63, 0x68, 0x65, 0x73, 0x2f, 0x7b, 0x73, 0x65, 0x61, - 0x72, 0x63, 0x68, 0x5f, 0x69, 0x64, 0x7d, 0x2f, 0x63, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x12, 0x8d, - 0x01, 0x0a, 0x11, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, - 0x61, 0x72, 0x63, 0x68, 0x12, 0x28, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, - 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x41, 0x73, 0x79, 0x6e, - 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, + 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x0f, 0x82, 0xd3, + 0xe4, 0x93, 0x02, 0x09, 0x12, 0x07, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x5d, 0x0a, + 0x06, 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x12, 0x1d, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, + 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, + 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x12, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x0c, 0x3a, 0x01, + 0x2a, 0x22, 0x07, 0x2f, 0x65, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x30, 0x01, 0x12, 0x81, 0x01, 0x0a, + 0x10, 0x53, 0x74, 0x61, 0x72, 0x74, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, + 0x68, 0x12, 0x27, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, + 0x76, 0x31, 0x2e, 0x53, 0x74, 0x61, 0x72, 0x74, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, + 0x72, 0x63, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x73, 0x65, 0x71, + 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x74, 0x61, 0x72, + 0x74, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x1a, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x14, 0x3a, 0x01, 0x2a, 0x22, + 0x0f, 0x2f, 0x61, 0x73, 0x79, 0x6e, 0x63, 0x2d, 0x73, 0x65, 0x61, 0x72, 0x63, 0x68, 0x65, 0x73, + 0x12, 0x99, 0x01, 0x0a, 0x16, 0x46, 0x65, 0x74, 0x63, 0x68, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, + 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x2d, 0x2e, 0x73, 0x65, + 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x65, 0x74, + 0x63, 0x68, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x73, + 0x75, 0x6c, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2e, 0x2e, 0x73, 0x65, 0x71, + 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x46, 0x65, 0x74, 0x63, + 0x68, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x73, 0x75, + 0x6c, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x20, 0x82, 0xd3, 0xe4, 0x93, + 0x02, 0x1a, 0x3a, 0x01, 0x2a, 0x22, 0x15, 0x2f, 0x61, 0x73, 0x79, 0x6e, 0x63, 0x2d, 0x73, 0x65, + 0x61, 0x72, 0x63, 0x68, 0x65, 0x73, 0x2f, 0x66, 0x65, 0x74, 0x63, 0x68, 0x12, 0x94, 0x01, 0x0a, + 0x11, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, + 0x63, 0x68, 0x12, 0x28, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, + 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, + 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x73, + 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x61, + 0x6e, 0x63, 0x65, 0x6c, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2a, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x24, 0x22, + 0x22, 0x2f, 0x61, 0x73, 0x79, 0x6e, 0x63, 0x2d, 0x73, 0x65, 0x61, 0x72, 0x63, 0x68, 0x65, 0x73, + 0x2f, 0x7b, 0x73, 0x65, 0x61, 0x72, 0x63, 0x68, 0x5f, 0x69, 0x64, 0x7d, 0x2f, 0x63, 0x61, 0x6e, + 0x63, 0x65, 0x6c, 0x12, 0x8d, 0x01, 0x0a, 0x11, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x41, 0x73, + 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x12, 0x28, 0x2e, 0x73, 0x65, 0x71, 0x70, + 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, + 0x65, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, + 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x41, 0x73, 0x79, 0x6e, 0x63, + 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1d, 0x2a, 0x1b, 0x2f, 0x61, 0x73, 0x79, 0x6e, 0x63, 0x2d, 0x73, + 0x65, 0x61, 0x72, 0x63, 0x68, 0x65, 0x73, 0x2f, 0x7b, 0x73, 0x65, 0x61, 0x72, 0x63, 0x68, 0x5f, + 0x69, 0x64, 0x7d, 0x12, 0x92, 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x73, 0x79, 0x6e, 0x63, + 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x65, 0x73, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x2b, 0x2e, 0x73, + 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, + 0x74, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x65, 0x73, 0x4c, 0x69, + 0x73, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x73, 0x65, 0x71, 0x70, + 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x73, + 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x65, 0x73, 0x4c, 0x69, 0x73, 0x74, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x1f, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x19, 0x3a, + 0x01, 0x2a, 0x22, 0x14, 0x2f, 0x61, 0x73, 0x79, 0x6e, 0x63, 0x2d, 0x73, 0x65, 0x61, 0x72, 0x63, + 0x68, 0x65, 0x73, 0x2f, 0x6c, 0x69, 0x73, 0x74, 0x12, 0x82, 0x01, 0x0a, 0x11, 0x45, 0x78, 0x70, + 0x6f, 0x72, 0x74, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x12, 0x28, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, - 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, - 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x23, 0x82, 0xd3, 0xe4, 0x93, 0x02, - 0x1d, 0x2a, 0x1b, 0x2f, 0x61, 0x73, 0x79, 0x6e, 0x63, 0x2d, 0x73, 0x65, 0x61, 0x72, 0x63, 0x68, - 0x65, 0x73, 0x2f, 0x7b, 0x73, 0x65, 0x61, 0x72, 0x63, 0x68, 0x5f, 0x69, 0x64, 0x7d, 0x12, 0x92, - 0x01, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, - 0x68, 0x65, 0x73, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x2b, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, - 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x73, 0x79, 0x6e, - 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x65, 0x73, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, - 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, - 0x61, 0x72, 0x63, 0x68, 0x65, 0x73, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x22, 0x1f, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x19, 0x3a, 0x01, 0x2a, 0x22, 0x14, 0x2f, - 0x61, 0x73, 0x79, 0x6e, 0x63, 0x2d, 0x73, 0x65, 0x61, 0x72, 0x63, 0x68, 0x65, 0x73, 0x2f, 0x6c, - 0x69, 0x73, 0x74, 0x42, 0x3b, 0x5a, 0x39, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, - 0x6d, 0x2f, 0x6f, 0x7a, 0x6f, 0x6e, 0x74, 0x65, 0x63, 0x68, 0x2f, 0x73, 0x65, 0x71, 0x2d, 0x64, - 0x62, 0x2f, 0x70, 0x6b, 0x67, 0x2f, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, - 0x69, 0x2f, 0x76, 0x31, 0x3b, 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, - 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x41, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x65, 0x61, 0x72, 0x63, + 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x2e, 0x73, 0x65, 0x71, 0x70, 0x72, + 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x2e, 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x21, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1b, + 0x3a, 0x01, 0x2a, 0x22, 0x16, 0x2f, 0x61, 0x73, 0x79, 0x6e, 0x63, 0x2d, 0x73, 0x65, 0x61, 0x72, + 0x63, 0x68, 0x65, 0x73, 0x2f, 0x65, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x30, 0x01, 0x42, 0x3b, 0x5a, + 0x39, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x6f, 0x7a, 0x6f, 0x6e, + 0x74, 0x65, 0x63, 0x68, 0x2f, 0x73, 0x65, 0x71, 0x2d, 0x64, 0x62, 0x2f, 0x70, 0x6b, 0x67, 0x2f, + 0x73, 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x31, 0x3b, 0x73, + 0x65, 0x71, 0x70, 0x72, 0x6f, 0x78, 0x79, 0x61, 0x70, 0x69, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x33, }) var ( @@ -3170,7 +3245,7 @@ func file_seqproxyapi_v1_seq_proxy_api_proto_rawDescGZIP() []byte { } var file_seqproxyapi_v1_seq_proxy_api_proto_enumTypes = make([]protoimpl.EnumInfo, 4) -var file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes = make([]protoimpl.MessageInfo, 39) +var file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes = make([]protoimpl.MessageInfo, 40) var file_seqproxyapi_v1_seq_proxy_api_proto_goTypes = []any{ (ErrorCode)(0), // 0: seqproxyapi.v1.ErrorCode (AggFunc)(0), // 1: seqproxyapi.v1.AggFunc @@ -3211,22 +3286,23 @@ var file_seqproxyapi_v1_seq_proxy_api_proto_goTypes = []any{ (*StoreStatus)(nil), // 36: seqproxyapi.v1.StoreStatus (*StoreStatusValues)(nil), // 37: seqproxyapi.v1.StoreStatusValues (*ExportRequest)(nil), // 38: seqproxyapi.v1.ExportRequest - (*ExportResponse)(nil), // 39: seqproxyapi.v1.ExportResponse - (*Aggregation_Bucket)(nil), // 40: seqproxyapi.v1.Aggregation.Bucket - (*Histogram_Bucket)(nil), // 41: seqproxyapi.v1.Histogram.Bucket - (*FetchRequest_FieldsFilter)(nil), // 42: seqproxyapi.v1.FetchRequest.FieldsFilter - (*timestamppb.Timestamp)(nil), // 43: google.protobuf.Timestamp - (*durationpb.Duration)(nil), // 44: google.protobuf.Duration + (*ExportAsyncSearchRequest)(nil), // 39: seqproxyapi.v1.ExportAsyncSearchRequest + (*ExportResponse)(nil), // 40: seqproxyapi.v1.ExportResponse + (*Aggregation_Bucket)(nil), // 41: seqproxyapi.v1.Aggregation.Bucket + (*Histogram_Bucket)(nil), // 42: seqproxyapi.v1.Histogram.Bucket + (*FetchRequest_FieldsFilter)(nil), // 43: seqproxyapi.v1.FetchRequest.FieldsFilter + (*timestamppb.Timestamp)(nil), // 44: google.protobuf.Timestamp + (*durationpb.Duration)(nil), // 45: google.protobuf.Duration } var file_seqproxyapi_v1_seq_proxy_api_proto_depIdxs = []int32{ 0, // 0: seqproxyapi.v1.Error.code:type_name -> seqproxyapi.v1.ErrorCode - 43, // 1: seqproxyapi.v1.Document.time:type_name -> google.protobuf.Timestamp - 40, // 2: seqproxyapi.v1.Aggregation.buckets:type_name -> seqproxyapi.v1.Aggregation.Bucket - 41, // 3: seqproxyapi.v1.Histogram.buckets:type_name -> seqproxyapi.v1.Histogram.Bucket - 43, // 4: seqproxyapi.v1.SearchQuery.from:type_name -> google.protobuf.Timestamp - 43, // 5: seqproxyapi.v1.SearchQuery.to:type_name -> google.protobuf.Timestamp + 44, // 1: seqproxyapi.v1.Document.time:type_name -> google.protobuf.Timestamp + 41, // 2: seqproxyapi.v1.Aggregation.buckets:type_name -> seqproxyapi.v1.Aggregation.Bucket + 42, // 3: seqproxyapi.v1.Histogram.buckets:type_name -> seqproxyapi.v1.Histogram.Bucket + 44, // 4: seqproxyapi.v1.SearchQuery.from:type_name -> google.protobuf.Timestamp + 44, // 5: seqproxyapi.v1.SearchQuery.to:type_name -> google.protobuf.Timestamp 1, // 6: seqproxyapi.v1.AggQuery.func:type_name -> seqproxyapi.v1.AggFunc - 44, // 7: seqproxyapi.v1.ExplainEntry.duration:type_name -> google.protobuf.Duration + 45, // 7: seqproxyapi.v1.ExplainEntry.duration:type_name -> google.protobuf.Duration 11, // 8: seqproxyapi.v1.ExplainEntry.children:type_name -> seqproxyapi.v1.ExplainEntry 8, // 9: seqproxyapi.v1.SearchRequest.query:type_name -> seqproxyapi.v1.SearchQuery 2, // 10: seqproxyapi.v1.SearchRequest.order:type_name -> seqproxyapi.v1.Order @@ -3241,7 +3317,7 @@ var file_seqproxyapi_v1_seq_proxy_api_proto_depIdxs = []int32{ 7, // 19: seqproxyapi.v1.ComplexSearchResponse.hist:type_name -> seqproxyapi.v1.Histogram 4, // 20: seqproxyapi.v1.ComplexSearchResponse.error:type_name -> seqproxyapi.v1.Error 11, // 21: seqproxyapi.v1.ComplexSearchResponse.explain:type_name -> seqproxyapi.v1.ExplainEntry - 44, // 22: seqproxyapi.v1.StartAsyncSearchRequest.retention:type_name -> google.protobuf.Duration + 45, // 22: seqproxyapi.v1.StartAsyncSearchRequest.retention:type_name -> google.protobuf.Duration 8, // 23: seqproxyapi.v1.StartAsyncSearchRequest.query:type_name -> seqproxyapi.v1.SearchQuery 9, // 24: seqproxyapi.v1.StartAsyncSearchRequest.aggs:type_name -> seqproxyapi.v1.AggQuery 10, // 25: seqproxyapi.v1.StartAsyncSearchRequest.hist:type_name -> seqproxyapi.v1.HistQuery @@ -3249,18 +3325,18 @@ var file_seqproxyapi_v1_seq_proxy_api_proto_depIdxs = []int32{ 3, // 27: seqproxyapi.v1.FetchAsyncSearchResultResponse.status:type_name -> seqproxyapi.v1.AsyncSearchStatus 16, // 28: seqproxyapi.v1.FetchAsyncSearchResultResponse.request:type_name -> seqproxyapi.v1.StartAsyncSearchRequest 15, // 29: seqproxyapi.v1.FetchAsyncSearchResultResponse.response:type_name -> seqproxyapi.v1.ComplexSearchResponse - 43, // 30: seqproxyapi.v1.FetchAsyncSearchResultResponse.started_at:type_name -> google.protobuf.Timestamp - 43, // 31: seqproxyapi.v1.FetchAsyncSearchResultResponse.expires_at:type_name -> google.protobuf.Timestamp - 43, // 32: seqproxyapi.v1.FetchAsyncSearchResultResponse.canceled_at:type_name -> google.protobuf.Timestamp + 44, // 30: seqproxyapi.v1.FetchAsyncSearchResultResponse.started_at:type_name -> google.protobuf.Timestamp + 44, // 31: seqproxyapi.v1.FetchAsyncSearchResultResponse.expires_at:type_name -> google.protobuf.Timestamp + 44, // 32: seqproxyapi.v1.FetchAsyncSearchResultResponse.canceled_at:type_name -> google.protobuf.Timestamp 4, // 33: seqproxyapi.v1.FetchAsyncSearchResultResponse.error:type_name -> seqproxyapi.v1.Error 3, // 34: seqproxyapi.v1.GetAsyncSearchesListRequest.status:type_name -> seqproxyapi.v1.AsyncSearchStatus 26, // 35: seqproxyapi.v1.GetAsyncSearchesListResponse.searches:type_name -> seqproxyapi.v1.AsyncSearchesListItem 4, // 36: seqproxyapi.v1.GetAsyncSearchesListResponse.error:type_name -> seqproxyapi.v1.Error 3, // 37: seqproxyapi.v1.AsyncSearchesListItem.status:type_name -> seqproxyapi.v1.AsyncSearchStatus 16, // 38: seqproxyapi.v1.AsyncSearchesListItem.request:type_name -> seqproxyapi.v1.StartAsyncSearchRequest - 43, // 39: seqproxyapi.v1.AsyncSearchesListItem.started_at:type_name -> google.protobuf.Timestamp - 43, // 40: seqproxyapi.v1.AsyncSearchesListItem.expires_at:type_name -> google.protobuf.Timestamp - 43, // 41: seqproxyapi.v1.AsyncSearchesListItem.canceled_at:type_name -> google.protobuf.Timestamp + 44, // 39: seqproxyapi.v1.AsyncSearchesListItem.started_at:type_name -> google.protobuf.Timestamp + 44, // 40: seqproxyapi.v1.AsyncSearchesListItem.expires_at:type_name -> google.protobuf.Timestamp + 44, // 41: seqproxyapi.v1.AsyncSearchesListItem.canceled_at:type_name -> google.protobuf.Timestamp 8, // 42: seqproxyapi.v1.GetAggregationRequest.query:type_name -> seqproxyapi.v1.SearchQuery 9, // 43: seqproxyapi.v1.GetAggregationRequest.aggs:type_name -> seqproxyapi.v1.AggQuery 6, // 44: seqproxyapi.v1.GetAggregationResponse.aggs:type_name -> seqproxyapi.v1.Aggregation @@ -3269,15 +3345,15 @@ var file_seqproxyapi_v1_seq_proxy_api_proto_depIdxs = []int32{ 10, // 47: seqproxyapi.v1.GetHistogramRequest.hist:type_name -> seqproxyapi.v1.HistQuery 7, // 48: seqproxyapi.v1.GetHistogramResponse.hist:type_name -> seqproxyapi.v1.Histogram 4, // 49: seqproxyapi.v1.GetHistogramResponse.error:type_name -> seqproxyapi.v1.Error - 42, // 50: seqproxyapi.v1.FetchRequest.fields_filter:type_name -> seqproxyapi.v1.FetchRequest.FieldsFilter - 43, // 51: seqproxyapi.v1.StatusResponse.oldest_storage_time:type_name -> google.protobuf.Timestamp + 43, // 50: seqproxyapi.v1.FetchRequest.fields_filter:type_name -> seqproxyapi.v1.FetchRequest.FieldsFilter + 44, // 51: seqproxyapi.v1.StatusResponse.oldest_storage_time:type_name -> google.protobuf.Timestamp 36, // 52: seqproxyapi.v1.StatusResponse.stores:type_name -> seqproxyapi.v1.StoreStatus 37, // 53: seqproxyapi.v1.StoreStatus.values:type_name -> seqproxyapi.v1.StoreStatusValues - 43, // 54: seqproxyapi.v1.StoreStatusValues.oldest_time:type_name -> google.protobuf.Timestamp + 44, // 54: seqproxyapi.v1.StoreStatusValues.oldest_time:type_name -> google.protobuf.Timestamp 8, // 55: seqproxyapi.v1.ExportRequest.query:type_name -> seqproxyapi.v1.SearchQuery 5, // 56: seqproxyapi.v1.ExportResponse.doc:type_name -> seqproxyapi.v1.Document - 43, // 57: seqproxyapi.v1.Aggregation.Bucket.ts:type_name -> google.protobuf.Timestamp - 43, // 58: seqproxyapi.v1.Histogram.Bucket.ts:type_name -> google.protobuf.Timestamp + 44, // 57: seqproxyapi.v1.Aggregation.Bucket.ts:type_name -> google.protobuf.Timestamp + 44, // 58: seqproxyapi.v1.Histogram.Bucket.ts:type_name -> google.protobuf.Timestamp 12, // 59: seqproxyapi.v1.SeqProxyApi.Search:input_type -> seqproxyapi.v1.SearchRequest 13, // 60: seqproxyapi.v1.SeqProxyApi.ComplexSearch:input_type -> seqproxyapi.v1.ComplexSearchRequest 27, // 61: seqproxyapi.v1.SeqProxyApi.GetAggregation:input_type -> seqproxyapi.v1.GetAggregationRequest @@ -3291,21 +3367,23 @@ var file_seqproxyapi_v1_seq_proxy_api_proto_depIdxs = []int32{ 20, // 69: seqproxyapi.v1.SeqProxyApi.CancelAsyncSearch:input_type -> seqproxyapi.v1.CancelAsyncSearchRequest 22, // 70: seqproxyapi.v1.SeqProxyApi.DeleteAsyncSearch:input_type -> seqproxyapi.v1.DeleteAsyncSearchRequest 24, // 71: seqproxyapi.v1.SeqProxyApi.GetAsyncSearchesList:input_type -> seqproxyapi.v1.GetAsyncSearchesListRequest - 14, // 72: seqproxyapi.v1.SeqProxyApi.Search:output_type -> seqproxyapi.v1.SearchResponse - 15, // 73: seqproxyapi.v1.SeqProxyApi.ComplexSearch:output_type -> seqproxyapi.v1.ComplexSearchResponse - 28, // 74: seqproxyapi.v1.SeqProxyApi.GetAggregation:output_type -> seqproxyapi.v1.GetAggregationResponse - 30, // 75: seqproxyapi.v1.SeqProxyApi.GetHistogram:output_type -> seqproxyapi.v1.GetHistogramResponse - 5, // 76: seqproxyapi.v1.SeqProxyApi.Fetch:output_type -> seqproxyapi.v1.Document - 33, // 77: seqproxyapi.v1.SeqProxyApi.Mapping:output_type -> seqproxyapi.v1.MappingResponse - 35, // 78: seqproxyapi.v1.SeqProxyApi.Status:output_type -> seqproxyapi.v1.StatusResponse - 39, // 79: seqproxyapi.v1.SeqProxyApi.Export:output_type -> seqproxyapi.v1.ExportResponse - 17, // 80: seqproxyapi.v1.SeqProxyApi.StartAsyncSearch:output_type -> seqproxyapi.v1.StartAsyncSearchResponse - 19, // 81: seqproxyapi.v1.SeqProxyApi.FetchAsyncSearchResult:output_type -> seqproxyapi.v1.FetchAsyncSearchResultResponse - 21, // 82: seqproxyapi.v1.SeqProxyApi.CancelAsyncSearch:output_type -> seqproxyapi.v1.CancelAsyncSearchResponse - 23, // 83: seqproxyapi.v1.SeqProxyApi.DeleteAsyncSearch:output_type -> seqproxyapi.v1.DeleteAsyncSearchResponse - 25, // 84: seqproxyapi.v1.SeqProxyApi.GetAsyncSearchesList:output_type -> seqproxyapi.v1.GetAsyncSearchesListResponse - 72, // [72:85] is the sub-list for method output_type - 59, // [59:72] is the sub-list for method input_type + 39, // 72: seqproxyapi.v1.SeqProxyApi.ExportAsyncSearch:input_type -> seqproxyapi.v1.ExportAsyncSearchRequest + 14, // 73: seqproxyapi.v1.SeqProxyApi.Search:output_type -> seqproxyapi.v1.SearchResponse + 15, // 74: seqproxyapi.v1.SeqProxyApi.ComplexSearch:output_type -> seqproxyapi.v1.ComplexSearchResponse + 28, // 75: seqproxyapi.v1.SeqProxyApi.GetAggregation:output_type -> seqproxyapi.v1.GetAggregationResponse + 30, // 76: seqproxyapi.v1.SeqProxyApi.GetHistogram:output_type -> seqproxyapi.v1.GetHistogramResponse + 5, // 77: seqproxyapi.v1.SeqProxyApi.Fetch:output_type -> seqproxyapi.v1.Document + 33, // 78: seqproxyapi.v1.SeqProxyApi.Mapping:output_type -> seqproxyapi.v1.MappingResponse + 35, // 79: seqproxyapi.v1.SeqProxyApi.Status:output_type -> seqproxyapi.v1.StatusResponse + 40, // 80: seqproxyapi.v1.SeqProxyApi.Export:output_type -> seqproxyapi.v1.ExportResponse + 17, // 81: seqproxyapi.v1.SeqProxyApi.StartAsyncSearch:output_type -> seqproxyapi.v1.StartAsyncSearchResponse + 19, // 82: seqproxyapi.v1.SeqProxyApi.FetchAsyncSearchResult:output_type -> seqproxyapi.v1.FetchAsyncSearchResultResponse + 21, // 83: seqproxyapi.v1.SeqProxyApi.CancelAsyncSearch:output_type -> seqproxyapi.v1.CancelAsyncSearchResponse + 23, // 84: seqproxyapi.v1.SeqProxyApi.DeleteAsyncSearch:output_type -> seqproxyapi.v1.DeleteAsyncSearchResponse + 25, // 85: seqproxyapi.v1.SeqProxyApi.GetAsyncSearchesList:output_type -> seqproxyapi.v1.GetAsyncSearchesListResponse + 40, // 86: seqproxyapi.v1.SeqProxyApi.ExportAsyncSearch:output_type -> seqproxyapi.v1.ExportResponse + 73, // [73:87] is the sub-list for method output_type + 59, // [59:73] is the sub-list for method input_type 59, // [59:59] is the sub-list for extension type_name 59, // [59:59] is the sub-list for extension extendee 0, // [0:59] is the sub-list for field type_name @@ -3325,14 +3403,14 @@ func file_seqproxyapi_v1_seq_proxy_api_proto_init() { file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[22].OneofWrappers = []any{} file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[31].OneofWrappers = []any{} file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[32].OneofWrappers = []any{} - file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[36].OneofWrappers = []any{} + file_seqproxyapi_v1_seq_proxy_api_proto_msgTypes[37].OneofWrappers = []any{} type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: unsafe.Slice(unsafe.StringData(file_seqproxyapi_v1_seq_proxy_api_proto_rawDesc), len(file_seqproxyapi_v1_seq_proxy_api_proto_rawDesc)), NumEnums: 4, - NumMessages: 39, + NumMessages: 40, NumExtensions: 0, NumServices: 1, }, diff --git a/pkg/seqproxyapi/v1/seq_proxy_api.pb.gw.go b/pkg/seqproxyapi/v1/seq_proxy_api.pb.gw.go index 28010d15e..9a4ece1ab 100644 --- a/pkg/seqproxyapi/v1/seq_proxy_api.pb.gw.go +++ b/pkg/seqproxyapi/v1/seq_proxy_api.pb.gw.go @@ -351,6 +351,26 @@ func local_request_SeqProxyApi_GetAsyncSearchesList_0(ctx context.Context, marsh return msg, metadata, err } +func request_SeqProxyApi_ExportAsyncSearch_0(ctx context.Context, marshaler runtime.Marshaler, client SeqProxyApiClient, req *http.Request, pathParams map[string]string) (SeqProxyApi_ExportAsyncSearchClient, runtime.ServerMetadata, error) { + var ( + protoReq ExportAsyncSearchRequest + metadata runtime.ServerMetadata + ) + if err := marshaler.NewDecoder(req.Body).Decode(&protoReq); err != nil && !errors.Is(err, io.EOF) { + return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) + } + stream, err := client.ExportAsyncSearch(ctx, &protoReq) + if err != nil { + return nil, metadata, err + } + header, err := stream.Header() + if err != nil { + return nil, metadata, err + } + metadata.HeaderMD = header + return stream, metadata, nil +} + // RegisterSeqProxyApiHandlerServer registers the http handlers for service SeqProxyApi to "mux". // UnaryRPC :call SeqProxyApiServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. @@ -592,6 +612,13 @@ func RegisterSeqProxyApiHandlerServer(ctx context.Context, mux *runtime.ServeMux forward_SeqProxyApi_GetAsyncSearchesList_0(annotatedContext, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) + mux.Handle(http.MethodPost, pattern_SeqProxyApi_ExportAsyncSearch_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + err := status.Error(codes.Unimplemented, "streaming calls are not yet supported in the in-process transport") + _, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + }) + return nil } @@ -852,6 +879,23 @@ func RegisterSeqProxyApiHandlerClient(ctx context.Context, mux *runtime.ServeMux } forward_SeqProxyApi_GetAsyncSearchesList_0(annotatedContext, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) + mux.Handle(http.MethodPost, pattern_SeqProxyApi_ExportAsyncSearch_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + ctx, cancel := context.WithCancel(req.Context()) + defer cancel() + inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) + annotatedContext, err := runtime.AnnotateContext(ctx, mux, req, "/seqproxyapi.v1.SeqProxyApi/ExportAsyncSearch", runtime.WithHTTPPathPattern("/async-searches/export")) + if err != nil { + runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) + return + } + resp, md, err := request_SeqProxyApi_ExportAsyncSearch_0(annotatedContext, inboundMarshaler, client, req, pathParams) + annotatedContext = runtime.NewServerMetadataContext(annotatedContext, md) + if err != nil { + runtime.HTTPError(annotatedContext, mux, outboundMarshaler, w, req, err) + return + } + forward_SeqProxyApi_ExportAsyncSearch_0(annotatedContext, mux, outboundMarshaler, w, req, func() (proto.Message, error) { return resp.Recv() }, mux.GetForwardResponseOptions()...) + }) return nil } @@ -869,6 +913,7 @@ var ( pattern_SeqProxyApi_CancelAsyncSearch_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 1, 0, 4, 1, 5, 1, 2, 2}, []string{"async-searches", "search_id", "cancel"}, "")) pattern_SeqProxyApi_DeleteAsyncSearch_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 1, 0, 4, 1, 5, 1}, []string{"async-searches", "search_id"}, "")) pattern_SeqProxyApi_GetAsyncSearchesList_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"async-searches", "list"}, "")) + pattern_SeqProxyApi_ExportAsyncSearch_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"async-searches", "export"}, "")) ) var ( @@ -885,4 +930,5 @@ var ( forward_SeqProxyApi_CancelAsyncSearch_0 = runtime.ForwardResponseMessage forward_SeqProxyApi_DeleteAsyncSearch_0 = runtime.ForwardResponseMessage forward_SeqProxyApi_GetAsyncSearchesList_0 = runtime.ForwardResponseMessage + forward_SeqProxyApi_ExportAsyncSearch_0 = runtime.ForwardResponseStream ) diff --git a/pkg/seqproxyapi/v1/seq_proxy_api_vtproto.pb.go b/pkg/seqproxyapi/v1/seq_proxy_api_vtproto.pb.go index 3b4d8b697..593582014 100644 --- a/pkg/seqproxyapi/v1/seq_proxy_api_vtproto.pb.go +++ b/pkg/seqproxyapi/v1/seq_proxy_api_vtproto.pb.go @@ -868,6 +868,25 @@ func (m *ExportRequest) CloneMessageVT() proto.Message { return m.CloneVT() } +func (m *ExportAsyncSearchRequest) CloneVT() *ExportAsyncSearchRequest { + if m == nil { + return (*ExportAsyncSearchRequest)(nil) + } + r := new(ExportAsyncSearchRequest) + r.SearchId = m.SearchId + r.Size = m.Size + r.Offset = m.Offset + if len(m.unknownFields) > 0 { + r.unknownFields = make([]byte, len(m.unknownFields)) + copy(r.unknownFields, m.unknownFields) + } + return r +} + +func (m *ExportAsyncSearchRequest) CloneMessageVT() proto.Message { + return m.CloneVT() +} + func (m *ExportResponse) CloneVT() *ExportResponse { if m == nil { return (*ExportResponse)(nil) @@ -2045,6 +2064,31 @@ func (this *ExportRequest) EqualMessageVT(thatMsg proto.Message) bool { } return this.EqualVT(that) } +func (this *ExportAsyncSearchRequest) EqualVT(that *ExportAsyncSearchRequest) bool { + if this == that { + return true + } else if this == nil || that == nil { + return false + } + if this.SearchId != that.SearchId { + return false + } + if this.Size != that.Size { + return false + } + if this.Offset != that.Offset { + return false + } + return string(this.unknownFields) == string(that.unknownFields) +} + +func (this *ExportAsyncSearchRequest) EqualMessageVT(thatMsg proto.Message) bool { + that, ok := thatMsg.(*ExportAsyncSearchRequest) + if !ok { + return false + } + return this.EqualVT(that) +} func (this *ExportResponse) EqualVT(that *ExportResponse) bool { if this == that { return true @@ -2102,6 +2146,8 @@ type SeqProxyApiClient interface { DeleteAsyncSearch(ctx context.Context, in *DeleteAsyncSearchRequest, opts ...grpc.CallOption) (*DeleteAsyncSearchResponse, error) // Fetch list of async searches. GetAsyncSearchesList(ctx context.Context, in *GetAsyncSearchesListRequest, opts ...grpc.CallOption) (*GetAsyncSearchesListResponse, error) + // Stream documents for given async search ID. + ExportAsyncSearch(ctx context.Context, in *ExportAsyncSearchRequest, opts ...grpc.CallOption) (SeqProxyApi_ExportAsyncSearchClient, error) } type seqProxyApiClient struct { @@ -2275,6 +2321,38 @@ func (c *seqProxyApiClient) GetAsyncSearchesList(ctx context.Context, in *GetAsy return out, nil } +func (c *seqProxyApiClient) ExportAsyncSearch(ctx context.Context, in *ExportAsyncSearchRequest, opts ...grpc.CallOption) (SeqProxyApi_ExportAsyncSearchClient, error) { + stream, err := c.cc.NewStream(ctx, &SeqProxyApi_ServiceDesc.Streams[2], "/seqproxyapi.v1.SeqProxyApi/ExportAsyncSearch", opts...) + if err != nil { + return nil, err + } + x := &seqProxyApiExportAsyncSearchClient{stream} + if err := x.ClientStream.SendMsg(in); err != nil { + return nil, err + } + if err := x.ClientStream.CloseSend(); err != nil { + return nil, err + } + return x, nil +} + +type SeqProxyApi_ExportAsyncSearchClient interface { + Recv() (*ExportResponse, error) + grpc.ClientStream +} + +type seqProxyApiExportAsyncSearchClient struct { + grpc.ClientStream +} + +func (x *seqProxyApiExportAsyncSearchClient) Recv() (*ExportResponse, error) { + m := new(ExportResponse) + if err := x.ClientStream.RecvMsg(m); err != nil { + return nil, err + } + return m, nil +} + // SeqProxyApiServer is the server API for SeqProxyApi service. // All implementations must embed UnimplementedSeqProxyApiServer // for forward compatibility @@ -2307,6 +2385,8 @@ type SeqProxyApiServer interface { DeleteAsyncSearch(context.Context, *DeleteAsyncSearchRequest) (*DeleteAsyncSearchResponse, error) // Fetch list of async searches. GetAsyncSearchesList(context.Context, *GetAsyncSearchesListRequest) (*GetAsyncSearchesListResponse, error) + // Stream documents for given async search ID. + ExportAsyncSearch(*ExportAsyncSearchRequest, SeqProxyApi_ExportAsyncSearchServer) error mustEmbedUnimplementedSeqProxyApiServer() } @@ -2353,6 +2433,9 @@ func (UnimplementedSeqProxyApiServer) DeleteAsyncSearch(context.Context, *Delete func (UnimplementedSeqProxyApiServer) GetAsyncSearchesList(context.Context, *GetAsyncSearchesListRequest) (*GetAsyncSearchesListResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method GetAsyncSearchesList not implemented") } +func (UnimplementedSeqProxyApiServer) ExportAsyncSearch(*ExportAsyncSearchRequest, SeqProxyApi_ExportAsyncSearchServer) error { + return status.Errorf(codes.Unimplemented, "method ExportAsyncSearch not implemented") +} func (UnimplementedSeqProxyApiServer) mustEmbedUnimplementedSeqProxyApiServer() {} // UnsafeSeqProxyApiServer may be embedded to opt out of forward compatibility for this service. @@ -2606,6 +2689,27 @@ func _SeqProxyApi_GetAsyncSearchesList_Handler(srv interface{}, ctx context.Cont return interceptor(ctx, in, info, handler) } +func _SeqProxyApi_ExportAsyncSearch_Handler(srv interface{}, stream grpc.ServerStream) error { + m := new(ExportAsyncSearchRequest) + if err := stream.RecvMsg(m); err != nil { + return err + } + return srv.(SeqProxyApiServer).ExportAsyncSearch(m, &seqProxyApiExportAsyncSearchServer{stream}) +} + +type SeqProxyApi_ExportAsyncSearchServer interface { + Send(*ExportResponse) error + grpc.ServerStream +} + +type seqProxyApiExportAsyncSearchServer struct { + grpc.ServerStream +} + +func (x *seqProxyApiExportAsyncSearchServer) Send(m *ExportResponse) error { + return x.ServerStream.SendMsg(m) +} + // SeqProxyApi_ServiceDesc is the grpc.ServiceDesc for SeqProxyApi service. // It's only intended for direct use with grpc.RegisterService, // and not to be introspected or modified (even as a copy) @@ -2669,6 +2773,11 @@ var SeqProxyApi_ServiceDesc = grpc.ServiceDesc{ Handler: _SeqProxyApi_Export_Handler, ServerStreams: true, }, + { + StreamName: "ExportAsyncSearch", + Handler: _SeqProxyApi_ExportAsyncSearch_Handler, + ServerStreams: true, + }, }, Metadata: "seqproxyapi/v1/seq_proxy_api.proto", } @@ -4903,6 +5012,56 @@ func (m *ExportRequest) MarshalToSizedBufferVT(dAtA []byte) (int, error) { return len(dAtA) - i, nil } +func (m *ExportAsyncSearchRequest) MarshalVT() (dAtA []byte, err error) { + if m == nil { + return nil, nil + } + size := m.SizeVT() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBufferVT(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ExportAsyncSearchRequest) MarshalToVT(dAtA []byte) (int, error) { + size := m.SizeVT() + return m.MarshalToSizedBufferVT(dAtA[:size]) +} + +func (m *ExportAsyncSearchRequest) MarshalToSizedBufferVT(dAtA []byte) (int, error) { + if m == nil { + return 0, nil + } + i := len(dAtA) + _ = i + var l int + _ = l + if m.unknownFields != nil { + i -= len(m.unknownFields) + copy(dAtA[i:], m.unknownFields) + } + if m.Offset != 0 { + i = protohelpers.EncodeVarint(dAtA, i, uint64(m.Offset)) + i-- + dAtA[i] = 0x18 + } + if m.Size != 0 { + i = protohelpers.EncodeVarint(dAtA, i, uint64(m.Size)) + i-- + dAtA[i] = 0x10 + } + if len(m.SearchId) > 0 { + i -= len(m.SearchId) + copy(dAtA[i:], m.SearchId) + i = protohelpers.EncodeVarint(dAtA, i, uint64(len(m.SearchId))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + func (m *ExportResponse) MarshalVT() (dAtA []byte, err error) { if m == nil { return nil, nil @@ -7176,6 +7335,56 @@ func (m *ExportRequest) MarshalToSizedBufferVTStrict(dAtA []byte) (int, error) { return len(dAtA) - i, nil } +func (m *ExportAsyncSearchRequest) MarshalVTStrict() (dAtA []byte, err error) { + if m == nil { + return nil, nil + } + size := m.SizeVT() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBufferVTStrict(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ExportAsyncSearchRequest) MarshalToVTStrict(dAtA []byte) (int, error) { + size := m.SizeVT() + return m.MarshalToSizedBufferVTStrict(dAtA[:size]) +} + +func (m *ExportAsyncSearchRequest) MarshalToSizedBufferVTStrict(dAtA []byte) (int, error) { + if m == nil { + return 0, nil + } + i := len(dAtA) + _ = i + var l int + _ = l + if m.unknownFields != nil { + i -= len(m.unknownFields) + copy(dAtA[i:], m.unknownFields) + } + if m.Offset != 0 { + i = protohelpers.EncodeVarint(dAtA, i, uint64(m.Offset)) + i-- + dAtA[i] = 0x18 + } + if m.Size != 0 { + i = protohelpers.EncodeVarint(dAtA, i, uint64(m.Size)) + i-- + dAtA[i] = 0x10 + } + if len(m.SearchId) > 0 { + i -= len(m.SearchId) + copy(dAtA[i:], m.SearchId) + i = protohelpers.EncodeVarint(dAtA, i, uint64(len(m.SearchId))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + func (m *ExportResponse) MarshalVTStrict() (dAtA []byte, err error) { if m == nil { return nil, nil @@ -8057,6 +8266,26 @@ func (m *ExportRequest) SizeVT() (n int) { return n } +func (m *ExportAsyncSearchRequest) SizeVT() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.SearchId) + if l > 0 { + n += 1 + l + protohelpers.SizeOfVarint(uint64(l)) + } + if m.Size != 0 { + n += 1 + protohelpers.SizeOfVarint(uint64(m.Size)) + } + if m.Offset != 0 { + n += 1 + protohelpers.SizeOfVarint(uint64(m.Offset)) + } + n += len(m.unknownFields) + return n +} + func (m *ExportResponse) SizeVT() (n int) { if m == nil { return 0 @@ -13452,6 +13681,127 @@ func (m *ExportRequest) UnmarshalVT(dAtA []byte) error { } return nil } +func (m *ExportAsyncSearchRequest) UnmarshalVT(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ExportAsyncSearchRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ExportAsyncSearchRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SearchId", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protohelpers.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protohelpers.ErrInvalidLength + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.SearchId = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Size", wireType) + } + m.Size = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Size |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Offset", wireType) + } + m.Offset = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Offset |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := protohelpers.Skip(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protohelpers.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + m.unknownFields = append(m.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func (m *ExportResponse) UnmarshalVT(dAtA []byte) error { l := len(dAtA) iNdEx := 0 @@ -19002,6 +19352,131 @@ func (m *ExportRequest) UnmarshalVTUnsafe(dAtA []byte) error { } return nil } +func (m *ExportAsyncSearchRequest) UnmarshalVTUnsafe(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ExportAsyncSearchRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ExportAsyncSearchRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SearchId", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protohelpers.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protohelpers.ErrInvalidLength + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + var stringValue string + if intStringLen > 0 { + stringValue = unsafe.String(&dAtA[iNdEx], intStringLen) + } + m.SearchId = stringValue + iNdEx = postIndex + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Size", wireType) + } + m.Size = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Size |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Offset", wireType) + } + m.Offset = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Offset |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := protohelpers.Skip(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protohelpers.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + m.unknownFields = append(m.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func (m *ExportResponse) UnmarshalVTUnsafe(dAtA []byte) error { l := len(dAtA) iNdEx := 0 diff --git a/pkg/storeapi/store_api.pb.go b/pkg/storeapi/store_api.pb.go index 80aabf744..199096dac 100644 --- a/pkg/storeapi/store_api.pb.go +++ b/pkg/storeapi/store_api.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.36.5 -// protoc v7.35.0 +// protoc v5.29.3 // source: storeapi/store_api.proto package storeapi diff --git a/proxyapi/grpc_async_search.go b/proxyapi/grpc_async_search.go index cd58d09f2..b8c622af6 100644 --- a/proxyapi/grpc_async_search.go +++ b/proxyapi/grpc_async_search.go @@ -184,6 +184,63 @@ func (g *grpcV1) GetAsyncSearchesList( return res, nil } +type asyncExportStream struct { + ExportAsyncSearchServer + size int +} + +func (s *asyncExportStream) Send(resp *seqproxyapi.ExportResponse) error { + s.size += len(resp.GetDoc().GetData()) + len(resp.GetDoc().GetId()) + return s.ExportAsyncSearchServer.Send(resp) +} + +func (g *grpcV1) ExportAsyncSearch(req *seqproxyapi.ExportAsyncSearchRequest, stream seqproxyapi.SeqProxyApi_ExportAsyncSearchServer) error { + ctx, cancel := context.WithTimeout(stream.Context(), g.config.ExportTimeout) + defer cancel() + + if g.config.AsyncSearchMaxDocumentsPerRequest > 0 && req.Size > g.config.AsyncSearchMaxDocumentsPerRequest { + return status.Errorf(codes.InvalidArgument, "too many documents are requested: count=%d, max=%d", + req.Size, g.config.AsyncSearchMaxDocumentsPerRequest) + } + + const protocol = "grpc" + defer func(start time.Time) { + asyncsearcher.ExportDuration.WithLabelValues(protocol).Observe(float64(time.Since(start).Milliseconds())) + }(time.Now()) + + asyncsearcher.CurrentExportersCount.WithLabelValues(protocol).Inc() + defer asyncsearcher.CurrentExportersCount.WithLabelValues(protocol).Dec() + + _, docsStream, err := g.searchIngestor.FetchAsyncSearchResult(ctx, search.FetchAsyncSearchResultRequest{ + ID: req.SearchId, + Size: int(req.Size), + Offset: int(req.Offset), + }) + if err != nil { + return err + } + + wrapped := asyncExportStream{ExportAsyncSearchServer: stream} + defer func() { + asyncsearcher.ExportSize.WithLabelValues(protocol).Observe(float64(wrapped.size)) + }() + + for doc, err := docsStream.Next(); err == nil; doc, err = docsStream.Next() { + eResp := &seqproxyapi.ExportResponse{ + Doc: &seqproxyapi.Document{ + Id: doc.ID.String(), + Data: doc.Data, + Time: timestamppb.New(doc.ID.MID.Time()), + }, + } + if err = wrapped.Send(eResp); err != nil { + return status.Errorf(codes.Internal, "failed to send data: %v", err) + } + } + + return nil +} + func (g *grpcV1) CancelAsyncSearch( ctx context.Context, r *seqproxyapi.CancelAsyncSearchRequest, diff --git a/proxyapi/grpc_async_search_test.go b/proxyapi/grpc_async_search_test.go new file mode 100644 index 000000000..188a9ab71 --- /dev/null +++ b/proxyapi/grpc_async_search_test.go @@ -0,0 +1,249 @@ +package proxyapi + +import ( + "context" + "errors" + "io" + "testing" + + "github.com/golang/mock/gomock" + "github.com/stretchr/testify/require" + "go.opencensus.io/trace" + + "github.com/ozontech/seq-db/pkg/seqproxyapi/v1" + "github.com/ozontech/seq-db/proxy/search" + "github.com/ozontech/seq-db/proxyapi/mock" +) + +type exportAsyncTestCaseData struct { + searchID string + size int64 + offset int64 + + // maxDocs overrides config.AsyncSearchMaxDocumentsPerRequest; 0 means no limit. + maxDocs int64 + + noResp bool + + fetchErr error + streamSendErr bool +} + +type exportAsyncTestData struct { + req *seqproxyapi.ExportAsyncSearchRequest + want []*seqproxyapi.ExportResponse + fetch search.FetchAsyncSearchResultRequest + docs search.DocsIterator +} + +func prepareExportAsyncTestData(cData exportAsyncTestCaseData) exportAsyncTestData { + req := &seqproxyapi.ExportAsyncSearchRequest{ + SearchId: cData.searchID, + Size: cData.size, + Offset: cData.offset, + } + + var resp []*seqproxyapi.ExportResponse + var docs search.DocsIterator = search.EmptyDocsStream{} + if !cData.noResp { + sRespData := makeExportRespData(int(cData.size)) + docs = newSliceDocsStream(sRespData.ids, sRespData.docs) + resp = sRespData.resp + } + + return exportAsyncTestData{ + req: req, + want: resp, + fetch: search.FetchAsyncSearchResultRequest{ + ID: req.SearchId, + Size: int(req.Size), + Offset: int(req.Offset), + }, + docs: docs, + } +} + +func TestGrpcV1_ExportAsyncSearch(t *testing.T) { + tests := []struct { + name string + data exportAsyncTestCaseData + wantErr bool + }{ + { + name: "ok", + data: exportAsyncTestCaseData{ + searchID: "test-id-ok", + size: 10, + offset: 0, + }, + wantErr: false, + }, + { + name: "empty_docs", + data: exportAsyncTestCaseData{ + searchID: "test-id-empty", + size: 10, + offset: 0, + noResp: true, + }, + wantErr: false, + }, + { + name: "fetch_err", + data: exportAsyncTestCaseData{ + searchID: "test-id-fetch-err", + size: 10, + offset: 0, + noResp: true, + fetchErr: errors.New("test"), + }, + wantErr: true, + }, + { + name: "too_many_documents", + data: exportAsyncTestCaseData{ + searchID: "test-id-too-many", + size: 20, + offset: 0, + maxDocs: 10, + noResp: true, + }, + wantErr: true, + }, + { + name: "stream_send_err", + data: exportAsyncTestCaseData{ + searchID: "test-id-stream-send-err", + size: 10, + offset: 0, + streamSendErr: true, + }, + wantErr: true, + }, + } + + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + t.Parallel() + r := require.New(t) + + ctrl := gomock.NewController(t) + + testData := prepareExportAsyncTestData(tt.data) + a := prepareTestGrpcV1(ctrl, &mocksData{}) + a.s.config.AsyncSearchMaxDocumentsPerRequest = tt.data.maxDocs + + // FetchAsyncSearchResult is only expected when the request passes + // the size limit check. + if tt.data.maxDocs == 0 || tt.data.size <= tt.data.maxDocs { + a.m.siMock.EXPECT(). + FetchAsyncSearchResult(gomock.Any(), testData.fetch). + Return(search.FetchAsyncSearchResultResponse{}, testData.docs, tt.data.fetchErr) + } + + ctx := context.Background() + ctx, span := trace.StartSpan( + ctx, "async-export-test", trace.WithSampler(trace.AlwaysSample()), + ) + defer span.End() + + streamMock := mock.NewMockExportAsyncSearchServer(ctrl) + streamMock.EXPECT().Send(gomock.Any()).DoAndReturn( + func(_ *seqproxyapi.ExportResponse) error { + if tt.data.streamSendErr { + return errors.New("test-send-error") + } + return nil + }, + ).AnyTimes() + streamMock.EXPECT().Context().Return(ctx).AnyTimes() + + err := a.s.ExportAsyncSearch(testData.req, streamMock) + r.Equal(tt.wantErr, err != nil) + }) + } +} + +func TestGrpcV1_ExportAsyncSearchLive(t *testing.T) { + tests := []struct { + name string + data exportAsyncTestCaseData + wantErr bool + }{ + { + name: "ok", + data: exportAsyncTestCaseData{ + searchID: "test-id-ok", + size: 10, + offset: 0, + }, + wantErr: false, + }, + { + name: "empty_docs", + data: exportAsyncTestCaseData{ + searchID: "test-id-empty", + size: 10, + offset: 0, + noResp: true, + }, + wantErr: false, + }, + { + name: "fetch_err", + data: exportAsyncTestCaseData{ + searchID: "test-id-fetch-err", + size: 10, + offset: 0, + noResp: true, + fetchErr: errors.New("test"), + }, + wantErr: true, + }, + } + + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + t.Parallel() + r := require.New(t) + + ctrl := gomock.NewController(t) + + testData := prepareExportAsyncTestData(tt.data) + a := prepareTestGrpcV1(ctrl, &mocksData{}) + + a.m.siMock.EXPECT(). + FetchAsyncSearchResult(gomock.Any(), testData.fetch). + Return(search.FetchAsyncSearchResultResponse{}, testData.docs, tt.data.fetchErr) + + client, closer := runGRPCServerWithClient(a.s) + defer closer() + + out, err := client.ExportAsyncSearch(a.ctx, testData.req) + r.NoError(err) + + var recvErr error + got := make([]*seqproxyapi.ExportResponse, 0) + for { + o, err := out.Recv() + if errors.Is(err, io.EOF) { + break + } else if err != nil { + recvErr = err + break + } + got = append(got, o) + } + + r.Equal(tt.wantErr, recvErr != nil) + if tt.wantErr { + return + } + r.Equal(len(testData.want), len(got)) + for i := 0; i < len(got); i++ { + r.Equal(testData.want[i].Doc.Id, got[i].Doc.Id) + r.Equal(testData.want[i].Doc.Data, got[i].Doc.Data) + } + }) + } +} diff --git a/proxyapi/grpc_v1.go b/proxyapi/grpc_v1.go index 6946067bc..0d87ed7f1 100644 --- a/proxyapi/grpc_v1.go +++ b/proxyapi/grpc_v1.go @@ -57,6 +57,10 @@ type FetchServer interface { seqproxyapi.SeqProxyApi_FetchServer } +type ExportAsyncSearchServer interface { + seqproxyapi.SeqProxyApi_ExportAsyncSearchServer +} + type grpcV1 struct { seqproxyapi.UnimplementedSeqProxyApiServer diff --git a/proxyapi/mock/grpc_v1.go b/proxyapi/mock/grpc_v1.go index 40f1e694d..c178291fa 100644 --- a/proxyapi/mock/grpc_v1.go +++ b/proxyapi/mock/grpc_v1.go @@ -472,3 +472,122 @@ func (mr *MockFetchServerMockRecorder) SetTrailer(arg0 interface{}) *gomock.Call mr.mock.ctrl.T.Helper() return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetTrailer", reflect.TypeOf((*MockFetchServer)(nil).SetTrailer), arg0) } + +// MockExportAsyncSearchServer is a mock of ExportAsyncSearchServer interface. +type MockExportAsyncSearchServer struct { + ctrl *gomock.Controller + recorder *MockExportAsyncSearchServerMockRecorder +} + +// MockExportAsyncSearchServerMockRecorder is the mock recorder for MockExportAsyncSearchServer. +type MockExportAsyncSearchServerMockRecorder struct { + mock *MockExportAsyncSearchServer +} + +// NewMockExportAsyncSearchServer creates a new mock instance. +func NewMockExportAsyncSearchServer(ctrl *gomock.Controller) *MockExportAsyncSearchServer { + mock := &MockExportAsyncSearchServer{ctrl: ctrl} + mock.recorder = &MockExportAsyncSearchServerMockRecorder{mock} + return mock +} + +// EXPECT returns an object that allows the caller to indicate expected use. +func (m *MockExportAsyncSearchServer) EXPECT() *MockExportAsyncSearchServerMockRecorder { + return m.recorder +} + +// Context mocks base method. +func (m *MockExportAsyncSearchServer) Context() context.Context { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "Context") + ret0, _ := ret[0].(context.Context) + return ret0 +} + +// Context indicates an expected call of Context. +func (mr *MockExportAsyncSearchServerMockRecorder) Context() *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Context", reflect.TypeOf((*MockExportAsyncSearchServer)(nil).Context)) +} + +// RecvMsg mocks base method. +func (m_2 *MockExportAsyncSearchServer) RecvMsg(m any) error { + m_2.ctrl.T.Helper() + ret := m_2.ctrl.Call(m_2, "RecvMsg", m) + ret0, _ := ret[0].(error) + return ret0 +} + +// RecvMsg indicates an expected call of RecvMsg. +func (mr *MockExportAsyncSearchServerMockRecorder) RecvMsg(m interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RecvMsg", reflect.TypeOf((*MockExportAsyncSearchServer)(nil).RecvMsg), m) +} + +// Send mocks base method. +func (m *MockExportAsyncSearchServer) Send(arg0 *seqproxyapi.ExportResponse) error { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "Send", arg0) + ret0, _ := ret[0].(error) + return ret0 +} + +// Send indicates an expected call of Send. +func (mr *MockExportAsyncSearchServerMockRecorder) Send(arg0 interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Send", reflect.TypeOf((*MockExportAsyncSearchServer)(nil).Send), arg0) +} + +// SendHeader mocks base method. +func (m *MockExportAsyncSearchServer) SendHeader(arg0 metadata.MD) error { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "SendHeader", arg0) + ret0, _ := ret[0].(error) + return ret0 +} + +// SendHeader indicates an expected call of SendHeader. +func (mr *MockExportAsyncSearchServerMockRecorder) SendHeader(arg0 interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SendHeader", reflect.TypeOf((*MockExportAsyncSearchServer)(nil).SendHeader), arg0) +} + +// SendMsg mocks base method. +func (m_2 *MockExportAsyncSearchServer) SendMsg(m any) error { + m_2.ctrl.T.Helper() + ret := m_2.ctrl.Call(m_2, "SendMsg", m) + ret0, _ := ret[0].(error) + return ret0 +} + +// SendMsg indicates an expected call of SendMsg. +func (mr *MockExportAsyncSearchServerMockRecorder) SendMsg(m interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SendMsg", reflect.TypeOf((*MockExportAsyncSearchServer)(nil).SendMsg), m) +} + +// SetHeader mocks base method. +func (m *MockExportAsyncSearchServer) SetHeader(arg0 metadata.MD) error { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "SetHeader", arg0) + ret0, _ := ret[0].(error) + return ret0 +} + +// SetHeader indicates an expected call of SetHeader. +func (mr *MockExportAsyncSearchServerMockRecorder) SetHeader(arg0 interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetHeader", reflect.TypeOf((*MockExportAsyncSearchServer)(nil).SetHeader), arg0) +} + +// SetTrailer mocks base method. +func (m *MockExportAsyncSearchServer) SetTrailer(arg0 metadata.MD) { + m.ctrl.T.Helper() + m.ctrl.Call(m, "SetTrailer", arg0) +} + +// SetTrailer indicates an expected call of SetTrailer. +func (mr *MockExportAsyncSearchServerMockRecorder) SetTrailer(arg0 interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetTrailer", reflect.TypeOf((*MockExportAsyncSearchServer)(nil).SetTrailer), arg0) +}