arc_vector_rust/
arc_vector.rs

1#[allow(clippy::derive_partial_eq_without_eq)]
2#[derive(Clone, PartialEq, ::prost::Message)]
3pub struct VectorParams {
4    /// Size of the vectors
5    #[prost(uint64, tag = "1")]
6    pub size: u64,
7    /// Distance function used for comparing vectors
8    #[prost(enumeration = "Distance", tag = "2")]
9    pub distance: i32,
10    /// Configuration of vector HNSW graph. If omitted - the collection configuration will be used
11    #[prost(message, optional, tag = "3")]
12    pub hnsw_config: ::core::option::Option<HnswConfigDiff>,
13    /// Configuration of vector quantization config. If omitted - the collection configuration will be used
14    #[prost(message, optional, tag = "4")]
15    pub quantization_config: ::core::option::Option<QuantizationConfig>,
16    /// If true - serve vectors from disk. If set to false, the vectors will be loaded in RAM.
17    #[prost(bool, optional, tag = "5")]
18    pub on_disk: ::core::option::Option<bool>,
19}
20#[allow(clippy::derive_partial_eq_without_eq)]
21#[derive(Clone, PartialEq, ::prost::Message)]
22pub struct VectorParamsDiff {
23    /// Update params for HNSW index. If empty object - it will be unset
24    #[prost(message, optional, tag = "1")]
25    pub hnsw_config: ::core::option::Option<HnswConfigDiff>,
26    /// Update quantization params. If none - it is left unchanged.
27    #[prost(message, optional, tag = "2")]
28    pub quantization_config: ::core::option::Option<QuantizationConfigDiff>,
29    /// If true - serve vectors from disk. If set to false, the vectors will be loaded in RAM.
30    #[prost(bool, optional, tag = "3")]
31    pub on_disk: ::core::option::Option<bool>,
32}
33#[allow(clippy::derive_partial_eq_without_eq)]
34#[derive(Clone, PartialEq, ::prost::Message)]
35pub struct VectorParamsMap {
36    #[prost(map = "string, message", tag = "1")]
37    pub map: ::std::collections::HashMap<::prost::alloc::string::String, VectorParams>,
38}
39#[allow(clippy::derive_partial_eq_without_eq)]
40#[derive(Clone, PartialEq, ::prost::Message)]
41pub struct VectorParamsDiffMap {
42    #[prost(map = "string, message", tag = "1")]
43    pub map: ::std::collections::HashMap<
44        ::prost::alloc::string::String,
45        VectorParamsDiff,
46    >,
47}
48#[allow(clippy::derive_partial_eq_without_eq)]
49#[derive(Clone, PartialEq, ::prost::Message)]
50pub struct VectorsConfig {
51    #[prost(oneof = "vectors_config::Config", tags = "1, 2")]
52    pub config: ::core::option::Option<vectors_config::Config>,
53}
54/// Nested message and enum types in `VectorsConfig`.
55pub mod vectors_config {
56    #[allow(clippy::derive_partial_eq_without_eq)]
57    #[derive(Clone, PartialEq, ::prost::Oneof)]
58    pub enum Config {
59        #[prost(message, tag = "1")]
60        Params(super::VectorParams),
61        #[prost(message, tag = "2")]
62        ParamsMap(super::VectorParamsMap),
63    }
64}
65#[allow(clippy::derive_partial_eq_without_eq)]
66#[derive(Clone, PartialEq, ::prost::Message)]
67pub struct VectorsConfigDiff {
68    #[prost(oneof = "vectors_config_diff::Config", tags = "1, 2")]
69    pub config: ::core::option::Option<vectors_config_diff::Config>,
70}
71/// Nested message and enum types in `VectorsConfigDiff`.
72pub mod vectors_config_diff {
73    #[allow(clippy::derive_partial_eq_without_eq)]
74    #[derive(Clone, PartialEq, ::prost::Oneof)]
75    pub enum Config {
76        #[prost(message, tag = "1")]
77        Params(super::VectorParamsDiff),
78        #[prost(message, tag = "2")]
79        ParamsMap(super::VectorParamsDiffMap),
80    }
81}
82#[allow(clippy::derive_partial_eq_without_eq)]
83#[derive(Clone, PartialEq, ::prost::Message)]
84pub struct GetCollectionInfoRequest {
85    /// Name of the collection
86    #[prost(string, tag = "1")]
87    pub collection_name: ::prost::alloc::string::String,
88}
89#[allow(clippy::derive_partial_eq_without_eq)]
90#[derive(Clone, PartialEq, ::prost::Message)]
91pub struct ListCollectionsRequest {}
92#[allow(clippy::derive_partial_eq_without_eq)]
93#[derive(Clone, PartialEq, ::prost::Message)]
94pub struct CollectionDescription {
95    /// Name of the collection
96    #[prost(string, tag = "1")]
97    pub name: ::prost::alloc::string::String,
98}
99#[allow(clippy::derive_partial_eq_without_eq)]
100#[derive(Clone, PartialEq, ::prost::Message)]
101pub struct GetCollectionInfoResponse {
102    #[prost(message, optional, tag = "1")]
103    pub result: ::core::option::Option<CollectionInfo>,
104    /// Time spent to process
105    #[prost(double, tag = "2")]
106    pub time: f64,
107}
108#[allow(clippy::derive_partial_eq_without_eq)]
109#[derive(Clone, PartialEq, ::prost::Message)]
110pub struct ListCollectionsResponse {
111    #[prost(message, repeated, tag = "1")]
112    pub collections: ::prost::alloc::vec::Vec<CollectionDescription>,
113    /// Time spent to process
114    #[prost(double, tag = "2")]
115    pub time: f64,
116}
117#[allow(clippy::derive_partial_eq_without_eq)]
118#[derive(Clone, PartialEq, ::prost::Message)]
119pub struct OptimizerStatus {
120    #[prost(bool, tag = "1")]
121    pub ok: bool,
122    #[prost(string, tag = "2")]
123    pub error: ::prost::alloc::string::String,
124}
125#[allow(clippy::derive_partial_eq_without_eq)]
126#[derive(Clone, PartialEq, ::prost::Message)]
127pub struct HnswConfigDiff {
128    ///
129    /// Number of edges per node in the index graph. Larger the value - more accurate the search, more space required.
130    #[prost(uint64, optional, tag = "1")]
131    pub m: ::core::option::Option<u64>,
132    ///
133    /// Number of neighbours to consider during the index building. Larger the value - more accurate the search, more time required to build the index.
134    #[prost(uint64, optional, tag = "2")]
135    pub ef_construct: ::core::option::Option<u64>,
136    ///
137    /// Minimal size (in KiloBytes) of vectors for additional payload-based indexing.
138    /// If the payload chunk is smaller than `full_scan_threshold` additional indexing won't be used -
139    /// in this case full-scan search should be preferred by query planner and additional indexing is not required.
140    /// Note: 1 Kb = 1 vector of size 256
141    #[prost(uint64, optional, tag = "3")]
142    pub full_scan_threshold: ::core::option::Option<u64>,
143    ///
144    /// Number of parallel threads used for background index building. If 0 - auto selection.
145    #[prost(uint64, optional, tag = "4")]
146    pub max_indexing_threads: ::core::option::Option<u64>,
147    ///
148    /// Store HNSW index on disk. If set to false, the index will be stored in RAM.
149    #[prost(bool, optional, tag = "5")]
150    pub on_disk: ::core::option::Option<bool>,
151    ///
152    /// Number of additional payload-aware links per node in the index graph. If not set - regular M parameter will be used.
153    #[prost(uint64, optional, tag = "6")]
154    pub payload_m: ::core::option::Option<u64>,
155}
156#[allow(clippy::derive_partial_eq_without_eq)]
157#[derive(Clone, PartialEq, ::prost::Message)]
158pub struct WalConfigDiff {
159    /// Size of a single WAL block file
160    #[prost(uint64, optional, tag = "1")]
161    pub wal_capacity_mb: ::core::option::Option<u64>,
162    /// Number of segments to create in advance
163    #[prost(uint64, optional, tag = "2")]
164    pub wal_segments_ahead: ::core::option::Option<u64>,
165}
166#[allow(clippy::derive_partial_eq_without_eq)]
167#[derive(Clone, PartialEq, ::prost::Message)]
168pub struct OptimizersConfigDiff {
169    ///
170    /// The minimal fraction of deleted vectors in a segment, required to perform segment optimization
171    #[prost(double, optional, tag = "1")]
172    pub deleted_threshold: ::core::option::Option<f64>,
173    ///
174    /// The minimal number of vectors in a segment, required to perform segment optimization
175    #[prost(uint64, optional, tag = "2")]
176    pub vacuum_min_vector_number: ::core::option::Option<u64>,
177    ///
178    /// Target amount of segments the optimizer will try to keep.
179    /// Real amount of segments may vary depending on multiple parameters:
180    ///
181    /// - Amount of stored points.
182    /// - Current write RPS.
183    ///
184    /// It is recommended to select the default number of segments as a factor of the number of search threads,
185    /// so that each segment would be handled evenly by one of the threads.
186    #[prost(uint64, optional, tag = "3")]
187    pub default_segment_number: ::core::option::Option<u64>,
188    ///
189    /// Do not create segments larger this size (in kilobytes).
190    /// Large segments might require disproportionately long indexation times,
191    /// therefore it makes sense to limit the size of segments.
192    ///
193    /// If indexing speed is more important - make this parameter lower.
194    /// If search speed is more important - make this parameter higher.
195    /// Note: 1Kb = 1 vector of size 256
196    /// If not set, will be automatically selected considering the number of available CPUs.
197    #[prost(uint64, optional, tag = "4")]
198    pub max_segment_size: ::core::option::Option<u64>,
199    ///
200    /// Maximum size (in kilobytes) of vectors to store in-memory per segment.
201    /// Segments larger than this threshold will be stored as read-only memmaped file.
202    ///
203    /// Memmap storage is disabled by default, to enable it, set this threshold to a reasonable value.
204    ///
205    /// To disable memmap storage, set this to `0`.
206    ///
207    /// Note: 1Kb = 1 vector of size 256
208    #[prost(uint64, optional, tag = "5")]
209    pub memmap_threshold: ::core::option::Option<u64>,
210    ///
211    /// Maximum size (in kilobytes) of vectors allowed for plain index, exceeding this threshold will enable vector indexing
212    ///
213    /// Default value is 20,000, based on <<https://github.com/google-research/google-research/blob/master/scann/docs/algorithms.md>.>
214    ///
215    /// To disable vector indexing, set to `0`.
216    ///
217    /// Note: 1kB = 1 vector of size 256.
218    #[prost(uint64, optional, tag = "6")]
219    pub indexing_threshold: ::core::option::Option<u64>,
220    ///
221    /// Interval between forced flushes.
222    #[prost(uint64, optional, tag = "7")]
223    pub flush_interval_sec: ::core::option::Option<u64>,
224    ///
225    /// Max number of threads, which can be used for optimization. If 0 - `NUM_CPU - 1` will be used
226    #[prost(uint64, optional, tag = "8")]
227    pub max_optimization_threads: ::core::option::Option<u64>,
228}
229#[allow(clippy::derive_partial_eq_without_eq)]
230#[derive(Clone, PartialEq, ::prost::Message)]
231pub struct ScalarQuantization {
232    /// Type of quantization
233    #[prost(enumeration = "QuantizationType", tag = "1")]
234    pub r#type: i32,
235    /// Number of bits to use for quantization
236    #[prost(float, optional, tag = "2")]
237    pub quantile: ::core::option::Option<f32>,
238    /// If true - quantized vectors always will be stored in RAM, ignoring the config of main storage
239    #[prost(bool, optional, tag = "3")]
240    pub always_ram: ::core::option::Option<bool>,
241}
242#[allow(clippy::derive_partial_eq_without_eq)]
243#[derive(Clone, PartialEq, ::prost::Message)]
244pub struct ProductQuantization {
245    /// Compression ratio
246    #[prost(enumeration = "CompressionRatio", tag = "1")]
247    pub compression: i32,
248    /// If true - quantized vectors always will be stored in RAM, ignoring the config of main storage
249    #[prost(bool, optional, tag = "2")]
250    pub always_ram: ::core::option::Option<bool>,
251}
252#[allow(clippy::derive_partial_eq_without_eq)]
253#[derive(Clone, PartialEq, ::prost::Message)]
254pub struct QuantizationConfig {
255    #[prost(oneof = "quantization_config::Quantization", tags = "1, 2")]
256    pub quantization: ::core::option::Option<quantization_config::Quantization>,
257}
258/// Nested message and enum types in `QuantizationConfig`.
259pub mod quantization_config {
260    #[allow(clippy::derive_partial_eq_without_eq)]
261    #[derive(Clone, PartialEq, ::prost::Oneof)]
262    pub enum Quantization {
263        #[prost(message, tag = "1")]
264        Scalar(super::ScalarQuantization),
265        #[prost(message, tag = "2")]
266        Product(super::ProductQuantization),
267    }
268}
269#[allow(clippy::derive_partial_eq_without_eq)]
270#[derive(Clone, PartialEq, ::prost::Message)]
271pub struct Disabled {}
272#[allow(clippy::derive_partial_eq_without_eq)]
273#[derive(Clone, PartialEq, ::prost::Message)]
274pub struct QuantizationConfigDiff {
275    #[prost(oneof = "quantization_config_diff::Quantization", tags = "1, 2, 3")]
276    pub quantization: ::core::option::Option<quantization_config_diff::Quantization>,
277}
278/// Nested message and enum types in `QuantizationConfigDiff`.
279pub mod quantization_config_diff {
280    #[allow(clippy::derive_partial_eq_without_eq)]
281    #[derive(Clone, PartialEq, ::prost::Oneof)]
282    pub enum Quantization {
283        #[prost(message, tag = "1")]
284        Scalar(super::ScalarQuantization),
285        #[prost(message, tag = "2")]
286        Product(super::ProductQuantization),
287        #[prost(message, tag = "3")]
288        Disabled(super::Disabled),
289    }
290}
291#[allow(clippy::derive_partial_eq_without_eq)]
292#[derive(Clone, PartialEq, ::prost::Message)]
293pub struct CreateCollection {
294    /// Name of the collection
295    #[prost(string, tag = "1")]
296    pub collection_name: ::prost::alloc::string::String,
297    /// Configuration of vector index
298    #[prost(message, optional, tag = "4")]
299    pub hnsw_config: ::core::option::Option<HnswConfigDiff>,
300    /// Configuration of the Write-Ahead-Log
301    #[prost(message, optional, tag = "5")]
302    pub wal_config: ::core::option::Option<WalConfigDiff>,
303    /// Configuration of the optimizers
304    #[prost(message, optional, tag = "6")]
305    pub optimizers_config: ::core::option::Option<OptimizersConfigDiff>,
306    /// Number of shards in the collection, default is 1 for standalone, otherwise equal to the number of nodes. Minimum is 1
307    #[prost(uint32, optional, tag = "7")]
308    pub shard_number: ::core::option::Option<u32>,
309    /// If true - point's payload will not be stored in memory
310    #[prost(bool, optional, tag = "8")]
311    pub on_disk_payload: ::core::option::Option<bool>,
312    /// Wait timeout for operation commit in seconds, if not specified - default value will be supplied
313    #[prost(uint64, optional, tag = "9")]
314    pub timeout: ::core::option::Option<u64>,
315    /// Configuration for vectors
316    #[prost(message, optional, tag = "10")]
317    pub vectors_config: ::core::option::Option<VectorsConfig>,
318    /// Number of replicas of each shard that network tries to maintain, default = 1
319    #[prost(uint32, optional, tag = "11")]
320    pub replication_factor: ::core::option::Option<u32>,
321    /// How many replicas should apply the operation for us to consider it successful, default = 1
322    #[prost(uint32, optional, tag = "12")]
323    pub write_consistency_factor: ::core::option::Option<u32>,
324    /// Specify name of the other collection to copy data from
325    #[prost(string, optional, tag = "13")]
326    pub init_from_collection: ::core::option::Option<::prost::alloc::string::String>,
327    /// Quantization configuration of vector
328    #[prost(message, optional, tag = "14")]
329    pub quantization_config: ::core::option::Option<QuantizationConfig>,
330}
331#[allow(clippy::derive_partial_eq_without_eq)]
332#[derive(Clone, PartialEq, ::prost::Message)]
333pub struct UpdateCollection {
334    /// Name of the collection
335    #[prost(string, tag = "1")]
336    pub collection_name: ::prost::alloc::string::String,
337    /// New configuration parameters for the collection. This operation is blocking, it will only proceed once all current optimizations are complete
338    #[prost(message, optional, tag = "2")]
339    pub optimizers_config: ::core::option::Option<OptimizersConfigDiff>,
340    /// Wait timeout for operation commit in seconds if blocking, if not specified - default value will be supplied
341    #[prost(uint64, optional, tag = "3")]
342    pub timeout: ::core::option::Option<u64>,
343    /// New configuration parameters for the collection
344    #[prost(message, optional, tag = "4")]
345    pub params: ::core::option::Option<CollectionParamsDiff>,
346    /// New HNSW parameters for the collection index
347    #[prost(message, optional, tag = "5")]
348    pub hnsw_config: ::core::option::Option<HnswConfigDiff>,
349    /// New vector parameters
350    #[prost(message, optional, tag = "6")]
351    pub vectors_config: ::core::option::Option<VectorsConfigDiff>,
352    /// Quantization configuration of vector
353    #[prost(message, optional, tag = "7")]
354    pub quantization_config: ::core::option::Option<QuantizationConfigDiff>,
355}
356#[allow(clippy::derive_partial_eq_without_eq)]
357#[derive(Clone, PartialEq, ::prost::Message)]
358pub struct DeleteCollection {
359    /// Name of the collection
360    #[prost(string, tag = "1")]
361    pub collection_name: ::prost::alloc::string::String,
362    /// Wait timeout for operation commit in seconds, if not specified - default value will be supplied
363    #[prost(uint64, optional, tag = "2")]
364    pub timeout: ::core::option::Option<u64>,
365}
366#[allow(clippy::derive_partial_eq_without_eq)]
367#[derive(Clone, PartialEq, ::prost::Message)]
368pub struct CollectionOperationResponse {
369    /// if operation made changes
370    #[prost(bool, tag = "1")]
371    pub result: bool,
372    /// Time spent to process
373    #[prost(double, tag = "2")]
374    pub time: f64,
375}
376#[allow(clippy::derive_partial_eq_without_eq)]
377#[derive(Clone, PartialEq, ::prost::Message)]
378pub struct CollectionParams {
379    /// Number of shards in collection
380    #[prost(uint32, tag = "3")]
381    pub shard_number: u32,
382    /// If true - point's payload will not be stored in memory
383    #[prost(bool, tag = "4")]
384    pub on_disk_payload: bool,
385    /// Configuration for vectors
386    #[prost(message, optional, tag = "5")]
387    pub vectors_config: ::core::option::Option<VectorsConfig>,
388    /// Number of replicas of each shard that network tries to maintain
389    #[prost(uint32, optional, tag = "6")]
390    pub replication_factor: ::core::option::Option<u32>,
391    /// How many replicas should apply the operation for us to consider it successful
392    #[prost(uint32, optional, tag = "7")]
393    pub write_consistency_factor: ::core::option::Option<u32>,
394}
395#[allow(clippy::derive_partial_eq_without_eq)]
396#[derive(Clone, PartialEq, ::prost::Message)]
397pub struct CollectionParamsDiff {
398    /// Number of replicas of each shard that network tries to maintain
399    #[prost(uint32, optional, tag = "1")]
400    pub replication_factor: ::core::option::Option<u32>,
401    /// How many replicas should apply the operation for us to consider it successful
402    #[prost(uint32, optional, tag = "2")]
403    pub write_consistency_factor: ::core::option::Option<u32>,
404    /// If true - point's payload will not be stored in memory
405    #[prost(bool, optional, tag = "3")]
406    pub on_disk_payload: ::core::option::Option<bool>,
407}
408#[allow(clippy::derive_partial_eq_without_eq)]
409#[derive(Clone, PartialEq, ::prost::Message)]
410pub struct CollectionConfig {
411    /// Collection parameters
412    #[prost(message, optional, tag = "1")]
413    pub params: ::core::option::Option<CollectionParams>,
414    /// Configuration of vector index
415    #[prost(message, optional, tag = "2")]
416    pub hnsw_config: ::core::option::Option<HnswConfigDiff>,
417    /// Configuration of the optimizers
418    #[prost(message, optional, tag = "3")]
419    pub optimizer_config: ::core::option::Option<OptimizersConfigDiff>,
420    /// Configuration of the Write-Ahead-Log
421    #[prost(message, optional, tag = "4")]
422    pub wal_config: ::core::option::Option<WalConfigDiff>,
423    /// Configuration of the vector quantization
424    #[prost(message, optional, tag = "5")]
425    pub quantization_config: ::core::option::Option<QuantizationConfig>,
426}
427#[allow(clippy::derive_partial_eq_without_eq)]
428#[derive(Clone, PartialEq, ::prost::Message)]
429pub struct TextIndexParams {
430    /// Tokenizer type
431    #[prost(enumeration = "TokenizerType", tag = "1")]
432    pub tokenizer: i32,
433    /// If true - all tokens will be lowercase
434    #[prost(bool, optional, tag = "2")]
435    pub lowercase: ::core::option::Option<bool>,
436    /// Minimal token length
437    #[prost(uint64, optional, tag = "3")]
438    pub min_token_len: ::core::option::Option<u64>,
439    /// Maximal token length
440    #[prost(uint64, optional, tag = "4")]
441    pub max_token_len: ::core::option::Option<u64>,
442}
443#[allow(clippy::derive_partial_eq_without_eq)]
444#[derive(Clone, PartialEq, ::prost::Message)]
445pub struct PayloadIndexParams {
446    #[prost(oneof = "payload_index_params::IndexParams", tags = "1")]
447    pub index_params: ::core::option::Option<payload_index_params::IndexParams>,
448}
449/// Nested message and enum types in `PayloadIndexParams`.
450pub mod payload_index_params {
451    #[allow(clippy::derive_partial_eq_without_eq)]
452    #[derive(Clone, PartialEq, ::prost::Oneof)]
453    pub enum IndexParams {
454        /// Parameters for text index
455        #[prost(message, tag = "1")]
456        TextIndexParams(super::TextIndexParams),
457    }
458}
459#[allow(clippy::derive_partial_eq_without_eq)]
460#[derive(Clone, PartialEq, ::prost::Message)]
461pub struct PayloadSchemaInfo {
462    /// Field data type
463    #[prost(enumeration = "PayloadSchemaType", tag = "1")]
464    pub data_type: i32,
465    /// Field index parameters
466    #[prost(message, optional, tag = "2")]
467    pub params: ::core::option::Option<PayloadIndexParams>,
468    /// Number of points indexed within this field indexed
469    #[prost(uint64, optional, tag = "3")]
470    pub points: ::core::option::Option<u64>,
471}
472#[allow(clippy::derive_partial_eq_without_eq)]
473#[derive(Clone, PartialEq, ::prost::Message)]
474pub struct CollectionInfo {
475    /// operating condition of the collection
476    #[prost(enumeration = "CollectionStatus", tag = "1")]
477    pub status: i32,
478    /// status of collection optimizers
479    #[prost(message, optional, tag = "2")]
480    pub optimizer_status: ::core::option::Option<OptimizerStatus>,
481    /// number of vectors in the collection
482    #[prost(uint64, tag = "3")]
483    pub vectors_count: u64,
484    /// Number of independent segments
485    #[prost(uint64, tag = "4")]
486    pub segments_count: u64,
487    /// Configuration
488    #[prost(message, optional, tag = "7")]
489    pub config: ::core::option::Option<CollectionConfig>,
490    /// Collection data types
491    #[prost(map = "string, message", tag = "8")]
492    pub payload_schema: ::std::collections::HashMap<
493        ::prost::alloc::string::String,
494        PayloadSchemaInfo,
495    >,
496    /// number of points in the collection
497    #[prost(uint64, tag = "9")]
498    pub points_count: u64,
499    /// number of indexed vectors in the collection.
500    #[prost(uint64, optional, tag = "10")]
501    pub indexed_vectors_count: ::core::option::Option<u64>,
502}
503#[allow(clippy::derive_partial_eq_without_eq)]
504#[derive(Clone, PartialEq, ::prost::Message)]
505pub struct ChangeAliases {
506    /// List of actions
507    #[prost(message, repeated, tag = "1")]
508    pub actions: ::prost::alloc::vec::Vec<AliasOperations>,
509    /// Wait timeout for operation commit in seconds, if not specified - default value will be supplied
510    #[prost(uint64, optional, tag = "2")]
511    pub timeout: ::core::option::Option<u64>,
512}
513#[allow(clippy::derive_partial_eq_without_eq)]
514#[derive(Clone, PartialEq, ::prost::Message)]
515pub struct AliasOperations {
516    #[prost(oneof = "alias_operations::Action", tags = "1, 2, 3")]
517    pub action: ::core::option::Option<alias_operations::Action>,
518}
519/// Nested message and enum types in `AliasOperations`.
520pub mod alias_operations {
521    #[allow(clippy::derive_partial_eq_without_eq)]
522    #[derive(Clone, PartialEq, ::prost::Oneof)]
523    pub enum Action {
524        #[prost(message, tag = "1")]
525        CreateAlias(super::CreateAlias),
526        #[prost(message, tag = "2")]
527        RenameAlias(super::RenameAlias),
528        #[prost(message, tag = "3")]
529        DeleteAlias(super::DeleteAlias),
530    }
531}
532#[allow(clippy::derive_partial_eq_without_eq)]
533#[derive(Clone, PartialEq, ::prost::Message)]
534pub struct CreateAlias {
535    /// Name of the collection
536    #[prost(string, tag = "1")]
537    pub collection_name: ::prost::alloc::string::String,
538    /// New name of the alias
539    #[prost(string, tag = "2")]
540    pub alias_name: ::prost::alloc::string::String,
541}
542#[allow(clippy::derive_partial_eq_without_eq)]
543#[derive(Clone, PartialEq, ::prost::Message)]
544pub struct RenameAlias {
545    /// Name of the alias to rename
546    #[prost(string, tag = "1")]
547    pub old_alias_name: ::prost::alloc::string::String,
548    /// Name of the alias
549    #[prost(string, tag = "2")]
550    pub new_alias_name: ::prost::alloc::string::String,
551}
552#[allow(clippy::derive_partial_eq_without_eq)]
553#[derive(Clone, PartialEq, ::prost::Message)]
554pub struct DeleteAlias {
555    /// Name of the alias
556    #[prost(string, tag = "1")]
557    pub alias_name: ::prost::alloc::string::String,
558}
559#[allow(clippy::derive_partial_eq_without_eq)]
560#[derive(Clone, PartialEq, ::prost::Message)]
561pub struct ListAliasesRequest {}
562#[allow(clippy::derive_partial_eq_without_eq)]
563#[derive(Clone, PartialEq, ::prost::Message)]
564pub struct ListCollectionAliasesRequest {
565    /// Name of the collection
566    #[prost(string, tag = "1")]
567    pub collection_name: ::prost::alloc::string::String,
568}
569#[allow(clippy::derive_partial_eq_without_eq)]
570#[derive(Clone, PartialEq, ::prost::Message)]
571pub struct AliasDescription {
572    /// Name of the alias
573    #[prost(string, tag = "1")]
574    pub alias_name: ::prost::alloc::string::String,
575    /// Name of the collection
576    #[prost(string, tag = "2")]
577    pub collection_name: ::prost::alloc::string::String,
578}
579#[allow(clippy::derive_partial_eq_without_eq)]
580#[derive(Clone, PartialEq, ::prost::Message)]
581pub struct ListAliasesResponse {
582    #[prost(message, repeated, tag = "1")]
583    pub aliases: ::prost::alloc::vec::Vec<AliasDescription>,
584    /// Time spent to process
585    #[prost(double, tag = "2")]
586    pub time: f64,
587}
588#[allow(clippy::derive_partial_eq_without_eq)]
589#[derive(Clone, PartialEq, ::prost::Message)]
590pub struct CollectionClusterInfoRequest {
591    /// Name of the collection
592    #[prost(string, tag = "1")]
593    pub collection_name: ::prost::alloc::string::String,
594}
595#[allow(clippy::derive_partial_eq_without_eq)]
596#[derive(Clone, PartialEq, ::prost::Message)]
597pub struct LocalShardInfo {
598    /// Local shard id
599    #[prost(uint32, tag = "1")]
600    pub shard_id: u32,
601    /// Number of points in the shard
602    #[prost(uint64, tag = "2")]
603    pub points_count: u64,
604    /// Is replica active
605    #[prost(enumeration = "ReplicaState", tag = "3")]
606    pub state: i32,
607}
608#[allow(clippy::derive_partial_eq_without_eq)]
609#[derive(Clone, PartialEq, ::prost::Message)]
610pub struct RemoteShardInfo {
611    /// Local shard id
612    #[prost(uint32, tag = "1")]
613    pub shard_id: u32,
614    /// Remote peer id
615    #[prost(uint64, tag = "2")]
616    pub peer_id: u64,
617    /// Is replica active
618    #[prost(enumeration = "ReplicaState", tag = "3")]
619    pub state: i32,
620}
621#[allow(clippy::derive_partial_eq_without_eq)]
622#[derive(Clone, PartialEq, ::prost::Message)]
623pub struct ShardTransferInfo {
624    /// Local shard id
625    #[prost(uint32, tag = "1")]
626    pub shard_id: u32,
627    #[prost(uint64, tag = "2")]
628    pub from: u64,
629    #[prost(uint64, tag = "3")]
630    pub to: u64,
631    /// If `true` transfer is a synchronization of a replicas; If `false` transfer is a moving of a shard from one peer to another
632    #[prost(bool, tag = "4")]
633    pub sync: bool,
634}
635#[allow(clippy::derive_partial_eq_without_eq)]
636#[derive(Clone, PartialEq, ::prost::Message)]
637pub struct CollectionClusterInfoResponse {
638    /// ID of this peer
639    #[prost(uint64, tag = "1")]
640    pub peer_id: u64,
641    /// Total number of shards
642    #[prost(uint64, tag = "2")]
643    pub shard_count: u64,
644    /// Local shards
645    #[prost(message, repeated, tag = "3")]
646    pub local_shards: ::prost::alloc::vec::Vec<LocalShardInfo>,
647    /// Remote shards
648    #[prost(message, repeated, tag = "4")]
649    pub remote_shards: ::prost::alloc::vec::Vec<RemoteShardInfo>,
650    /// Shard transfers
651    #[prost(message, repeated, tag = "5")]
652    pub shard_transfers: ::prost::alloc::vec::Vec<ShardTransferInfo>,
653}
654#[allow(clippy::derive_partial_eq_without_eq)]
655#[derive(Clone, PartialEq, ::prost::Message)]
656pub struct MoveShard {
657    /// Local shard id
658    #[prost(uint32, tag = "1")]
659    pub shard_id: u32,
660    #[prost(uint64, tag = "2")]
661    pub from_peer_id: u64,
662    #[prost(uint64, tag = "3")]
663    pub to_peer_id: u64,
664}
665#[allow(clippy::derive_partial_eq_without_eq)]
666#[derive(Clone, PartialEq, ::prost::Message)]
667pub struct Replica {
668    #[prost(uint32, tag = "1")]
669    pub shard_id: u32,
670    #[prost(uint64, tag = "2")]
671    pub peer_id: u64,
672}
673#[allow(clippy::derive_partial_eq_without_eq)]
674#[derive(Clone, PartialEq, ::prost::Message)]
675pub struct UpdateCollectionClusterSetupRequest {
676    /// Name of the collection
677    #[prost(string, tag = "1")]
678    pub collection_name: ::prost::alloc::string::String,
679    /// Wait timeout for operation commit in seconds, if not specified - default value will be supplied
680    #[prost(uint64, optional, tag = "6")]
681    pub timeout: ::core::option::Option<u64>,
682    #[prost(
683        oneof = "update_collection_cluster_setup_request::Operation",
684        tags = "2, 3, 4, 5"
685    )]
686    pub operation: ::core::option::Option<
687        update_collection_cluster_setup_request::Operation,
688    >,
689}
690/// Nested message and enum types in `UpdateCollectionClusterSetupRequest`.
691pub mod update_collection_cluster_setup_request {
692    #[allow(clippy::derive_partial_eq_without_eq)]
693    #[derive(Clone, PartialEq, ::prost::Oneof)]
694    pub enum Operation {
695        #[prost(message, tag = "2")]
696        MoveShard(super::MoveShard),
697        #[prost(message, tag = "3")]
698        ReplicateShard(super::MoveShard),
699        #[prost(message, tag = "4")]
700        AbortTransfer(super::MoveShard),
701        #[prost(message, tag = "5")]
702        DropReplica(super::Replica),
703    }
704}
705#[allow(clippy::derive_partial_eq_without_eq)]
706#[derive(Clone, PartialEq, ::prost::Message)]
707pub struct UpdateCollectionClusterSetupResponse {
708    #[prost(bool, tag = "1")]
709    pub result: bool,
710}
711#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
712#[repr(i32)]
713pub enum Distance {
714    UnknownDistance = 0,
715    Cosine = 1,
716    Euclid = 2,
717    Dot = 3,
718}
719impl Distance {
720    /// String value of the enum field names used in the ProtoBuf definition.
721    ///
722    /// The values are not transformed in any way and thus are considered stable
723    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
724    pub fn as_str_name(&self) -> &'static str {
725        match self {
726            Distance::UnknownDistance => "UnknownDistance",
727            Distance::Cosine => "Cosine",
728            Distance::Euclid => "Euclid",
729            Distance::Dot => "Dot",
730        }
731    }
732    /// Creates an enum from field names used in the ProtoBuf definition.
733    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
734        match value {
735            "UnknownDistance" => Some(Self::UnknownDistance),
736            "Cosine" => Some(Self::Cosine),
737            "Euclid" => Some(Self::Euclid),
738            "Dot" => Some(Self::Dot),
739            _ => None,
740        }
741    }
742}
743#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
744#[repr(i32)]
745pub enum CollectionStatus {
746    UnknownCollectionStatus = 0,
747    /// All segments are ready
748    Green = 1,
749    /// Optimization in process
750    Yellow = 2,
751    /// Something went wrong
752    Red = 3,
753}
754impl CollectionStatus {
755    /// String value of the enum field names used in the ProtoBuf definition.
756    ///
757    /// The values are not transformed in any way and thus are considered stable
758    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
759    pub fn as_str_name(&self) -> &'static str {
760        match self {
761            CollectionStatus::UnknownCollectionStatus => "UnknownCollectionStatus",
762            CollectionStatus::Green => "Green",
763            CollectionStatus::Yellow => "Yellow",
764            CollectionStatus::Red => "Red",
765        }
766    }
767    /// Creates an enum from field names used in the ProtoBuf definition.
768    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
769        match value {
770            "UnknownCollectionStatus" => Some(Self::UnknownCollectionStatus),
771            "Green" => Some(Self::Green),
772            "Yellow" => Some(Self::Yellow),
773            "Red" => Some(Self::Red),
774            _ => None,
775        }
776    }
777}
778#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
779#[repr(i32)]
780pub enum PayloadSchemaType {
781    UnknownType = 0,
782    Keyword = 1,
783    Integer = 2,
784    Float = 3,
785    Geo = 4,
786    Text = 5,
787    Bool = 6,
788}
789impl PayloadSchemaType {
790    /// String value of the enum field names used in the ProtoBuf definition.
791    ///
792    /// The values are not transformed in any way and thus are considered stable
793    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
794    pub fn as_str_name(&self) -> &'static str {
795        match self {
796            PayloadSchemaType::UnknownType => "UnknownType",
797            PayloadSchemaType::Keyword => "Keyword",
798            PayloadSchemaType::Integer => "Integer",
799            PayloadSchemaType::Float => "Float",
800            PayloadSchemaType::Geo => "Geo",
801            PayloadSchemaType::Text => "Text",
802            PayloadSchemaType::Bool => "Bool",
803        }
804    }
805    /// Creates an enum from field names used in the ProtoBuf definition.
806    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
807        match value {
808            "UnknownType" => Some(Self::UnknownType),
809            "Keyword" => Some(Self::Keyword),
810            "Integer" => Some(Self::Integer),
811            "Float" => Some(Self::Float),
812            "Geo" => Some(Self::Geo),
813            "Text" => Some(Self::Text),
814            "Bool" => Some(Self::Bool),
815            _ => None,
816        }
817    }
818}
819#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
820#[repr(i32)]
821pub enum QuantizationType {
822    UnknownQuantization = 0,
823    Int8 = 1,
824}
825impl QuantizationType {
826    /// String value of the enum field names used in the ProtoBuf definition.
827    ///
828    /// The values are not transformed in any way and thus are considered stable
829    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
830    pub fn as_str_name(&self) -> &'static str {
831        match self {
832            QuantizationType::UnknownQuantization => "UnknownQuantization",
833            QuantizationType::Int8 => "Int8",
834        }
835    }
836    /// Creates an enum from field names used in the ProtoBuf definition.
837    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
838        match value {
839            "UnknownQuantization" => Some(Self::UnknownQuantization),
840            "Int8" => Some(Self::Int8),
841            _ => None,
842        }
843    }
844}
845#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
846#[repr(i32)]
847pub enum CompressionRatio {
848    X4 = 0,
849    X8 = 1,
850    X16 = 2,
851    X32 = 3,
852    X64 = 4,
853}
854impl CompressionRatio {
855    /// String value of the enum field names used in the ProtoBuf definition.
856    ///
857    /// The values are not transformed in any way and thus are considered stable
858    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
859    pub fn as_str_name(&self) -> &'static str {
860        match self {
861            CompressionRatio::X4 => "x4",
862            CompressionRatio::X8 => "x8",
863            CompressionRatio::X16 => "x16",
864            CompressionRatio::X32 => "x32",
865            CompressionRatio::X64 => "x64",
866        }
867    }
868    /// Creates an enum from field names used in the ProtoBuf definition.
869    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
870        match value {
871            "x4" => Some(Self::X4),
872            "x8" => Some(Self::X8),
873            "x16" => Some(Self::X16),
874            "x32" => Some(Self::X32),
875            "x64" => Some(Self::X64),
876            _ => None,
877        }
878    }
879}
880#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
881#[repr(i32)]
882pub enum TokenizerType {
883    Unknown = 0,
884    Prefix = 1,
885    Whitespace = 2,
886    Word = 3,
887    Multilingual = 4,
888}
889impl TokenizerType {
890    /// String value of the enum field names used in the ProtoBuf definition.
891    ///
892    /// The values are not transformed in any way and thus are considered stable
893    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
894    pub fn as_str_name(&self) -> &'static str {
895        match self {
896            TokenizerType::Unknown => "Unknown",
897            TokenizerType::Prefix => "Prefix",
898            TokenizerType::Whitespace => "Whitespace",
899            TokenizerType::Word => "Word",
900            TokenizerType::Multilingual => "Multilingual",
901        }
902    }
903    /// Creates an enum from field names used in the ProtoBuf definition.
904    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
905        match value {
906            "Unknown" => Some(Self::Unknown),
907            "Prefix" => Some(Self::Prefix),
908            "Whitespace" => Some(Self::Whitespace),
909            "Word" => Some(Self::Word),
910            "Multilingual" => Some(Self::Multilingual),
911            _ => None,
912        }
913    }
914}
915#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
916#[repr(i32)]
917pub enum ReplicaState {
918    /// Active and sound
919    Active = 0,
920    /// Failed for some reason
921    Dead = 1,
922    /// The shard is partially loaded and is currently receiving data from other shards
923    Partial = 2,
924    /// Collection is being created
925    Initializing = 3,
926    /// A shard which receives data, but is not used for search; Useful for backup shards
927    Listener = 4,
928}
929impl ReplicaState {
930    /// String value of the enum field names used in the ProtoBuf definition.
931    ///
932    /// The values are not transformed in any way and thus are considered stable
933    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
934    pub fn as_str_name(&self) -> &'static str {
935        match self {
936            ReplicaState::Active => "Active",
937            ReplicaState::Dead => "Dead",
938            ReplicaState::Partial => "Partial",
939            ReplicaState::Initializing => "Initializing",
940            ReplicaState::Listener => "Listener",
941        }
942    }
943    /// Creates an enum from field names used in the ProtoBuf definition.
944    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
945        match value {
946            "Active" => Some(Self::Active),
947            "Dead" => Some(Self::Dead),
948            "Partial" => Some(Self::Partial),
949            "Initializing" => Some(Self::Initializing),
950            "Listener" => Some(Self::Listener),
951            _ => None,
952        }
953    }
954}
955/// Generated client implementations.
956pub mod collections_client {
957    #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)]
958    use tonic::codegen::*;
959    use tonic::codegen::http::Uri;
960    #[derive(Debug, Clone)]
961    pub struct CollectionsClient<T> {
962        inner: tonic::client::Grpc<T>,
963    }
964    impl CollectionsClient<tonic::transport::Channel> {
965        /// Attempt to create a new client by connecting to a given endpoint.
966        pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
967        where
968            D: TryInto<tonic::transport::Endpoint>,
969            D::Error: Into<StdError>,
970        {
971            let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
972            Ok(Self::new(conn))
973        }
974    }
975    impl<T> CollectionsClient<T>
976    where
977        T: tonic::client::GrpcService<tonic::body::BoxBody>,
978        T::Error: Into<StdError>,
979        T::ResponseBody: Body<Data = Bytes> + Send + 'static,
980        <T::ResponseBody as Body>::Error: Into<StdError> + Send,
981    {
982        pub fn new(inner: T) -> Self {
983            let inner = tonic::client::Grpc::new(inner);
984            Self { inner }
985        }
986        pub fn with_origin(inner: T, origin: Uri) -> Self {
987            let inner = tonic::client::Grpc::with_origin(inner, origin);
988            Self { inner }
989        }
990        pub fn with_interceptor<F>(
991            inner: T,
992            interceptor: F,
993        ) -> CollectionsClient<InterceptedService<T, F>>
994        where
995            F: tonic::service::Interceptor,
996            T::ResponseBody: Default,
997            T: tonic::codegen::Service<
998                http::Request<tonic::body::BoxBody>,
999                Response = http::Response<
1000                    <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
1001                >,
1002            >,
1003            <T as tonic::codegen::Service<
1004                http::Request<tonic::body::BoxBody>,
1005            >>::Error: Into<StdError> + Send + Sync,
1006        {
1007            CollectionsClient::new(InterceptedService::new(inner, interceptor))
1008        }
1009        /// Compress requests with the given encoding.
1010        ///
1011        /// This requires the server to support it otherwise it might respond with an
1012        /// error.
1013        #[must_use]
1014        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
1015            self.inner = self.inner.send_compressed(encoding);
1016            self
1017        }
1018        /// Enable decompressing responses.
1019        #[must_use]
1020        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
1021            self.inner = self.inner.accept_compressed(encoding);
1022            self
1023        }
1024        /// Limits the maximum size of a decoded message.
1025        ///
1026        /// Default: `4MB`
1027        #[must_use]
1028        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
1029            self.inner = self.inner.max_decoding_message_size(limit);
1030            self
1031        }
1032        /// Limits the maximum size of an encoded message.
1033        ///
1034        /// Default: `usize::MAX`
1035        #[must_use]
1036        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
1037            self.inner = self.inner.max_encoding_message_size(limit);
1038            self
1039        }
1040        ///
1041        /// Get detailed information about specified existing collection
1042        pub async fn get(
1043            &mut self,
1044            request: impl tonic::IntoRequest<super::GetCollectionInfoRequest>,
1045        ) -> std::result::Result<
1046            tonic::Response<super::GetCollectionInfoResponse>,
1047            tonic::Status,
1048        > {
1049            self.inner
1050                .ready()
1051                .await
1052                .map_err(|e| {
1053                    tonic::Status::new(
1054                        tonic::Code::Unknown,
1055                        format!("Service was not ready: {}", e.into()),
1056                    )
1057                })?;
1058            let codec = tonic::codec::ProstCodec::default();
1059            let path = http::uri::PathAndQuery::from_static("/arc_vector.Collections/Get");
1060            let mut req = request.into_request();
1061            req.extensions_mut().insert(GrpcMethod::new("arc_vector.Collections", "Get"));
1062            self.inner.unary(req, path, codec).await
1063        }
1064        ///
1065        /// Get list name of all existing collections
1066        pub async fn list(
1067            &mut self,
1068            request: impl tonic::IntoRequest<super::ListCollectionsRequest>,
1069        ) -> std::result::Result<
1070            tonic::Response<super::ListCollectionsResponse>,
1071            tonic::Status,
1072        > {
1073            self.inner
1074                .ready()
1075                .await
1076                .map_err(|e| {
1077                    tonic::Status::new(
1078                        tonic::Code::Unknown,
1079                        format!("Service was not ready: {}", e.into()),
1080                    )
1081                })?;
1082            let codec = tonic::codec::ProstCodec::default();
1083            let path = http::uri::PathAndQuery::from_static("/arc_vector.Collections/List");
1084            let mut req = request.into_request();
1085            req.extensions_mut().insert(GrpcMethod::new("arc_vector.Collections", "List"));
1086            self.inner.unary(req, path, codec).await
1087        }
1088        ///
1089        /// Create new collection with given parameters
1090        pub async fn create(
1091            &mut self,
1092            request: impl tonic::IntoRequest<super::CreateCollection>,
1093        ) -> std::result::Result<
1094            tonic::Response<super::CollectionOperationResponse>,
1095            tonic::Status,
1096        > {
1097            self.inner
1098                .ready()
1099                .await
1100                .map_err(|e| {
1101                    tonic::Status::new(
1102                        tonic::Code::Unknown,
1103                        format!("Service was not ready: {}", e.into()),
1104                    )
1105                })?;
1106            let codec = tonic::codec::ProstCodec::default();
1107            let path = http::uri::PathAndQuery::from_static(
1108                "/arc_vector.Collections/Create",
1109            );
1110            let mut req = request.into_request();
1111            req.extensions_mut().insert(GrpcMethod::new("arc_vector.Collections", "Create"));
1112            self.inner.unary(req, path, codec).await
1113        }
1114        ///
1115        /// Update parameters of the existing collection
1116        pub async fn update(
1117            &mut self,
1118            request: impl tonic::IntoRequest<super::UpdateCollection>,
1119        ) -> std::result::Result<
1120            tonic::Response<super::CollectionOperationResponse>,
1121            tonic::Status,
1122        > {
1123            self.inner
1124                .ready()
1125                .await
1126                .map_err(|e| {
1127                    tonic::Status::new(
1128                        tonic::Code::Unknown,
1129                        format!("Service was not ready: {}", e.into()),
1130                    )
1131                })?;
1132            let codec = tonic::codec::ProstCodec::default();
1133            let path = http::uri::PathAndQuery::from_static(
1134                "/arc_vector.Collections/Update",
1135            );
1136            let mut req = request.into_request();
1137            req.extensions_mut().insert(GrpcMethod::new("arc_vector.Collections", "Update"));
1138            self.inner.unary(req, path, codec).await
1139        }
1140        ///
1141        /// Drop collection and all associated data
1142        pub async fn delete(
1143            &mut self,
1144            request: impl tonic::IntoRequest<super::DeleteCollection>,
1145        ) -> std::result::Result<
1146            tonic::Response<super::CollectionOperationResponse>,
1147            tonic::Status,
1148        > {
1149            self.inner
1150                .ready()
1151                .await
1152                .map_err(|e| {
1153                    tonic::Status::new(
1154                        tonic::Code::Unknown,
1155                        format!("Service was not ready: {}", e.into()),
1156                    )
1157                })?;
1158            let codec = tonic::codec::ProstCodec::default();
1159            let path = http::uri::PathAndQuery::from_static(
1160                "/arc_vector.Collections/Delete",
1161            );
1162            let mut req = request.into_request();
1163            req.extensions_mut().insert(GrpcMethod::new("arc_vector.Collections", "Delete"));
1164            self.inner.unary(req, path, codec).await
1165        }
1166        ///
1167        /// Update Aliases of the existing collection
1168        pub async fn update_aliases(
1169            &mut self,
1170            request: impl tonic::IntoRequest<super::ChangeAliases>,
1171        ) -> std::result::Result<
1172            tonic::Response<super::CollectionOperationResponse>,
1173            tonic::Status,
1174        > {
1175            self.inner
1176                .ready()
1177                .await
1178                .map_err(|e| {
1179                    tonic::Status::new(
1180                        tonic::Code::Unknown,
1181                        format!("Service was not ready: {}", e.into()),
1182                    )
1183                })?;
1184            let codec = tonic::codec::ProstCodec::default();
1185            let path = http::uri::PathAndQuery::from_static(
1186                "/arc_vector.Collections/UpdateAliases",
1187            );
1188            let mut req = request.into_request();
1189            req.extensions_mut()
1190                .insert(GrpcMethod::new("arc_vector.Collections", "UpdateAliases"));
1191            self.inner.unary(req, path, codec).await
1192        }
1193        ///
1194        /// Get list of all aliases for a collection
1195        pub async fn list_collection_aliases(
1196            &mut self,
1197            request: impl tonic::IntoRequest<super::ListCollectionAliasesRequest>,
1198        ) -> std::result::Result<
1199            tonic::Response<super::ListAliasesResponse>,
1200            tonic::Status,
1201        > {
1202            self.inner
1203                .ready()
1204                .await
1205                .map_err(|e| {
1206                    tonic::Status::new(
1207                        tonic::Code::Unknown,
1208                        format!("Service was not ready: {}", e.into()),
1209                    )
1210                })?;
1211            let codec = tonic::codec::ProstCodec::default();
1212            let path = http::uri::PathAndQuery::from_static(
1213                "/arc_vector.Collections/ListCollectionAliases",
1214            );
1215            let mut req = request.into_request();
1216            req.extensions_mut()
1217                .insert(GrpcMethod::new("arc_vector.Collections", "ListCollectionAliases"));
1218            self.inner.unary(req, path, codec).await
1219        }
1220        ///
1221        /// Get list of all aliases for all existing collections
1222        pub async fn list_aliases(
1223            &mut self,
1224            request: impl tonic::IntoRequest<super::ListAliasesRequest>,
1225        ) -> std::result::Result<
1226            tonic::Response<super::ListAliasesResponse>,
1227            tonic::Status,
1228        > {
1229            self.inner
1230                .ready()
1231                .await
1232                .map_err(|e| {
1233                    tonic::Status::new(
1234                        tonic::Code::Unknown,
1235                        format!("Service was not ready: {}", e.into()),
1236                    )
1237                })?;
1238            let codec = tonic::codec::ProstCodec::default();
1239            let path = http::uri::PathAndQuery::from_static(
1240                "/arc_vector.Collections/ListAliases",
1241            );
1242            let mut req = request.into_request();
1243            req.extensions_mut()
1244                .insert(GrpcMethod::new("arc_vector.Collections", "ListAliases"));
1245            self.inner.unary(req, path, codec).await
1246        }
1247        ///
1248        /// Get cluster information for a collection
1249        pub async fn collection_cluster_info(
1250            &mut self,
1251            request: impl tonic::IntoRequest<super::CollectionClusterInfoRequest>,
1252        ) -> std::result::Result<
1253            tonic::Response<super::CollectionClusterInfoResponse>,
1254            tonic::Status,
1255        > {
1256            self.inner
1257                .ready()
1258                .await
1259                .map_err(|e| {
1260                    tonic::Status::new(
1261                        tonic::Code::Unknown,
1262                        format!("Service was not ready: {}", e.into()),
1263                    )
1264                })?;
1265            let codec = tonic::codec::ProstCodec::default();
1266            let path = http::uri::PathAndQuery::from_static(
1267                "/arc_vector.Collections/CollectionClusterInfo",
1268            );
1269            let mut req = request.into_request();
1270            req.extensions_mut()
1271                .insert(GrpcMethod::new("arc_vector.Collections", "CollectionClusterInfo"));
1272            self.inner.unary(req, path, codec).await
1273        }
1274        ///
1275        /// Update cluster setup for a collection
1276        pub async fn update_collection_cluster_setup(
1277            &mut self,
1278            request: impl tonic::IntoRequest<super::UpdateCollectionClusterSetupRequest>,
1279        ) -> std::result::Result<
1280            tonic::Response<super::UpdateCollectionClusterSetupResponse>,
1281            tonic::Status,
1282        > {
1283            self.inner
1284                .ready()
1285                .await
1286                .map_err(|e| {
1287                    tonic::Status::new(
1288                        tonic::Code::Unknown,
1289                        format!("Service was not ready: {}", e.into()),
1290                    )
1291                })?;
1292            let codec = tonic::codec::ProstCodec::default();
1293            let path = http::uri::PathAndQuery::from_static(
1294                "/arc_vector.Collections/UpdateCollectionClusterSetup",
1295            );
1296            let mut req = request.into_request();
1297            req.extensions_mut()
1298                .insert(
1299                    GrpcMethod::new("arc_vector.Collections", "UpdateCollectionClusterSetup"),
1300                );
1301            self.inner.unary(req, path, codec).await
1302        }
1303    }
1304}
1305/// Generated server implementations.
1306pub mod collections_server {
1307    #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)]
1308    use tonic::codegen::*;
1309    /// Generated trait containing gRPC methods that should be implemented for use with CollectionsServer.
1310    #[async_trait]
1311    pub trait Collections: Send + Sync + 'static {
1312        ///
1313        /// Get detailed information about specified existing collection
1314        async fn get(
1315            &self,
1316            request: tonic::Request<super::GetCollectionInfoRequest>,
1317        ) -> std::result::Result<
1318            tonic::Response<super::GetCollectionInfoResponse>,
1319            tonic::Status,
1320        >;
1321        ///
1322        /// Get list name of all existing collections
1323        async fn list(
1324            &self,
1325            request: tonic::Request<super::ListCollectionsRequest>,
1326        ) -> std::result::Result<
1327            tonic::Response<super::ListCollectionsResponse>,
1328            tonic::Status,
1329        >;
1330        ///
1331        /// Create new collection with given parameters
1332        async fn create(
1333            &self,
1334            request: tonic::Request<super::CreateCollection>,
1335        ) -> std::result::Result<
1336            tonic::Response<super::CollectionOperationResponse>,
1337            tonic::Status,
1338        >;
1339        ///
1340        /// Update parameters of the existing collection
1341        async fn update(
1342            &self,
1343            request: tonic::Request<super::UpdateCollection>,
1344        ) -> std::result::Result<
1345            tonic::Response<super::CollectionOperationResponse>,
1346            tonic::Status,
1347        >;
1348        ///
1349        /// Drop collection and all associated data
1350        async fn delete(
1351            &self,
1352            request: tonic::Request<super::DeleteCollection>,
1353        ) -> std::result::Result<
1354            tonic::Response<super::CollectionOperationResponse>,
1355            tonic::Status,
1356        >;
1357        ///
1358        /// Update Aliases of the existing collection
1359        async fn update_aliases(
1360            &self,
1361            request: tonic::Request<super::ChangeAliases>,
1362        ) -> std::result::Result<
1363            tonic::Response<super::CollectionOperationResponse>,
1364            tonic::Status,
1365        >;
1366        ///
1367        /// Get list of all aliases for a collection
1368        async fn list_collection_aliases(
1369            &self,
1370            request: tonic::Request<super::ListCollectionAliasesRequest>,
1371        ) -> std::result::Result<
1372            tonic::Response<super::ListAliasesResponse>,
1373            tonic::Status,
1374        >;
1375        ///
1376        /// Get list of all aliases for all existing collections
1377        async fn list_aliases(
1378            &self,
1379            request: tonic::Request<super::ListAliasesRequest>,
1380        ) -> std::result::Result<
1381            tonic::Response<super::ListAliasesResponse>,
1382            tonic::Status,
1383        >;
1384        ///
1385        /// Get cluster information for a collection
1386        async fn collection_cluster_info(
1387            &self,
1388            request: tonic::Request<super::CollectionClusterInfoRequest>,
1389        ) -> std::result::Result<
1390            tonic::Response<super::CollectionClusterInfoResponse>,
1391            tonic::Status,
1392        >;
1393        ///
1394        /// Update cluster setup for a collection
1395        async fn update_collection_cluster_setup(
1396            &self,
1397            request: tonic::Request<super::UpdateCollectionClusterSetupRequest>,
1398        ) -> std::result::Result<
1399            tonic::Response<super::UpdateCollectionClusterSetupResponse>,
1400            tonic::Status,
1401        >;
1402    }
1403    #[derive(Debug)]
1404    pub struct CollectionsServer<T: Collections> {
1405        inner: _Inner<T>,
1406        accept_compression_encodings: EnabledCompressionEncodings,
1407        send_compression_encodings: EnabledCompressionEncodings,
1408        max_decoding_message_size: Option<usize>,
1409        max_encoding_message_size: Option<usize>,
1410    }
1411    struct _Inner<T>(Arc<T>);
1412    impl<T: Collections> CollectionsServer<T> {
1413        pub fn new(inner: T) -> Self {
1414            Self::from_arc(Arc::new(inner))
1415        }
1416        pub fn from_arc(inner: Arc<T>) -> Self {
1417            let inner = _Inner(inner);
1418            Self {
1419                inner,
1420                accept_compression_encodings: Default::default(),
1421                send_compression_encodings: Default::default(),
1422                max_decoding_message_size: None,
1423                max_encoding_message_size: None,
1424            }
1425        }
1426        pub fn with_interceptor<F>(
1427            inner: T,
1428            interceptor: F,
1429        ) -> InterceptedService<Self, F>
1430        where
1431            F: tonic::service::Interceptor,
1432        {
1433            InterceptedService::new(Self::new(inner), interceptor)
1434        }
1435        /// Enable decompressing requests with the given encoding.
1436        #[must_use]
1437        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
1438            self.accept_compression_encodings.enable(encoding);
1439            self
1440        }
1441        /// Compress responses with the given encoding, if the client supports it.
1442        #[must_use]
1443        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
1444            self.send_compression_encodings.enable(encoding);
1445            self
1446        }
1447        /// Limits the maximum size of a decoded message.
1448        ///
1449        /// Default: `4MB`
1450        #[must_use]
1451        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
1452            self.max_decoding_message_size = Some(limit);
1453            self
1454        }
1455        /// Limits the maximum size of an encoded message.
1456        ///
1457        /// Default: `usize::MAX`
1458        #[must_use]
1459        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
1460            self.max_encoding_message_size = Some(limit);
1461            self
1462        }
1463    }
1464    impl<T, B> tonic::codegen::Service<http::Request<B>> for CollectionsServer<T>
1465    where
1466        T: Collections,
1467        B: Body + Send + 'static,
1468        B::Error: Into<StdError> + Send + 'static,
1469    {
1470        type Response = http::Response<tonic::body::BoxBody>;
1471        type Error = std::convert::Infallible;
1472        type Future = BoxFuture<Self::Response, Self::Error>;
1473        fn poll_ready(
1474            &mut self,
1475            _cx: &mut Context<'_>,
1476        ) -> Poll<std::result::Result<(), Self::Error>> {
1477            Poll::Ready(Ok(()))
1478        }
1479        fn call(&mut self, req: http::Request<B>) -> Self::Future {
1480            let inner = self.inner.clone();
1481            match req.uri().path() {
1482                "/arc_vector.Collections/Get" => {
1483                    #[allow(non_camel_case_types)]
1484                    struct GetSvc<T: Collections>(pub Arc<T>);
1485                    impl<
1486                        T: Collections,
1487                    > tonic::server::UnaryService<super::GetCollectionInfoRequest>
1488                    for GetSvc<T> {
1489                        type Response = super::GetCollectionInfoResponse;
1490                        type Future = BoxFuture<
1491                            tonic::Response<Self::Response>,
1492                            tonic::Status,
1493                        >;
1494                        fn call(
1495                            &mut self,
1496                            request: tonic::Request<super::GetCollectionInfoRequest>,
1497                        ) -> Self::Future {
1498                            let inner = Arc::clone(&self.0);
1499                            let fut = async move { (*inner).get(request).await };
1500                            Box::pin(fut)
1501                        }
1502                    }
1503                    let accept_compression_encodings = self.accept_compression_encodings;
1504                    let send_compression_encodings = self.send_compression_encodings;
1505                    let max_decoding_message_size = self.max_decoding_message_size;
1506                    let max_encoding_message_size = self.max_encoding_message_size;
1507                    let inner = self.inner.clone();
1508                    let fut = async move {
1509                        let inner = inner.0;
1510                        let method = GetSvc(inner);
1511                        let codec = tonic::codec::ProstCodec::default();
1512                        let mut grpc = tonic::server::Grpc::new(codec)
1513                            .apply_compression_config(
1514                                accept_compression_encodings,
1515                                send_compression_encodings,
1516                            )
1517                            .apply_max_message_size_config(
1518                                max_decoding_message_size,
1519                                max_encoding_message_size,
1520                            );
1521                        let res = grpc.unary(method, req).await;
1522                        Ok(res)
1523                    };
1524                    Box::pin(fut)
1525                }
1526                "/arc_vector.Collections/List" => {
1527                    #[allow(non_camel_case_types)]
1528                    struct ListSvc<T: Collections>(pub Arc<T>);
1529                    impl<
1530                        T: Collections,
1531                    > tonic::server::UnaryService<super::ListCollectionsRequest>
1532                    for ListSvc<T> {
1533                        type Response = super::ListCollectionsResponse;
1534                        type Future = BoxFuture<
1535                            tonic::Response<Self::Response>,
1536                            tonic::Status,
1537                        >;
1538                        fn call(
1539                            &mut self,
1540                            request: tonic::Request<super::ListCollectionsRequest>,
1541                        ) -> Self::Future {
1542                            let inner = Arc::clone(&self.0);
1543                            let fut = async move { (*inner).list(request).await };
1544                            Box::pin(fut)
1545                        }
1546                    }
1547                    let accept_compression_encodings = self.accept_compression_encodings;
1548                    let send_compression_encodings = self.send_compression_encodings;
1549                    let max_decoding_message_size = self.max_decoding_message_size;
1550                    let max_encoding_message_size = self.max_encoding_message_size;
1551                    let inner = self.inner.clone();
1552                    let fut = async move {
1553                        let inner = inner.0;
1554                        let method = ListSvc(inner);
1555                        let codec = tonic::codec::ProstCodec::default();
1556                        let mut grpc = tonic::server::Grpc::new(codec)
1557                            .apply_compression_config(
1558                                accept_compression_encodings,
1559                                send_compression_encodings,
1560                            )
1561                            .apply_max_message_size_config(
1562                                max_decoding_message_size,
1563                                max_encoding_message_size,
1564                            );
1565                        let res = grpc.unary(method, req).await;
1566                        Ok(res)
1567                    };
1568                    Box::pin(fut)
1569                }
1570                "/arc_vector.Collections/Create" => {
1571                    #[allow(non_camel_case_types)]
1572                    struct CreateSvc<T: Collections>(pub Arc<T>);
1573                    impl<
1574                        T: Collections,
1575                    > tonic::server::UnaryService<super::CreateCollection>
1576                    for CreateSvc<T> {
1577                        type Response = super::CollectionOperationResponse;
1578                        type Future = BoxFuture<
1579                            tonic::Response<Self::Response>,
1580                            tonic::Status,
1581                        >;
1582                        fn call(
1583                            &mut self,
1584                            request: tonic::Request<super::CreateCollection>,
1585                        ) -> Self::Future {
1586                            let inner = Arc::clone(&self.0);
1587                            let fut = async move { (*inner).create(request).await };
1588                            Box::pin(fut)
1589                        }
1590                    }
1591                    let accept_compression_encodings = self.accept_compression_encodings;
1592                    let send_compression_encodings = self.send_compression_encodings;
1593                    let max_decoding_message_size = self.max_decoding_message_size;
1594                    let max_encoding_message_size = self.max_encoding_message_size;
1595                    let inner = self.inner.clone();
1596                    let fut = async move {
1597                        let inner = inner.0;
1598                        let method = CreateSvc(inner);
1599                        let codec = tonic::codec::ProstCodec::default();
1600                        let mut grpc = tonic::server::Grpc::new(codec)
1601                            .apply_compression_config(
1602                                accept_compression_encodings,
1603                                send_compression_encodings,
1604                            )
1605                            .apply_max_message_size_config(
1606                                max_decoding_message_size,
1607                                max_encoding_message_size,
1608                            );
1609                        let res = grpc.unary(method, req).await;
1610                        Ok(res)
1611                    };
1612                    Box::pin(fut)
1613                }
1614                "/arc_vector.Collections/Update" => {
1615                    #[allow(non_camel_case_types)]
1616                    struct UpdateSvc<T: Collections>(pub Arc<T>);
1617                    impl<
1618                        T: Collections,
1619                    > tonic::server::UnaryService<super::UpdateCollection>
1620                    for UpdateSvc<T> {
1621                        type Response = super::CollectionOperationResponse;
1622                        type Future = BoxFuture<
1623                            tonic::Response<Self::Response>,
1624                            tonic::Status,
1625                        >;
1626                        fn call(
1627                            &mut self,
1628                            request: tonic::Request<super::UpdateCollection>,
1629                        ) -> Self::Future {
1630                            let inner = Arc::clone(&self.0);
1631                            let fut = async move { (*inner).update(request).await };
1632                            Box::pin(fut)
1633                        }
1634                    }
1635                    let accept_compression_encodings = self.accept_compression_encodings;
1636                    let send_compression_encodings = self.send_compression_encodings;
1637                    let max_decoding_message_size = self.max_decoding_message_size;
1638                    let max_encoding_message_size = self.max_encoding_message_size;
1639                    let inner = self.inner.clone();
1640                    let fut = async move {
1641                        let inner = inner.0;
1642                        let method = UpdateSvc(inner);
1643                        let codec = tonic::codec::ProstCodec::default();
1644                        let mut grpc = tonic::server::Grpc::new(codec)
1645                            .apply_compression_config(
1646                                accept_compression_encodings,
1647                                send_compression_encodings,
1648                            )
1649                            .apply_max_message_size_config(
1650                                max_decoding_message_size,
1651                                max_encoding_message_size,
1652                            );
1653                        let res = grpc.unary(method, req).await;
1654                        Ok(res)
1655                    };
1656                    Box::pin(fut)
1657                }
1658                "/arc_vector.Collections/Delete" => {
1659                    #[allow(non_camel_case_types)]
1660                    struct DeleteSvc<T: Collections>(pub Arc<T>);
1661                    impl<
1662                        T: Collections,
1663                    > tonic::server::UnaryService<super::DeleteCollection>
1664                    for DeleteSvc<T> {
1665                        type Response = super::CollectionOperationResponse;
1666                        type Future = BoxFuture<
1667                            tonic::Response<Self::Response>,
1668                            tonic::Status,
1669                        >;
1670                        fn call(
1671                            &mut self,
1672                            request: tonic::Request<super::DeleteCollection>,
1673                        ) -> Self::Future {
1674                            let inner = Arc::clone(&self.0);
1675                            let fut = async move { (*inner).delete(request).await };
1676                            Box::pin(fut)
1677                        }
1678                    }
1679                    let accept_compression_encodings = self.accept_compression_encodings;
1680                    let send_compression_encodings = self.send_compression_encodings;
1681                    let max_decoding_message_size = self.max_decoding_message_size;
1682                    let max_encoding_message_size = self.max_encoding_message_size;
1683                    let inner = self.inner.clone();
1684                    let fut = async move {
1685                        let inner = inner.0;
1686                        let method = DeleteSvc(inner);
1687                        let codec = tonic::codec::ProstCodec::default();
1688                        let mut grpc = tonic::server::Grpc::new(codec)
1689                            .apply_compression_config(
1690                                accept_compression_encodings,
1691                                send_compression_encodings,
1692                            )
1693                            .apply_max_message_size_config(
1694                                max_decoding_message_size,
1695                                max_encoding_message_size,
1696                            );
1697                        let res = grpc.unary(method, req).await;
1698                        Ok(res)
1699                    };
1700                    Box::pin(fut)
1701                }
1702                "/arc_vector.Collections/UpdateAliases" => {
1703                    #[allow(non_camel_case_types)]
1704                    struct UpdateAliasesSvc<T: Collections>(pub Arc<T>);
1705                    impl<
1706                        T: Collections,
1707                    > tonic::server::UnaryService<super::ChangeAliases>
1708                    for UpdateAliasesSvc<T> {
1709                        type Response = super::CollectionOperationResponse;
1710                        type Future = BoxFuture<
1711                            tonic::Response<Self::Response>,
1712                            tonic::Status,
1713                        >;
1714                        fn call(
1715                            &mut self,
1716                            request: tonic::Request<super::ChangeAliases>,
1717                        ) -> Self::Future {
1718                            let inner = Arc::clone(&self.0);
1719                            let fut = async move {
1720                                (*inner).update_aliases(request).await
1721                            };
1722                            Box::pin(fut)
1723                        }
1724                    }
1725                    let accept_compression_encodings = self.accept_compression_encodings;
1726                    let send_compression_encodings = self.send_compression_encodings;
1727                    let max_decoding_message_size = self.max_decoding_message_size;
1728                    let max_encoding_message_size = self.max_encoding_message_size;
1729                    let inner = self.inner.clone();
1730                    let fut = async move {
1731                        let inner = inner.0;
1732                        let method = UpdateAliasesSvc(inner);
1733                        let codec = tonic::codec::ProstCodec::default();
1734                        let mut grpc = tonic::server::Grpc::new(codec)
1735                            .apply_compression_config(
1736                                accept_compression_encodings,
1737                                send_compression_encodings,
1738                            )
1739                            .apply_max_message_size_config(
1740                                max_decoding_message_size,
1741                                max_encoding_message_size,
1742                            );
1743                        let res = grpc.unary(method, req).await;
1744                        Ok(res)
1745                    };
1746                    Box::pin(fut)
1747                }
1748                "/arc_vector.Collections/ListCollectionAliases" => {
1749                    #[allow(non_camel_case_types)]
1750                    struct ListCollectionAliasesSvc<T: Collections>(pub Arc<T>);
1751                    impl<
1752                        T: Collections,
1753                    > tonic::server::UnaryService<super::ListCollectionAliasesRequest>
1754                    for ListCollectionAliasesSvc<T> {
1755                        type Response = super::ListAliasesResponse;
1756                        type Future = BoxFuture<
1757                            tonic::Response<Self::Response>,
1758                            tonic::Status,
1759                        >;
1760                        fn call(
1761                            &mut self,
1762                            request: tonic::Request<super::ListCollectionAliasesRequest>,
1763                        ) -> Self::Future {
1764                            let inner = Arc::clone(&self.0);
1765                            let fut = async move {
1766                                (*inner).list_collection_aliases(request).await
1767                            };
1768                            Box::pin(fut)
1769                        }
1770                    }
1771                    let accept_compression_encodings = self.accept_compression_encodings;
1772                    let send_compression_encodings = self.send_compression_encodings;
1773                    let max_decoding_message_size = self.max_decoding_message_size;
1774                    let max_encoding_message_size = self.max_encoding_message_size;
1775                    let inner = self.inner.clone();
1776                    let fut = async move {
1777                        let inner = inner.0;
1778                        let method = ListCollectionAliasesSvc(inner);
1779                        let codec = tonic::codec::ProstCodec::default();
1780                        let mut grpc = tonic::server::Grpc::new(codec)
1781                            .apply_compression_config(
1782                                accept_compression_encodings,
1783                                send_compression_encodings,
1784                            )
1785                            .apply_max_message_size_config(
1786                                max_decoding_message_size,
1787                                max_encoding_message_size,
1788                            );
1789                        let res = grpc.unary(method, req).await;
1790                        Ok(res)
1791                    };
1792                    Box::pin(fut)
1793                }
1794                "/arc_vector.Collections/ListAliases" => {
1795                    #[allow(non_camel_case_types)]
1796                    struct ListAliasesSvc<T: Collections>(pub Arc<T>);
1797                    impl<
1798                        T: Collections,
1799                    > tonic::server::UnaryService<super::ListAliasesRequest>
1800                    for ListAliasesSvc<T> {
1801                        type Response = super::ListAliasesResponse;
1802                        type Future = BoxFuture<
1803                            tonic::Response<Self::Response>,
1804                            tonic::Status,
1805                        >;
1806                        fn call(
1807                            &mut self,
1808                            request: tonic::Request<super::ListAliasesRequest>,
1809                        ) -> Self::Future {
1810                            let inner = Arc::clone(&self.0);
1811                            let fut = async move {
1812                                (*inner).list_aliases(request).await
1813                            };
1814                            Box::pin(fut)
1815                        }
1816                    }
1817                    let accept_compression_encodings = self.accept_compression_encodings;
1818                    let send_compression_encodings = self.send_compression_encodings;
1819                    let max_decoding_message_size = self.max_decoding_message_size;
1820                    let max_encoding_message_size = self.max_encoding_message_size;
1821                    let inner = self.inner.clone();
1822                    let fut = async move {
1823                        let inner = inner.0;
1824                        let method = ListAliasesSvc(inner);
1825                        let codec = tonic::codec::ProstCodec::default();
1826                        let mut grpc = tonic::server::Grpc::new(codec)
1827                            .apply_compression_config(
1828                                accept_compression_encodings,
1829                                send_compression_encodings,
1830                            )
1831                            .apply_max_message_size_config(
1832                                max_decoding_message_size,
1833                                max_encoding_message_size,
1834                            );
1835                        let res = grpc.unary(method, req).await;
1836                        Ok(res)
1837                    };
1838                    Box::pin(fut)
1839                }
1840                "/arc_vector.Collections/CollectionClusterInfo" => {
1841                    #[allow(non_camel_case_types)]
1842                    struct CollectionClusterInfoSvc<T: Collections>(pub Arc<T>);
1843                    impl<
1844                        T: Collections,
1845                    > tonic::server::UnaryService<super::CollectionClusterInfoRequest>
1846                    for CollectionClusterInfoSvc<T> {
1847                        type Response = super::CollectionClusterInfoResponse;
1848                        type Future = BoxFuture<
1849                            tonic::Response<Self::Response>,
1850                            tonic::Status,
1851                        >;
1852                        fn call(
1853                            &mut self,
1854                            request: tonic::Request<super::CollectionClusterInfoRequest>,
1855                        ) -> Self::Future {
1856                            let inner = Arc::clone(&self.0);
1857                            let fut = async move {
1858                                (*inner).collection_cluster_info(request).await
1859                            };
1860                            Box::pin(fut)
1861                        }
1862                    }
1863                    let accept_compression_encodings = self.accept_compression_encodings;
1864                    let send_compression_encodings = self.send_compression_encodings;
1865                    let max_decoding_message_size = self.max_decoding_message_size;
1866                    let max_encoding_message_size = self.max_encoding_message_size;
1867                    let inner = self.inner.clone();
1868                    let fut = async move {
1869                        let inner = inner.0;
1870                        let method = CollectionClusterInfoSvc(inner);
1871                        let codec = tonic::codec::ProstCodec::default();
1872                        let mut grpc = tonic::server::Grpc::new(codec)
1873                            .apply_compression_config(
1874                                accept_compression_encodings,
1875                                send_compression_encodings,
1876                            )
1877                            .apply_max_message_size_config(
1878                                max_decoding_message_size,
1879                                max_encoding_message_size,
1880                            );
1881                        let res = grpc.unary(method, req).await;
1882                        Ok(res)
1883                    };
1884                    Box::pin(fut)
1885                }
1886                "/arc_vector.Collections/UpdateCollectionClusterSetup" => {
1887                    #[allow(non_camel_case_types)]
1888                    struct UpdateCollectionClusterSetupSvc<T: Collections>(pub Arc<T>);
1889                    impl<
1890                        T: Collections,
1891                    > tonic::server::UnaryService<
1892                        super::UpdateCollectionClusterSetupRequest,
1893                    > for UpdateCollectionClusterSetupSvc<T> {
1894                        type Response = super::UpdateCollectionClusterSetupResponse;
1895                        type Future = BoxFuture<
1896                            tonic::Response<Self::Response>,
1897                            tonic::Status,
1898                        >;
1899                        fn call(
1900                            &mut self,
1901                            request: tonic::Request<
1902                                super::UpdateCollectionClusterSetupRequest,
1903                            >,
1904                        ) -> Self::Future {
1905                            let inner = Arc::clone(&self.0);
1906                            let fut = async move {
1907                                (*inner).update_collection_cluster_setup(request).await
1908                            };
1909                            Box::pin(fut)
1910                        }
1911                    }
1912                    let accept_compression_encodings = self.accept_compression_encodings;
1913                    let send_compression_encodings = self.send_compression_encodings;
1914                    let max_decoding_message_size = self.max_decoding_message_size;
1915                    let max_encoding_message_size = self.max_encoding_message_size;
1916                    let inner = self.inner.clone();
1917                    let fut = async move {
1918                        let inner = inner.0;
1919                        let method = UpdateCollectionClusterSetupSvc(inner);
1920                        let codec = tonic::codec::ProstCodec::default();
1921                        let mut grpc = tonic::server::Grpc::new(codec)
1922                            .apply_compression_config(
1923                                accept_compression_encodings,
1924                                send_compression_encodings,
1925                            )
1926                            .apply_max_message_size_config(
1927                                max_decoding_message_size,
1928                                max_encoding_message_size,
1929                            );
1930                        let res = grpc.unary(method, req).await;
1931                        Ok(res)
1932                    };
1933                    Box::pin(fut)
1934                }
1935                _ => {
1936                    Box::pin(async move {
1937                        Ok(
1938                            http::Response::builder()
1939                                .status(200)
1940                                .header("grpc-status", "12")
1941                                .header("content-type", "application/grpc")
1942                                .body(empty_body())
1943                                .unwrap(),
1944                        )
1945                    })
1946                }
1947            }
1948        }
1949    }
1950    impl<T: Collections> Clone for CollectionsServer<T> {
1951        fn clone(&self) -> Self {
1952            let inner = self.inner.clone();
1953            Self {
1954                inner,
1955                accept_compression_encodings: self.accept_compression_encodings,
1956                send_compression_encodings: self.send_compression_encodings,
1957                max_decoding_message_size: self.max_decoding_message_size,
1958                max_encoding_message_size: self.max_encoding_message_size,
1959            }
1960        }
1961    }
1962    impl<T: Collections> Clone for _Inner<T> {
1963        fn clone(&self) -> Self {
1964            Self(Arc::clone(&self.0))
1965        }
1966    }
1967    impl<T: std::fmt::Debug> std::fmt::Debug for _Inner<T> {
1968        fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
1969            write!(f, "{:?}", self.0)
1970        }
1971    }
1972    impl<T: Collections> tonic::server::NamedService for CollectionsServer<T> {
1973        const NAME: &'static str = "arc_vector.Collections";
1974    }
1975}
1976/// `Struct` represents a structured data value, consisting of fields
1977/// which map to dynamically typed values. In some languages, `Struct`
1978/// might be supported by a native representation. For example, in
1979/// scripting languages like JS a struct is represented as an
1980/// object. The details of that representation are described together
1981/// with the proto support for the language.
1982///
1983/// The JSON representation for `Struct` is a JSON object.
1984#[allow(clippy::derive_partial_eq_without_eq)]
1985#[derive(Clone, PartialEq, ::prost::Message)]
1986pub struct Struct {
1987    /// Unordered map of dynamically typed values.
1988    #[prost(map = "string, message", tag = "1")]
1989    pub fields: ::std::collections::HashMap<::prost::alloc::string::String, Value>,
1990}
1991/// `Value` represents a dynamically typed value which can be either
1992/// null, a number, a string, a boolean, a recursive struct value, or a
1993/// list of values. A producer of value is expected to set one of those
1994/// variants, absence of any variant indicates an error.
1995///
1996/// The JSON representation for `Value` is a JSON value.
1997#[allow(clippy::derive_partial_eq_without_eq)]
1998#[derive(Clone, PartialEq, ::prost::Message)]
1999pub struct Value {
2000    /// The kind of value.
2001    #[prost(oneof = "value::Kind", tags = "1, 2, 3, 4, 5, 6, 7")]
2002    pub kind: ::core::option::Option<value::Kind>,
2003}
2004/// Nested message and enum types in `Value`.
2005pub mod value {
2006    /// The kind of value.
2007    #[allow(clippy::derive_partial_eq_without_eq)]
2008    #[derive(Clone, PartialEq, ::prost::Oneof)]
2009    pub enum Kind {
2010        /// Represents a null value.
2011        #[prost(enumeration = "super::NullValue", tag = "1")]
2012        NullValue(i32),
2013        /// Represents a double value.
2014        #[prost(double, tag = "2")]
2015        DoubleValue(f64),
2016        /// Represents an integer value
2017        #[prost(int64, tag = "3")]
2018        IntegerValue(i64),
2019        /// Represents a string value.
2020        #[prost(string, tag = "4")]
2021        StringValue(::prost::alloc::string::String),
2022        /// Represents a boolean value.
2023        #[prost(bool, tag = "5")]
2024        BoolValue(bool),
2025        /// Represents a structured value.
2026        #[prost(message, tag = "6")]
2027        StructValue(super::Struct),
2028        /// Represents a repeated `Value`.
2029        #[prost(message, tag = "7")]
2030        ListValue(super::ListValue),
2031    }
2032}
2033/// `ListValue` is a wrapper around a repeated field of values.
2034///
2035/// The JSON representation for `ListValue` is a JSON array.
2036#[allow(clippy::derive_partial_eq_without_eq)]
2037#[derive(Clone, PartialEq, ::prost::Message)]
2038pub struct ListValue {
2039    /// Repeated field of dynamically typed values.
2040    #[prost(message, repeated, tag = "1")]
2041    pub values: ::prost::alloc::vec::Vec<Value>,
2042}
2043/// `NullValue` is a singleton enumeration to represent the null value for the
2044/// `Value` type union.
2045///
2046///   The JSON representation for `NullValue` is JSON `null`.
2047#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2048#[repr(i32)]
2049pub enum NullValue {
2050    /// Null value.
2051    NullValue = 0,
2052}
2053impl NullValue {
2054    /// String value of the enum field names used in the ProtoBuf definition.
2055    ///
2056    /// The values are not transformed in any way and thus are considered stable
2057    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2058    pub fn as_str_name(&self) -> &'static str {
2059        match self {
2060            NullValue::NullValue => "NULL_VALUE",
2061        }
2062    }
2063    /// Creates an enum from field names used in the ProtoBuf definition.
2064    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2065        match value {
2066            "NULL_VALUE" => Some(Self::NullValue),
2067            _ => None,
2068        }
2069    }
2070}
2071#[allow(clippy::derive_partial_eq_without_eq)]
2072#[derive(Clone, PartialEq, ::prost::Message)]
2073pub struct WriteOrdering {
2074    /// Write ordering guarantees
2075    #[prost(enumeration = "WriteOrderingType", tag = "1")]
2076    pub r#type: i32,
2077}
2078#[allow(clippy::derive_partial_eq_without_eq)]
2079#[derive(Clone, PartialEq, ::prost::Message)]
2080pub struct ReadConsistency {
2081    #[prost(oneof = "read_consistency::Value", tags = "1, 2")]
2082    pub value: ::core::option::Option<read_consistency::Value>,
2083}
2084/// Nested message and enum types in `ReadConsistency`.
2085pub mod read_consistency {
2086    #[allow(clippy::derive_partial_eq_without_eq)]
2087    #[derive(Clone, PartialEq, ::prost::Oneof)]
2088    pub enum Value {
2089        /// Common read consistency configurations
2090        #[prost(enumeration = "super::ReadConsistencyType", tag = "1")]
2091        Type(i32),
2092        /// Send request to a specified number of nodes, and return points which are present on all of them
2093        #[prost(uint64, tag = "2")]
2094        Factor(u64),
2095    }
2096}
2097#[allow(clippy::derive_partial_eq_without_eq)]
2098#[derive(Clone, PartialEq, ::prost::Message)]
2099pub struct PointId {
2100    #[prost(oneof = "point_id::PointIdOptions", tags = "1, 2")]
2101    pub point_id_options: ::core::option::Option<point_id::PointIdOptions>,
2102}
2103/// Nested message and enum types in `PointId`.
2104pub mod point_id {
2105    #[allow(clippy::derive_partial_eq_without_eq)]
2106    #[derive(Clone, PartialEq, ::prost::Oneof)]
2107    pub enum PointIdOptions {
2108        /// Numerical ID of the point
2109        #[prost(uint64, tag = "1")]
2110        Num(u64),
2111        /// UUID
2112        #[prost(string, tag = "2")]
2113        Uuid(::prost::alloc::string::String),
2114    }
2115}
2116#[allow(clippy::derive_partial_eq_without_eq)]
2117#[derive(Clone, PartialEq, ::prost::Message)]
2118pub struct Vector {
2119    #[prost(float, repeated, tag = "1")]
2120    pub data: ::prost::alloc::vec::Vec<f32>,
2121}
2122#[allow(clippy::derive_partial_eq_without_eq)]
2123#[derive(Clone, PartialEq, ::prost::Message)]
2124pub struct UpsertPoints {
2125    /// name of the collection
2126    #[prost(string, tag = "1")]
2127    pub collection_name: ::prost::alloc::string::String,
2128    /// Wait until the changes have been applied?
2129    #[prost(bool, optional, tag = "2")]
2130    pub wait: ::core::option::Option<bool>,
2131    #[prost(message, repeated, tag = "3")]
2132    pub points: ::prost::alloc::vec::Vec<PointStruct>,
2133    /// Write ordering guarantees
2134    #[prost(message, optional, tag = "4")]
2135    pub ordering: ::core::option::Option<WriteOrdering>,
2136}
2137#[allow(clippy::derive_partial_eq_without_eq)]
2138#[derive(Clone, PartialEq, ::prost::Message)]
2139pub struct DeletePoints {
2140    /// name of the collection
2141    #[prost(string, tag = "1")]
2142    pub collection_name: ::prost::alloc::string::String,
2143    /// Wait until the changes have been applied?
2144    #[prost(bool, optional, tag = "2")]
2145    pub wait: ::core::option::Option<bool>,
2146    /// Affected points
2147    #[prost(message, optional, tag = "3")]
2148    pub points: ::core::option::Option<PointsSelector>,
2149    /// Write ordering guarantees
2150    #[prost(message, optional, tag = "4")]
2151    pub ordering: ::core::option::Option<WriteOrdering>,
2152}
2153#[allow(clippy::derive_partial_eq_without_eq)]
2154#[derive(Clone, PartialEq, ::prost::Message)]
2155pub struct GetPoints {
2156    /// name of the collection
2157    #[prost(string, tag = "1")]
2158    pub collection_name: ::prost::alloc::string::String,
2159    /// List of points to retrieve
2160    #[prost(message, repeated, tag = "2")]
2161    pub ids: ::prost::alloc::vec::Vec<PointId>,
2162    /// Options for specifying which payload to include or not
2163    #[prost(message, optional, tag = "4")]
2164    pub with_payload: ::core::option::Option<WithPayloadSelector>,
2165    /// Options for specifying which vectors to include into response
2166    #[prost(message, optional, tag = "5")]
2167    pub with_vectors: ::core::option::Option<WithVectorsSelector>,
2168    /// Options for specifying read consistency guarantees
2169    #[prost(message, optional, tag = "6")]
2170    pub read_consistency: ::core::option::Option<ReadConsistency>,
2171}
2172#[allow(clippy::derive_partial_eq_without_eq)]
2173#[derive(Clone, PartialEq, ::prost::Message)]
2174pub struct UpdatePointVectors {
2175    /// name of the collection
2176    #[prost(string, tag = "1")]
2177    pub collection_name: ::prost::alloc::string::String,
2178    /// Wait until the changes have been applied?
2179    #[prost(bool, optional, tag = "2")]
2180    pub wait: ::core::option::Option<bool>,
2181    /// List of points and vectors to update
2182    #[prost(message, repeated, tag = "3")]
2183    pub points: ::prost::alloc::vec::Vec<PointVectors>,
2184    /// Write ordering guarantees
2185    #[prost(message, optional, tag = "4")]
2186    pub ordering: ::core::option::Option<WriteOrdering>,
2187}
2188#[allow(clippy::derive_partial_eq_without_eq)]
2189#[derive(Clone, PartialEq, ::prost::Message)]
2190pub struct PointVectors {
2191    /// ID to update vectors for
2192    #[prost(message, optional, tag = "1")]
2193    pub id: ::core::option::Option<PointId>,
2194    /// Named vectors to update, leave others intact
2195    #[prost(message, optional, tag = "2")]
2196    pub vectors: ::core::option::Option<Vectors>,
2197}
2198#[allow(clippy::derive_partial_eq_without_eq)]
2199#[derive(Clone, PartialEq, ::prost::Message)]
2200pub struct DeletePointVectors {
2201    /// name of the collection
2202    #[prost(string, tag = "1")]
2203    pub collection_name: ::prost::alloc::string::String,
2204    /// Wait until the changes have been applied?
2205    #[prost(bool, optional, tag = "2")]
2206    pub wait: ::core::option::Option<bool>,
2207    /// Affected points
2208    #[prost(message, optional, tag = "3")]
2209    pub points_selector: ::core::option::Option<PointsSelector>,
2210    /// List of vector names to delete
2211    #[prost(message, optional, tag = "4")]
2212    pub vectors: ::core::option::Option<VectorsSelector>,
2213    /// Write ordering guarantees
2214    #[prost(message, optional, tag = "5")]
2215    pub ordering: ::core::option::Option<WriteOrdering>,
2216}
2217#[allow(clippy::derive_partial_eq_without_eq)]
2218#[derive(Clone, PartialEq, ::prost::Message)]
2219pub struct SetPayloadPoints {
2220    /// name of the collection
2221    #[prost(string, tag = "1")]
2222    pub collection_name: ::prost::alloc::string::String,
2223    /// Wait until the changes have been applied?
2224    #[prost(bool, optional, tag = "2")]
2225    pub wait: ::core::option::Option<bool>,
2226    /// New payload values
2227    #[prost(map = "string, message", tag = "3")]
2228    pub payload: ::std::collections::HashMap<::prost::alloc::string::String, Value>,
2229    /// Affected points
2230    #[prost(message, optional, tag = "5")]
2231    pub points_selector: ::core::option::Option<PointsSelector>,
2232    /// Write ordering guarantees
2233    #[prost(message, optional, tag = "6")]
2234    pub ordering: ::core::option::Option<WriteOrdering>,
2235}
2236#[allow(clippy::derive_partial_eq_without_eq)]
2237#[derive(Clone, PartialEq, ::prost::Message)]
2238pub struct DeletePayloadPoints {
2239    /// name of the collection
2240    #[prost(string, tag = "1")]
2241    pub collection_name: ::prost::alloc::string::String,
2242    /// Wait until the changes have been applied?
2243    #[prost(bool, optional, tag = "2")]
2244    pub wait: ::core::option::Option<bool>,
2245    /// List of keys to delete
2246    #[prost(string, repeated, tag = "3")]
2247    pub keys: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
2248    /// Affected points
2249    #[prost(message, optional, tag = "5")]
2250    pub points_selector: ::core::option::Option<PointsSelector>,
2251    /// Write ordering guarantees
2252    #[prost(message, optional, tag = "6")]
2253    pub ordering: ::core::option::Option<WriteOrdering>,
2254}
2255#[allow(clippy::derive_partial_eq_without_eq)]
2256#[derive(Clone, PartialEq, ::prost::Message)]
2257pub struct ClearPayloadPoints {
2258    /// name of the collection
2259    #[prost(string, tag = "1")]
2260    pub collection_name: ::prost::alloc::string::String,
2261    /// Wait until the changes have been applied?
2262    #[prost(bool, optional, tag = "2")]
2263    pub wait: ::core::option::Option<bool>,
2264    /// Affected points
2265    #[prost(message, optional, tag = "3")]
2266    pub points: ::core::option::Option<PointsSelector>,
2267    /// Write ordering guarantees
2268    #[prost(message, optional, tag = "4")]
2269    pub ordering: ::core::option::Option<WriteOrdering>,
2270}
2271#[allow(clippy::derive_partial_eq_without_eq)]
2272#[derive(Clone, PartialEq, ::prost::Message)]
2273pub struct CreateFieldIndexCollection {
2274    /// name of the collection
2275    #[prost(string, tag = "1")]
2276    pub collection_name: ::prost::alloc::string::String,
2277    /// Wait until the changes have been applied?
2278    #[prost(bool, optional, tag = "2")]
2279    pub wait: ::core::option::Option<bool>,
2280    /// Field name to index
2281    #[prost(string, tag = "3")]
2282    pub field_name: ::prost::alloc::string::String,
2283    /// Field type.
2284    #[prost(enumeration = "FieldType", optional, tag = "4")]
2285    pub field_type: ::core::option::Option<i32>,
2286    /// Payload index params.
2287    #[prost(message, optional, tag = "5")]
2288    pub field_index_params: ::core::option::Option<PayloadIndexParams>,
2289    /// Write ordering guarantees
2290    #[prost(message, optional, tag = "6")]
2291    pub ordering: ::core::option::Option<WriteOrdering>,
2292}
2293#[allow(clippy::derive_partial_eq_without_eq)]
2294#[derive(Clone, PartialEq, ::prost::Message)]
2295pub struct DeleteFieldIndexCollection {
2296    /// name of the collection
2297    #[prost(string, tag = "1")]
2298    pub collection_name: ::prost::alloc::string::String,
2299    /// Wait until the changes have been applied?
2300    #[prost(bool, optional, tag = "2")]
2301    pub wait: ::core::option::Option<bool>,
2302    /// Field name to delete
2303    #[prost(string, tag = "3")]
2304    pub field_name: ::prost::alloc::string::String,
2305    /// Write ordering guarantees
2306    #[prost(message, optional, tag = "4")]
2307    pub ordering: ::core::option::Option<WriteOrdering>,
2308}
2309#[allow(clippy::derive_partial_eq_without_eq)]
2310#[derive(Clone, PartialEq, ::prost::Message)]
2311pub struct PayloadIncludeSelector {
2312    /// List of payload keys to include into result
2313    #[prost(string, repeated, tag = "1")]
2314    pub fields: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
2315}
2316#[allow(clippy::derive_partial_eq_without_eq)]
2317#[derive(Clone, PartialEq, ::prost::Message)]
2318pub struct PayloadExcludeSelector {
2319    /// List of payload keys to exclude from the result
2320    #[prost(string, repeated, tag = "1")]
2321    pub fields: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
2322}
2323#[allow(clippy::derive_partial_eq_without_eq)]
2324#[derive(Clone, PartialEq, ::prost::Message)]
2325pub struct WithPayloadSelector {
2326    #[prost(oneof = "with_payload_selector::SelectorOptions", tags = "1, 2, 3")]
2327    pub selector_options: ::core::option::Option<with_payload_selector::SelectorOptions>,
2328}
2329/// Nested message and enum types in `WithPayloadSelector`.
2330pub mod with_payload_selector {
2331    #[allow(clippy::derive_partial_eq_without_eq)]
2332    #[derive(Clone, PartialEq, ::prost::Oneof)]
2333    pub enum SelectorOptions {
2334        /// If `true` - return all payload, if `false` - none
2335        #[prost(bool, tag = "1")]
2336        Enable(bool),
2337        #[prost(message, tag = "2")]
2338        Include(super::PayloadIncludeSelector),
2339        #[prost(message, tag = "3")]
2340        Exclude(super::PayloadExcludeSelector),
2341    }
2342}
2343#[allow(clippy::derive_partial_eq_without_eq)]
2344#[derive(Clone, PartialEq, ::prost::Message)]
2345pub struct NamedVectors {
2346    #[prost(map = "string, message", tag = "1")]
2347    pub vectors: ::std::collections::HashMap<::prost::alloc::string::String, Vector>,
2348}
2349#[allow(clippy::derive_partial_eq_without_eq)]
2350#[derive(Clone, PartialEq, ::prost::Message)]
2351pub struct Vectors {
2352    #[prost(oneof = "vectors::VectorsOptions", tags = "1, 2")]
2353    pub vectors_options: ::core::option::Option<vectors::VectorsOptions>,
2354}
2355/// Nested message and enum types in `Vectors`.
2356pub mod vectors {
2357    #[allow(clippy::derive_partial_eq_without_eq)]
2358    #[derive(Clone, PartialEq, ::prost::Oneof)]
2359    pub enum VectorsOptions {
2360        #[prost(message, tag = "1")]
2361        Vector(super::Vector),
2362        #[prost(message, tag = "2")]
2363        Vectors(super::NamedVectors),
2364    }
2365}
2366#[allow(clippy::derive_partial_eq_without_eq)]
2367#[derive(Clone, PartialEq, ::prost::Message)]
2368pub struct VectorsSelector {
2369    /// List of vectors to include into result
2370    #[prost(string, repeated, tag = "1")]
2371    pub names: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
2372}
2373#[allow(clippy::derive_partial_eq_without_eq)]
2374#[derive(Clone, PartialEq, ::prost::Message)]
2375pub struct WithVectorsSelector {
2376    #[prost(oneof = "with_vectors_selector::SelectorOptions", tags = "1, 2")]
2377    pub selector_options: ::core::option::Option<with_vectors_selector::SelectorOptions>,
2378}
2379/// Nested message and enum types in `WithVectorsSelector`.
2380pub mod with_vectors_selector {
2381    #[allow(clippy::derive_partial_eq_without_eq)]
2382    #[derive(Clone, PartialEq, ::prost::Oneof)]
2383    pub enum SelectorOptions {
2384        /// If `true` - return all vectors, if `false` - none
2385        #[prost(bool, tag = "1")]
2386        Enable(bool),
2387        /// List of payload keys to include into result
2388        #[prost(message, tag = "2")]
2389        Include(super::VectorsSelector),
2390    }
2391}
2392#[allow(clippy::derive_partial_eq_without_eq)]
2393#[derive(Clone, PartialEq, ::prost::Message)]
2394pub struct QuantizationSearchParams {
2395    ///
2396    /// If set to true, search will ignore quantized vector data
2397    #[prost(bool, optional, tag = "1")]
2398    pub ignore: ::core::option::Option<bool>,
2399    ///
2400    /// If true, use original vectors to re-score top-k results. Default is true.
2401    #[prost(bool, optional, tag = "2")]
2402    pub rescore: ::core::option::Option<bool>,
2403    ///
2404    /// Oversampling factor for quantization.
2405    ///
2406    /// Defines how many extra vectors should be pre-selected using quantized index,
2407    /// and then re-scored using original vectors.
2408    ///
2409    /// For example, if `oversampling` is 2.4 and `limit` is 100, then 240 vectors will be pre-selected using quantized index,
2410    /// and then top-100 will be returned after re-scoring.
2411    #[prost(double, optional, tag = "3")]
2412    pub oversampling: ::core::option::Option<f64>,
2413}
2414#[allow(clippy::derive_partial_eq_without_eq)]
2415#[derive(Clone, PartialEq, ::prost::Message)]
2416pub struct SearchParams {
2417    ///
2418    /// Params relevant to HNSW index. Size of the beam in a beam-search.
2419    /// Larger the value - more accurate the result, more time required for search.
2420    #[prost(uint64, optional, tag = "1")]
2421    pub hnsw_ef: ::core::option::Option<u64>,
2422    ///
2423    /// Search without approximation. If set to true, search may run long but with exact results.
2424    #[prost(bool, optional, tag = "2")]
2425    pub exact: ::core::option::Option<bool>,
2426    ///
2427    /// If set to true, search will ignore quantized vector data
2428    #[prost(message, optional, tag = "3")]
2429    pub quantization: ::core::option::Option<QuantizationSearchParams>,
2430}
2431#[allow(clippy::derive_partial_eq_without_eq)]
2432#[derive(Clone, PartialEq, ::prost::Message)]
2433pub struct SearchPoints {
2434    /// name of the collection
2435    #[prost(string, tag = "1")]
2436    pub collection_name: ::prost::alloc::string::String,
2437    /// vector
2438    #[prost(float, repeated, tag = "2")]
2439    pub vector: ::prost::alloc::vec::Vec<f32>,
2440    /// Filter conditions - return only those points that satisfy the specified conditions
2441    #[prost(message, optional, tag = "3")]
2442    pub filter: ::core::option::Option<Filter>,
2443    /// Max number of result
2444    #[prost(uint64, tag = "4")]
2445    pub limit: u64,
2446    /// Options for specifying which payload to include or not
2447    #[prost(message, optional, tag = "6")]
2448    pub with_payload: ::core::option::Option<WithPayloadSelector>,
2449    /// Search config
2450    #[prost(message, optional, tag = "7")]
2451    pub params: ::core::option::Option<SearchParams>,
2452    /// If provided - cut off results with worse scores
2453    #[prost(float, optional, tag = "8")]
2454    pub score_threshold: ::core::option::Option<f32>,
2455    /// Offset of the result
2456    #[prost(uint64, optional, tag = "9")]
2457    pub offset: ::core::option::Option<u64>,
2458    /// Which vector to use for search, if not specified - use default vector
2459    #[prost(string, optional, tag = "10")]
2460    pub vector_name: ::core::option::Option<::prost::alloc::string::String>,
2461    /// Options for specifying which vectors to include into response
2462    #[prost(message, optional, tag = "11")]
2463    pub with_vectors: ::core::option::Option<WithVectorsSelector>,
2464    /// Options for specifying read consistency guarantees
2465    #[prost(message, optional, tag = "12")]
2466    pub read_consistency: ::core::option::Option<ReadConsistency>,
2467}
2468#[allow(clippy::derive_partial_eq_without_eq)]
2469#[derive(Clone, PartialEq, ::prost::Message)]
2470pub struct SearchBatchPoints {
2471    /// Name of the collection
2472    #[prost(string, tag = "1")]
2473    pub collection_name: ::prost::alloc::string::String,
2474    #[prost(message, repeated, tag = "2")]
2475    pub search_points: ::prost::alloc::vec::Vec<SearchPoints>,
2476    /// Options for specifying read consistency guarantees
2477    #[prost(message, optional, tag = "3")]
2478    pub read_consistency: ::core::option::Option<ReadConsistency>,
2479}
2480#[allow(clippy::derive_partial_eq_without_eq)]
2481#[derive(Clone, PartialEq, ::prost::Message)]
2482pub struct WithLookup {
2483    /// Name of the collection to use for points lookup
2484    #[prost(string, tag = "1")]
2485    pub collection: ::prost::alloc::string::String,
2486    /// Options for specifying which payload to include (or not)
2487    #[prost(message, optional, tag = "2")]
2488    pub with_payload: ::core::option::Option<WithPayloadSelector>,
2489    /// Options for specifying which vectors to include (or not)
2490    #[prost(message, optional, tag = "3")]
2491    pub with_vectors: ::core::option::Option<WithVectorsSelector>,
2492}
2493#[allow(clippy::derive_partial_eq_without_eq)]
2494#[derive(Clone, PartialEq, ::prost::Message)]
2495pub struct SearchPointGroups {
2496    /// Name of the collection
2497    #[prost(string, tag = "1")]
2498    pub collection_name: ::prost::alloc::string::String,
2499    /// Vector to compare against
2500    #[prost(float, repeated, tag = "2")]
2501    pub vector: ::prost::alloc::vec::Vec<f32>,
2502    /// Filter conditions - return only those points that satisfy the specified conditions
2503    #[prost(message, optional, tag = "3")]
2504    pub filter: ::core::option::Option<Filter>,
2505    /// Max number of result
2506    #[prost(uint32, tag = "4")]
2507    pub limit: u32,
2508    /// Options for specifying which payload to include or not
2509    #[prost(message, optional, tag = "5")]
2510    pub with_payload: ::core::option::Option<WithPayloadSelector>,
2511    /// Search config
2512    #[prost(message, optional, tag = "6")]
2513    pub params: ::core::option::Option<SearchParams>,
2514    /// If provided - cut off results with worse scores
2515    #[prost(float, optional, tag = "7")]
2516    pub score_threshold: ::core::option::Option<f32>,
2517    /// Which vector to use for search, if not specified - use default vector
2518    #[prost(string, optional, tag = "8")]
2519    pub vector_name: ::core::option::Option<::prost::alloc::string::String>,
2520    /// Options for specifying which vectors to include into response
2521    #[prost(message, optional, tag = "9")]
2522    pub with_vectors: ::core::option::Option<WithVectorsSelector>,
2523    /// Payload field to group by, must be a string or number field. If there are multiple values for the field, all of them will be used. One point can be in multiple groups.
2524    #[prost(string, tag = "10")]
2525    pub group_by: ::prost::alloc::string::String,
2526    /// Maximum amount of points to return per group
2527    #[prost(uint32, tag = "11")]
2528    pub group_size: u32,
2529    /// Options for specifying read consistency guarantees
2530    #[prost(message, optional, tag = "12")]
2531    pub read_consistency: ::core::option::Option<ReadConsistency>,
2532    /// Options for specifying how to use the group id to lookup points in another collection
2533    #[prost(message, optional, tag = "13")]
2534    pub with_lookup: ::core::option::Option<WithLookup>,
2535}
2536#[allow(clippy::derive_partial_eq_without_eq)]
2537#[derive(Clone, PartialEq, ::prost::Message)]
2538pub struct ScrollPoints {
2539    #[prost(string, tag = "1")]
2540    pub collection_name: ::prost::alloc::string::String,
2541    /// Filter conditions - return only those points that satisfy the specified conditions
2542    #[prost(message, optional, tag = "2")]
2543    pub filter: ::core::option::Option<Filter>,
2544    /// Start with this ID
2545    #[prost(message, optional, tag = "3")]
2546    pub offset: ::core::option::Option<PointId>,
2547    /// Max number of result
2548    #[prost(uint32, optional, tag = "4")]
2549    pub limit: ::core::option::Option<u32>,
2550    /// Options for specifying which payload to include or not
2551    #[prost(message, optional, tag = "6")]
2552    pub with_payload: ::core::option::Option<WithPayloadSelector>,
2553    /// Options for specifying which vectors to include into response
2554    #[prost(message, optional, tag = "7")]
2555    pub with_vectors: ::core::option::Option<WithVectorsSelector>,
2556    /// Options for specifying read consistency guarantees
2557    #[prost(message, optional, tag = "8")]
2558    pub read_consistency: ::core::option::Option<ReadConsistency>,
2559}
2560#[allow(clippy::derive_partial_eq_without_eq)]
2561#[derive(Clone, PartialEq, ::prost::Message)]
2562pub struct LookupLocation {
2563    #[prost(string, tag = "1")]
2564    pub collection_name: ::prost::alloc::string::String,
2565    /// Which vector to use for search, if not specified - use default vector
2566    #[prost(string, optional, tag = "2")]
2567    pub vector_name: ::core::option::Option<::prost::alloc::string::String>,
2568}
2569#[allow(clippy::derive_partial_eq_without_eq)]
2570#[derive(Clone, PartialEq, ::prost::Message)]
2571pub struct RecommendPoints {
2572    /// name of the collection
2573    #[prost(string, tag = "1")]
2574    pub collection_name: ::prost::alloc::string::String,
2575    /// Look for vectors closest to those
2576    #[prost(message, repeated, tag = "2")]
2577    pub positive: ::prost::alloc::vec::Vec<PointId>,
2578    /// Try to avoid vectors like this
2579    #[prost(message, repeated, tag = "3")]
2580    pub negative: ::prost::alloc::vec::Vec<PointId>,
2581    /// Filter conditions - return only those points that satisfy the specified conditions
2582    #[prost(message, optional, tag = "4")]
2583    pub filter: ::core::option::Option<Filter>,
2584    /// Max number of result
2585    #[prost(uint64, tag = "5")]
2586    pub limit: u64,
2587    /// Options for specifying which payload to include or not
2588    #[prost(message, optional, tag = "7")]
2589    pub with_payload: ::core::option::Option<WithPayloadSelector>,
2590    /// Search config
2591    #[prost(message, optional, tag = "8")]
2592    pub params: ::core::option::Option<SearchParams>,
2593    /// If provided - cut off results with worse scores
2594    #[prost(float, optional, tag = "9")]
2595    pub score_threshold: ::core::option::Option<f32>,
2596    /// Offset of the result
2597    #[prost(uint64, optional, tag = "10")]
2598    pub offset: ::core::option::Option<u64>,
2599    /// Define which vector to use for recommendation, if not specified - default vector
2600    #[prost(string, optional, tag = "11")]
2601    pub using: ::core::option::Option<::prost::alloc::string::String>,
2602    /// Options for specifying which vectors to include into response
2603    #[prost(message, optional, tag = "12")]
2604    pub with_vectors: ::core::option::Option<WithVectorsSelector>,
2605    /// Name of the collection to use for points lookup, if not specified - use current collection
2606    #[prost(message, optional, tag = "13")]
2607    pub lookup_from: ::core::option::Option<LookupLocation>,
2608    /// Options for specifying read consistency guarantees
2609    #[prost(message, optional, tag = "14")]
2610    pub read_consistency: ::core::option::Option<ReadConsistency>,
2611}
2612#[allow(clippy::derive_partial_eq_without_eq)]
2613#[derive(Clone, PartialEq, ::prost::Message)]
2614pub struct RecommendBatchPoints {
2615    /// Name of the collection
2616    #[prost(string, tag = "1")]
2617    pub collection_name: ::prost::alloc::string::String,
2618    #[prost(message, repeated, tag = "2")]
2619    pub recommend_points: ::prost::alloc::vec::Vec<RecommendPoints>,
2620    /// Options for specifying read consistency guarantees
2621    #[prost(message, optional, tag = "3")]
2622    pub read_consistency: ::core::option::Option<ReadConsistency>,
2623}
2624#[allow(clippy::derive_partial_eq_without_eq)]
2625#[derive(Clone, PartialEq, ::prost::Message)]
2626pub struct RecommendPointGroups {
2627    /// Name of the collection
2628    #[prost(string, tag = "1")]
2629    pub collection_name: ::prost::alloc::string::String,
2630    /// Look for vectors closest to those
2631    #[prost(message, repeated, tag = "2")]
2632    pub positive: ::prost::alloc::vec::Vec<PointId>,
2633    /// Try to avoid vectors like this
2634    #[prost(message, repeated, tag = "3")]
2635    pub negative: ::prost::alloc::vec::Vec<PointId>,
2636    /// Filter conditions - return only those points that satisfy the specified conditions
2637    #[prost(message, optional, tag = "4")]
2638    pub filter: ::core::option::Option<Filter>,
2639    /// Max number of groups in result
2640    #[prost(uint32, tag = "5")]
2641    pub limit: u32,
2642    /// Options for specifying which payload to include or not
2643    #[prost(message, optional, tag = "6")]
2644    pub with_payload: ::core::option::Option<WithPayloadSelector>,
2645    /// Search config
2646    #[prost(message, optional, tag = "7")]
2647    pub params: ::core::option::Option<SearchParams>,
2648    /// If provided - cut off results with worse scores
2649    #[prost(float, optional, tag = "8")]
2650    pub score_threshold: ::core::option::Option<f32>,
2651    /// Define which vector to use for recommendation, if not specified - default vector
2652    #[prost(string, optional, tag = "9")]
2653    pub using: ::core::option::Option<::prost::alloc::string::String>,
2654    /// Options for specifying which vectors to include into response
2655    #[prost(message, optional, tag = "10")]
2656    pub with_vectors: ::core::option::Option<WithVectorsSelector>,
2657    /// Name of the collection to use for points lookup, if not specified - use current collection
2658    #[prost(message, optional, tag = "11")]
2659    pub lookup_from: ::core::option::Option<LookupLocation>,
2660    /// Payload field to group by, must be a string or number field. If there are multiple values for the field, all of them will be used. One point can be in multiple groups.
2661    #[prost(string, tag = "12")]
2662    pub group_by: ::prost::alloc::string::String,
2663    /// Maximum amount of points to return per group
2664    #[prost(uint32, tag = "13")]
2665    pub group_size: u32,
2666    /// Options for specifying read consistency guarantees
2667    #[prost(message, optional, tag = "14")]
2668    pub read_consistency: ::core::option::Option<ReadConsistency>,
2669    /// Options for specifying how to use the group id to lookup points in another collection
2670    #[prost(message, optional, tag = "15")]
2671    pub with_lookup: ::core::option::Option<WithLookup>,
2672}
2673#[allow(clippy::derive_partial_eq_without_eq)]
2674#[derive(Clone, PartialEq, ::prost::Message)]
2675pub struct CountPoints {
2676    /// name of the collection
2677    #[prost(string, tag = "1")]
2678    pub collection_name: ::prost::alloc::string::String,
2679    /// Filter conditions - return only those points that satisfy the specified conditions
2680    #[prost(message, optional, tag = "2")]
2681    pub filter: ::core::option::Option<Filter>,
2682    /// If `true` - return exact count, if `false` - return approximate count
2683    #[prost(bool, optional, tag = "3")]
2684    pub exact: ::core::option::Option<bool>,
2685}
2686#[allow(clippy::derive_partial_eq_without_eq)]
2687#[derive(Clone, PartialEq, ::prost::Message)]
2688pub struct PointsOperationResponse {
2689    #[prost(message, optional, tag = "1")]
2690    pub result: ::core::option::Option<UpdateResult>,
2691    /// Time spent to process
2692    #[prost(double, tag = "2")]
2693    pub time: f64,
2694}
2695#[allow(clippy::derive_partial_eq_without_eq)]
2696#[derive(Clone, PartialEq, ::prost::Message)]
2697pub struct UpdateResult {
2698    /// Number of operation
2699    #[prost(uint64, tag = "1")]
2700    pub operation_id: u64,
2701    /// Operation status
2702    #[prost(enumeration = "UpdateStatus", tag = "2")]
2703    pub status: i32,
2704}
2705#[allow(clippy::derive_partial_eq_without_eq)]
2706#[derive(Clone, PartialEq, ::prost::Message)]
2707pub struct ScoredPoint {
2708    /// Point id
2709    #[prost(message, optional, tag = "1")]
2710    pub id: ::core::option::Option<PointId>,
2711    /// Payload
2712    #[prost(map = "string, message", tag = "2")]
2713    pub payload: ::std::collections::HashMap<::prost::alloc::string::String, Value>,
2714    /// Similarity score
2715    #[prost(float, tag = "3")]
2716    pub score: f32,
2717    /// Last update operation applied to this point
2718    #[prost(uint64, tag = "5")]
2719    pub version: u64,
2720    /// Vectors to search
2721    #[prost(message, optional, tag = "6")]
2722    pub vectors: ::core::option::Option<Vectors>,
2723}
2724#[allow(clippy::derive_partial_eq_without_eq)]
2725#[derive(Clone, PartialEq, ::prost::Message)]
2726pub struct GroupId {
2727    #[prost(oneof = "group_id::Kind", tags = "1, 2, 3")]
2728    pub kind: ::core::option::Option<group_id::Kind>,
2729}
2730/// Nested message and enum types in `GroupId`.
2731pub mod group_id {
2732    #[allow(clippy::derive_partial_eq_without_eq)]
2733    #[derive(Clone, PartialEq, ::prost::Oneof)]
2734    pub enum Kind {
2735        /// Represents a double value.
2736        #[prost(uint64, tag = "1")]
2737        UnsignedValue(u64),
2738        /// Represents an integer value
2739        #[prost(int64, tag = "2")]
2740        IntegerValue(i64),
2741        /// Represents a string value.
2742        #[prost(string, tag = "3")]
2743        StringValue(::prost::alloc::string::String),
2744    }
2745}
2746#[allow(clippy::derive_partial_eq_without_eq)]
2747#[derive(Clone, PartialEq, ::prost::Message)]
2748pub struct PointGroup {
2749    /// Group id
2750    #[prost(message, optional, tag = "1")]
2751    pub id: ::core::option::Option<GroupId>,
2752    /// Points in the group
2753    #[prost(message, repeated, tag = "2")]
2754    pub hits: ::prost::alloc::vec::Vec<ScoredPoint>,
2755    /// Point(s) from the lookup collection that matches the group id
2756    #[prost(message, optional, tag = "3")]
2757    pub lookup: ::core::option::Option<RetrievedPoint>,
2758}
2759#[allow(clippy::derive_partial_eq_without_eq)]
2760#[derive(Clone, PartialEq, ::prost::Message)]
2761pub struct GroupsResult {
2762    /// Groups
2763    #[prost(message, repeated, tag = "1")]
2764    pub groups: ::prost::alloc::vec::Vec<PointGroup>,
2765}
2766#[allow(clippy::derive_partial_eq_without_eq)]
2767#[derive(Clone, PartialEq, ::prost::Message)]
2768pub struct SearchResponse {
2769    #[prost(message, repeated, tag = "1")]
2770    pub result: ::prost::alloc::vec::Vec<ScoredPoint>,
2771    /// Time spent to process
2772    #[prost(double, tag = "2")]
2773    pub time: f64,
2774}
2775#[allow(clippy::derive_partial_eq_without_eq)]
2776#[derive(Clone, PartialEq, ::prost::Message)]
2777pub struct BatchResult {
2778    #[prost(message, repeated, tag = "1")]
2779    pub result: ::prost::alloc::vec::Vec<ScoredPoint>,
2780}
2781#[allow(clippy::derive_partial_eq_without_eq)]
2782#[derive(Clone, PartialEq, ::prost::Message)]
2783pub struct SearchBatchResponse {
2784    #[prost(message, repeated, tag = "1")]
2785    pub result: ::prost::alloc::vec::Vec<BatchResult>,
2786    /// Time spent to process
2787    #[prost(double, tag = "2")]
2788    pub time: f64,
2789}
2790#[allow(clippy::derive_partial_eq_without_eq)]
2791#[derive(Clone, PartialEq, ::prost::Message)]
2792pub struct SearchGroupsResponse {
2793    #[prost(message, optional, tag = "1")]
2794    pub result: ::core::option::Option<GroupsResult>,
2795    /// Time spent to process
2796    #[prost(double, tag = "2")]
2797    pub time: f64,
2798}
2799#[allow(clippy::derive_partial_eq_without_eq)]
2800#[derive(Clone, PartialEq, ::prost::Message)]
2801pub struct CountResponse {
2802    #[prost(message, optional, tag = "1")]
2803    pub result: ::core::option::Option<CountResult>,
2804    /// Time spent to process
2805    #[prost(double, tag = "2")]
2806    pub time: f64,
2807}
2808#[allow(clippy::derive_partial_eq_without_eq)]
2809#[derive(Clone, PartialEq, ::prost::Message)]
2810pub struct ScrollResponse {
2811    /// Use this offset for the next query
2812    #[prost(message, optional, tag = "1")]
2813    pub next_page_offset: ::core::option::Option<PointId>,
2814    #[prost(message, repeated, tag = "2")]
2815    pub result: ::prost::alloc::vec::Vec<RetrievedPoint>,
2816    /// Time spent to process
2817    #[prost(double, tag = "3")]
2818    pub time: f64,
2819}
2820#[allow(clippy::derive_partial_eq_without_eq)]
2821#[derive(Clone, PartialEq, ::prost::Message)]
2822pub struct CountResult {
2823    #[prost(uint64, tag = "1")]
2824    pub count: u64,
2825}
2826#[allow(clippy::derive_partial_eq_without_eq)]
2827#[derive(Clone, PartialEq, ::prost::Message)]
2828pub struct RetrievedPoint {
2829    #[prost(message, optional, tag = "1")]
2830    pub id: ::core::option::Option<PointId>,
2831    #[prost(map = "string, message", tag = "2")]
2832    pub payload: ::std::collections::HashMap<::prost::alloc::string::String, Value>,
2833    #[prost(message, optional, tag = "4")]
2834    pub vectors: ::core::option::Option<Vectors>,
2835}
2836#[allow(clippy::derive_partial_eq_without_eq)]
2837#[derive(Clone, PartialEq, ::prost::Message)]
2838pub struct GetResponse {
2839    #[prost(message, repeated, tag = "1")]
2840    pub result: ::prost::alloc::vec::Vec<RetrievedPoint>,
2841    /// Time spent to process
2842    #[prost(double, tag = "2")]
2843    pub time: f64,
2844}
2845#[allow(clippy::derive_partial_eq_without_eq)]
2846#[derive(Clone, PartialEq, ::prost::Message)]
2847pub struct RecommendResponse {
2848    #[prost(message, repeated, tag = "1")]
2849    pub result: ::prost::alloc::vec::Vec<ScoredPoint>,
2850    /// Time spent to process
2851    #[prost(double, tag = "2")]
2852    pub time: f64,
2853}
2854#[allow(clippy::derive_partial_eq_without_eq)]
2855#[derive(Clone, PartialEq, ::prost::Message)]
2856pub struct RecommendBatchResponse {
2857    #[prost(message, repeated, tag = "1")]
2858    pub result: ::prost::alloc::vec::Vec<BatchResult>,
2859    /// Time spent to process
2860    #[prost(double, tag = "2")]
2861    pub time: f64,
2862}
2863#[allow(clippy::derive_partial_eq_without_eq)]
2864#[derive(Clone, PartialEq, ::prost::Message)]
2865pub struct RecommendGroupsResponse {
2866    #[prost(message, optional, tag = "1")]
2867    pub result: ::core::option::Option<GroupsResult>,
2868    /// Time spent to process
2869    #[prost(double, tag = "2")]
2870    pub time: f64,
2871}
2872#[allow(clippy::derive_partial_eq_without_eq)]
2873#[derive(Clone, PartialEq, ::prost::Message)]
2874pub struct Filter {
2875    /// At least one of those conditions should match
2876    #[prost(message, repeated, tag = "1")]
2877    pub should: ::prost::alloc::vec::Vec<Condition>,
2878    /// All conditions must match
2879    #[prost(message, repeated, tag = "2")]
2880    pub must: ::prost::alloc::vec::Vec<Condition>,
2881    /// All conditions must NOT match
2882    #[prost(message, repeated, tag = "3")]
2883    pub must_not: ::prost::alloc::vec::Vec<Condition>,
2884}
2885#[allow(clippy::derive_partial_eq_without_eq)]
2886#[derive(Clone, PartialEq, ::prost::Message)]
2887pub struct Condition {
2888    #[prost(oneof = "condition::ConditionOneOf", tags = "1, 2, 3, 4, 5, 6")]
2889    pub condition_one_of: ::core::option::Option<condition::ConditionOneOf>,
2890}
2891/// Nested message and enum types in `Condition`.
2892pub mod condition {
2893    #[allow(clippy::derive_partial_eq_without_eq)]
2894    #[derive(Clone, PartialEq, ::prost::Oneof)]
2895    pub enum ConditionOneOf {
2896        #[prost(message, tag = "1")]
2897        Field(super::FieldCondition),
2898        #[prost(message, tag = "2")]
2899        IsEmpty(super::IsEmptyCondition),
2900        #[prost(message, tag = "3")]
2901        HasId(super::HasIdCondition),
2902        #[prost(message, tag = "4")]
2903        Filter(super::Filter),
2904        #[prost(message, tag = "5")]
2905        IsNull(super::IsNullCondition),
2906        #[prost(message, tag = "6")]
2907        Nested(super::NestedCondition),
2908    }
2909}
2910#[allow(clippy::derive_partial_eq_without_eq)]
2911#[derive(Clone, PartialEq, ::prost::Message)]
2912pub struct IsEmptyCondition {
2913    #[prost(string, tag = "1")]
2914    pub key: ::prost::alloc::string::String,
2915}
2916#[allow(clippy::derive_partial_eq_without_eq)]
2917#[derive(Clone, PartialEq, ::prost::Message)]
2918pub struct IsNullCondition {
2919    #[prost(string, tag = "1")]
2920    pub key: ::prost::alloc::string::String,
2921}
2922#[allow(clippy::derive_partial_eq_without_eq)]
2923#[derive(Clone, PartialEq, ::prost::Message)]
2924pub struct HasIdCondition {
2925    #[prost(message, repeated, tag = "1")]
2926    pub has_id: ::prost::alloc::vec::Vec<PointId>,
2927}
2928#[allow(clippy::derive_partial_eq_without_eq)]
2929#[derive(Clone, PartialEq, ::prost::Message)]
2930pub struct NestedCondition {
2931    /// Path to nested object
2932    #[prost(string, tag = "1")]
2933    pub key: ::prost::alloc::string::String,
2934    /// Filter condition
2935    #[prost(message, optional, tag = "2")]
2936    pub filter: ::core::option::Option<Filter>,
2937}
2938#[allow(clippy::derive_partial_eq_without_eq)]
2939#[derive(Clone, PartialEq, ::prost::Message)]
2940pub struct FieldCondition {
2941    #[prost(string, tag = "1")]
2942    pub key: ::prost::alloc::string::String,
2943    /// Check if point has field with a given value
2944    #[prost(message, optional, tag = "2")]
2945    pub r#match: ::core::option::Option<Match>,
2946    /// Check if points value lies in a given range
2947    #[prost(message, optional, tag = "3")]
2948    pub range: ::core::option::Option<Range>,
2949    /// Check if points geolocation lies in a given area
2950    #[prost(message, optional, tag = "4")]
2951    pub geo_bounding_box: ::core::option::Option<GeoBoundingBox>,
2952    /// Check if geo point is within a given radius
2953    #[prost(message, optional, tag = "5")]
2954    pub geo_radius: ::core::option::Option<GeoRadius>,
2955    /// Check number of values for a specific field
2956    #[prost(message, optional, tag = "6")]
2957    pub values_count: ::core::option::Option<ValuesCount>,
2958}
2959#[allow(clippy::derive_partial_eq_without_eq)]
2960#[derive(Clone, PartialEq, ::prost::Message)]
2961pub struct Match {
2962    #[prost(oneof = "r#match::MatchValue", tags = "1, 2, 3, 4, 5, 6, 7, 8")]
2963    pub match_value: ::core::option::Option<r#match::MatchValue>,
2964}
2965/// Nested message and enum types in `Match`.
2966pub mod r#match {
2967    #[allow(clippy::derive_partial_eq_without_eq)]
2968    #[derive(Clone, PartialEq, ::prost::Oneof)]
2969    pub enum MatchValue {
2970        /// Match string keyword
2971        #[prost(string, tag = "1")]
2972        Keyword(::prost::alloc::string::String),
2973        /// Match integer
2974        #[prost(int64, tag = "2")]
2975        Integer(i64),
2976        /// Match boolean
2977        #[prost(bool, tag = "3")]
2978        Boolean(bool),
2979        /// Match text
2980        #[prost(string, tag = "4")]
2981        Text(::prost::alloc::string::String),
2982        /// Match multiple keywords
2983        #[prost(message, tag = "5")]
2984        Keywords(super::RepeatedStrings),
2985        /// Match multiple integers
2986        #[prost(message, tag = "6")]
2987        Integers(super::RepeatedIntegers),
2988        /// Match any other value except those integers
2989        #[prost(message, tag = "7")]
2990        ExceptIntegers(super::RepeatedIntegers),
2991        /// Match any other value except those keywords
2992        #[prost(message, tag = "8")]
2993        ExceptKeywords(super::RepeatedStrings),
2994    }
2995}
2996#[allow(clippy::derive_partial_eq_without_eq)]
2997#[derive(Clone, PartialEq, ::prost::Message)]
2998pub struct RepeatedStrings {
2999    #[prost(string, repeated, tag = "1")]
3000    pub strings: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
3001}
3002#[allow(clippy::derive_partial_eq_without_eq)]
3003#[derive(Clone, PartialEq, ::prost::Message)]
3004pub struct RepeatedIntegers {
3005    #[prost(int64, repeated, tag = "1")]
3006    pub integers: ::prost::alloc::vec::Vec<i64>,
3007}
3008#[allow(clippy::derive_partial_eq_without_eq)]
3009#[derive(Clone, PartialEq, ::prost::Message)]
3010pub struct Range {
3011    #[prost(double, optional, tag = "1")]
3012    pub lt: ::core::option::Option<f64>,
3013    #[prost(double, optional, tag = "2")]
3014    pub gt: ::core::option::Option<f64>,
3015    #[prost(double, optional, tag = "3")]
3016    pub gte: ::core::option::Option<f64>,
3017    #[prost(double, optional, tag = "4")]
3018    pub lte: ::core::option::Option<f64>,
3019}
3020#[allow(clippy::derive_partial_eq_without_eq)]
3021#[derive(Clone, PartialEq, ::prost::Message)]
3022pub struct GeoBoundingBox {
3023    /// north-west corner
3024    #[prost(message, optional, tag = "1")]
3025    pub top_left: ::core::option::Option<GeoPoint>,
3026    /// south-east corner
3027    #[prost(message, optional, tag = "2")]
3028    pub bottom_right: ::core::option::Option<GeoPoint>,
3029}
3030#[allow(clippy::derive_partial_eq_without_eq)]
3031#[derive(Clone, PartialEq, ::prost::Message)]
3032pub struct GeoRadius {
3033    /// Center of the circle
3034    #[prost(message, optional, tag = "1")]
3035    pub center: ::core::option::Option<GeoPoint>,
3036    /// In meters
3037    #[prost(float, tag = "2")]
3038    pub radius: f32,
3039}
3040#[allow(clippy::derive_partial_eq_without_eq)]
3041#[derive(Clone, PartialEq, ::prost::Message)]
3042pub struct GeoPolygon {
3043    /// Ordered list of coordinates representing the vertices of a polygon.
3044    /// The minimum size is 4, and the first coordinate and the last coordinate
3045    /// should be the same to form a closed polygon.
3046    #[prost(message, repeated, tag = "1")]
3047    pub points: ::prost::alloc::vec::Vec<GeoPoint>,
3048}
3049#[allow(clippy::derive_partial_eq_without_eq)]
3050#[derive(Clone, PartialEq, ::prost::Message)]
3051pub struct ValuesCount {
3052    #[prost(uint64, optional, tag = "1")]
3053    pub lt: ::core::option::Option<u64>,
3054    #[prost(uint64, optional, tag = "2")]
3055    pub gt: ::core::option::Option<u64>,
3056    #[prost(uint64, optional, tag = "3")]
3057    pub gte: ::core::option::Option<u64>,
3058    #[prost(uint64, optional, tag = "4")]
3059    pub lte: ::core::option::Option<u64>,
3060}
3061#[allow(clippy::derive_partial_eq_without_eq)]
3062#[derive(Clone, PartialEq, ::prost::Message)]
3063pub struct PointsSelector {
3064    #[prost(oneof = "points_selector::PointsSelectorOneOf", tags = "1, 2")]
3065    pub points_selector_one_of: ::core::option::Option<
3066        points_selector::PointsSelectorOneOf,
3067    >,
3068}
3069/// Nested message and enum types in `PointsSelector`.
3070pub mod points_selector {
3071    #[allow(clippy::derive_partial_eq_without_eq)]
3072    #[derive(Clone, PartialEq, ::prost::Oneof)]
3073    pub enum PointsSelectorOneOf {
3074        #[prost(message, tag = "1")]
3075        Points(super::PointsIdsList),
3076        #[prost(message, tag = "2")]
3077        Filter(super::Filter),
3078    }
3079}
3080#[allow(clippy::derive_partial_eq_without_eq)]
3081#[derive(Clone, PartialEq, ::prost::Message)]
3082pub struct PointsIdsList {
3083    #[prost(message, repeated, tag = "1")]
3084    pub ids: ::prost::alloc::vec::Vec<PointId>,
3085}
3086#[allow(clippy::derive_partial_eq_without_eq)]
3087#[derive(Clone, PartialEq, ::prost::Message)]
3088pub struct PointStruct {
3089    #[prost(message, optional, tag = "1")]
3090    pub id: ::core::option::Option<PointId>,
3091    #[prost(map = "string, message", tag = "3")]
3092    pub payload: ::std::collections::HashMap<::prost::alloc::string::String, Value>,
3093    #[prost(message, optional, tag = "4")]
3094    pub vectors: ::core::option::Option<Vectors>,
3095}
3096#[allow(clippy::derive_partial_eq_without_eq)]
3097#[derive(Clone, PartialEq, ::prost::Message)]
3098pub struct GeoPoint {
3099    #[prost(double, tag = "1")]
3100    pub lon: f64,
3101    #[prost(double, tag = "2")]
3102    pub lat: f64,
3103}
3104#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
3105#[repr(i32)]
3106pub enum WriteOrderingType {
3107    /// Write operations may be reordered, works faster, default
3108    Weak = 0,
3109    /// Write operations go through dynamically selected leader, may be inconsistent for a short period of time in case of leader change
3110    Medium = 1,
3111    /// Write operations go through the permanent leader, consistent, but may be unavailable if leader is down
3112    Strong = 2,
3113}
3114impl WriteOrderingType {
3115    /// String value of the enum field names used in the ProtoBuf definition.
3116    ///
3117    /// The values are not transformed in any way and thus are considered stable
3118    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
3119    pub fn as_str_name(&self) -> &'static str {
3120        match self {
3121            WriteOrderingType::Weak => "Weak",
3122            WriteOrderingType::Medium => "Medium",
3123            WriteOrderingType::Strong => "Strong",
3124        }
3125    }
3126    /// Creates an enum from field names used in the ProtoBuf definition.
3127    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
3128        match value {
3129            "Weak" => Some(Self::Weak),
3130            "Medium" => Some(Self::Medium),
3131            "Strong" => Some(Self::Strong),
3132            _ => None,
3133        }
3134    }
3135}
3136#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
3137#[repr(i32)]
3138pub enum ReadConsistencyType {
3139    /// Send request to all nodes and return points which are present on all of them
3140    All = 0,
3141    /// Send requests to all nodes and return points which are present on majority of them
3142    Majority = 1,
3143    /// Send requests to half + 1 nodes, return points which are present on all of them
3144    Quorum = 2,
3145}
3146impl ReadConsistencyType {
3147    /// String value of the enum field names used in the ProtoBuf definition.
3148    ///
3149    /// The values are not transformed in any way and thus are considered stable
3150    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
3151    pub fn as_str_name(&self) -> &'static str {
3152        match self {
3153            ReadConsistencyType::All => "All",
3154            ReadConsistencyType::Majority => "Majority",
3155            ReadConsistencyType::Quorum => "Quorum",
3156        }
3157    }
3158    /// Creates an enum from field names used in the ProtoBuf definition.
3159    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
3160        match value {
3161            "All" => Some(Self::All),
3162            "Majority" => Some(Self::Majority),
3163            "Quorum" => Some(Self::Quorum),
3164            _ => None,
3165        }
3166    }
3167}
3168#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
3169#[repr(i32)]
3170pub enum FieldType {
3171    Keyword = 0,
3172    Integer = 1,
3173    Float = 2,
3174    Geo = 3,
3175    Text = 4,
3176    Bool = 5,
3177}
3178impl FieldType {
3179    /// String value of the enum field names used in the ProtoBuf definition.
3180    ///
3181    /// The values are not transformed in any way and thus are considered stable
3182    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
3183    pub fn as_str_name(&self) -> &'static str {
3184        match self {
3185            FieldType::Keyword => "FieldTypeKeyword",
3186            FieldType::Integer => "FieldTypeInteger",
3187            FieldType::Float => "FieldTypeFloat",
3188            FieldType::Geo => "FieldTypeGeo",
3189            FieldType::Text => "FieldTypeText",
3190            FieldType::Bool => "FieldTypeBool",
3191        }
3192    }
3193    /// Creates an enum from field names used in the ProtoBuf definition.
3194    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
3195        match value {
3196            "FieldTypeKeyword" => Some(Self::Keyword),
3197            "FieldTypeInteger" => Some(Self::Integer),
3198            "FieldTypeFloat" => Some(Self::Float),
3199            "FieldTypeGeo" => Some(Self::Geo),
3200            "FieldTypeText" => Some(Self::Text),
3201            "FieldTypeBool" => Some(Self::Bool),
3202            _ => None,
3203        }
3204    }
3205}
3206#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
3207#[repr(i32)]
3208pub enum UpdateStatus {
3209    UnknownUpdateStatus = 0,
3210    /// Update is received, but not processed yet
3211    Acknowledged = 1,
3212    /// Update is applied and ready for search
3213    Completed = 2,
3214}
3215impl UpdateStatus {
3216    /// String value of the enum field names used in the ProtoBuf definition.
3217    ///
3218    /// The values are not transformed in any way and thus are considered stable
3219    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
3220    pub fn as_str_name(&self) -> &'static str {
3221        match self {
3222            UpdateStatus::UnknownUpdateStatus => "UnknownUpdateStatus",
3223            UpdateStatus::Acknowledged => "Acknowledged",
3224            UpdateStatus::Completed => "Completed",
3225        }
3226    }
3227    /// Creates an enum from field names used in the ProtoBuf definition.
3228    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
3229        match value {
3230            "UnknownUpdateStatus" => Some(Self::UnknownUpdateStatus),
3231            "Acknowledged" => Some(Self::Acknowledged),
3232            "Completed" => Some(Self::Completed),
3233            _ => None,
3234        }
3235    }
3236}
3237/// Generated client implementations.
3238pub mod points_client {
3239    #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)]
3240    use tonic::codegen::*;
3241    use tonic::codegen::http::Uri;
3242    #[derive(Debug, Clone)]
3243    pub struct PointsClient<T> {
3244        inner: tonic::client::Grpc<T>,
3245    }
3246    impl PointsClient<tonic::transport::Channel> {
3247        /// Attempt to create a new client by connecting to a given endpoint.
3248        pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
3249        where
3250            D: TryInto<tonic::transport::Endpoint>,
3251            D::Error: Into<StdError>,
3252        {
3253            let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
3254            Ok(Self::new(conn))
3255        }
3256    }
3257    impl<T> PointsClient<T>
3258    where
3259        T: tonic::client::GrpcService<tonic::body::BoxBody>,
3260        T::Error: Into<StdError>,
3261        T::ResponseBody: Body<Data = Bytes> + Send + 'static,
3262        <T::ResponseBody as Body>::Error: Into<StdError> + Send,
3263    {
3264        pub fn new(inner: T) -> Self {
3265            let inner = tonic::client::Grpc::new(inner);
3266            Self { inner }
3267        }
3268        pub fn with_origin(inner: T, origin: Uri) -> Self {
3269            let inner = tonic::client::Grpc::with_origin(inner, origin);
3270            Self { inner }
3271        }
3272        pub fn with_interceptor<F>(
3273            inner: T,
3274            interceptor: F,
3275        ) -> PointsClient<InterceptedService<T, F>>
3276        where
3277            F: tonic::service::Interceptor,
3278            T::ResponseBody: Default,
3279            T: tonic::codegen::Service<
3280                http::Request<tonic::body::BoxBody>,
3281                Response = http::Response<
3282                    <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
3283                >,
3284            >,
3285            <T as tonic::codegen::Service<
3286                http::Request<tonic::body::BoxBody>,
3287            >>::Error: Into<StdError> + Send + Sync,
3288        {
3289            PointsClient::new(InterceptedService::new(inner, interceptor))
3290        }
3291        /// Compress requests with the given encoding.
3292        ///
3293        /// This requires the server to support it otherwise it might respond with an
3294        /// error.
3295        #[must_use]
3296        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
3297            self.inner = self.inner.send_compressed(encoding);
3298            self
3299        }
3300        /// Enable decompressing responses.
3301        #[must_use]
3302        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
3303            self.inner = self.inner.accept_compressed(encoding);
3304            self
3305        }
3306        /// Limits the maximum size of a decoded message.
3307        ///
3308        /// Default: `4MB`
3309        #[must_use]
3310        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
3311            self.inner = self.inner.max_decoding_message_size(limit);
3312            self
3313        }
3314        /// Limits the maximum size of an encoded message.
3315        ///
3316        /// Default: `usize::MAX`
3317        #[must_use]
3318        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
3319            self.inner = self.inner.max_encoding_message_size(limit);
3320            self
3321        }
3322        ///
3323        /// Perform insert + updates on points. If a point with a given ID already exists - it will be overwritten.
3324        pub async fn upsert(
3325            &mut self,
3326            request: impl tonic::IntoRequest<super::UpsertPoints>,
3327        ) -> std::result::Result<
3328            tonic::Response<super::PointsOperationResponse>,
3329            tonic::Status,
3330        > {
3331            self.inner
3332                .ready()
3333                .await
3334                .map_err(|e| {
3335                    tonic::Status::new(
3336                        tonic::Code::Unknown,
3337                        format!("Service was not ready: {}", e.into()),
3338                    )
3339                })?;
3340            let codec = tonic::codec::ProstCodec::default();
3341            let path = http::uri::PathAndQuery::from_static("/arc_vector.Points/Upsert");
3342            let mut req = request.into_request();
3343            req.extensions_mut().insert(GrpcMethod::new("arc_vector.Points", "Upsert"));
3344            self.inner.unary(req, path, codec).await
3345        }
3346        ///
3347        /// Delete points
3348        pub async fn delete(
3349            &mut self,
3350            request: impl tonic::IntoRequest<super::DeletePoints>,
3351        ) -> std::result::Result<
3352            tonic::Response<super::PointsOperationResponse>,
3353            tonic::Status,
3354        > {
3355            self.inner
3356                .ready()
3357                .await
3358                .map_err(|e| {
3359                    tonic::Status::new(
3360                        tonic::Code::Unknown,
3361                        format!("Service was not ready: {}", e.into()),
3362                    )
3363                })?;
3364            let codec = tonic::codec::ProstCodec::default();
3365            let path = http::uri::PathAndQuery::from_static("/arc_vector.Points/Delete");
3366            let mut req = request.into_request();
3367            req.extensions_mut().insert(GrpcMethod::new("arc_vector.Points", "Delete"));
3368            self.inner.unary(req, path, codec).await
3369        }
3370        ///
3371        /// Retrieve points
3372        pub async fn get(
3373            &mut self,
3374            request: impl tonic::IntoRequest<super::GetPoints>,
3375        ) -> std::result::Result<tonic::Response<super::GetResponse>, tonic::Status> {
3376            self.inner
3377                .ready()
3378                .await
3379                .map_err(|e| {
3380                    tonic::Status::new(
3381                        tonic::Code::Unknown,
3382                        format!("Service was not ready: {}", e.into()),
3383                    )
3384                })?;
3385            let codec = tonic::codec::ProstCodec::default();
3386            let path = http::uri::PathAndQuery::from_static("/arc_vector.Points/Get");
3387            let mut req = request.into_request();
3388            req.extensions_mut().insert(GrpcMethod::new("arc_vector.Points", "Get"));
3389            self.inner.unary(req, path, codec).await
3390        }
3391        ///
3392        /// Update named vectors for point
3393        pub async fn update_vectors(
3394            &mut self,
3395            request: impl tonic::IntoRequest<super::UpdatePointVectors>,
3396        ) -> std::result::Result<
3397            tonic::Response<super::PointsOperationResponse>,
3398            tonic::Status,
3399        > {
3400            self.inner
3401                .ready()
3402                .await
3403                .map_err(|e| {
3404                    tonic::Status::new(
3405                        tonic::Code::Unknown,
3406                        format!("Service was not ready: {}", e.into()),
3407                    )
3408                })?;
3409            let codec = tonic::codec::ProstCodec::default();
3410            let path = http::uri::PathAndQuery::from_static(
3411                "/arc_vector.Points/UpdateVectors",
3412            );
3413            let mut req = request.into_request();
3414            req.extensions_mut()
3415                .insert(GrpcMethod::new("arc_vector.Points", "UpdateVectors"));
3416            self.inner.unary(req, path, codec).await
3417        }
3418        ///
3419        /// Delete named vectors for points
3420        pub async fn delete_vectors(
3421            &mut self,
3422            request: impl tonic::IntoRequest<super::DeletePointVectors>,
3423        ) -> std::result::Result<
3424            tonic::Response<super::PointsOperationResponse>,
3425            tonic::Status,
3426        > {
3427            self.inner
3428                .ready()
3429                .await
3430                .map_err(|e| {
3431                    tonic::Status::new(
3432                        tonic::Code::Unknown,
3433                        format!("Service was not ready: {}", e.into()),
3434                    )
3435                })?;
3436            let codec = tonic::codec::ProstCodec::default();
3437            let path = http::uri::PathAndQuery::from_static(
3438                "/arc_vector.Points/DeleteVectors",
3439            );
3440            let mut req = request.into_request();
3441            req.extensions_mut()
3442                .insert(GrpcMethod::new("arc_vector.Points", "DeleteVectors"));
3443            self.inner.unary(req, path, codec).await
3444        }
3445        ///
3446        /// Set payload for points
3447        pub async fn set_payload(
3448            &mut self,
3449            request: impl tonic::IntoRequest<super::SetPayloadPoints>,
3450        ) -> std::result::Result<
3451            tonic::Response<super::PointsOperationResponse>,
3452            tonic::Status,
3453        > {
3454            self.inner
3455                .ready()
3456                .await
3457                .map_err(|e| {
3458                    tonic::Status::new(
3459                        tonic::Code::Unknown,
3460                        format!("Service was not ready: {}", e.into()),
3461                    )
3462                })?;
3463            let codec = tonic::codec::ProstCodec::default();
3464            let path = http::uri::PathAndQuery::from_static("/arc_vector.Points/SetPayload");
3465            let mut req = request.into_request();
3466            req.extensions_mut().insert(GrpcMethod::new("arc_vector.Points", "SetPayload"));
3467            self.inner.unary(req, path, codec).await
3468        }
3469        ///
3470        /// Overwrite payload for points
3471        pub async fn overwrite_payload(
3472            &mut self,
3473            request: impl tonic::IntoRequest<super::SetPayloadPoints>,
3474        ) -> std::result::Result<
3475            tonic::Response<super::PointsOperationResponse>,
3476            tonic::Status,
3477        > {
3478            self.inner
3479                .ready()
3480                .await
3481                .map_err(|e| {
3482                    tonic::Status::new(
3483                        tonic::Code::Unknown,
3484                        format!("Service was not ready: {}", e.into()),
3485                    )
3486                })?;
3487            let codec = tonic::codec::ProstCodec::default();
3488            let path = http::uri::PathAndQuery::from_static(
3489                "/arc_vector.Points/OverwritePayload",
3490            );
3491            let mut req = request.into_request();
3492            req.extensions_mut()
3493                .insert(GrpcMethod::new("arc_vector.Points", "OverwritePayload"));
3494            self.inner.unary(req, path, codec).await
3495        }
3496        ///
3497        /// Delete specified key payload for points
3498        pub async fn delete_payload(
3499            &mut self,
3500            request: impl tonic::IntoRequest<super::DeletePayloadPoints>,
3501        ) -> std::result::Result<
3502            tonic::Response<super::PointsOperationResponse>,
3503            tonic::Status,
3504        > {
3505            self.inner
3506                .ready()
3507                .await
3508                .map_err(|e| {
3509                    tonic::Status::new(
3510                        tonic::Code::Unknown,
3511                        format!("Service was not ready: {}", e.into()),
3512                    )
3513                })?;
3514            let codec = tonic::codec::ProstCodec::default();
3515            let path = http::uri::PathAndQuery::from_static(
3516                "/arc_vector.Points/DeletePayload",
3517            );
3518            let mut req = request.into_request();
3519            req.extensions_mut()
3520                .insert(GrpcMethod::new("arc_vector.Points", "DeletePayload"));
3521            self.inner.unary(req, path, codec).await
3522        }
3523        ///
3524        /// Remove all payload for specified points
3525        pub async fn clear_payload(
3526            &mut self,
3527            request: impl tonic::IntoRequest<super::ClearPayloadPoints>,
3528        ) -> std::result::Result<
3529            tonic::Response<super::PointsOperationResponse>,
3530            tonic::Status,
3531        > {
3532            self.inner
3533                .ready()
3534                .await
3535                .map_err(|e| {
3536                    tonic::Status::new(
3537                        tonic::Code::Unknown,
3538                        format!("Service was not ready: {}", e.into()),
3539                    )
3540                })?;
3541            let codec = tonic::codec::ProstCodec::default();
3542            let path = http::uri::PathAndQuery::from_static(
3543                "/arc_vector.Points/ClearPayload",
3544            );
3545            let mut req = request.into_request();
3546            req.extensions_mut()
3547                .insert(GrpcMethod::new("arc_vector.Points", "ClearPayload"));
3548            self.inner.unary(req, path, codec).await
3549        }
3550        ///
3551        /// Create index for field in collection
3552        pub async fn create_field_index(
3553            &mut self,
3554            request: impl tonic::IntoRequest<super::CreateFieldIndexCollection>,
3555        ) -> std::result::Result<
3556            tonic::Response<super::PointsOperationResponse>,
3557            tonic::Status,
3558        > {
3559            self.inner
3560                .ready()
3561                .await
3562                .map_err(|e| {
3563                    tonic::Status::new(
3564                        tonic::Code::Unknown,
3565                        format!("Service was not ready: {}", e.into()),
3566                    )
3567                })?;
3568            let codec = tonic::codec::ProstCodec::default();
3569            let path = http::uri::PathAndQuery::from_static(
3570                "/arc_vector.Points/CreateFieldIndex",
3571            );
3572            let mut req = request.into_request();
3573            req.extensions_mut()
3574                .insert(GrpcMethod::new("arc_vector.Points", "CreateFieldIndex"));
3575            self.inner.unary(req, path, codec).await
3576        }
3577        ///
3578        /// Delete field index for collection
3579        pub async fn delete_field_index(
3580            &mut self,
3581            request: impl tonic::IntoRequest<super::DeleteFieldIndexCollection>,
3582        ) -> std::result::Result<
3583            tonic::Response<super::PointsOperationResponse>,
3584            tonic::Status,
3585        > {
3586            self.inner
3587                .ready()
3588                .await
3589                .map_err(|e| {
3590                    tonic::Status::new(
3591                        tonic::Code::Unknown,
3592                        format!("Service was not ready: {}", e.into()),
3593                    )
3594                })?;
3595            let codec = tonic::codec::ProstCodec::default();
3596            let path = http::uri::PathAndQuery::from_static(
3597                "/arc_vector.Points/DeleteFieldIndex",
3598            );
3599            let mut req = request.into_request();
3600            req.extensions_mut()
3601                .insert(GrpcMethod::new("arc_vector.Points", "DeleteFieldIndex"));
3602            self.inner.unary(req, path, codec).await
3603        }
3604        ///
3605        /// Retrieve closest points based on vector similarity and given filtering conditions
3606        pub async fn search(
3607            &mut self,
3608            request: impl tonic::IntoRequest<super::SearchPoints>,
3609        ) -> std::result::Result<tonic::Response<super::SearchResponse>, tonic::Status> {
3610            self.inner
3611                .ready()
3612                .await
3613                .map_err(|e| {
3614                    tonic::Status::new(
3615                        tonic::Code::Unknown,
3616                        format!("Service was not ready: {}", e.into()),
3617                    )
3618                })?;
3619            let codec = tonic::codec::ProstCodec::default();
3620            let path = http::uri::PathAndQuery::from_static("/arc_vector.Points/Search");
3621            let mut req = request.into_request();
3622            req.extensions_mut().insert(GrpcMethod::new("arc_vector.Points", "Search"));
3623            self.inner.unary(req, path, codec).await
3624        }
3625        ///
3626        /// Retrieve closest points based on vector similarity and given filtering conditions
3627        pub async fn search_batch(
3628            &mut self,
3629            request: impl tonic::IntoRequest<super::SearchBatchPoints>,
3630        ) -> std::result::Result<
3631            tonic::Response<super::SearchBatchResponse>,
3632            tonic::Status,
3633        > {
3634            self.inner
3635                .ready()
3636                .await
3637                .map_err(|e| {
3638                    tonic::Status::new(
3639                        tonic::Code::Unknown,
3640                        format!("Service was not ready: {}", e.into()),
3641                    )
3642                })?;
3643            let codec = tonic::codec::ProstCodec::default();
3644            let path = http::uri::PathAndQuery::from_static(
3645                "/arc_vector.Points/SearchBatch",
3646            );
3647            let mut req = request.into_request();
3648            req.extensions_mut().insert(GrpcMethod::new("arc_vector.Points", "SearchBatch"));
3649            self.inner.unary(req, path, codec).await
3650        }
3651        ///
3652        /// Retrieve closest points based on vector similarity and given filtering conditions, grouped by a given field
3653        pub async fn search_groups(
3654            &mut self,
3655            request: impl tonic::IntoRequest<super::SearchPointGroups>,
3656        ) -> std::result::Result<
3657            tonic::Response<super::SearchGroupsResponse>,
3658            tonic::Status,
3659        > {
3660            self.inner
3661                .ready()
3662                .await
3663                .map_err(|e| {
3664                    tonic::Status::new(
3665                        tonic::Code::Unknown,
3666                        format!("Service was not ready: {}", e.into()),
3667                    )
3668                })?;
3669            let codec = tonic::codec::ProstCodec::default();
3670            let path = http::uri::PathAndQuery::from_static(
3671                "/arc_vector.Points/SearchGroups",
3672            );
3673            let mut req = request.into_request();
3674            req.extensions_mut()
3675                .insert(GrpcMethod::new("arc_vector.Points", "SearchGroups"));
3676            self.inner.unary(req, path, codec).await
3677        }
3678        ///
3679        /// Iterate over all or filtered points points
3680        pub async fn scroll(
3681            &mut self,
3682            request: impl tonic::IntoRequest<super::ScrollPoints>,
3683        ) -> std::result::Result<tonic::Response<super::ScrollResponse>, tonic::Status> {
3684            self.inner
3685                .ready()
3686                .await
3687                .map_err(|e| {
3688                    tonic::Status::new(
3689                        tonic::Code::Unknown,
3690                        format!("Service was not ready: {}", e.into()),
3691                    )
3692                })?;
3693            let codec = tonic::codec::ProstCodec::default();
3694            let path = http::uri::PathAndQuery::from_static("/arc_vector.Points/Scroll");
3695            let mut req = request.into_request();
3696            req.extensions_mut().insert(GrpcMethod::new("arc_vector.Points", "Scroll"));
3697            self.inner.unary(req, path, codec).await
3698        }
3699        ///
3700        /// Look for the points which are closer to stored positive examples and at the same time further to negative examples.
3701        pub async fn recommend(
3702            &mut self,
3703            request: impl tonic::IntoRequest<super::RecommendPoints>,
3704        ) -> std::result::Result<
3705            tonic::Response<super::RecommendResponse>,
3706            tonic::Status,
3707        > {
3708            self.inner
3709                .ready()
3710                .await
3711                .map_err(|e| {
3712                    tonic::Status::new(
3713                        tonic::Code::Unknown,
3714                        format!("Service was not ready: {}", e.into()),
3715                    )
3716                })?;
3717            let codec = tonic::codec::ProstCodec::default();
3718            let path = http::uri::PathAndQuery::from_static("/arc_vector.Points/Recommend");
3719            let mut req = request.into_request();
3720            req.extensions_mut().insert(GrpcMethod::new("arc_vector.Points", "Recommend"));
3721            self.inner.unary(req, path, codec).await
3722        }
3723        ///
3724        /// Look for the points which are closer to stored positive examples and at the same time further to negative examples.
3725        pub async fn recommend_batch(
3726            &mut self,
3727            request: impl tonic::IntoRequest<super::RecommendBatchPoints>,
3728        ) -> std::result::Result<
3729            tonic::Response<super::RecommendBatchResponse>,
3730            tonic::Status,
3731        > {
3732            self.inner
3733                .ready()
3734                .await
3735                .map_err(|e| {
3736                    tonic::Status::new(
3737                        tonic::Code::Unknown,
3738                        format!("Service was not ready: {}", e.into()),
3739                    )
3740                })?;
3741            let codec = tonic::codec::ProstCodec::default();
3742            let path = http::uri::PathAndQuery::from_static(
3743                "/arc_vector.Points/RecommendBatch",
3744            );
3745            let mut req = request.into_request();
3746            req.extensions_mut()
3747                .insert(GrpcMethod::new("arc_vector.Points", "RecommendBatch"));
3748            self.inner.unary(req, path, codec).await
3749        }
3750        ///
3751        /// Look for the points which are closer to stored positive examples and at the same time further to negative examples, grouped by a given field
3752        pub async fn recommend_groups(
3753            &mut self,
3754            request: impl tonic::IntoRequest<super::RecommendPointGroups>,
3755        ) -> std::result::Result<
3756            tonic::Response<super::RecommendGroupsResponse>,
3757            tonic::Status,
3758        > {
3759            self.inner
3760                .ready()
3761                .await
3762                .map_err(|e| {
3763                    tonic::Status::new(
3764                        tonic::Code::Unknown,
3765                        format!("Service was not ready: {}", e.into()),
3766                    )
3767                })?;
3768            let codec = tonic::codec::ProstCodec::default();
3769            let path = http::uri::PathAndQuery::from_static(
3770                "/arc_vector.Points/RecommendGroups",
3771            );
3772            let mut req = request.into_request();
3773            req.extensions_mut()
3774                .insert(GrpcMethod::new("arc_vector.Points", "RecommendGroups"));
3775            self.inner.unary(req, path, codec).await
3776        }
3777        ///
3778        /// Count points in collection with given filtering conditions
3779        pub async fn count(
3780            &mut self,
3781            request: impl tonic::IntoRequest<super::CountPoints>,
3782        ) -> std::result::Result<tonic::Response<super::CountResponse>, tonic::Status> {
3783            self.inner
3784                .ready()
3785                .await
3786                .map_err(|e| {
3787                    tonic::Status::new(
3788                        tonic::Code::Unknown,
3789                        format!("Service was not ready: {}", e.into()),
3790                    )
3791                })?;
3792            let codec = tonic::codec::ProstCodec::default();
3793            let path = http::uri::PathAndQuery::from_static("/arc_vector.Points/Count");
3794            let mut req = request.into_request();
3795            req.extensions_mut().insert(GrpcMethod::new("arc_vector.Points", "Count"));
3796            self.inner.unary(req, path, codec).await
3797        }
3798    }
3799}
3800/// Generated server implementations.
3801pub mod points_server {
3802    #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)]
3803    use tonic::codegen::*;
3804    /// Generated trait containing gRPC methods that should be implemented for use with PointsServer.
3805    #[async_trait]
3806    pub trait Points: Send + Sync + 'static {
3807        ///
3808        /// Perform insert + updates on points. If a point with a given ID already exists - it will be overwritten.
3809        async fn upsert(
3810            &self,
3811            request: tonic::Request<super::UpsertPoints>,
3812        ) -> std::result::Result<
3813            tonic::Response<super::PointsOperationResponse>,
3814            tonic::Status,
3815        >;
3816        ///
3817        /// Delete points
3818        async fn delete(
3819            &self,
3820            request: tonic::Request<super::DeletePoints>,
3821        ) -> std::result::Result<
3822            tonic::Response<super::PointsOperationResponse>,
3823            tonic::Status,
3824        >;
3825        ///
3826        /// Retrieve points
3827        async fn get(
3828            &self,
3829            request: tonic::Request<super::GetPoints>,
3830        ) -> std::result::Result<tonic::Response<super::GetResponse>, tonic::Status>;
3831        ///
3832        /// Update named vectors for point
3833        async fn update_vectors(
3834            &self,
3835            request: tonic::Request<super::UpdatePointVectors>,
3836        ) -> std::result::Result<
3837            tonic::Response<super::PointsOperationResponse>,
3838            tonic::Status,
3839        >;
3840        ///
3841        /// Delete named vectors for points
3842        async fn delete_vectors(
3843            &self,
3844            request: tonic::Request<super::DeletePointVectors>,
3845        ) -> std::result::Result<
3846            tonic::Response<super::PointsOperationResponse>,
3847            tonic::Status,
3848        >;
3849        ///
3850        /// Set payload for points
3851        async fn set_payload(
3852            &self,
3853            request: tonic::Request<super::SetPayloadPoints>,
3854        ) -> std::result::Result<
3855            tonic::Response<super::PointsOperationResponse>,
3856            tonic::Status,
3857        >;
3858        ///
3859        /// Overwrite payload for points
3860        async fn overwrite_payload(
3861            &self,
3862            request: tonic::Request<super::SetPayloadPoints>,
3863        ) -> std::result::Result<
3864            tonic::Response<super::PointsOperationResponse>,
3865            tonic::Status,
3866        >;
3867        ///
3868        /// Delete specified key payload for points
3869        async fn delete_payload(
3870            &self,
3871            request: tonic::Request<super::DeletePayloadPoints>,
3872        ) -> std::result::Result<
3873            tonic::Response<super::PointsOperationResponse>,
3874            tonic::Status,
3875        >;
3876        ///
3877        /// Remove all payload for specified points
3878        async fn clear_payload(
3879            &self,
3880            request: tonic::Request<super::ClearPayloadPoints>,
3881        ) -> std::result::Result<
3882            tonic::Response<super::PointsOperationResponse>,
3883            tonic::Status,
3884        >;
3885        ///
3886        /// Create index for field in collection
3887        async fn create_field_index(
3888            &self,
3889            request: tonic::Request<super::CreateFieldIndexCollection>,
3890        ) -> std::result::Result<
3891            tonic::Response<super::PointsOperationResponse>,
3892            tonic::Status,
3893        >;
3894        ///
3895        /// Delete field index for collection
3896        async fn delete_field_index(
3897            &self,
3898            request: tonic::Request<super::DeleteFieldIndexCollection>,
3899        ) -> std::result::Result<
3900            tonic::Response<super::PointsOperationResponse>,
3901            tonic::Status,
3902        >;
3903        ///
3904        /// Retrieve closest points based on vector similarity and given filtering conditions
3905        async fn search(
3906            &self,
3907            request: tonic::Request<super::SearchPoints>,
3908        ) -> std::result::Result<tonic::Response<super::SearchResponse>, tonic::Status>;
3909        ///
3910        /// Retrieve closest points based on vector similarity and given filtering conditions
3911        async fn search_batch(
3912            &self,
3913            request: tonic::Request<super::SearchBatchPoints>,
3914        ) -> std::result::Result<
3915            tonic::Response<super::SearchBatchResponse>,
3916            tonic::Status,
3917        >;
3918        ///
3919        /// Retrieve closest points based on vector similarity and given filtering conditions, grouped by a given field
3920        async fn search_groups(
3921            &self,
3922            request: tonic::Request<super::SearchPointGroups>,
3923        ) -> std::result::Result<
3924            tonic::Response<super::SearchGroupsResponse>,
3925            tonic::Status,
3926        >;
3927        ///
3928        /// Iterate over all or filtered points points
3929        async fn scroll(
3930            &self,
3931            request: tonic::Request<super::ScrollPoints>,
3932        ) -> std::result::Result<tonic::Response<super::ScrollResponse>, tonic::Status>;
3933        ///
3934        /// Look for the points which are closer to stored positive examples and at the same time further to negative examples.
3935        async fn recommend(
3936            &self,
3937            request: tonic::Request<super::RecommendPoints>,
3938        ) -> std::result::Result<
3939            tonic::Response<super::RecommendResponse>,
3940            tonic::Status,
3941        >;
3942        ///
3943        /// Look for the points which are closer to stored positive examples and at the same time further to negative examples.
3944        async fn recommend_batch(
3945            &self,
3946            request: tonic::Request<super::RecommendBatchPoints>,
3947        ) -> std::result::Result<
3948            tonic::Response<super::RecommendBatchResponse>,
3949            tonic::Status,
3950        >;
3951        ///
3952        /// Look for the points which are closer to stored positive examples and at the same time further to negative examples, grouped by a given field
3953        async fn recommend_groups(
3954            &self,
3955            request: tonic::Request<super::RecommendPointGroups>,
3956        ) -> std::result::Result<
3957            tonic::Response<super::RecommendGroupsResponse>,
3958            tonic::Status,
3959        >;
3960        ///
3961        /// Count points in collection with given filtering conditions
3962        async fn count(
3963            &self,
3964            request: tonic::Request<super::CountPoints>,
3965        ) -> std::result::Result<tonic::Response<super::CountResponse>, tonic::Status>;
3966    }
3967    #[derive(Debug)]
3968    pub struct PointsServer<T: Points> {
3969        inner: _Inner<T>,
3970        accept_compression_encodings: EnabledCompressionEncodings,
3971        send_compression_encodings: EnabledCompressionEncodings,
3972        max_decoding_message_size: Option<usize>,
3973        max_encoding_message_size: Option<usize>,
3974    }
3975    struct _Inner<T>(Arc<T>);
3976    impl<T: Points> PointsServer<T> {
3977        pub fn new(inner: T) -> Self {
3978            Self::from_arc(Arc::new(inner))
3979        }
3980        pub fn from_arc(inner: Arc<T>) -> Self {
3981            let inner = _Inner(inner);
3982            Self {
3983                inner,
3984                accept_compression_encodings: Default::default(),
3985                send_compression_encodings: Default::default(),
3986                max_decoding_message_size: None,
3987                max_encoding_message_size: None,
3988            }
3989        }
3990        pub fn with_interceptor<F>(
3991            inner: T,
3992            interceptor: F,
3993        ) -> InterceptedService<Self, F>
3994        where
3995            F: tonic::service::Interceptor,
3996        {
3997            InterceptedService::new(Self::new(inner), interceptor)
3998        }
3999        /// Enable decompressing requests with the given encoding.
4000        #[must_use]
4001        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
4002            self.accept_compression_encodings.enable(encoding);
4003            self
4004        }
4005        /// Compress responses with the given encoding, if the client supports it.
4006        #[must_use]
4007        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
4008            self.send_compression_encodings.enable(encoding);
4009            self
4010        }
4011        /// Limits the maximum size of a decoded message.
4012        ///
4013        /// Default: `4MB`
4014        #[must_use]
4015        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
4016            self.max_decoding_message_size = Some(limit);
4017            self
4018        }
4019        /// Limits the maximum size of an encoded message.
4020        ///
4021        /// Default: `usize::MAX`
4022        #[must_use]
4023        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
4024            self.max_encoding_message_size = Some(limit);
4025            self
4026        }
4027    }
4028    impl<T, B> tonic::codegen::Service<http::Request<B>> for PointsServer<T>
4029    where
4030        T: Points,
4031        B: Body + Send + 'static,
4032        B::Error: Into<StdError> + Send + 'static,
4033    {
4034        type Response = http::Response<tonic::body::BoxBody>;
4035        type Error = std::convert::Infallible;
4036        type Future = BoxFuture<Self::Response, Self::Error>;
4037        fn poll_ready(
4038            &mut self,
4039            _cx: &mut Context<'_>,
4040        ) -> Poll<std::result::Result<(), Self::Error>> {
4041            Poll::Ready(Ok(()))
4042        }
4043        fn call(&mut self, req: http::Request<B>) -> Self::Future {
4044            let inner = self.inner.clone();
4045            match req.uri().path() {
4046                "/arc_vector.Points/Upsert" => {
4047                    #[allow(non_camel_case_types)]
4048                    struct UpsertSvc<T: Points>(pub Arc<T>);
4049                    impl<T: Points> tonic::server::UnaryService<super::UpsertPoints>
4050                    for UpsertSvc<T> {
4051                        type Response = super::PointsOperationResponse;
4052                        type Future = BoxFuture<
4053                            tonic::Response<Self::Response>,
4054                            tonic::Status,
4055                        >;
4056                        fn call(
4057                            &mut self,
4058                            request: tonic::Request<super::UpsertPoints>,
4059                        ) -> Self::Future {
4060                            let inner = Arc::clone(&self.0);
4061                            let fut = async move { (*inner).upsert(request).await };
4062                            Box::pin(fut)
4063                        }
4064                    }
4065                    let accept_compression_encodings = self.accept_compression_encodings;
4066                    let send_compression_encodings = self.send_compression_encodings;
4067                    let max_decoding_message_size = self.max_decoding_message_size;
4068                    let max_encoding_message_size = self.max_encoding_message_size;
4069                    let inner = self.inner.clone();
4070                    let fut = async move {
4071                        let inner = inner.0;
4072                        let method = UpsertSvc(inner);
4073                        let codec = tonic::codec::ProstCodec::default();
4074                        let mut grpc = tonic::server::Grpc::new(codec)
4075                            .apply_compression_config(
4076                                accept_compression_encodings,
4077                                send_compression_encodings,
4078                            )
4079                            .apply_max_message_size_config(
4080                                max_decoding_message_size,
4081                                max_encoding_message_size,
4082                            );
4083                        let res = grpc.unary(method, req).await;
4084                        Ok(res)
4085                    };
4086                    Box::pin(fut)
4087                }
4088                "/arc_vector.Points/Delete" => {
4089                    #[allow(non_camel_case_types)]
4090                    struct DeleteSvc<T: Points>(pub Arc<T>);
4091                    impl<T: Points> tonic::server::UnaryService<super::DeletePoints>
4092                    for DeleteSvc<T> {
4093                        type Response = super::PointsOperationResponse;
4094                        type Future = BoxFuture<
4095                            tonic::Response<Self::Response>,
4096                            tonic::Status,
4097                        >;
4098                        fn call(
4099                            &mut self,
4100                            request: tonic::Request<super::DeletePoints>,
4101                        ) -> Self::Future {
4102                            let inner = Arc::clone(&self.0);
4103                            let fut = async move { (*inner).delete(request).await };
4104                            Box::pin(fut)
4105                        }
4106                    }
4107                    let accept_compression_encodings = self.accept_compression_encodings;
4108                    let send_compression_encodings = self.send_compression_encodings;
4109                    let max_decoding_message_size = self.max_decoding_message_size;
4110                    let max_encoding_message_size = self.max_encoding_message_size;
4111                    let inner = self.inner.clone();
4112                    let fut = async move {
4113                        let inner = inner.0;
4114                        let method = DeleteSvc(inner);
4115                        let codec = tonic::codec::ProstCodec::default();
4116                        let mut grpc = tonic::server::Grpc::new(codec)
4117                            .apply_compression_config(
4118                                accept_compression_encodings,
4119                                send_compression_encodings,
4120                            )
4121                            .apply_max_message_size_config(
4122                                max_decoding_message_size,
4123                                max_encoding_message_size,
4124                            );
4125                        let res = grpc.unary(method, req).await;
4126                        Ok(res)
4127                    };
4128                    Box::pin(fut)
4129                }
4130                "/arc_vector.Points/Get" => {
4131                    #[allow(non_camel_case_types)]
4132                    struct GetSvc<T: Points>(pub Arc<T>);
4133                    impl<T: Points> tonic::server::UnaryService<super::GetPoints>
4134                    for GetSvc<T> {
4135                        type Response = super::GetResponse;
4136                        type Future = BoxFuture<
4137                            tonic::Response<Self::Response>,
4138                            tonic::Status,
4139                        >;
4140                        fn call(
4141                            &mut self,
4142                            request: tonic::Request<super::GetPoints>,
4143                        ) -> Self::Future {
4144                            let inner = Arc::clone(&self.0);
4145                            let fut = async move { (*inner).get(request).await };
4146                            Box::pin(fut)
4147                        }
4148                    }
4149                    let accept_compression_encodings = self.accept_compression_encodings;
4150                    let send_compression_encodings = self.send_compression_encodings;
4151                    let max_decoding_message_size = self.max_decoding_message_size;
4152                    let max_encoding_message_size = self.max_encoding_message_size;
4153                    let inner = self.inner.clone();
4154                    let fut = async move {
4155                        let inner = inner.0;
4156                        let method = GetSvc(inner);
4157                        let codec = tonic::codec::ProstCodec::default();
4158                        let mut grpc = tonic::server::Grpc::new(codec)
4159                            .apply_compression_config(
4160                                accept_compression_encodings,
4161                                send_compression_encodings,
4162                            )
4163                            .apply_max_message_size_config(
4164                                max_decoding_message_size,
4165                                max_encoding_message_size,
4166                            );
4167                        let res = grpc.unary(method, req).await;
4168                        Ok(res)
4169                    };
4170                    Box::pin(fut)
4171                }
4172                "/arc_vector.Points/UpdateVectors" => {
4173                    #[allow(non_camel_case_types)]
4174                    struct UpdateVectorsSvc<T: Points>(pub Arc<T>);
4175                    impl<
4176                        T: Points,
4177                    > tonic::server::UnaryService<super::UpdatePointVectors>
4178                    for UpdateVectorsSvc<T> {
4179                        type Response = super::PointsOperationResponse;
4180                        type Future = BoxFuture<
4181                            tonic::Response<Self::Response>,
4182                            tonic::Status,
4183                        >;
4184                        fn call(
4185                            &mut self,
4186                            request: tonic::Request<super::UpdatePointVectors>,
4187                        ) -> Self::Future {
4188                            let inner = Arc::clone(&self.0);
4189                            let fut = async move {
4190                                (*inner).update_vectors(request).await
4191                            };
4192                            Box::pin(fut)
4193                        }
4194                    }
4195                    let accept_compression_encodings = self.accept_compression_encodings;
4196                    let send_compression_encodings = self.send_compression_encodings;
4197                    let max_decoding_message_size = self.max_decoding_message_size;
4198                    let max_encoding_message_size = self.max_encoding_message_size;
4199                    let inner = self.inner.clone();
4200                    let fut = async move {
4201                        let inner = inner.0;
4202                        let method = UpdateVectorsSvc(inner);
4203                        let codec = tonic::codec::ProstCodec::default();
4204                        let mut grpc = tonic::server::Grpc::new(codec)
4205                            .apply_compression_config(
4206                                accept_compression_encodings,
4207                                send_compression_encodings,
4208                            )
4209                            .apply_max_message_size_config(
4210                                max_decoding_message_size,
4211                                max_encoding_message_size,
4212                            );
4213                        let res = grpc.unary(method, req).await;
4214                        Ok(res)
4215                    };
4216                    Box::pin(fut)
4217                }
4218                "/arc_vector.Points/DeleteVectors" => {
4219                    #[allow(non_camel_case_types)]
4220                    struct DeleteVectorsSvc<T: Points>(pub Arc<T>);
4221                    impl<
4222                        T: Points,
4223                    > tonic::server::UnaryService<super::DeletePointVectors>
4224                    for DeleteVectorsSvc<T> {
4225                        type Response = super::PointsOperationResponse;
4226                        type Future = BoxFuture<
4227                            tonic::Response<Self::Response>,
4228                            tonic::Status,
4229                        >;
4230                        fn call(
4231                            &mut self,
4232                            request: tonic::Request<super::DeletePointVectors>,
4233                        ) -> Self::Future {
4234                            let inner = Arc::clone(&self.0);
4235                            let fut = async move {
4236                                (*inner).delete_vectors(request).await
4237                            };
4238                            Box::pin(fut)
4239                        }
4240                    }
4241                    let accept_compression_encodings = self.accept_compression_encodings;
4242                    let send_compression_encodings = self.send_compression_encodings;
4243                    let max_decoding_message_size = self.max_decoding_message_size;
4244                    let max_encoding_message_size = self.max_encoding_message_size;
4245                    let inner = self.inner.clone();
4246                    let fut = async move {
4247                        let inner = inner.0;
4248                        let method = DeleteVectorsSvc(inner);
4249                        let codec = tonic::codec::ProstCodec::default();
4250                        let mut grpc = tonic::server::Grpc::new(codec)
4251                            .apply_compression_config(
4252                                accept_compression_encodings,
4253                                send_compression_encodings,
4254                            )
4255                            .apply_max_message_size_config(
4256                                max_decoding_message_size,
4257                                max_encoding_message_size,
4258                            );
4259                        let res = grpc.unary(method, req).await;
4260                        Ok(res)
4261                    };
4262                    Box::pin(fut)
4263                }
4264                "/arc_vector.Points/SetPayload" => {
4265                    #[allow(non_camel_case_types)]
4266                    struct SetPayloadSvc<T: Points>(pub Arc<T>);
4267                    impl<T: Points> tonic::server::UnaryService<super::SetPayloadPoints>
4268                    for SetPayloadSvc<T> {
4269                        type Response = super::PointsOperationResponse;
4270                        type Future = BoxFuture<
4271                            tonic::Response<Self::Response>,
4272                            tonic::Status,
4273                        >;
4274                        fn call(
4275                            &mut self,
4276                            request: tonic::Request<super::SetPayloadPoints>,
4277                        ) -> Self::Future {
4278                            let inner = Arc::clone(&self.0);
4279                            let fut = async move { (*inner).set_payload(request).await };
4280                            Box::pin(fut)
4281                        }
4282                    }
4283                    let accept_compression_encodings = self.accept_compression_encodings;
4284                    let send_compression_encodings = self.send_compression_encodings;
4285                    let max_decoding_message_size = self.max_decoding_message_size;
4286                    let max_encoding_message_size = self.max_encoding_message_size;
4287                    let inner = self.inner.clone();
4288                    let fut = async move {
4289                        let inner = inner.0;
4290                        let method = SetPayloadSvc(inner);
4291                        let codec = tonic::codec::ProstCodec::default();
4292                        let mut grpc = tonic::server::Grpc::new(codec)
4293                            .apply_compression_config(
4294                                accept_compression_encodings,
4295                                send_compression_encodings,
4296                            )
4297                            .apply_max_message_size_config(
4298                                max_decoding_message_size,
4299                                max_encoding_message_size,
4300                            );
4301                        let res = grpc.unary(method, req).await;
4302                        Ok(res)
4303                    };
4304                    Box::pin(fut)
4305                }
4306                "/arc_vector.Points/OverwritePayload" => {
4307                    #[allow(non_camel_case_types)]
4308                    struct OverwritePayloadSvc<T: Points>(pub Arc<T>);
4309                    impl<T: Points> tonic::server::UnaryService<super::SetPayloadPoints>
4310                    for OverwritePayloadSvc<T> {
4311                        type Response = super::PointsOperationResponse;
4312                        type Future = BoxFuture<
4313                            tonic::Response<Self::Response>,
4314                            tonic::Status,
4315                        >;
4316                        fn call(
4317                            &mut self,
4318                            request: tonic::Request<super::SetPayloadPoints>,
4319                        ) -> Self::Future {
4320                            let inner = Arc::clone(&self.0);
4321                            let fut = async move {
4322                                (*inner).overwrite_payload(request).await
4323                            };
4324                            Box::pin(fut)
4325                        }
4326                    }
4327                    let accept_compression_encodings = self.accept_compression_encodings;
4328                    let send_compression_encodings = self.send_compression_encodings;
4329                    let max_decoding_message_size = self.max_decoding_message_size;
4330                    let max_encoding_message_size = self.max_encoding_message_size;
4331                    let inner = self.inner.clone();
4332                    let fut = async move {
4333                        let inner = inner.0;
4334                        let method = OverwritePayloadSvc(inner);
4335                        let codec = tonic::codec::ProstCodec::default();
4336                        let mut grpc = tonic::server::Grpc::new(codec)
4337                            .apply_compression_config(
4338                                accept_compression_encodings,
4339                                send_compression_encodings,
4340                            )
4341                            .apply_max_message_size_config(
4342                                max_decoding_message_size,
4343                                max_encoding_message_size,
4344                            );
4345                        let res = grpc.unary(method, req).await;
4346                        Ok(res)
4347                    };
4348                    Box::pin(fut)
4349                }
4350                "/arc_vector.Points/DeletePayload" => {
4351                    #[allow(non_camel_case_types)]
4352                    struct DeletePayloadSvc<T: Points>(pub Arc<T>);
4353                    impl<
4354                        T: Points,
4355                    > tonic::server::UnaryService<super::DeletePayloadPoints>
4356                    for DeletePayloadSvc<T> {
4357                        type Response = super::PointsOperationResponse;
4358                        type Future = BoxFuture<
4359                            tonic::Response<Self::Response>,
4360                            tonic::Status,
4361                        >;
4362                        fn call(
4363                            &mut self,
4364                            request: tonic::Request<super::DeletePayloadPoints>,
4365                        ) -> Self::Future {
4366                            let inner = Arc::clone(&self.0);
4367                            let fut = async move {
4368                                (*inner).delete_payload(request).await
4369                            };
4370                            Box::pin(fut)
4371                        }
4372                    }
4373                    let accept_compression_encodings = self.accept_compression_encodings;
4374                    let send_compression_encodings = self.send_compression_encodings;
4375                    let max_decoding_message_size = self.max_decoding_message_size;
4376                    let max_encoding_message_size = self.max_encoding_message_size;
4377                    let inner = self.inner.clone();
4378                    let fut = async move {
4379                        let inner = inner.0;
4380                        let method = DeletePayloadSvc(inner);
4381                        let codec = tonic::codec::ProstCodec::default();
4382                        let mut grpc = tonic::server::Grpc::new(codec)
4383                            .apply_compression_config(
4384                                accept_compression_encodings,
4385                                send_compression_encodings,
4386                            )
4387                            .apply_max_message_size_config(
4388                                max_decoding_message_size,
4389                                max_encoding_message_size,
4390                            );
4391                        let res = grpc.unary(method, req).await;
4392                        Ok(res)
4393                    };
4394                    Box::pin(fut)
4395                }
4396                "/arc_vector.Points/ClearPayload" => {
4397                    #[allow(non_camel_case_types)]
4398                    struct ClearPayloadSvc<T: Points>(pub Arc<T>);
4399                    impl<
4400                        T: Points,
4401                    > tonic::server::UnaryService<super::ClearPayloadPoints>
4402                    for ClearPayloadSvc<T> {
4403                        type Response = super::PointsOperationResponse;
4404                        type Future = BoxFuture<
4405                            tonic::Response<Self::Response>,
4406                            tonic::Status,
4407                        >;
4408                        fn call(
4409                            &mut self,
4410                            request: tonic::Request<super::ClearPayloadPoints>,
4411                        ) -> Self::Future {
4412                            let inner = Arc::clone(&self.0);
4413                            let fut = async move {
4414                                (*inner).clear_payload(request).await
4415                            };
4416                            Box::pin(fut)
4417                        }
4418                    }
4419                    let accept_compression_encodings = self.accept_compression_encodings;
4420                    let send_compression_encodings = self.send_compression_encodings;
4421                    let max_decoding_message_size = self.max_decoding_message_size;
4422                    let max_encoding_message_size = self.max_encoding_message_size;
4423                    let inner = self.inner.clone();
4424                    let fut = async move {
4425                        let inner = inner.0;
4426                        let method = ClearPayloadSvc(inner);
4427                        let codec = tonic::codec::ProstCodec::default();
4428                        let mut grpc = tonic::server::Grpc::new(codec)
4429                            .apply_compression_config(
4430                                accept_compression_encodings,
4431                                send_compression_encodings,
4432                            )
4433                            .apply_max_message_size_config(
4434                                max_decoding_message_size,
4435                                max_encoding_message_size,
4436                            );
4437                        let res = grpc.unary(method, req).await;
4438                        Ok(res)
4439                    };
4440                    Box::pin(fut)
4441                }
4442                "/arc_vector.Points/CreateFieldIndex" => {
4443                    #[allow(non_camel_case_types)]
4444                    struct CreateFieldIndexSvc<T: Points>(pub Arc<T>);
4445                    impl<
4446                        T: Points,
4447                    > tonic::server::UnaryService<super::CreateFieldIndexCollection>
4448                    for CreateFieldIndexSvc<T> {
4449                        type Response = super::PointsOperationResponse;
4450                        type Future = BoxFuture<
4451                            tonic::Response<Self::Response>,
4452                            tonic::Status,
4453                        >;
4454                        fn call(
4455                            &mut self,
4456                            request: tonic::Request<super::CreateFieldIndexCollection>,
4457                        ) -> Self::Future {
4458                            let inner = Arc::clone(&self.0);
4459                            let fut = async move {
4460                                (*inner).create_field_index(request).await
4461                            };
4462                            Box::pin(fut)
4463                        }
4464                    }
4465                    let accept_compression_encodings = self.accept_compression_encodings;
4466                    let send_compression_encodings = self.send_compression_encodings;
4467                    let max_decoding_message_size = self.max_decoding_message_size;
4468                    let max_encoding_message_size = self.max_encoding_message_size;
4469                    let inner = self.inner.clone();
4470                    let fut = async move {
4471                        let inner = inner.0;
4472                        let method = CreateFieldIndexSvc(inner);
4473                        let codec = tonic::codec::ProstCodec::default();
4474                        let mut grpc = tonic::server::Grpc::new(codec)
4475                            .apply_compression_config(
4476                                accept_compression_encodings,
4477                                send_compression_encodings,
4478                            )
4479                            .apply_max_message_size_config(
4480                                max_decoding_message_size,
4481                                max_encoding_message_size,
4482                            );
4483                        let res = grpc.unary(method, req).await;
4484                        Ok(res)
4485                    };
4486                    Box::pin(fut)
4487                }
4488                "/arc_vector.Points/DeleteFieldIndex" => {
4489                    #[allow(non_camel_case_types)]
4490                    struct DeleteFieldIndexSvc<T: Points>(pub Arc<T>);
4491                    impl<
4492                        T: Points,
4493                    > tonic::server::UnaryService<super::DeleteFieldIndexCollection>
4494                    for DeleteFieldIndexSvc<T> {
4495                        type Response = super::PointsOperationResponse;
4496                        type Future = BoxFuture<
4497                            tonic::Response<Self::Response>,
4498                            tonic::Status,
4499                        >;
4500                        fn call(
4501                            &mut self,
4502                            request: tonic::Request<super::DeleteFieldIndexCollection>,
4503                        ) -> Self::Future {
4504                            let inner = Arc::clone(&self.0);
4505                            let fut = async move {
4506                                (*inner).delete_field_index(request).await
4507                            };
4508                            Box::pin(fut)
4509                        }
4510                    }
4511                    let accept_compression_encodings = self.accept_compression_encodings;
4512                    let send_compression_encodings = self.send_compression_encodings;
4513                    let max_decoding_message_size = self.max_decoding_message_size;
4514                    let max_encoding_message_size = self.max_encoding_message_size;
4515                    let inner = self.inner.clone();
4516                    let fut = async move {
4517                        let inner = inner.0;
4518                        let method = DeleteFieldIndexSvc(inner);
4519                        let codec = tonic::codec::ProstCodec::default();
4520                        let mut grpc = tonic::server::Grpc::new(codec)
4521                            .apply_compression_config(
4522                                accept_compression_encodings,
4523                                send_compression_encodings,
4524                            )
4525                            .apply_max_message_size_config(
4526                                max_decoding_message_size,
4527                                max_encoding_message_size,
4528                            );
4529                        let res = grpc.unary(method, req).await;
4530                        Ok(res)
4531                    };
4532                    Box::pin(fut)
4533                }
4534                "/arc_vector.Points/Search" => {
4535                    #[allow(non_camel_case_types)]
4536                    struct SearchSvc<T: Points>(pub Arc<T>);
4537                    impl<T: Points> tonic::server::UnaryService<super::SearchPoints>
4538                    for SearchSvc<T> {
4539                        type Response = super::SearchResponse;
4540                        type Future = BoxFuture<
4541                            tonic::Response<Self::Response>,
4542                            tonic::Status,
4543                        >;
4544                        fn call(
4545                            &mut self,
4546                            request: tonic::Request<super::SearchPoints>,
4547                        ) -> Self::Future {
4548                            let inner = Arc::clone(&self.0);
4549                            let fut = async move { (*inner).search(request).await };
4550                            Box::pin(fut)
4551                        }
4552                    }
4553                    let accept_compression_encodings = self.accept_compression_encodings;
4554                    let send_compression_encodings = self.send_compression_encodings;
4555                    let max_decoding_message_size = self.max_decoding_message_size;
4556                    let max_encoding_message_size = self.max_encoding_message_size;
4557                    let inner = self.inner.clone();
4558                    let fut = async move {
4559                        let inner = inner.0;
4560                        let method = SearchSvc(inner);
4561                        let codec = tonic::codec::ProstCodec::default();
4562                        let mut grpc = tonic::server::Grpc::new(codec)
4563                            .apply_compression_config(
4564                                accept_compression_encodings,
4565                                send_compression_encodings,
4566                            )
4567                            .apply_max_message_size_config(
4568                                max_decoding_message_size,
4569                                max_encoding_message_size,
4570                            );
4571                        let res = grpc.unary(method, req).await;
4572                        Ok(res)
4573                    };
4574                    Box::pin(fut)
4575                }
4576                "/arc_vector.Points/SearchBatch" => {
4577                    #[allow(non_camel_case_types)]
4578                    struct SearchBatchSvc<T: Points>(pub Arc<T>);
4579                    impl<T: Points> tonic::server::UnaryService<super::SearchBatchPoints>
4580                    for SearchBatchSvc<T> {
4581                        type Response = super::SearchBatchResponse;
4582                        type Future = BoxFuture<
4583                            tonic::Response<Self::Response>,
4584                            tonic::Status,
4585                        >;
4586                        fn call(
4587                            &mut self,
4588                            request: tonic::Request<super::SearchBatchPoints>,
4589                        ) -> Self::Future {
4590                            let inner = Arc::clone(&self.0);
4591                            let fut = async move {
4592                                (*inner).search_batch(request).await
4593                            };
4594                            Box::pin(fut)
4595                        }
4596                    }
4597                    let accept_compression_encodings = self.accept_compression_encodings;
4598                    let send_compression_encodings = self.send_compression_encodings;
4599                    let max_decoding_message_size = self.max_decoding_message_size;
4600                    let max_encoding_message_size = self.max_encoding_message_size;
4601                    let inner = self.inner.clone();
4602                    let fut = async move {
4603                        let inner = inner.0;
4604                        let method = SearchBatchSvc(inner);
4605                        let codec = tonic::codec::ProstCodec::default();
4606                        let mut grpc = tonic::server::Grpc::new(codec)
4607                            .apply_compression_config(
4608                                accept_compression_encodings,
4609                                send_compression_encodings,
4610                            )
4611                            .apply_max_message_size_config(
4612                                max_decoding_message_size,
4613                                max_encoding_message_size,
4614                            );
4615                        let res = grpc.unary(method, req).await;
4616                        Ok(res)
4617                    };
4618                    Box::pin(fut)
4619                }
4620                "/arc_vector.Points/SearchGroups" => {
4621                    #[allow(non_camel_case_types)]
4622                    struct SearchGroupsSvc<T: Points>(pub Arc<T>);
4623                    impl<T: Points> tonic::server::UnaryService<super::SearchPointGroups>
4624                    for SearchGroupsSvc<T> {
4625                        type Response = super::SearchGroupsResponse;
4626                        type Future = BoxFuture<
4627                            tonic::Response<Self::Response>,
4628                            tonic::Status,
4629                        >;
4630                        fn call(
4631                            &mut self,
4632                            request: tonic::Request<super::SearchPointGroups>,
4633                        ) -> Self::Future {
4634                            let inner = Arc::clone(&self.0);
4635                            let fut = async move {
4636                                (*inner).search_groups(request).await
4637                            };
4638                            Box::pin(fut)
4639                        }
4640                    }
4641                    let accept_compression_encodings = self.accept_compression_encodings;
4642                    let send_compression_encodings = self.send_compression_encodings;
4643                    let max_decoding_message_size = self.max_decoding_message_size;
4644                    let max_encoding_message_size = self.max_encoding_message_size;
4645                    let inner = self.inner.clone();
4646                    let fut = async move {
4647                        let inner = inner.0;
4648                        let method = SearchGroupsSvc(inner);
4649                        let codec = tonic::codec::ProstCodec::default();
4650                        let mut grpc = tonic::server::Grpc::new(codec)
4651                            .apply_compression_config(
4652                                accept_compression_encodings,
4653                                send_compression_encodings,
4654                            )
4655                            .apply_max_message_size_config(
4656                                max_decoding_message_size,
4657                                max_encoding_message_size,
4658                            );
4659                        let res = grpc.unary(method, req).await;
4660                        Ok(res)
4661                    };
4662                    Box::pin(fut)
4663                }
4664                "/arc_vector.Points/Scroll" => {
4665                    #[allow(non_camel_case_types)]
4666                    struct ScrollSvc<T: Points>(pub Arc<T>);
4667                    impl<T: Points> tonic::server::UnaryService<super::ScrollPoints>
4668                    for ScrollSvc<T> {
4669                        type Response = super::ScrollResponse;
4670                        type Future = BoxFuture<
4671                            tonic::Response<Self::Response>,
4672                            tonic::Status,
4673                        >;
4674                        fn call(
4675                            &mut self,
4676                            request: tonic::Request<super::ScrollPoints>,
4677                        ) -> Self::Future {
4678                            let inner = Arc::clone(&self.0);
4679                            let fut = async move { (*inner).scroll(request).await };
4680                            Box::pin(fut)
4681                        }
4682                    }
4683                    let accept_compression_encodings = self.accept_compression_encodings;
4684                    let send_compression_encodings = self.send_compression_encodings;
4685                    let max_decoding_message_size = self.max_decoding_message_size;
4686                    let max_encoding_message_size = self.max_encoding_message_size;
4687                    let inner = self.inner.clone();
4688                    let fut = async move {
4689                        let inner = inner.0;
4690                        let method = ScrollSvc(inner);
4691                        let codec = tonic::codec::ProstCodec::default();
4692                        let mut grpc = tonic::server::Grpc::new(codec)
4693                            .apply_compression_config(
4694                                accept_compression_encodings,
4695                                send_compression_encodings,
4696                            )
4697                            .apply_max_message_size_config(
4698                                max_decoding_message_size,
4699                                max_encoding_message_size,
4700                            );
4701                        let res = grpc.unary(method, req).await;
4702                        Ok(res)
4703                    };
4704                    Box::pin(fut)
4705                }
4706                "/arc_vector.Points/Recommend" => {
4707                    #[allow(non_camel_case_types)]
4708                    struct RecommendSvc<T: Points>(pub Arc<T>);
4709                    impl<T: Points> tonic::server::UnaryService<super::RecommendPoints>
4710                    for RecommendSvc<T> {
4711                        type Response = super::RecommendResponse;
4712                        type Future = BoxFuture<
4713                            tonic::Response<Self::Response>,
4714                            tonic::Status,
4715                        >;
4716                        fn call(
4717                            &mut self,
4718                            request: tonic::Request<super::RecommendPoints>,
4719                        ) -> Self::Future {
4720                            let inner = Arc::clone(&self.0);
4721                            let fut = async move { (*inner).recommend(request).await };
4722                            Box::pin(fut)
4723                        }
4724                    }
4725                    let accept_compression_encodings = self.accept_compression_encodings;
4726                    let send_compression_encodings = self.send_compression_encodings;
4727                    let max_decoding_message_size = self.max_decoding_message_size;
4728                    let max_encoding_message_size = self.max_encoding_message_size;
4729                    let inner = self.inner.clone();
4730                    let fut = async move {
4731                        let inner = inner.0;
4732                        let method = RecommendSvc(inner);
4733                        let codec = tonic::codec::ProstCodec::default();
4734                        let mut grpc = tonic::server::Grpc::new(codec)
4735                            .apply_compression_config(
4736                                accept_compression_encodings,
4737                                send_compression_encodings,
4738                            )
4739                            .apply_max_message_size_config(
4740                                max_decoding_message_size,
4741                                max_encoding_message_size,
4742                            );
4743                        let res = grpc.unary(method, req).await;
4744                        Ok(res)
4745                    };
4746                    Box::pin(fut)
4747                }
4748                "/arc_vector.Points/RecommendBatch" => {
4749                    #[allow(non_camel_case_types)]
4750                    struct RecommendBatchSvc<T: Points>(pub Arc<T>);
4751                    impl<
4752                        T: Points,
4753                    > tonic::server::UnaryService<super::RecommendBatchPoints>
4754                    for RecommendBatchSvc<T> {
4755                        type Response = super::RecommendBatchResponse;
4756                        type Future = BoxFuture<
4757                            tonic::Response<Self::Response>,
4758                            tonic::Status,
4759                        >;
4760                        fn call(
4761                            &mut self,
4762                            request: tonic::Request<super::RecommendBatchPoints>,
4763                        ) -> Self::Future {
4764                            let inner = Arc::clone(&self.0);
4765                            let fut = async move {
4766                                (*inner).recommend_batch(request).await
4767                            };
4768                            Box::pin(fut)
4769                        }
4770                    }
4771                    let accept_compression_encodings = self.accept_compression_encodings;
4772                    let send_compression_encodings = self.send_compression_encodings;
4773                    let max_decoding_message_size = self.max_decoding_message_size;
4774                    let max_encoding_message_size = self.max_encoding_message_size;
4775                    let inner = self.inner.clone();
4776                    let fut = async move {
4777                        let inner = inner.0;
4778                        let method = RecommendBatchSvc(inner);
4779                        let codec = tonic::codec::ProstCodec::default();
4780                        let mut grpc = tonic::server::Grpc::new(codec)
4781                            .apply_compression_config(
4782                                accept_compression_encodings,
4783                                send_compression_encodings,
4784                            )
4785                            .apply_max_message_size_config(
4786                                max_decoding_message_size,
4787                                max_encoding_message_size,
4788                            );
4789                        let res = grpc.unary(method, req).await;
4790                        Ok(res)
4791                    };
4792                    Box::pin(fut)
4793                }
4794                "/arc_vector.Points/RecommendGroups" => {
4795                    #[allow(non_camel_case_types)]
4796                    struct RecommendGroupsSvc<T: Points>(pub Arc<T>);
4797                    impl<
4798                        T: Points,
4799                    > tonic::server::UnaryService<super::RecommendPointGroups>
4800                    for RecommendGroupsSvc<T> {
4801                        type Response = super::RecommendGroupsResponse;
4802                        type Future = BoxFuture<
4803                            tonic::Response<Self::Response>,
4804                            tonic::Status,
4805                        >;
4806                        fn call(
4807                            &mut self,
4808                            request: tonic::Request<super::RecommendPointGroups>,
4809                        ) -> Self::Future {
4810                            let inner = Arc::clone(&self.0);
4811                            let fut = async move {
4812                                (*inner).recommend_groups(request).await
4813                            };
4814                            Box::pin(fut)
4815                        }
4816                    }
4817                    let accept_compression_encodings = self.accept_compression_encodings;
4818                    let send_compression_encodings = self.send_compression_encodings;
4819                    let max_decoding_message_size = self.max_decoding_message_size;
4820                    let max_encoding_message_size = self.max_encoding_message_size;
4821                    let inner = self.inner.clone();
4822                    let fut = async move {
4823                        let inner = inner.0;
4824                        let method = RecommendGroupsSvc(inner);
4825                        let codec = tonic::codec::ProstCodec::default();
4826                        let mut grpc = tonic::server::Grpc::new(codec)
4827                            .apply_compression_config(
4828                                accept_compression_encodings,
4829                                send_compression_encodings,
4830                            )
4831                            .apply_max_message_size_config(
4832                                max_decoding_message_size,
4833                                max_encoding_message_size,
4834                            );
4835                        let res = grpc.unary(method, req).await;
4836                        Ok(res)
4837                    };
4838                    Box::pin(fut)
4839                }
4840                "/arc_vector.Points/Count" => {
4841                    #[allow(non_camel_case_types)]
4842                    struct CountSvc<T: Points>(pub Arc<T>);
4843                    impl<T: Points> tonic::server::UnaryService<super::CountPoints>
4844                    for CountSvc<T> {
4845                        type Response = super::CountResponse;
4846                        type Future = BoxFuture<
4847                            tonic::Response<Self::Response>,
4848                            tonic::Status,
4849                        >;
4850                        fn call(
4851                            &mut self,
4852                            request: tonic::Request<super::CountPoints>,
4853                        ) -> Self::Future {
4854                            let inner = Arc::clone(&self.0);
4855                            let fut = async move { (*inner).count(request).await };
4856                            Box::pin(fut)
4857                        }
4858                    }
4859                    let accept_compression_encodings = self.accept_compression_encodings;
4860                    let send_compression_encodings = self.send_compression_encodings;
4861                    let max_decoding_message_size = self.max_decoding_message_size;
4862                    let max_encoding_message_size = self.max_encoding_message_size;
4863                    let inner = self.inner.clone();
4864                    let fut = async move {
4865                        let inner = inner.0;
4866                        let method = CountSvc(inner);
4867                        let codec = tonic::codec::ProstCodec::default();
4868                        let mut grpc = tonic::server::Grpc::new(codec)
4869                            .apply_compression_config(
4870                                accept_compression_encodings,
4871                                send_compression_encodings,
4872                            )
4873                            .apply_max_message_size_config(
4874                                max_decoding_message_size,
4875                                max_encoding_message_size,
4876                            );
4877                        let res = grpc.unary(method, req).await;
4878                        Ok(res)
4879                    };
4880                    Box::pin(fut)
4881                }
4882                _ => {
4883                    Box::pin(async move {
4884                        Ok(
4885                            http::Response::builder()
4886                                .status(200)
4887                                .header("grpc-status", "12")
4888                                .header("content-type", "application/grpc")
4889                                .body(empty_body())
4890                                .unwrap(),
4891                        )
4892                    })
4893                }
4894            }
4895        }
4896    }
4897    impl<T: Points> Clone for PointsServer<T> {
4898        fn clone(&self) -> Self {
4899            let inner = self.inner.clone();
4900            Self {
4901                inner,
4902                accept_compression_encodings: self.accept_compression_encodings,
4903                send_compression_encodings: self.send_compression_encodings,
4904                max_decoding_message_size: self.max_decoding_message_size,
4905                max_encoding_message_size: self.max_encoding_message_size,
4906            }
4907        }
4908    }
4909    impl<T: Points> Clone for _Inner<T> {
4910        fn clone(&self) -> Self {
4911            Self(Arc::clone(&self.0))
4912        }
4913    }
4914    impl<T: std::fmt::Debug> std::fmt::Debug for _Inner<T> {
4915        fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
4916            write!(f, "{:?}", self.0)
4917        }
4918    }
4919    impl<T: Points> tonic::server::NamedService for PointsServer<T> {
4920        const NAME: &'static str = "arc_vector.Points";
4921    }
4922}
4923#[allow(clippy::derive_partial_eq_without_eq)]
4924#[derive(Clone, PartialEq, ::prost::Message)]
4925pub struct CreateFullSnapshotRequest {}
4926#[allow(clippy::derive_partial_eq_without_eq)]
4927#[derive(Clone, PartialEq, ::prost::Message)]
4928pub struct ListFullSnapshotsRequest {}
4929#[allow(clippy::derive_partial_eq_without_eq)]
4930#[derive(Clone, PartialEq, ::prost::Message)]
4931pub struct DeleteFullSnapshotRequest {
4932    /// Name of the full snapshot
4933    #[prost(string, tag = "1")]
4934    pub snapshot_name: ::prost::alloc::string::String,
4935}
4936#[allow(clippy::derive_partial_eq_without_eq)]
4937#[derive(Clone, PartialEq, ::prost::Message)]
4938pub struct CreateSnapshotRequest {
4939    /// Name of the collection
4940    #[prost(string, tag = "1")]
4941    pub collection_name: ::prost::alloc::string::String,
4942}
4943#[allow(clippy::derive_partial_eq_without_eq)]
4944#[derive(Clone, PartialEq, ::prost::Message)]
4945pub struct ListSnapshotsRequest {
4946    /// Name of the collection
4947    #[prost(string, tag = "1")]
4948    pub collection_name: ::prost::alloc::string::String,
4949}
4950#[allow(clippy::derive_partial_eq_without_eq)]
4951#[derive(Clone, PartialEq, ::prost::Message)]
4952pub struct DeleteSnapshotRequest {
4953    /// Name of the collection
4954    #[prost(string, tag = "1")]
4955    pub collection_name: ::prost::alloc::string::String,
4956    /// Name of the collection snapshot
4957    #[prost(string, tag = "2")]
4958    pub snapshot_name: ::prost::alloc::string::String,
4959}
4960#[allow(clippy::derive_partial_eq_without_eq)]
4961#[derive(Clone, PartialEq, ::prost::Message)]
4962pub struct SnapshotDescription {
4963    /// Name of the snapshot
4964    #[prost(string, tag = "1")]
4965    pub name: ::prost::alloc::string::String,
4966    /// Creation time of the snapshot
4967    #[prost(message, optional, tag = "2")]
4968    pub creation_time: ::core::option::Option<::prost_types::Timestamp>,
4969    /// Size of the snapshot in bytes
4970    #[prost(int64, tag = "3")]
4971    pub size: i64,
4972}
4973#[allow(clippy::derive_partial_eq_without_eq)]
4974#[derive(Clone, PartialEq, ::prost::Message)]
4975pub struct CreateSnapshotResponse {
4976    #[prost(message, optional, tag = "1")]
4977    pub snapshot_description: ::core::option::Option<SnapshotDescription>,
4978    /// Time spent to process
4979    #[prost(double, tag = "2")]
4980    pub time: f64,
4981}
4982#[allow(clippy::derive_partial_eq_without_eq)]
4983#[derive(Clone, PartialEq, ::prost::Message)]
4984pub struct ListSnapshotsResponse {
4985    #[prost(message, repeated, tag = "1")]
4986    pub snapshot_descriptions: ::prost::alloc::vec::Vec<SnapshotDescription>,
4987    /// Time spent to process
4988    #[prost(double, tag = "2")]
4989    pub time: f64,
4990}
4991#[allow(clippy::derive_partial_eq_without_eq)]
4992#[derive(Clone, PartialEq, ::prost::Message)]
4993pub struct DeleteSnapshotResponse {
4994    /// Time spent to process
4995    #[prost(double, tag = "1")]
4996    pub time: f64,
4997}
4998/// Generated client implementations.
4999pub mod snapshots_client {
5000    #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)]
5001    use tonic::codegen::*;
5002    use tonic::codegen::http::Uri;
5003    #[derive(Debug, Clone)]
5004    pub struct SnapshotsClient<T> {
5005        inner: tonic::client::Grpc<T>,
5006    }
5007    impl SnapshotsClient<tonic::transport::Channel> {
5008        /// Attempt to create a new client by connecting to a given endpoint.
5009        pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
5010        where
5011            D: TryInto<tonic::transport::Endpoint>,
5012            D::Error: Into<StdError>,
5013        {
5014            let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
5015            Ok(Self::new(conn))
5016        }
5017    }
5018    impl<T> SnapshotsClient<T>
5019    where
5020        T: tonic::client::GrpcService<tonic::body::BoxBody>,
5021        T::Error: Into<StdError>,
5022        T::ResponseBody: Body<Data = Bytes> + Send + 'static,
5023        <T::ResponseBody as Body>::Error: Into<StdError> + Send,
5024    {
5025        pub fn new(inner: T) -> Self {
5026            let inner = tonic::client::Grpc::new(inner);
5027            Self { inner }
5028        }
5029        pub fn with_origin(inner: T, origin: Uri) -> Self {
5030            let inner = tonic::client::Grpc::with_origin(inner, origin);
5031            Self { inner }
5032        }
5033        pub fn with_interceptor<F>(
5034            inner: T,
5035            interceptor: F,
5036        ) -> SnapshotsClient<InterceptedService<T, F>>
5037        where
5038            F: tonic::service::Interceptor,
5039            T::ResponseBody: Default,
5040            T: tonic::codegen::Service<
5041                http::Request<tonic::body::BoxBody>,
5042                Response = http::Response<
5043                    <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
5044                >,
5045            >,
5046            <T as tonic::codegen::Service<
5047                http::Request<tonic::body::BoxBody>,
5048            >>::Error: Into<StdError> + Send + Sync,
5049        {
5050            SnapshotsClient::new(InterceptedService::new(inner, interceptor))
5051        }
5052        /// Compress requests with the given encoding.
5053        ///
5054        /// This requires the server to support it otherwise it might respond with an
5055        /// error.
5056        #[must_use]
5057        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
5058            self.inner = self.inner.send_compressed(encoding);
5059            self
5060        }
5061        /// Enable decompressing responses.
5062        #[must_use]
5063        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
5064            self.inner = self.inner.accept_compressed(encoding);
5065            self
5066        }
5067        /// Limits the maximum size of a decoded message.
5068        ///
5069        /// Default: `4MB`
5070        #[must_use]
5071        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
5072            self.inner = self.inner.max_decoding_message_size(limit);
5073            self
5074        }
5075        /// Limits the maximum size of an encoded message.
5076        ///
5077        /// Default: `usize::MAX`
5078        #[must_use]
5079        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
5080            self.inner = self.inner.max_encoding_message_size(limit);
5081            self
5082        }
5083        ///
5084        /// Create collection snapshot
5085        pub async fn create(
5086            &mut self,
5087            request: impl tonic::IntoRequest<super::CreateSnapshotRequest>,
5088        ) -> std::result::Result<
5089            tonic::Response<super::CreateSnapshotResponse>,
5090            tonic::Status,
5091        > {
5092            self.inner
5093                .ready()
5094                .await
5095                .map_err(|e| {
5096                    tonic::Status::new(
5097                        tonic::Code::Unknown,
5098                        format!("Service was not ready: {}", e.into()),
5099                    )
5100                })?;
5101            let codec = tonic::codec::ProstCodec::default();
5102            let path = http::uri::PathAndQuery::from_static("/arc_vector.Snapshots/Create");
5103            let mut req = request.into_request();
5104            req.extensions_mut().insert(GrpcMethod::new("arc_vector.Snapshots", "Create"));
5105            self.inner.unary(req, path, codec).await
5106        }
5107        ///
5108        /// List collection snapshots
5109        pub async fn list(
5110            &mut self,
5111            request: impl tonic::IntoRequest<super::ListSnapshotsRequest>,
5112        ) -> std::result::Result<
5113            tonic::Response<super::ListSnapshotsResponse>,
5114            tonic::Status,
5115        > {
5116            self.inner
5117                .ready()
5118                .await
5119                .map_err(|e| {
5120                    tonic::Status::new(
5121                        tonic::Code::Unknown,
5122                        format!("Service was not ready: {}", e.into()),
5123                    )
5124                })?;
5125            let codec = tonic::codec::ProstCodec::default();
5126            let path = http::uri::PathAndQuery::from_static("/arc_vector.Snapshots/List");
5127            let mut req = request.into_request();
5128            req.extensions_mut().insert(GrpcMethod::new("arc_vector.Snapshots", "List"));
5129            self.inner.unary(req, path, codec).await
5130        }
5131        ///
5132        /// Delete collection snapshots
5133        pub async fn delete(
5134            &mut self,
5135            request: impl tonic::IntoRequest<super::DeleteSnapshotRequest>,
5136        ) -> std::result::Result<
5137            tonic::Response<super::DeleteSnapshotResponse>,
5138            tonic::Status,
5139        > {
5140            self.inner
5141                .ready()
5142                .await
5143                .map_err(|e| {
5144                    tonic::Status::new(
5145                        tonic::Code::Unknown,
5146                        format!("Service was not ready: {}", e.into()),
5147                    )
5148                })?;
5149            let codec = tonic::codec::ProstCodec::default();
5150            let path = http::uri::PathAndQuery::from_static("/arc_vector.Snapshots/Delete");
5151            let mut req = request.into_request();
5152            req.extensions_mut().insert(GrpcMethod::new("arc_vector.Snapshots", "Delete"));
5153            self.inner.unary(req, path, codec).await
5154        }
5155        ///
5156        /// Create full storage snapshot
5157        pub async fn create_full(
5158            &mut self,
5159            request: impl tonic::IntoRequest<super::CreateFullSnapshotRequest>,
5160        ) -> std::result::Result<
5161            tonic::Response<super::CreateSnapshotResponse>,
5162            tonic::Status,
5163        > {
5164            self.inner
5165                .ready()
5166                .await
5167                .map_err(|e| {
5168                    tonic::Status::new(
5169                        tonic::Code::Unknown,
5170                        format!("Service was not ready: {}", e.into()),
5171                    )
5172                })?;
5173            let codec = tonic::codec::ProstCodec::default();
5174            let path = http::uri::PathAndQuery::from_static(
5175                "/arc_vector.Snapshots/CreateFull",
5176            );
5177            let mut req = request.into_request();
5178            req.extensions_mut()
5179                .insert(GrpcMethod::new("arc_vector.Snapshots", "CreateFull"));
5180            self.inner.unary(req, path, codec).await
5181        }
5182        ///
5183        /// List full storage snapshots
5184        pub async fn list_full(
5185            &mut self,
5186            request: impl tonic::IntoRequest<super::ListFullSnapshotsRequest>,
5187        ) -> std::result::Result<
5188            tonic::Response<super::ListSnapshotsResponse>,
5189            tonic::Status,
5190        > {
5191            self.inner
5192                .ready()
5193                .await
5194                .map_err(|e| {
5195                    tonic::Status::new(
5196                        tonic::Code::Unknown,
5197                        format!("Service was not ready: {}", e.into()),
5198                    )
5199                })?;
5200            let codec = tonic::codec::ProstCodec::default();
5201            let path = http::uri::PathAndQuery::from_static(
5202                "/arc_vector.Snapshots/ListFull",
5203            );
5204            let mut req = request.into_request();
5205            req.extensions_mut().insert(GrpcMethod::new("arc_vector.Snapshots", "ListFull"));
5206            self.inner.unary(req, path, codec).await
5207        }
5208        ///
5209        /// List full storage snapshots
5210        pub async fn delete_full(
5211            &mut self,
5212            request: impl tonic::IntoRequest<super::DeleteFullSnapshotRequest>,
5213        ) -> std::result::Result<
5214            tonic::Response<super::DeleteSnapshotResponse>,
5215            tonic::Status,
5216        > {
5217            self.inner
5218                .ready()
5219                .await
5220                .map_err(|e| {
5221                    tonic::Status::new(
5222                        tonic::Code::Unknown,
5223                        format!("Service was not ready: {}", e.into()),
5224                    )
5225                })?;
5226            let codec = tonic::codec::ProstCodec::default();
5227            let path = http::uri::PathAndQuery::from_static(
5228                "/arc_vector.Snapshots/DeleteFull",
5229            );
5230            let mut req = request.into_request();
5231            req.extensions_mut()
5232                .insert(GrpcMethod::new("arc_vector.Snapshots", "DeleteFull"));
5233            self.inner.unary(req, path, codec).await
5234        }
5235    }
5236}
5237/// Generated server implementations.
5238pub mod snapshots_server {
5239    #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)]
5240    use tonic::codegen::*;
5241    /// Generated trait containing gRPC methods that should be implemented for use with SnapshotsServer.
5242    #[async_trait]
5243    pub trait Snapshots: Send + Sync + 'static {
5244        ///
5245        /// Create collection snapshot
5246        async fn create(
5247            &self,
5248            request: tonic::Request<super::CreateSnapshotRequest>,
5249        ) -> std::result::Result<
5250            tonic::Response<super::CreateSnapshotResponse>,
5251            tonic::Status,
5252        >;
5253        ///
5254        /// List collection snapshots
5255        async fn list(
5256            &self,
5257            request: tonic::Request<super::ListSnapshotsRequest>,
5258        ) -> std::result::Result<
5259            tonic::Response<super::ListSnapshotsResponse>,
5260            tonic::Status,
5261        >;
5262        ///
5263        /// Delete collection snapshots
5264        async fn delete(
5265            &self,
5266            request: tonic::Request<super::DeleteSnapshotRequest>,
5267        ) -> std::result::Result<
5268            tonic::Response<super::DeleteSnapshotResponse>,
5269            tonic::Status,
5270        >;
5271        ///
5272        /// Create full storage snapshot
5273        async fn create_full(
5274            &self,
5275            request: tonic::Request<super::CreateFullSnapshotRequest>,
5276        ) -> std::result::Result<
5277            tonic::Response<super::CreateSnapshotResponse>,
5278            tonic::Status,
5279        >;
5280        ///
5281        /// List full storage snapshots
5282        async fn list_full(
5283            &self,
5284            request: tonic::Request<super::ListFullSnapshotsRequest>,
5285        ) -> std::result::Result<
5286            tonic::Response<super::ListSnapshotsResponse>,
5287            tonic::Status,
5288        >;
5289        ///
5290        /// List full storage snapshots
5291        async fn delete_full(
5292            &self,
5293            request: tonic::Request<super::DeleteFullSnapshotRequest>,
5294        ) -> std::result::Result<
5295            tonic::Response<super::DeleteSnapshotResponse>,
5296            tonic::Status,
5297        >;
5298    }
5299    #[derive(Debug)]
5300    pub struct SnapshotsServer<T: Snapshots> {
5301        inner: _Inner<T>,
5302        accept_compression_encodings: EnabledCompressionEncodings,
5303        send_compression_encodings: EnabledCompressionEncodings,
5304        max_decoding_message_size: Option<usize>,
5305        max_encoding_message_size: Option<usize>,
5306    }
5307    struct _Inner<T>(Arc<T>);
5308    impl<T: Snapshots> SnapshotsServer<T> {
5309        pub fn new(inner: T) -> Self {
5310            Self::from_arc(Arc::new(inner))
5311        }
5312        pub fn from_arc(inner: Arc<T>) -> Self {
5313            let inner = _Inner(inner);
5314            Self {
5315                inner,
5316                accept_compression_encodings: Default::default(),
5317                send_compression_encodings: Default::default(),
5318                max_decoding_message_size: None,
5319                max_encoding_message_size: None,
5320            }
5321        }
5322        pub fn with_interceptor<F>(
5323            inner: T,
5324            interceptor: F,
5325        ) -> InterceptedService<Self, F>
5326        where
5327            F: tonic::service::Interceptor,
5328        {
5329            InterceptedService::new(Self::new(inner), interceptor)
5330        }
5331        /// Enable decompressing requests with the given encoding.
5332        #[must_use]
5333        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
5334            self.accept_compression_encodings.enable(encoding);
5335            self
5336        }
5337        /// Compress responses with the given encoding, if the client supports it.
5338        #[must_use]
5339        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
5340            self.send_compression_encodings.enable(encoding);
5341            self
5342        }
5343        /// Limits the maximum size of a decoded message.
5344        ///
5345        /// Default: `4MB`
5346        #[must_use]
5347        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
5348            self.max_decoding_message_size = Some(limit);
5349            self
5350        }
5351        /// Limits the maximum size of an encoded message.
5352        ///
5353        /// Default: `usize::MAX`
5354        #[must_use]
5355        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
5356            self.max_encoding_message_size = Some(limit);
5357            self
5358        }
5359    }
5360    impl<T, B> tonic::codegen::Service<http::Request<B>> for SnapshotsServer<T>
5361    where
5362        T: Snapshots,
5363        B: Body + Send + 'static,
5364        B::Error: Into<StdError> + Send + 'static,
5365    {
5366        type Response = http::Response<tonic::body::BoxBody>;
5367        type Error = std::convert::Infallible;
5368        type Future = BoxFuture<Self::Response, Self::Error>;
5369        fn poll_ready(
5370            &mut self,
5371            _cx: &mut Context<'_>,
5372        ) -> Poll<std::result::Result<(), Self::Error>> {
5373            Poll::Ready(Ok(()))
5374        }
5375        fn call(&mut self, req: http::Request<B>) -> Self::Future {
5376            let inner = self.inner.clone();
5377            match req.uri().path() {
5378                "/arc_vector.Snapshots/Create" => {
5379                    #[allow(non_camel_case_types)]
5380                    struct CreateSvc<T: Snapshots>(pub Arc<T>);
5381                    impl<
5382                        T: Snapshots,
5383                    > tonic::server::UnaryService<super::CreateSnapshotRequest>
5384                    for CreateSvc<T> {
5385                        type Response = super::CreateSnapshotResponse;
5386                        type Future = BoxFuture<
5387                            tonic::Response<Self::Response>,
5388                            tonic::Status,
5389                        >;
5390                        fn call(
5391                            &mut self,
5392                            request: tonic::Request<super::CreateSnapshotRequest>,
5393                        ) -> Self::Future {
5394                            let inner = Arc::clone(&self.0);
5395                            let fut = async move { (*inner).create(request).await };
5396                            Box::pin(fut)
5397                        }
5398                    }
5399                    let accept_compression_encodings = self.accept_compression_encodings;
5400                    let send_compression_encodings = self.send_compression_encodings;
5401                    let max_decoding_message_size = self.max_decoding_message_size;
5402                    let max_encoding_message_size = self.max_encoding_message_size;
5403                    let inner = self.inner.clone();
5404                    let fut = async move {
5405                        let inner = inner.0;
5406                        let method = CreateSvc(inner);
5407                        let codec = tonic::codec::ProstCodec::default();
5408                        let mut grpc = tonic::server::Grpc::new(codec)
5409                            .apply_compression_config(
5410                                accept_compression_encodings,
5411                                send_compression_encodings,
5412                            )
5413                            .apply_max_message_size_config(
5414                                max_decoding_message_size,
5415                                max_encoding_message_size,
5416                            );
5417                        let res = grpc.unary(method, req).await;
5418                        Ok(res)
5419                    };
5420                    Box::pin(fut)
5421                }
5422                "/arc_vector.Snapshots/List" => {
5423                    #[allow(non_camel_case_types)]
5424                    struct ListSvc<T: Snapshots>(pub Arc<T>);
5425                    impl<
5426                        T: Snapshots,
5427                    > tonic::server::UnaryService<super::ListSnapshotsRequest>
5428                    for ListSvc<T> {
5429                        type Response = super::ListSnapshotsResponse;
5430                        type Future = BoxFuture<
5431                            tonic::Response<Self::Response>,
5432                            tonic::Status,
5433                        >;
5434                        fn call(
5435                            &mut self,
5436                            request: tonic::Request<super::ListSnapshotsRequest>,
5437                        ) -> Self::Future {
5438                            let inner = Arc::clone(&self.0);
5439                            let fut = async move { (*inner).list(request).await };
5440                            Box::pin(fut)
5441                        }
5442                    }
5443                    let accept_compression_encodings = self.accept_compression_encodings;
5444                    let send_compression_encodings = self.send_compression_encodings;
5445                    let max_decoding_message_size = self.max_decoding_message_size;
5446                    let max_encoding_message_size = self.max_encoding_message_size;
5447                    let inner = self.inner.clone();
5448                    let fut = async move {
5449                        let inner = inner.0;
5450                        let method = ListSvc(inner);
5451                        let codec = tonic::codec::ProstCodec::default();
5452                        let mut grpc = tonic::server::Grpc::new(codec)
5453                            .apply_compression_config(
5454                                accept_compression_encodings,
5455                                send_compression_encodings,
5456                            )
5457                            .apply_max_message_size_config(
5458                                max_decoding_message_size,
5459                                max_encoding_message_size,
5460                            );
5461                        let res = grpc.unary(method, req).await;
5462                        Ok(res)
5463                    };
5464                    Box::pin(fut)
5465                }
5466                "/arc_vector.Snapshots/Delete" => {
5467                    #[allow(non_camel_case_types)]
5468                    struct DeleteSvc<T: Snapshots>(pub Arc<T>);
5469                    impl<
5470                        T: Snapshots,
5471                    > tonic::server::UnaryService<super::DeleteSnapshotRequest>
5472                    for DeleteSvc<T> {
5473                        type Response = super::DeleteSnapshotResponse;
5474                        type Future = BoxFuture<
5475                            tonic::Response<Self::Response>,
5476                            tonic::Status,
5477                        >;
5478                        fn call(
5479                            &mut self,
5480                            request: tonic::Request<super::DeleteSnapshotRequest>,
5481                        ) -> Self::Future {
5482                            let inner = Arc::clone(&self.0);
5483                            let fut = async move { (*inner).delete(request).await };
5484                            Box::pin(fut)
5485                        }
5486                    }
5487                    let accept_compression_encodings = self.accept_compression_encodings;
5488                    let send_compression_encodings = self.send_compression_encodings;
5489                    let max_decoding_message_size = self.max_decoding_message_size;
5490                    let max_encoding_message_size = self.max_encoding_message_size;
5491                    let inner = self.inner.clone();
5492                    let fut = async move {
5493                        let inner = inner.0;
5494                        let method = DeleteSvc(inner);
5495                        let codec = tonic::codec::ProstCodec::default();
5496                        let mut grpc = tonic::server::Grpc::new(codec)
5497                            .apply_compression_config(
5498                                accept_compression_encodings,
5499                                send_compression_encodings,
5500                            )
5501                            .apply_max_message_size_config(
5502                                max_decoding_message_size,
5503                                max_encoding_message_size,
5504                            );
5505                        let res = grpc.unary(method, req).await;
5506                        Ok(res)
5507                    };
5508                    Box::pin(fut)
5509                }
5510                "/arc_vector.Snapshots/CreateFull" => {
5511                    #[allow(non_camel_case_types)]
5512                    struct CreateFullSvc<T: Snapshots>(pub Arc<T>);
5513                    impl<
5514                        T: Snapshots,
5515                    > tonic::server::UnaryService<super::CreateFullSnapshotRequest>
5516                    for CreateFullSvc<T> {
5517                        type Response = super::CreateSnapshotResponse;
5518                        type Future = BoxFuture<
5519                            tonic::Response<Self::Response>,
5520                            tonic::Status,
5521                        >;
5522                        fn call(
5523                            &mut self,
5524                            request: tonic::Request<super::CreateFullSnapshotRequest>,
5525                        ) -> Self::Future {
5526                            let inner = Arc::clone(&self.0);
5527                            let fut = async move { (*inner).create_full(request).await };
5528                            Box::pin(fut)
5529                        }
5530                    }
5531                    let accept_compression_encodings = self.accept_compression_encodings;
5532                    let send_compression_encodings = self.send_compression_encodings;
5533                    let max_decoding_message_size = self.max_decoding_message_size;
5534                    let max_encoding_message_size = self.max_encoding_message_size;
5535                    let inner = self.inner.clone();
5536                    let fut = async move {
5537                        let inner = inner.0;
5538                        let method = CreateFullSvc(inner);
5539                        let codec = tonic::codec::ProstCodec::default();
5540                        let mut grpc = tonic::server::Grpc::new(codec)
5541                            .apply_compression_config(
5542                                accept_compression_encodings,
5543                                send_compression_encodings,
5544                            )
5545                            .apply_max_message_size_config(
5546                                max_decoding_message_size,
5547                                max_encoding_message_size,
5548                            );
5549                        let res = grpc.unary(method, req).await;
5550                        Ok(res)
5551                    };
5552                    Box::pin(fut)
5553                }
5554                "/arc_vector.Snapshots/ListFull" => {
5555                    #[allow(non_camel_case_types)]
5556                    struct ListFullSvc<T: Snapshots>(pub Arc<T>);
5557                    impl<
5558                        T: Snapshots,
5559                    > tonic::server::UnaryService<super::ListFullSnapshotsRequest>
5560                    for ListFullSvc<T> {
5561                        type Response = super::ListSnapshotsResponse;
5562                        type Future = BoxFuture<
5563                            tonic::Response<Self::Response>,
5564                            tonic::Status,
5565                        >;
5566                        fn call(
5567                            &mut self,
5568                            request: tonic::Request<super::ListFullSnapshotsRequest>,
5569                        ) -> Self::Future {
5570                            let inner = Arc::clone(&self.0);
5571                            let fut = async move { (*inner).list_full(request).await };
5572                            Box::pin(fut)
5573                        }
5574                    }
5575                    let accept_compression_encodings = self.accept_compression_encodings;
5576                    let send_compression_encodings = self.send_compression_encodings;
5577                    let max_decoding_message_size = self.max_decoding_message_size;
5578                    let max_encoding_message_size = self.max_encoding_message_size;
5579                    let inner = self.inner.clone();
5580                    let fut = async move {
5581                        let inner = inner.0;
5582                        let method = ListFullSvc(inner);
5583                        let codec = tonic::codec::ProstCodec::default();
5584                        let mut grpc = tonic::server::Grpc::new(codec)
5585                            .apply_compression_config(
5586                                accept_compression_encodings,
5587                                send_compression_encodings,
5588                            )
5589                            .apply_max_message_size_config(
5590                                max_decoding_message_size,
5591                                max_encoding_message_size,
5592                            );
5593                        let res = grpc.unary(method, req).await;
5594                        Ok(res)
5595                    };
5596                    Box::pin(fut)
5597                }
5598                "/arc_vector.Snapshots/DeleteFull" => {
5599                    #[allow(non_camel_case_types)]
5600                    struct DeleteFullSvc<T: Snapshots>(pub Arc<T>);
5601                    impl<
5602                        T: Snapshots,
5603                    > tonic::server::UnaryService<super::DeleteFullSnapshotRequest>
5604                    for DeleteFullSvc<T> {
5605                        type Response = super::DeleteSnapshotResponse;
5606                        type Future = BoxFuture<
5607                            tonic::Response<Self::Response>,
5608                            tonic::Status,
5609                        >;
5610                        fn call(
5611                            &mut self,
5612                            request: tonic::Request<super::DeleteFullSnapshotRequest>,
5613                        ) -> Self::Future {
5614                            let inner = Arc::clone(&self.0);
5615                            let fut = async move { (*inner).delete_full(request).await };
5616                            Box::pin(fut)
5617                        }
5618                    }
5619                    let accept_compression_encodings = self.accept_compression_encodings;
5620                    let send_compression_encodings = self.send_compression_encodings;
5621                    let max_decoding_message_size = self.max_decoding_message_size;
5622                    let max_encoding_message_size = self.max_encoding_message_size;
5623                    let inner = self.inner.clone();
5624                    let fut = async move {
5625                        let inner = inner.0;
5626                        let method = DeleteFullSvc(inner);
5627                        let codec = tonic::codec::ProstCodec::default();
5628                        let mut grpc = tonic::server::Grpc::new(codec)
5629                            .apply_compression_config(
5630                                accept_compression_encodings,
5631                                send_compression_encodings,
5632                            )
5633                            .apply_max_message_size_config(
5634                                max_decoding_message_size,
5635                                max_encoding_message_size,
5636                            );
5637                        let res = grpc.unary(method, req).await;
5638                        Ok(res)
5639                    };
5640                    Box::pin(fut)
5641                }
5642                _ => {
5643                    Box::pin(async move {
5644                        Ok(
5645                            http::Response::builder()
5646                                .status(200)
5647                                .header("grpc-status", "12")
5648                                .header("content-type", "application/grpc")
5649                                .body(empty_body())
5650                                .unwrap(),
5651                        )
5652                    })
5653                }
5654            }
5655        }
5656    }
5657    impl<T: Snapshots> Clone for SnapshotsServer<T> {
5658        fn clone(&self) -> Self {
5659            let inner = self.inner.clone();
5660            Self {
5661                inner,
5662                accept_compression_encodings: self.accept_compression_encodings,
5663                send_compression_encodings: self.send_compression_encodings,
5664                max_decoding_message_size: self.max_decoding_message_size,
5665                max_encoding_message_size: self.max_encoding_message_size,
5666            }
5667        }
5668    }
5669    impl<T: Snapshots> Clone for _Inner<T> {
5670        fn clone(&self) -> Self {
5671            Self(Arc::clone(&self.0))
5672        }
5673    }
5674    impl<T: std::fmt::Debug> std::fmt::Debug for _Inner<T> {
5675        fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
5676            write!(f, "{:?}", self.0)
5677        }
5678    }
5679    impl<T: Snapshots> tonic::server::NamedService for SnapshotsServer<T> {
5680        const NAME: &'static str = "arc_vector.Snapshots";
5681    }
5682}
5683#[allow(clippy::derive_partial_eq_without_eq)]
5684#[derive(Clone, PartialEq, ::prost::Message)]
5685pub struct HealthCheckRequest {}
5686#[allow(clippy::derive_partial_eq_without_eq)]
5687#[derive(Clone, PartialEq, ::prost::Message)]
5688pub struct HealthCheckReply {
5689    #[prost(string, tag = "1")]
5690    pub title: ::prost::alloc::string::String,
5691    #[prost(string, tag = "2")]
5692    pub version: ::prost::alloc::string::String,
5693}
5694/// Generated client implementations.
5695pub mod arc_vector_client {
5696    #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)]
5697    use tonic::codegen::*;
5698    use tonic::codegen::http::Uri;
5699    #[derive(Debug, Clone)]
5700    pub struct ArcVectorClient<T> {
5701        inner: tonic::client::Grpc<T>,
5702    }
5703    impl ArcVectorClient<tonic::transport::Channel> {
5704        /// Attempt to create a new client by connecting to a given endpoint.
5705        pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
5706        where
5707            D: TryInto<tonic::transport::Endpoint>,
5708            D::Error: Into<StdError>,
5709        {
5710            let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
5711            Ok(Self::new(conn))
5712        }
5713    }
5714    impl<T> ArcVectorClient<T>
5715    where
5716        T: tonic::client::GrpcService<tonic::body::BoxBody>,
5717        T::Error: Into<StdError>,
5718        T::ResponseBody: Body<Data = Bytes> + Send + 'static,
5719        <T::ResponseBody as Body>::Error: Into<StdError> + Send,
5720    {
5721        pub fn new(inner: T) -> Self {
5722            let inner = tonic::client::Grpc::new(inner);
5723            Self { inner }
5724        }
5725        pub fn with_origin(inner: T, origin: Uri) -> Self {
5726            let inner = tonic::client::Grpc::with_origin(inner, origin);
5727            Self { inner }
5728        }
5729        pub fn with_interceptor<F>(
5730            inner: T,
5731            interceptor: F,
5732        ) -> ArcVectorClient<InterceptedService<T, F>>
5733        where
5734            F: tonic::service::Interceptor,
5735            T::ResponseBody: Default,
5736            T: tonic::codegen::Service<
5737                http::Request<tonic::body::BoxBody>,
5738                Response = http::Response<
5739                    <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
5740                >,
5741            >,
5742            <T as tonic::codegen::Service<
5743                http::Request<tonic::body::BoxBody>,
5744            >>::Error: Into<StdError> + Send + Sync,
5745        {
5746            ArcVectorClient::new(InterceptedService::new(inner, interceptor))
5747        }
5748        /// Compress requests with the given encoding.
5749        ///
5750        /// This requires the server to support it otherwise it might respond with an
5751        /// error.
5752        #[must_use]
5753        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
5754            self.inner = self.inner.send_compressed(encoding);
5755            self
5756        }
5757        /// Enable decompressing responses.
5758        #[must_use]
5759        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
5760            self.inner = self.inner.accept_compressed(encoding);
5761            self
5762        }
5763        /// Limits the maximum size of a decoded message.
5764        ///
5765        /// Default: `4MB`
5766        #[must_use]
5767        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
5768            self.inner = self.inner.max_decoding_message_size(limit);
5769            self
5770        }
5771        /// Limits the maximum size of an encoded message.
5772        ///
5773        /// Default: `usize::MAX`
5774        #[must_use]
5775        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
5776            self.inner = self.inner.max_encoding_message_size(limit);
5777            self
5778        }
5779        pub async fn health_check(
5780            &mut self,
5781            request: impl tonic::IntoRequest<super::HealthCheckRequest>,
5782        ) -> std::result::Result<
5783            tonic::Response<super::HealthCheckReply>,
5784            tonic::Status,
5785        > {
5786            self.inner
5787                .ready()
5788                .await
5789                .map_err(|e| {
5790                    tonic::Status::new(
5791                        tonic::Code::Unknown,
5792                        format!("Service was not ready: {}", e.into()),
5793                    )
5794                })?;
5795            let codec = tonic::codec::ProstCodec::default();
5796            let path = http::uri::PathAndQuery::from_static(
5797                "/arc_vector.ArcVector/HealthCheck",
5798            );
5799            let mut req = request.into_request();
5800            req.extensions_mut().insert(GrpcMethod::new("arc_vector.ArcVector", "HealthCheck"));
5801            self.inner.unary(req, path, codec).await
5802        }
5803    }
5804}
5805/// Generated server implementations.
5806pub mod arc_vector_server {
5807    #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)]
5808    use tonic::codegen::*;
5809    /// Generated trait containing gRPC methods that should be implemented for use with ArcVectorServer.
5810    #[async_trait]
5811    pub trait ArcVector: Send + Sync + 'static {
5812        async fn health_check(
5813            &self,
5814            request: tonic::Request<super::HealthCheckRequest>,
5815        ) -> std::result::Result<
5816            tonic::Response<super::HealthCheckReply>,
5817            tonic::Status,
5818        >;
5819    }
5820    #[derive(Debug)]
5821    pub struct ArcVectorServer<T: ArcVector> {
5822        inner: _Inner<T>,
5823        accept_compression_encodings: EnabledCompressionEncodings,
5824        send_compression_encodings: EnabledCompressionEncodings,
5825        max_decoding_message_size: Option<usize>,
5826        max_encoding_message_size: Option<usize>,
5827    }
5828    struct _Inner<T>(Arc<T>);
5829    impl<T: ArcVector> ArcVectorServer<T> {
5830        pub fn new(inner: T) -> Self {
5831            Self::from_arc(Arc::new(inner))
5832        }
5833        pub fn from_arc(inner: Arc<T>) -> Self {
5834            let inner = _Inner(inner);
5835            Self {
5836                inner,
5837                accept_compression_encodings: Default::default(),
5838                send_compression_encodings: Default::default(),
5839                max_decoding_message_size: None,
5840                max_encoding_message_size: None,
5841            }
5842        }
5843        pub fn with_interceptor<F>(
5844            inner: T,
5845            interceptor: F,
5846        ) -> InterceptedService<Self, F>
5847        where
5848            F: tonic::service::Interceptor,
5849        {
5850            InterceptedService::new(Self::new(inner), interceptor)
5851        }
5852        /// Enable decompressing requests with the given encoding.
5853        #[must_use]
5854        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
5855            self.accept_compression_encodings.enable(encoding);
5856            self
5857        }
5858        /// Compress responses with the given encoding, if the client supports it.
5859        #[must_use]
5860        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
5861            self.send_compression_encodings.enable(encoding);
5862            self
5863        }
5864        /// Limits the maximum size of a decoded message.
5865        ///
5866        /// Default: `4MB`
5867        #[must_use]
5868        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
5869            self.max_decoding_message_size = Some(limit);
5870            self
5871        }
5872        /// Limits the maximum size of an encoded message.
5873        ///
5874        /// Default: `usize::MAX`
5875        #[must_use]
5876        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
5877            self.max_encoding_message_size = Some(limit);
5878            self
5879        }
5880    }
5881    impl<T, B> tonic::codegen::Service<http::Request<B>> for ArcVectorServer<T>
5882    where
5883        T: ArcVector,
5884        B: Body + Send + 'static,
5885        B::Error: Into<StdError> + Send + 'static,
5886    {
5887        type Response = http::Response<tonic::body::BoxBody>;
5888        type Error = std::convert::Infallible;
5889        type Future = BoxFuture<Self::Response, Self::Error>;
5890        fn poll_ready(
5891            &mut self,
5892            _cx: &mut Context<'_>,
5893        ) -> Poll<std::result::Result<(), Self::Error>> {
5894            Poll::Ready(Ok(()))
5895        }
5896        fn call(&mut self, req: http::Request<B>) -> Self::Future {
5897            let inner = self.inner.clone();
5898            match req.uri().path() {
5899                "/arc_vector.ArcVector/HealthCheck" => {
5900                    #[allow(non_camel_case_types)]
5901                    struct HealthCheckSvc<T: ArcVector>(pub Arc<T>);
5902                    impl<
5903                        T: ArcVector,
5904                    > tonic::server::UnaryService<super::HealthCheckRequest>
5905                    for HealthCheckSvc<T> {
5906                        type Response = super::HealthCheckReply;
5907                        type Future = BoxFuture<
5908                            tonic::Response<Self::Response>,
5909                            tonic::Status,
5910                        >;
5911                        fn call(
5912                            &mut self,
5913                            request: tonic::Request<super::HealthCheckRequest>,
5914                        ) -> Self::Future {
5915                            let inner = Arc::clone(&self.0);
5916                            let fut = async move {
5917                                (*inner).health_check(request).await
5918                            };
5919                            Box::pin(fut)
5920                        }
5921                    }
5922                    let accept_compression_encodings = self.accept_compression_encodings;
5923                    let send_compression_encodings = self.send_compression_encodings;
5924                    let max_decoding_message_size = self.max_decoding_message_size;
5925                    let max_encoding_message_size = self.max_encoding_message_size;
5926                    let inner = self.inner.clone();
5927                    let fut = async move {
5928                        let inner = inner.0;
5929                        let method = HealthCheckSvc(inner);
5930                        let codec = tonic::codec::ProstCodec::default();
5931                        let mut grpc = tonic::server::Grpc::new(codec)
5932                            .apply_compression_config(
5933                                accept_compression_encodings,
5934                                send_compression_encodings,
5935                            )
5936                            .apply_max_message_size_config(
5937                                max_decoding_message_size,
5938                                max_encoding_message_size,
5939                            );
5940                        let res = grpc.unary(method, req).await;
5941                        Ok(res)
5942                    };
5943                    Box::pin(fut)
5944                }
5945                _ => {
5946                    Box::pin(async move {
5947                        Ok(
5948                            http::Response::builder()
5949                                .status(200)
5950                                .header("grpc-status", "12")
5951                                .header("content-type", "application/grpc")
5952                                .body(empty_body())
5953                                .unwrap(),
5954                        )
5955                    })
5956                }
5957            }
5958        }
5959    }
5960    impl<T: ArcVector> Clone for ArcVectorServer<T> {
5961        fn clone(&self) -> Self {
5962            let inner = self.inner.clone();
5963            Self {
5964                inner,
5965                accept_compression_encodings: self.accept_compression_encodings,
5966                send_compression_encodings: self.send_compression_encodings,
5967                max_decoding_message_size: self.max_decoding_message_size,
5968                max_encoding_message_size: self.max_encoding_message_size,
5969            }
5970        }
5971    }
5972    impl<T: ArcVector> Clone for _Inner<T> {
5973        fn clone(&self) -> Self {
5974            Self(Arc::clone(&self.0))
5975        }
5976    }
5977    impl<T: std::fmt::Debug> std::fmt::Debug for _Inner<T> {
5978        fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
5979            write!(f, "{:?}", self.0)
5980        }
5981    }
5982    impl<T: ArcVector> tonic::server::NamedService for ArcVectorServer<T> {
5983        const NAME: &'static str = "arc_vector.ArcVector";
5984    }
5985}