risingwave_pb/
hummock.rs

1// This file is @generated by prost-build.
2#[derive(prost_helpers::AnyPB)]
3#[derive(Eq)]
4#[derive(Clone, PartialEq, ::prost::Message)]
5pub struct SstableInfo {
6    #[prost(uint64, tag = "1")]
7    pub object_id: u64,
8    #[prost(uint64, tag = "2")]
9    pub sst_id: u64,
10    #[prost(message, optional, tag = "3")]
11    pub key_range: ::core::option::Option<KeyRange>,
12    /// represents the physical object size, which is usually used in the builder.
13    #[prost(uint64, tag = "4")]
14    pub file_size: u64,
15    #[prost(uint32, repeated, tag = "5")]
16    pub table_ids: ::prost::alloc::vec::Vec<u32>,
17    #[prost(uint64, tag = "6")]
18    pub meta_offset: u64,
19    #[prost(uint64, tag = "7")]
20    pub stale_key_count: u64,
21    #[prost(uint64, tag = "8")]
22    pub total_key_count: u64,
23    #[prost(uint64, tag = "9")]
24    pub min_epoch: u64,
25    #[prost(uint64, tag = "10")]
26    pub max_epoch: u64,
27    #[prost(uint64, tag = "11")]
28    pub uncompressed_file_size: u64,
29    #[prost(uint64, tag = "12")]
30    pub range_tombstone_count: u64,
31    #[prost(enumeration = "BloomFilterType", tag = "13")]
32    pub bloom_filter_kind: i32,
33    /// In order to calculate more finely in the compaction strategy, we need to re-calculate the sst_size after split sst
34    /// `sst_size` represents the size of the sst instead of the object size(usually used in the meta).
35    #[prost(uint64, tag = "14")]
36    pub sst_size: u64,
37}
38#[derive(prost_helpers::AnyPB)]
39#[derive(Clone, PartialEq, ::prost::Message)]
40pub struct OverlappingLevel {
41    #[prost(message, repeated, tag = "1")]
42    pub sub_levels: ::prost::alloc::vec::Vec<Level>,
43    #[prost(uint64, tag = "2")]
44    pub total_file_size: u64,
45    #[prost(uint64, tag = "3")]
46    pub uncompressed_file_size: u64,
47}
48#[derive(prost_helpers::AnyPB)]
49#[derive(Clone, PartialEq, ::prost::Message)]
50pub struct Level {
51    #[prost(uint32, tag = "1")]
52    pub level_idx: u32,
53    #[prost(enumeration = "LevelType", tag = "2")]
54    pub level_type: i32,
55    #[prost(message, repeated, tag = "3")]
56    pub table_infos: ::prost::alloc::vec::Vec<SstableInfo>,
57    #[prost(uint64, tag = "4")]
58    pub total_file_size: u64,
59    #[prost(uint64, tag = "5")]
60    pub sub_level_id: u64,
61    #[prost(uint64, tag = "6")]
62    pub uncompressed_file_size: u64,
63    #[prost(uint32, tag = "7")]
64    pub vnode_partition_count: u32,
65}
66#[derive(prost_helpers::AnyPB)]
67#[derive(Eq)]
68#[derive(Clone, PartialEq, ::prost::Message)]
69pub struct InputLevel {
70    #[prost(uint32, tag = "1")]
71    pub level_idx: u32,
72    #[prost(enumeration = "LevelType", tag = "2")]
73    pub level_type: i32,
74    #[prost(message, repeated, tag = "3")]
75    pub table_infos: ::prost::alloc::vec::Vec<SstableInfo>,
76}
77#[derive(prost_helpers::AnyPB)]
78#[derive(Eq)]
79#[derive(Clone, PartialEq, ::prost::Message)]
80pub struct NewL0SubLevel {
81    #[prost(message, repeated, tag = "1")]
82    pub inserted_table_infos: ::prost::alloc::vec::Vec<SstableInfo>,
83}
84#[derive(prost_helpers::AnyPB)]
85#[derive(Eq)]
86#[derive(Clone, PartialEq, ::prost::Message)]
87pub struct IntraLevelDelta {
88    #[prost(uint32, tag = "1")]
89    pub level_idx: u32,
90    #[prost(uint64, tag = "2")]
91    pub l0_sub_level_id: u64,
92    #[prost(uint64, repeated, tag = "3")]
93    pub removed_table_ids: ::prost::alloc::vec::Vec<u64>,
94    #[prost(message, repeated, tag = "4")]
95    pub inserted_table_infos: ::prost::alloc::vec::Vec<SstableInfo>,
96    #[prost(uint32, tag = "5")]
97    pub vnode_partition_count: u32,
98    #[prost(uint64, tag = "6")]
99    pub compaction_group_version_id: u64,
100}
101#[derive(prost_helpers::AnyPB)]
102#[derive(Eq)]
103#[derive(Clone, PartialEq, ::prost::Message)]
104pub struct GroupConstruct {
105    #[prost(message, optional, tag = "1")]
106    pub group_config: ::core::option::Option<CompactionConfig>,
107    /// If parent_group_id is not 0, it means parent_group_id splits into parent_group_id and this group, so this group is not empty initially.
108    #[prost(uint64, tag = "2")]
109    pub parent_group_id: u64,
110    #[deprecated]
111    #[prost(uint32, repeated, packed = "false", tag = "3")]
112    pub table_ids: ::prost::alloc::vec::Vec<u32>,
113    #[prost(uint64, tag = "4")]
114    pub group_id: u64,
115    #[prost(uint64, tag = "5")]
116    pub new_sst_start_id: u64,
117    #[prost(enumeration = "CompatibilityVersion", tag = "6")]
118    pub version: i32,
119    /// The split_key is the key that the group is split by.
120    /// When GroupConstruct with commit_epoch, split_key will be empty
121    /// When split_key is not None, GroupConstruct tells to use split_key to check each level and split the sstable_info in the level into two groups (bounded by split_key).
122    /// For the left sstable_info, split_key (right_exclusive=true) will be used as key_range_right.
123    /// In the current implementation split_key always contains a table_id, vnode = 0, epoch = MAX
124    #[prost(bytes = "vec", optional, tag = "7")]
125    pub split_key: ::core::option::Option<::prost::alloc::vec::Vec<u8>>,
126}
127#[derive(prost_helpers::AnyPB)]
128#[derive(Eq)]
129#[derive(Clone, Copy, PartialEq, ::prost::Message)]
130pub struct GroupDestroy {}
131#[derive(prost_helpers::AnyPB)]
132#[derive(Eq)]
133#[derive(Clone, Copy, PartialEq, ::prost::Message)]
134pub struct GroupMerge {
135    #[prost(uint64, tag = "1")]
136    pub left_group_id: u64,
137    #[prost(uint64, tag = "2")]
138    pub right_group_id: u64,
139}
140#[derive(prost_helpers::AnyPB)]
141#[derive(Eq)]
142#[derive(Clone, PartialEq, ::prost::Message)]
143pub struct GroupDelta {
144    #[prost(oneof = "group_delta::DeltaType", tags = "1, 2, 3, 6, 7")]
145    pub delta_type: ::core::option::Option<group_delta::DeltaType>,
146}
147/// Nested message and enum types in `GroupDelta`.
148pub mod group_delta {
149    #[derive(prost_helpers::AnyPB)]
150    #[derive(Eq)]
151    #[derive(Clone, PartialEq, ::prost::Oneof)]
152    pub enum DeltaType {
153        #[prost(message, tag = "1")]
154        IntraLevel(super::IntraLevelDelta),
155        #[prost(message, tag = "2")]
156        GroupConstruct(super::GroupConstruct),
157        #[prost(message, tag = "3")]
158        GroupDestroy(super::GroupDestroy),
159        #[prost(message, tag = "6")]
160        GroupMerge(super::GroupMerge),
161        #[prost(message, tag = "7")]
162        NewL0SubLevel(super::NewL0SubLevel),
163    }
164}
165#[derive(prost_helpers::AnyPB)]
166#[derive(Clone, PartialEq, ::prost::Message)]
167pub struct UncommittedEpoch {
168    #[prost(uint64, tag = "1")]
169    pub epoch: u64,
170    #[prost(message, repeated, tag = "2")]
171    pub tables: ::prost::alloc::vec::Vec<SstableInfo>,
172}
173#[derive(prost_helpers::AnyPB)]
174#[derive(Eq)]
175#[derive(Clone, PartialEq, ::prost::Message)]
176pub struct VnodeWatermark {
177    /// The watermark shared by multiple vnodes
178    #[prost(bytes = "vec", tag = "1")]
179    pub watermark: ::prost::alloc::vec::Vec<u8>,
180    /// The set of vnodes that share the same watermark
181    #[prost(message, optional, tag = "2")]
182    pub vnode_bitmap: ::core::option::Option<super::common::Buffer>,
183}
184/// Table watermark is a lighter weight range delete introduced in
185/// <https://github.com/risingwavelabs/risingwave/issues/13148>
186/// It means the lowest (or highest when `is_ascending` is false) visible
187/// keys in the table within a vnode. Keys lower (or higher) than the
188/// table watermark is invisible and will be cleaned in later compaction.
189#[derive(prost_helpers::AnyPB)]
190#[derive(Eq)]
191#[derive(Clone, PartialEq, ::prost::Message)]
192pub struct TableWatermarks {
193    /// Table watermarks of a state table from all vnodes written in multiple epochs.
194    /// Epochs should be sorted in ascending order, which means earlier epoch at the front
195    #[prost(message, repeated, tag = "1")]
196    pub epoch_watermarks: ::prost::alloc::vec::Vec<table_watermarks::EpochNewWatermarks>,
197    /// The direction of the table watermark.
198    #[prost(bool, tag = "2")]
199    pub is_ascending: bool,
200    /// The table watermark is non-pk prefix table watermark.
201    #[prost(bool, tag = "3")]
202    pub is_non_pk_prefix: bool,
203}
204/// Nested message and enum types in `TableWatermarks`.
205pub mod table_watermarks {
206    #[derive(prost_helpers::AnyPB)]
207    #[derive(Eq)]
208    #[derive(Clone, PartialEq, ::prost::Message)]
209    pub struct EpochNewWatermarks {
210        #[prost(message, repeated, tag = "1")]
211        pub watermarks: ::prost::alloc::vec::Vec<super::VnodeWatermark>,
212        #[prost(uint64, tag = "2")]
213        pub epoch: u64,
214    }
215}
216#[derive(prost_helpers::AnyPB)]
217#[derive(Clone, PartialEq, ::prost::Message)]
218pub struct EpochNewChangeLog {
219    #[prost(message, repeated, tag = "1")]
220    pub old_value: ::prost::alloc::vec::Vec<SstableInfo>,
221    #[prost(message, repeated, tag = "2")]
222    pub new_value: ::prost::alloc::vec::Vec<SstableInfo>,
223    /// Epochs should be sorted in ascending order, which means earlier epoch at the front
224    #[prost(uint64, repeated, tag = "3")]
225    pub epochs: ::prost::alloc::vec::Vec<u64>,
226}
227#[derive(prost_helpers::AnyPB)]
228#[derive(Clone, PartialEq, ::prost::Message)]
229pub struct TableChangeLog {
230    /// Epochs should be sorted in ascending order, which means earlier epoch at the front.
231    #[prost(message, repeated, tag = "1")]
232    pub change_logs: ::prost::alloc::vec::Vec<EpochNewChangeLog>,
233}
234#[derive(prost_helpers::AnyPB)]
235#[derive(Clone, Copy, PartialEq, ::prost::Message)]
236pub struct StateTableInfo {
237    #[prost(uint64, tag = "1")]
238    pub committed_epoch: u64,
239    #[prost(uint64, tag = "3")]
240    pub compaction_group_id: u64,
241}
242#[derive(prost_helpers::AnyPB)]
243#[derive(Clone, Copy, PartialEq, ::prost::Message)]
244pub struct StateTableInfoDelta {
245    #[prost(uint64, tag = "1")]
246    pub committed_epoch: u64,
247    #[prost(uint64, tag = "3")]
248    pub compaction_group_id: u64,
249}
250#[derive(prost_helpers::AnyPB)]
251#[derive(Clone, PartialEq, ::prost::Message)]
252pub struct HummockVersion {
253    #[prost(uint64, tag = "1")]
254    pub id: u64,
255    /// Levels of each compaction group
256    #[prost(map = "uint64, message", tag = "2")]
257    pub levels: ::std::collections::HashMap<u64, hummock_version::Levels>,
258    #[deprecated]
259    #[prost(uint64, tag = "3")]
260    pub max_committed_epoch: u64,
261    #[prost(map = "uint32, message", tag = "5")]
262    pub table_watermarks: ::std::collections::HashMap<u32, TableWatermarks>,
263    #[prost(map = "uint32, message", tag = "6")]
264    pub table_change_logs: ::std::collections::HashMap<u32, TableChangeLog>,
265    #[prost(map = "uint32, message", tag = "7")]
266    pub state_table_info: ::std::collections::HashMap<u32, StateTableInfo>,
267}
268/// Nested message and enum types in `HummockVersion`.
269pub mod hummock_version {
270    #[derive(prost_helpers::AnyPB)]
271    #[derive(Clone, PartialEq, ::prost::Message)]
272    pub struct Levels {
273        #[prost(message, repeated, tag = "1")]
274        pub levels: ::prost::alloc::vec::Vec<super::Level>,
275        #[prost(message, optional, tag = "2")]
276        pub l0: ::core::option::Option<super::OverlappingLevel>,
277        #[prost(uint64, tag = "3")]
278        pub group_id: u64,
279        #[prost(uint64, tag = "4")]
280        pub parent_group_id: u64,
281        #[deprecated]
282        #[prost(uint32, repeated, packed = "false", tag = "5")]
283        pub member_table_ids: ::prost::alloc::vec::Vec<u32>,
284        #[prost(uint64, tag = "6")]
285        pub compaction_group_version_id: u64,
286    }
287}
288#[derive(prost_helpers::AnyPB)]
289#[derive(Clone, PartialEq, ::prost::Message)]
290pub struct HummockVersionDelta {
291    #[prost(uint64, tag = "1")]
292    pub id: u64,
293    #[prost(uint64, tag = "2")]
294    pub prev_id: u64,
295    /// Levels of each compaction group
296    #[prost(map = "uint64, message", tag = "3")]
297    pub group_deltas: ::std::collections::HashMap<
298        u64,
299        hummock_version_delta::GroupDeltas,
300    >,
301    #[deprecated]
302    #[prost(uint64, tag = "4")]
303    pub max_committed_epoch: u64,
304    #[prost(bool, tag = "6")]
305    pub trivial_move: bool,
306    #[prost(map = "uint32, message", tag = "8")]
307    pub new_table_watermarks: ::std::collections::HashMap<u32, TableWatermarks>,
308    #[prost(uint32, repeated, tag = "9")]
309    pub removed_table_ids: ::prost::alloc::vec::Vec<u32>,
310    #[prost(map = "uint32, message", tag = "10")]
311    pub change_log_delta: ::std::collections::HashMap<
312        u32,
313        hummock_version_delta::ChangeLogDelta,
314    >,
315    #[prost(map = "uint32, message", tag = "11")]
316    pub state_table_info_delta: ::std::collections::HashMap<u32, StateTableInfoDelta>,
317}
318/// Nested message and enum types in `HummockVersionDelta`.
319pub mod hummock_version_delta {
320    #[derive(prost_helpers::AnyPB)]
321    #[derive(Clone, PartialEq, ::prost::Message)]
322    pub struct GroupDeltas {
323        #[prost(message, repeated, tag = "1")]
324        pub group_deltas: ::prost::alloc::vec::Vec<super::GroupDelta>,
325    }
326    #[derive(prost_helpers::AnyPB)]
327    #[derive(Clone, PartialEq, ::prost::Message)]
328    pub struct ChangeLogDelta {
329        #[prost(message, optional, tag = "1")]
330        pub new_log: ::core::option::Option<super::EpochNewChangeLog>,
331        /// only logs in epoch later than truncate_epoch will be preserved
332        #[prost(uint64, tag = "2")]
333        pub truncate_epoch: u64,
334    }
335}
336#[derive(prost_helpers::AnyPB)]
337#[derive(Clone, PartialEq, ::prost::Message)]
338pub struct HummockVersionDeltas {
339    #[prost(message, repeated, tag = "1")]
340    pub version_deltas: ::prost::alloc::vec::Vec<HummockVersionDelta>,
341}
342#[derive(prost_helpers::AnyPB)]
343#[derive(Clone, PartialEq, ::prost::Message)]
344pub struct HummockVersionCheckpoint {
345    #[prost(message, optional, tag = "1")]
346    pub version: ::core::option::Option<HummockVersion>,
347    #[prost(map = "uint64, message", tag = "2")]
348    pub stale_objects: ::std::collections::HashMap<
349        u64,
350        hummock_version_checkpoint::StaleObjects,
351    >,
352}
353/// Nested message and enum types in `HummockVersionCheckpoint`.
354pub mod hummock_version_checkpoint {
355    #[derive(prost_helpers::AnyPB)]
356    #[derive(Clone, PartialEq, ::prost::Message)]
357    pub struct StaleObjects {
358        #[prost(uint64, repeated, tag = "1")]
359        pub id: ::prost::alloc::vec::Vec<u64>,
360        #[prost(uint64, tag = "2")]
361        pub total_file_size: u64,
362    }
363}
364#[derive(prost_helpers::AnyPB)]
365#[derive(Clone, PartialEq, ::prost::Message)]
366pub struct HummockVersionArchive {
367    #[prost(message, optional, tag = "1")]
368    pub version: ::core::option::Option<HummockVersion>,
369    /// some version_deltas since version
370    #[prost(message, repeated, tag = "2")]
371    pub version_deltas: ::prost::alloc::vec::Vec<HummockVersionDelta>,
372}
373#[derive(prost_helpers::AnyPB)]
374#[derive(Clone, PartialEq, ::prost::Message)]
375pub struct VersionUpdatePayload {
376    #[prost(oneof = "version_update_payload::Payload", tags = "1, 2")]
377    pub payload: ::core::option::Option<version_update_payload::Payload>,
378}
379/// Nested message and enum types in `VersionUpdatePayload`.
380pub mod version_update_payload {
381    #[derive(prost_helpers::AnyPB)]
382    #[derive(Clone, PartialEq, ::prost::Oneof)]
383    pub enum Payload {
384        #[prost(message, tag = "1")]
385        VersionDeltas(super::HummockVersionDeltas),
386        #[prost(message, tag = "2")]
387        PinnedVersion(super::HummockVersion),
388    }
389}
390#[derive(prost_helpers::AnyPB)]
391#[derive(Clone, Copy, PartialEq, ::prost::Message)]
392pub struct UnpinVersionBeforeRequest {
393    #[prost(uint32, tag = "1")]
394    pub context_id: u32,
395    #[prost(uint64, tag = "2")]
396    pub unpin_version_before: u64,
397}
398#[derive(prost_helpers::AnyPB)]
399#[derive(Clone, PartialEq, ::prost::Message)]
400pub struct UnpinVersionBeforeResponse {
401    #[prost(message, optional, tag = "1")]
402    pub status: ::core::option::Option<super::common::Status>,
403}
404#[derive(prost_helpers::AnyPB)]
405#[derive(Clone, Copy, PartialEq, ::prost::Message)]
406pub struct GetCurrentVersionRequest {}
407#[derive(prost_helpers::AnyPB)]
408#[derive(Clone, PartialEq, ::prost::Message)]
409pub struct GetCurrentVersionResponse {
410    #[prost(message, optional, tag = "1")]
411    pub status: ::core::option::Option<super::common::Status>,
412    #[prost(message, optional, tag = "2")]
413    pub current_version: ::core::option::Option<HummockVersion>,
414}
415#[derive(prost_helpers::AnyPB)]
416#[derive(Clone, Copy, PartialEq, ::prost::Message)]
417pub struct UnpinVersionRequest {
418    #[prost(uint32, tag = "1")]
419    pub context_id: u32,
420}
421#[derive(prost_helpers::AnyPB)]
422#[derive(Clone, PartialEq, ::prost::Message)]
423pub struct UnpinVersionResponse {
424    #[prost(message, optional, tag = "1")]
425    pub status: ::core::option::Option<super::common::Status>,
426}
427#[derive(prost_helpers::AnyPB)]
428#[derive(Clone, Copy, PartialEq, ::prost::Message)]
429pub struct GetAssignedCompactTaskNumRequest {}
430#[derive(prost_helpers::AnyPB)]
431#[derive(Clone, Copy, PartialEq, ::prost::Message)]
432pub struct GetAssignedCompactTaskNumResponse {
433    #[prost(uint32, tag = "1")]
434    pub num_tasks: u32,
435}
436/// When right_exclusive=false, it represents \[left, right\], of which both boundary are open. When right_exclusive=true,
437/// it represents [left, right), of which right is exclusive.
438#[derive(prost_helpers::AnyPB)]
439#[derive(Eq)]
440#[derive(Clone, PartialEq, ::prost::Message)]
441pub struct KeyRange {
442    #[prost(bytes = "vec", tag = "1")]
443    pub left: ::prost::alloc::vec::Vec<u8>,
444    #[prost(bytes = "vec", tag = "2")]
445    pub right: ::prost::alloc::vec::Vec<u8>,
446    #[prost(bool, tag = "3")]
447    pub right_exclusive: bool,
448}
449#[derive(prost_helpers::AnyPB)]
450#[derive(Eq)]
451#[derive(Clone, Copy, PartialEq, ::prost::Message)]
452pub struct TableOption {
453    #[prost(uint32, optional, tag = "2")]
454    pub retention_seconds: ::core::option::Option<u32>,
455}
456#[derive(prost_helpers::AnyPB)]
457#[derive(Eq)]
458#[derive(Clone, PartialEq, ::prost::Message)]
459pub struct TableSchema {
460    #[prost(int32, repeated, tag = "1")]
461    pub column_ids: ::prost::alloc::vec::Vec<i32>,
462}
463#[derive(prost_helpers::AnyPB)]
464#[derive(Eq)]
465#[derive(Clone, PartialEq, ::prost::Message)]
466pub struct CompactTask {
467    /// SSTs to be compacted, which will be removed from LSM after compaction
468    #[prost(message, repeated, tag = "1")]
469    pub input_ssts: ::prost::alloc::vec::Vec<InputLevel>,
470    /// In ideal case, the compaction will generate splits.len() tables which have key range
471    /// corresponding to that in \[splits\], respectively
472    #[prost(message, repeated, tag = "2")]
473    pub splits: ::prost::alloc::vec::Vec<KeyRange>,
474    /// compaction output, which will be added to \[target_level\] of LSM after compaction
475    #[prost(message, repeated, tag = "4")]
476    pub sorted_output_ssts: ::prost::alloc::vec::Vec<SstableInfo>,
477    /// task id assigned by hummock storage service
478    #[prost(uint64, tag = "5")]
479    pub task_id: u64,
480    /// compaction output will be added to \[target_level\] of LSM after compaction
481    #[prost(uint32, tag = "6")]
482    pub target_level: u32,
483    #[prost(bool, tag = "7")]
484    pub gc_delete_keys: bool,
485    /// Lbase in LSM
486    #[prost(uint32, tag = "8")]
487    pub base_level: u32,
488    #[prost(enumeration = "compact_task::TaskStatus", tag = "9")]
489    pub task_status: i32,
490    /// compaction group the task belongs to
491    #[prost(uint64, tag = "12")]
492    pub compaction_group_id: u64,
493    /// existing_table_ids for compaction drop key
494    #[prost(uint32, repeated, tag = "13")]
495    pub existing_table_ids: ::prost::alloc::vec::Vec<u32>,
496    #[prost(uint32, tag = "14")]
497    pub compression_algorithm: u32,
498    #[prost(uint64, tag = "15")]
499    pub target_file_size: u64,
500    #[prost(uint32, tag = "16")]
501    pub compaction_filter_mask: u32,
502    #[prost(btree_map = "uint32, message", tag = "17")]
503    pub table_options: ::prost::alloc::collections::BTreeMap<u32, TableOption>,
504    #[prost(uint64, tag = "18")]
505    pub current_epoch_time: u64,
506    #[prost(uint64, tag = "19")]
507    pub target_sub_level_id: u64,
508    /// Identifies whether the task is space_reclaim, if the compact_task_type increases, it will be refactored to enum
509    #[prost(enumeration = "compact_task::TaskType", tag = "20")]
510    pub task_type: i32,
511    /// Deprecated. use table_vnode_partition instead;
512    #[deprecated]
513    #[prost(bool, tag = "21")]
514    pub split_by_state_table: bool,
515    /// Compaction needs to cut the state table every time 1/weight of vnodes in the table have been processed.
516    /// Deprecated. use table_vnode_partition instead;
517    #[prost(uint32, tag = "22")]
518    pub split_weight_by_vnode: u32,
519    #[prost(btree_map = "uint32, uint32", tag = "23")]
520    pub table_vnode_partition: ::prost::alloc::collections::BTreeMap<u32, u32>,
521    /// The table watermark of any table id. In compaction we only use the table watermarks on safe epoch,
522    /// so we only need to include the table watermarks on safe epoch to reduce the size of metadata.
523    #[prost(btree_map = "uint32, message", tag = "24")]
524    pub table_watermarks: ::prost::alloc::collections::BTreeMap<u32, TableWatermarks>,
525    /// The table schemas that are at least as new as the one used to create `input_ssts`.
526    #[prost(btree_map = "uint32, message", tag = "25")]
527    pub table_schemas: ::prost::alloc::collections::BTreeMap<u32, TableSchema>,
528    /// Max sub compaction task numbers
529    #[prost(uint32, tag = "26")]
530    pub max_sub_compaction: u32,
531    /// The compaction group id when the compaction task is created.
532    #[prost(uint64, tag = "27")]
533    pub compaction_group_version_id: u64,
534}
535/// Nested message and enum types in `CompactTask`.
536pub mod compact_task {
537    #[derive(prost_helpers::AnyPB)]
538    #[derive(
539        Clone,
540        Copy,
541        Debug,
542        PartialEq,
543        Eq,
544        Hash,
545        PartialOrd,
546        Ord,
547        ::prost::Enumeration
548    )]
549    #[repr(i32)]
550    pub enum TaskStatus {
551        Unspecified = 0,
552        Pending = 1,
553        Success = 2,
554        HeartbeatCanceled = 3,
555        NoAvailMemoryResourceCanceled = 4,
556        AssignFailCanceled = 5,
557        SendFailCanceled = 6,
558        ManualCanceled = 7,
559        InvalidGroupCanceled = 8,
560        InputOutdatedCanceled = 9,
561        ExecuteFailed = 10,
562        JoinHandleFailed = 11,
563        TrackSstObjectIdFailed = 12,
564        NoAvailCpuResourceCanceled = 13,
565        HeartbeatProgressCanceled = 14,
566        RetentionTimeRejected = 17,
567        /// for serverless compaction
568        ServerlessSendFailCanceled = 15,
569        ServerlessTableNotFoundCanceled = 16,
570    }
571    impl TaskStatus {
572        /// String value of the enum field names used in the ProtoBuf definition.
573        ///
574        /// The values are not transformed in any way and thus are considered stable
575        /// (if the ProtoBuf definition does not change) and safe for programmatic use.
576        pub fn as_str_name(&self) -> &'static str {
577            match self {
578                Self::Unspecified => "UNSPECIFIED",
579                Self::Pending => "PENDING",
580                Self::Success => "SUCCESS",
581                Self::HeartbeatCanceled => "HEARTBEAT_CANCELED",
582                Self::NoAvailMemoryResourceCanceled => {
583                    "NO_AVAIL_MEMORY_RESOURCE_CANCELED"
584                }
585                Self::AssignFailCanceled => "ASSIGN_FAIL_CANCELED",
586                Self::SendFailCanceled => "SEND_FAIL_CANCELED",
587                Self::ManualCanceled => "MANUAL_CANCELED",
588                Self::InvalidGroupCanceled => "INVALID_GROUP_CANCELED",
589                Self::InputOutdatedCanceled => "INPUT_OUTDATED_CANCELED",
590                Self::ExecuteFailed => "EXECUTE_FAILED",
591                Self::JoinHandleFailed => "JOIN_HANDLE_FAILED",
592                Self::TrackSstObjectIdFailed => "TRACK_SST_OBJECT_ID_FAILED",
593                Self::NoAvailCpuResourceCanceled => "NO_AVAIL_CPU_RESOURCE_CANCELED",
594                Self::HeartbeatProgressCanceled => "HEARTBEAT_PROGRESS_CANCELED",
595                Self::RetentionTimeRejected => "RETENTION_TIME_REJECTED",
596                Self::ServerlessSendFailCanceled => "SERVERLESS_SEND_FAIL_CANCELED",
597                Self::ServerlessTableNotFoundCanceled => {
598                    "SERVERLESS_TABLE_NOT_FOUND_CANCELED"
599                }
600            }
601        }
602        /// Creates an enum from field names used in the ProtoBuf definition.
603        pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
604            match value {
605                "UNSPECIFIED" => Some(Self::Unspecified),
606                "PENDING" => Some(Self::Pending),
607                "SUCCESS" => Some(Self::Success),
608                "HEARTBEAT_CANCELED" => Some(Self::HeartbeatCanceled),
609                "NO_AVAIL_MEMORY_RESOURCE_CANCELED" => {
610                    Some(Self::NoAvailMemoryResourceCanceled)
611                }
612                "ASSIGN_FAIL_CANCELED" => Some(Self::AssignFailCanceled),
613                "SEND_FAIL_CANCELED" => Some(Self::SendFailCanceled),
614                "MANUAL_CANCELED" => Some(Self::ManualCanceled),
615                "INVALID_GROUP_CANCELED" => Some(Self::InvalidGroupCanceled),
616                "INPUT_OUTDATED_CANCELED" => Some(Self::InputOutdatedCanceled),
617                "EXECUTE_FAILED" => Some(Self::ExecuteFailed),
618                "JOIN_HANDLE_FAILED" => Some(Self::JoinHandleFailed),
619                "TRACK_SST_OBJECT_ID_FAILED" => Some(Self::TrackSstObjectIdFailed),
620                "NO_AVAIL_CPU_RESOURCE_CANCELED" => {
621                    Some(Self::NoAvailCpuResourceCanceled)
622                }
623                "HEARTBEAT_PROGRESS_CANCELED" => Some(Self::HeartbeatProgressCanceled),
624                "RETENTION_TIME_REJECTED" => Some(Self::RetentionTimeRejected),
625                "SERVERLESS_SEND_FAIL_CANCELED" => Some(Self::ServerlessSendFailCanceled),
626                "SERVERLESS_TABLE_NOT_FOUND_CANCELED" => {
627                    Some(Self::ServerlessTableNotFoundCanceled)
628                }
629                _ => None,
630            }
631        }
632    }
633    #[derive(prost_helpers::AnyPB)]
634    #[derive(
635        Clone,
636        Copy,
637        Debug,
638        PartialEq,
639        Eq,
640        Hash,
641        PartialOrd,
642        Ord,
643        ::prost::Enumeration
644    )]
645    #[repr(i32)]
646    pub enum TaskType {
647        TypeUnspecified = 0,
648        Dynamic = 1,
649        SpaceReclaim = 2,
650        Manual = 3,
651        SharedBuffer = 4,
652        Ttl = 5,
653        Tombstone = 6,
654        Emergency = 7,
655        VnodeWatermark = 8,
656    }
657    impl TaskType {
658        /// String value of the enum field names used in the ProtoBuf definition.
659        ///
660        /// The values are not transformed in any way and thus are considered stable
661        /// (if the ProtoBuf definition does not change) and safe for programmatic use.
662        pub fn as_str_name(&self) -> &'static str {
663            match self {
664                Self::TypeUnspecified => "TYPE_UNSPECIFIED",
665                Self::Dynamic => "DYNAMIC",
666                Self::SpaceReclaim => "SPACE_RECLAIM",
667                Self::Manual => "MANUAL",
668                Self::SharedBuffer => "SHARED_BUFFER",
669                Self::Ttl => "TTL",
670                Self::Tombstone => "TOMBSTONE",
671                Self::Emergency => "EMERGENCY",
672                Self::VnodeWatermark => "VNODE_WATERMARK",
673            }
674        }
675        /// Creates an enum from field names used in the ProtoBuf definition.
676        pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
677            match value {
678                "TYPE_UNSPECIFIED" => Some(Self::TypeUnspecified),
679                "DYNAMIC" => Some(Self::Dynamic),
680                "SPACE_RECLAIM" => Some(Self::SpaceReclaim),
681                "MANUAL" => Some(Self::Manual),
682                "SHARED_BUFFER" => Some(Self::SharedBuffer),
683                "TTL" => Some(Self::Ttl),
684                "TOMBSTONE" => Some(Self::Tombstone),
685                "EMERGENCY" => Some(Self::Emergency),
686                "VNODE_WATERMARK" => Some(Self::VnodeWatermark),
687                _ => None,
688            }
689        }
690    }
691}
692#[derive(prost_helpers::AnyPB)]
693#[derive(Eq)]
694#[derive(Clone, PartialEq, ::prost::Message)]
695pub struct LevelHandler {
696    #[prost(uint32, tag = "1")]
697    pub level: u32,
698    #[prost(message, repeated, tag = "3")]
699    pub tasks: ::prost::alloc::vec::Vec<level_handler::RunningCompactTask>,
700}
701/// Nested message and enum types in `LevelHandler`.
702pub mod level_handler {
703    #[derive(prost_helpers::AnyPB)]
704    #[derive(Eq)]
705    #[derive(Clone, PartialEq, ::prost::Message)]
706    pub struct RunningCompactTask {
707        #[prost(uint64, tag = "1")]
708        pub task_id: u64,
709        #[prost(uint64, repeated, tag = "2")]
710        pub ssts: ::prost::alloc::vec::Vec<u64>,
711        #[prost(uint64, tag = "3")]
712        pub total_file_size: u64,
713        #[prost(uint32, tag = "4")]
714        pub target_level: u32,
715    }
716}
717#[derive(prost_helpers::AnyPB)]
718#[derive(Clone, PartialEq, ::prost::Message)]
719pub struct CompactStatus {
720    #[prost(uint64, tag = "1")]
721    pub compaction_group_id: u64,
722    #[prost(message, repeated, tag = "2")]
723    pub level_handlers: ::prost::alloc::vec::Vec<LevelHandler>,
724}
725/// Config info of compaction group.
726#[derive(prost_helpers::AnyPB)]
727#[derive(Clone, PartialEq, ::prost::Message)]
728pub struct CompactionGroup {
729    #[prost(uint64, tag = "1")]
730    pub id: u64,
731    #[prost(message, optional, tag = "4")]
732    pub compaction_config: ::core::option::Option<CompactionConfig>,
733}
734/// Complete info of compaction group.
735/// The info is the aggregate of HummockVersion and CompactionGroupConfig
736#[derive(prost_helpers::AnyPB)]
737#[derive(Clone, PartialEq, ::prost::Message)]
738pub struct CompactionGroupInfo {
739    #[prost(uint64, tag = "1")]
740    pub id: u64,
741    #[prost(uint64, tag = "2")]
742    pub parent_id: u64,
743    #[prost(uint32, repeated, tag = "3")]
744    pub member_table_ids: ::prost::alloc::vec::Vec<u32>,
745    #[prost(message, optional, tag = "4")]
746    pub compaction_config: ::core::option::Option<CompactionConfig>,
747}
748#[derive(prost_helpers::AnyPB)]
749#[derive(Clone, PartialEq, ::prost::Message)]
750pub struct CompactTaskAssignment {
751    #[prost(message, optional, tag = "1")]
752    pub compact_task: ::core::option::Option<CompactTask>,
753    #[prost(uint32, tag = "2")]
754    pub context_id: u32,
755}
756#[derive(prost_helpers::AnyPB)]
757#[derive(Clone, Copy, PartialEq, ::prost::Message)]
758pub struct HummockPinnedVersion {
759    #[prost(uint32, tag = "1")]
760    pub context_id: u32,
761    #[prost(uint64, tag = "2")]
762    pub min_pinned_id: u64,
763}
764#[derive(prost_helpers::AnyPB)]
765#[derive(Clone, Copy, PartialEq, ::prost::Message)]
766pub struct HummockPinnedSnapshot {
767    #[prost(uint32, tag = "1")]
768    pub context_id: u32,
769    #[prost(uint64, tag = "2")]
770    pub minimal_pinned_snapshot: u64,
771}
772#[derive(prost_helpers::AnyPB)]
773#[derive(Clone, Copy, PartialEq, ::prost::Message)]
774pub struct GetNewSstIdsRequest {
775    #[prost(uint32, tag = "1")]
776    pub number: u32,
777}
778#[derive(prost_helpers::AnyPB)]
779#[derive(Clone, PartialEq, ::prost::Message)]
780pub struct GetNewSstIdsResponse {
781    #[prost(message, optional, tag = "1")]
782    pub status: ::core::option::Option<super::common::Status>,
783    /// inclusive
784    #[prost(uint64, tag = "2")]
785    pub start_id: u64,
786    /// exclusive
787    #[prost(uint64, tag = "3")]
788    pub end_id: u64,
789}
790/// This is a heartbeat message. Task will be considered dead if
791/// CompactTaskProgress is not received for a timeout
792/// or num_ssts_sealed/num_ssts_uploaded do not increase for a timeout.
793#[derive(prost_helpers::AnyPB)]
794#[derive(Clone, Copy, PartialEq, ::prost::Message)]
795pub struct CompactTaskProgress {
796    #[prost(uint64, tag = "1")]
797    pub task_id: u64,
798    #[prost(uint32, tag = "2")]
799    pub num_ssts_sealed: u32,
800    #[prost(uint32, tag = "3")]
801    pub num_ssts_uploaded: u32,
802    #[prost(uint64, tag = "4")]
803    pub num_progress_key: u64,
804    #[prost(uint64, tag = "5")]
805    pub num_pending_read_io: u64,
806    #[prost(uint64, tag = "6")]
807    pub num_pending_write_io: u64,
808    #[prost(uint64, optional, tag = "7")]
809    pub compaction_group_id: ::core::option::Option<u64>,
810}
811#[derive(prost_helpers::AnyPB)]
812#[derive(Clone, PartialEq, ::prost::Message)]
813pub struct SubscribeCompactionEventRequest {
814    #[prost(uint64, tag = "7")]
815    pub create_at: u64,
816    #[prost(oneof = "subscribe_compaction_event_request::Event", tags = "1, 2, 3, 4")]
817    pub event: ::core::option::Option<subscribe_compaction_event_request::Event>,
818}
819/// Nested message and enum types in `SubscribeCompactionEventRequest`.
820pub mod subscribe_compaction_event_request {
821    /// Register provides the context_id of the corresponding Compactor.
822    #[derive(prost_helpers::AnyPB)]
823    #[derive(Clone, Copy, PartialEq, ::prost::Message)]
824    pub struct Register {
825        #[prost(uint32, tag = "1")]
826        pub context_id: u32,
827    }
828    /// PullTask provides the number of tasks needed for the Compactor.
829    #[derive(prost_helpers::AnyPB)]
830    #[derive(Clone, Copy, PartialEq, ::prost::Message)]
831    pub struct PullTask {
832        #[prost(uint32, tag = "4")]
833        pub pull_task_count: u32,
834    }
835    /// ReportTask provides the compact task to report to the meta.
836    #[derive(prost_helpers::AnyPB)]
837    #[derive(Clone, PartialEq, ::prost::Message)]
838    pub struct ReportTask {
839        #[prost(map = "uint32, message", tag = "3")]
840        pub table_stats_change: ::std::collections::HashMap<u32, super::TableStats>,
841        #[prost(uint64, tag = "4")]
842        pub task_id: u64,
843        #[prost(enumeration = "super::compact_task::TaskStatus", tag = "5")]
844        pub task_status: i32,
845        #[prost(message, repeated, tag = "6")]
846        pub sorted_output_ssts: ::prost::alloc::vec::Vec<super::SstableInfo>,
847        #[prost(map = "uint64, uint64", tag = "7")]
848        pub object_timestamps: ::std::collections::HashMap<u64, u64>,
849    }
850    /// HeartBeat provides the progress status of all tasks on the Compactor.
851    #[derive(prost_helpers::AnyPB)]
852    #[derive(Clone, PartialEq, ::prost::Message)]
853    pub struct HeartBeat {
854        #[prost(message, repeated, tag = "2")]
855        pub progress: ::prost::alloc::vec::Vec<super::CompactTaskProgress>,
856    }
857    #[derive(prost_helpers::AnyPB)]
858    #[derive(Clone, PartialEq, ::prost::Oneof)]
859    pub enum Event {
860        /// Compactor will register its own context_id with Meta via Register and establish a bi-directional streaming rpc.
861        #[prost(message, tag = "1")]
862        Register(Register),
863        /// Compactor will recalculate the number of tasks needed locally after receiving the PullTaskAck and get the next batch of tasks from Meta via PullTask.
864        #[prost(message, tag = "2")]
865        PullTask(PullTask),
866        /// When the execution of each task completes/fails, Compactor returns the task to the meta via ReportTask.
867        #[prost(message, tag = "3")]
868        ReportTask(ReportTask),
869        /// Periodically, HeartBeat carries the progress of all tasks on the Compactor, and the meta will cancel the task when it expires.
870        #[prost(message, tag = "4")]
871        HeartBeat(HeartBeat),
872    }
873}
874#[derive(prost_helpers::AnyPB)]
875#[derive(Clone, PartialEq, ::prost::Message)]
876pub struct SubscribeCompactionEventResponse {
877    #[prost(uint64, tag = "7")]
878    pub create_at: u64,
879    #[prost(
880        oneof = "subscribe_compaction_event_response::Event",
881        tags = "1, 2, 3, 4, 5, 6"
882    )]
883    pub event: ::core::option::Option<subscribe_compaction_event_response::Event>,
884}
885/// Nested message and enum types in `SubscribeCompactionEventResponse`.
886pub mod subscribe_compaction_event_response {
887    /// PullTaskAck is a response, the meta will return a PullTaskAck after distributing the task requested by the PullTask.
888    /// The Compactor receives the PullTaskAck and remakes its state and tries to initiate the next PullTask.
889    #[derive(prost_helpers::AnyPB)]
890    #[derive(Clone, Copy, PartialEq, ::prost::Message)]
891    pub struct PullTaskAck {}
892    #[derive(prost_helpers::AnyPB)]
893    #[derive(Clone, PartialEq, ::prost::Oneof)]
894    pub enum Event {
895        #[prost(message, tag = "1")]
896        CompactTask(super::CompactTask),
897        #[prost(message, tag = "2")]
898        VacuumTask(super::VacuumTask),
899        #[prost(message, tag = "3")]
900        FullScanTask(super::FullScanTask),
901        #[prost(message, tag = "4")]
902        ValidationTask(super::ValidationTask),
903        #[prost(message, tag = "5")]
904        CancelCompactTask(super::CancelCompactTask),
905        #[prost(message, tag = "6")]
906        PullTaskAck(PullTaskAck),
907    }
908}
909#[derive(prost_helpers::AnyPB)]
910#[derive(Clone, PartialEq, ::prost::Message)]
911pub struct ReportCompactionTaskRequest {
912    #[prost(oneof = "report_compaction_task_request::Event", tags = "1, 2")]
913    pub event: ::core::option::Option<report_compaction_task_request::Event>,
914}
915/// Nested message and enum types in `ReportCompactionTaskRequest`.
916pub mod report_compaction_task_request {
917    /// ReportTask provides the compact task to report to the meta.
918    #[derive(prost_helpers::AnyPB)]
919    #[derive(Clone, PartialEq, ::prost::Message)]
920    pub struct ReportTask {
921        #[prost(message, optional, tag = "2")]
922        pub compact_task: ::core::option::Option<super::CompactTask>,
923        #[prost(map = "uint32, message", tag = "3")]
924        pub table_stats_change: ::std::collections::HashMap<u32, super::TableStats>,
925        #[prost(map = "uint64, uint64", tag = "4")]
926        pub object_timestamps: ::std::collections::HashMap<u64, u64>,
927    }
928    /// HeartBeat provides the progress status of all tasks on the Compactor.
929    #[derive(prost_helpers::AnyPB)]
930    #[derive(Clone, PartialEq, ::prost::Message)]
931    pub struct HeartBeat {
932        #[prost(message, repeated, tag = "2")]
933        pub progress: ::prost::alloc::vec::Vec<super::CompactTaskProgress>,
934    }
935    #[derive(prost_helpers::AnyPB)]
936    #[derive(Clone, PartialEq, ::prost::Oneof)]
937    pub enum Event {
938        #[prost(message, tag = "1")]
939        ReportTask(ReportTask),
940        #[prost(message, tag = "2")]
941        HeartBeat(HeartBeat),
942    }
943}
944#[derive(prost_helpers::AnyPB)]
945#[derive(Clone, PartialEq, ::prost::Message)]
946pub struct ReportCompactionTaskResponse {
947    #[prost(message, optional, tag = "1")]
948    pub status: ::core::option::Option<super::common::Status>,
949}
950#[derive(prost_helpers::AnyPB)]
951#[derive(Clone, PartialEq, ::prost::Message)]
952pub struct ValidationTask {
953    #[prost(message, repeated, tag = "1")]
954    pub sst_infos: ::prost::alloc::vec::Vec<SstableInfo>,
955    #[prost(map = "uint64, uint32", tag = "2")]
956    pub sst_id_to_worker_id: ::std::collections::HashMap<u64, u32>,
957}
958/// Delete SSTs in object store
959#[derive(prost_helpers::AnyPB)]
960#[derive(Clone, PartialEq, ::prost::Message)]
961pub struct VacuumTask {
962    #[prost(uint64, repeated, tag = "1")]
963    pub sstable_object_ids: ::prost::alloc::vec::Vec<u64>,
964}
965/// Scan object store to get candidate orphan SSTs.
966#[derive(prost_helpers::AnyPB)]
967#[derive(Clone, PartialEq, ::prost::Message)]
968pub struct FullScanTask {
969    #[prost(uint64, tag = "1")]
970    pub sst_retention_watermark: u64,
971    #[prost(string, optional, tag = "2")]
972    pub prefix: ::core::option::Option<::prost::alloc::string::String>,
973    #[prost(string, optional, tag = "3")]
974    pub start_after: ::core::option::Option<::prost::alloc::string::String>,
975    #[prost(uint64, optional, tag = "4")]
976    pub limit: ::core::option::Option<u64>,
977}
978/// Cancel compact task
979#[derive(prost_helpers::AnyPB)]
980#[derive(Clone, Copy, PartialEq, ::prost::Message)]
981pub struct CancelCompactTask {
982    #[prost(uint32, tag = "1")]
983    pub context_id: u32,
984    #[prost(uint64, tag = "2")]
985    pub task_id: u64,
986}
987#[derive(prost_helpers::AnyPB)]
988#[derive(Clone, PartialEq, ::prost::Message)]
989pub struct TriggerManualCompactionRequest {
990    #[prost(uint64, tag = "1")]
991    pub compaction_group_id: u64,
992    #[prost(message, optional, tag = "2")]
993    pub key_range: ::core::option::Option<KeyRange>,
994    #[prost(uint32, tag = "3")]
995    pub table_id: u32,
996    #[prost(uint32, tag = "4")]
997    pub level: u32,
998    #[prost(uint64, repeated, tag = "5")]
999    pub sst_ids: ::prost::alloc::vec::Vec<u64>,
1000}
1001#[derive(prost_helpers::AnyPB)]
1002#[derive(Clone, PartialEq, ::prost::Message)]
1003pub struct TriggerManualCompactionResponse {
1004    #[prost(message, optional, tag = "1")]
1005    pub status: ::core::option::Option<super::common::Status>,
1006}
1007#[derive(prost_helpers::AnyPB)]
1008#[derive(Clone, PartialEq, ::prost::Message)]
1009pub struct TriggerFullGcRequest {
1010    #[prost(uint64, tag = "1")]
1011    pub sst_retention_time_sec: u64,
1012    #[prost(string, optional, tag = "2")]
1013    pub prefix: ::core::option::Option<::prost::alloc::string::String>,
1014}
1015#[derive(prost_helpers::AnyPB)]
1016#[derive(Clone, PartialEq, ::prost::Message)]
1017pub struct TriggerFullGcResponse {
1018    #[prost(message, optional, tag = "1")]
1019    pub status: ::core::option::Option<super::common::Status>,
1020}
1021#[derive(prost_helpers::AnyPB)]
1022#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1023pub struct ListVersionDeltasRequest {
1024    #[prost(uint64, tag = "1")]
1025    pub start_id: u64,
1026    #[prost(uint32, tag = "2")]
1027    pub num_limit: u32,
1028    #[prost(uint64, tag = "3")]
1029    pub committed_epoch_limit: u64,
1030}
1031#[derive(prost_helpers::AnyPB)]
1032#[derive(Clone, PartialEq, ::prost::Message)]
1033pub struct ListVersionDeltasResponse {
1034    #[prost(message, optional, tag = "1")]
1035    pub version_deltas: ::core::option::Option<HummockVersionDeltas>,
1036}
1037#[derive(prost_helpers::AnyPB)]
1038#[derive(Clone, PartialEq, ::prost::Message)]
1039pub struct PinnedVersionsSummary {
1040    #[prost(message, repeated, tag = "1")]
1041    pub pinned_versions: ::prost::alloc::vec::Vec<HummockPinnedVersion>,
1042    #[prost(map = "uint32, message", tag = "2")]
1043    pub workers: ::std::collections::HashMap<u32, super::common::WorkerNode>,
1044}
1045#[derive(prost_helpers::AnyPB)]
1046#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1047pub struct RiseCtlGetPinnedVersionsSummaryRequest {}
1048#[derive(prost_helpers::AnyPB)]
1049#[derive(Clone, PartialEq, ::prost::Message)]
1050pub struct RiseCtlGetPinnedVersionsSummaryResponse {
1051    #[prost(message, optional, tag = "1")]
1052    pub summary: ::core::option::Option<PinnedVersionsSummary>,
1053}
1054#[derive(prost_helpers::AnyPB)]
1055#[derive(Clone, PartialEq, ::prost::Message)]
1056pub struct InitMetadataForReplayRequest {
1057    #[prost(message, repeated, tag = "1")]
1058    pub tables: ::prost::alloc::vec::Vec<super::catalog::Table>,
1059    #[prost(message, repeated, tag = "2")]
1060    pub compaction_groups: ::prost::alloc::vec::Vec<CompactionGroupInfo>,
1061}
1062#[derive(prost_helpers::AnyPB)]
1063#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1064pub struct InitMetadataForReplayResponse {}
1065#[derive(prost_helpers::AnyPB)]
1066#[derive(Clone, PartialEq, ::prost::Message)]
1067pub struct ReplayVersionDeltaRequest {
1068    #[prost(message, optional, tag = "1")]
1069    pub version_delta: ::core::option::Option<HummockVersionDelta>,
1070}
1071#[derive(prost_helpers::AnyPB)]
1072#[derive(Clone, PartialEq, ::prost::Message)]
1073pub struct ReplayVersionDeltaResponse {
1074    #[prost(message, optional, tag = "1")]
1075    pub version: ::core::option::Option<HummockVersion>,
1076    #[prost(uint64, repeated, tag = "2")]
1077    pub modified_compaction_groups: ::prost::alloc::vec::Vec<u64>,
1078}
1079#[derive(prost_helpers::AnyPB)]
1080#[derive(Clone, PartialEq, ::prost::Message)]
1081pub struct TriggerCompactionDeterministicRequest {
1082    #[prost(uint64, tag = "1")]
1083    pub version_id: u64,
1084    #[prost(uint64, repeated, tag = "2")]
1085    pub compaction_groups: ::prost::alloc::vec::Vec<u64>,
1086}
1087#[derive(prost_helpers::AnyPB)]
1088#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1089pub struct TriggerCompactionDeterministicResponse {}
1090#[derive(prost_helpers::AnyPB)]
1091#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1092pub struct DisableCommitEpochRequest {}
1093#[derive(prost_helpers::AnyPB)]
1094#[derive(Clone, PartialEq, ::prost::Message)]
1095pub struct DisableCommitEpochResponse {
1096    #[prost(message, optional, tag = "1")]
1097    pub current_version: ::core::option::Option<HummockVersion>,
1098}
1099#[derive(prost_helpers::AnyPB)]
1100#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1101pub struct RiseCtlListCompactionGroupRequest {}
1102#[derive(prost_helpers::AnyPB)]
1103#[derive(Clone, PartialEq, ::prost::Message)]
1104pub struct RiseCtlListCompactionGroupResponse {
1105    #[prost(message, optional, tag = "1")]
1106    pub status: ::core::option::Option<super::common::Status>,
1107    #[prost(message, repeated, tag = "2")]
1108    pub compaction_groups: ::prost::alloc::vec::Vec<CompactionGroupInfo>,
1109}
1110#[derive(prost_helpers::AnyPB)]
1111#[derive(Clone, PartialEq, ::prost::Message)]
1112pub struct RiseCtlUpdateCompactionConfigRequest {
1113    #[prost(uint64, repeated, tag = "1")]
1114    pub compaction_group_ids: ::prost::alloc::vec::Vec<u64>,
1115    #[prost(message, repeated, tag = "2")]
1116    pub configs: ::prost::alloc::vec::Vec<
1117        rise_ctl_update_compaction_config_request::MutableConfig,
1118    >,
1119}
1120/// Nested message and enum types in `RiseCtlUpdateCompactionConfigRequest`.
1121pub mod rise_ctl_update_compaction_config_request {
1122    #[derive(prost_helpers::AnyPB)]
1123    #[derive(Clone, PartialEq, ::prost::Message)]
1124    pub struct CompressionAlgorithm {
1125        #[prost(uint32, tag = "1")]
1126        pub level: u32,
1127        #[prost(string, tag = "2")]
1128        pub compression_algorithm: ::prost::alloc::string::String,
1129    }
1130    #[derive(prost_helpers::AnyPB)]
1131    #[derive(Clone, PartialEq, ::prost::Message)]
1132    pub struct MutableConfig {
1133        #[prost(
1134            oneof = "mutable_config::MutableConfig",
1135            tags = "1, 2, 3, 4, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 25, 26, 27, 28, 29"
1136        )]
1137        pub mutable_config: ::core::option::Option<mutable_config::MutableConfig>,
1138    }
1139    /// Nested message and enum types in `MutableConfig`.
1140    pub mod mutable_config {
1141        #[derive(prost_helpers::AnyPB)]
1142        #[derive(Clone, PartialEq, ::prost::Oneof)]
1143        pub enum MutableConfig {
1144            #[prost(uint64, tag = "1")]
1145            MaxBytesForLevelBase(u64),
1146            #[prost(uint64, tag = "2")]
1147            MaxBytesForLevelMultiplier(u64),
1148            #[prost(uint64, tag = "3")]
1149            MaxCompactionBytes(u64),
1150            #[prost(uint64, tag = "4")]
1151            SubLevelMaxCompactionBytes(u64),
1152            #[prost(uint64, tag = "6")]
1153            Level0TierCompactFileNumber(u64),
1154            #[prost(uint64, tag = "7")]
1155            TargetFileSizeBase(u64),
1156            #[prost(uint32, tag = "8")]
1157            CompactionFilterMask(u32),
1158            #[prost(uint32, tag = "9")]
1159            MaxSubCompaction(u32),
1160            #[prost(uint64, tag = "10")]
1161            Level0StopWriteThresholdSubLevelNumber(u64),
1162            #[prost(uint32, tag = "11")]
1163            Level0SubLevelCompactLevelCount(u32),
1164            #[prost(uint32, tag = "12")]
1165            Level0OverlappingSubLevelCompactLevelCount(u32),
1166            #[prost(uint64, tag = "13")]
1167            MaxSpaceReclaimBytes(u64),
1168            #[prost(uint64, tag = "14")]
1169            Level0MaxCompactFileNumber(u64),
1170            #[prost(bool, tag = "15")]
1171            EnableEmergencyPicker(bool),
1172            #[prost(uint32, tag = "16")]
1173            TombstoneReclaimRatio(u32),
1174            #[prost(message, tag = "17")]
1175            CompressionAlgorithm(super::CompressionAlgorithm),
1176            #[prost(uint32, tag = "18")]
1177            MaxL0CompactLevelCount(u32),
1178            #[prost(uint64, tag = "19")]
1179            SstAllowedTrivialMoveMinSize(u64),
1180            #[prost(uint32, tag = "20")]
1181            SplitWeightByVnode(u32),
1182            #[prost(bool, tag = "21")]
1183            DisableAutoGroupScheduling(bool),
1184            #[prost(uint64, tag = "22")]
1185            MaxOverlappingLevelSize(u64),
1186            /// The emergency compaction limitations for the level0 sstables file count
1187            #[prost(uint32, tag = "25")]
1188            EmergencyLevel0SstFileCount(u32),
1189            /// The emergency compaction limitations for the level0 sub level partition
1190            #[prost(uint32, tag = "26")]
1191            EmergencyLevel0SubLevelPartition(u32),
1192            /// The limitation of the max sst size of the level0 to trigger the write stop
1193            #[prost(uint32, tag = "27")]
1194            Level0StopWriteThresholdMaxSstCount(u32),
1195            /// The limitation of the max sst size of the level0 to trigger the write stop
1196            #[prost(uint64, tag = "28")]
1197            Level0StopWriteThresholdMaxSize(u64),
1198            /// The limitation of the max sst count of the trivial move task
1199            #[prost(uint32, tag = "29")]
1200            SstAllowedTrivialMoveMaxCount(u32),
1201        }
1202    }
1203}
1204#[derive(prost_helpers::AnyPB)]
1205#[derive(Clone, PartialEq, ::prost::Message)]
1206pub struct RiseCtlUpdateCompactionConfigResponse {
1207    #[prost(message, optional, tag = "1")]
1208    pub status: ::core::option::Option<super::common::Status>,
1209}
1210#[derive(prost_helpers::AnyPB)]
1211#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1212pub struct PinVersionRequest {
1213    #[prost(uint32, tag = "1")]
1214    pub context_id: u32,
1215}
1216#[derive(prost_helpers::AnyPB)]
1217#[derive(Clone, PartialEq, ::prost::Message)]
1218pub struct PinVersionResponse {
1219    #[prost(message, optional, tag = "1")]
1220    pub pinned_version: ::core::option::Option<HummockVersion>,
1221}
1222#[derive(prost_helpers::AnyPB)]
1223#[derive(Clone, PartialEq, ::prost::Message)]
1224pub struct SplitCompactionGroupRequest {
1225    #[prost(uint64, tag = "1")]
1226    pub group_id: u64,
1227    #[prost(uint32, repeated, tag = "2")]
1228    pub table_ids: ::prost::alloc::vec::Vec<u32>,
1229    #[prost(uint32, tag = "3")]
1230    pub partition_vnode_count: u32,
1231}
1232#[derive(prost_helpers::AnyPB)]
1233#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1234pub struct SplitCompactionGroupResponse {
1235    #[prost(uint64, tag = "1")]
1236    pub new_group_id: u64,
1237}
1238#[derive(prost_helpers::AnyPB)]
1239#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1240pub struct RiseCtlPauseVersionCheckpointRequest {}
1241#[derive(prost_helpers::AnyPB)]
1242#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1243pub struct RiseCtlPauseVersionCheckpointResponse {}
1244#[derive(prost_helpers::AnyPB)]
1245#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1246pub struct RiseCtlResumeVersionCheckpointRequest {}
1247#[derive(prost_helpers::AnyPB)]
1248#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1249pub struct RiseCtlResumeVersionCheckpointResponse {}
1250#[derive(prost_helpers::AnyPB)]
1251#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1252pub struct RiseCtlGetCheckpointVersionRequest {}
1253#[derive(prost_helpers::AnyPB)]
1254#[derive(Clone, PartialEq, ::prost::Message)]
1255pub struct RiseCtlGetCheckpointVersionResponse {
1256    #[prost(message, optional, tag = "1")]
1257    pub checkpoint_version: ::core::option::Option<HummockVersion>,
1258}
1259#[derive(prost_helpers::AnyPB)]
1260#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1261pub struct RiseCtlListCompactionStatusRequest {}
1262#[derive(prost_helpers::AnyPB)]
1263#[derive(Clone, PartialEq, ::prost::Message)]
1264pub struct RiseCtlListCompactionStatusResponse {
1265    #[prost(message, repeated, tag = "1")]
1266    pub compaction_statuses: ::prost::alloc::vec::Vec<CompactStatus>,
1267    #[prost(message, repeated, tag = "2")]
1268    pub task_assignment: ::prost::alloc::vec::Vec<CompactTaskAssignment>,
1269    #[prost(message, repeated, tag = "3")]
1270    pub task_progress: ::prost::alloc::vec::Vec<CompactTaskProgress>,
1271}
1272#[derive(prost_helpers::AnyPB)]
1273#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1274pub struct ListBranchedObjectRequest {}
1275#[derive(prost_helpers::AnyPB)]
1276#[derive(Clone, PartialEq, ::prost::Message)]
1277pub struct ListBranchedObjectResponse {
1278    #[prost(message, repeated, tag = "1")]
1279    pub branched_objects: ::prost::alloc::vec::Vec<BranchedObject>,
1280}
1281#[derive(prost_helpers::AnyPB)]
1282#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1283pub struct ListActiveWriteLimitRequest {}
1284#[derive(prost_helpers::AnyPB)]
1285#[derive(Clone, PartialEq, ::prost::Message)]
1286pub struct ListActiveWriteLimitResponse {
1287    /// < compaction group id, write limit info >
1288    #[prost(map = "uint64, message", tag = "1")]
1289    pub write_limits: ::std::collections::HashMap<u64, write_limits::WriteLimit>,
1290}
1291#[derive(prost_helpers::AnyPB)]
1292#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1293pub struct ListHummockMetaConfigRequest {}
1294#[derive(prost_helpers::AnyPB)]
1295#[derive(Clone, PartialEq, ::prost::Message)]
1296pub struct ListHummockMetaConfigResponse {
1297    #[prost(map = "string, string", tag = "1")]
1298    pub configs: ::std::collections::HashMap<
1299        ::prost::alloc::string::String,
1300        ::prost::alloc::string::String,
1301    >,
1302}
1303#[derive(prost_helpers::AnyPB)]
1304#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1305pub struct RiseCtlRebuildTableStatsRequest {}
1306#[derive(prost_helpers::AnyPB)]
1307#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1308pub struct RiseCtlRebuildTableStatsResponse {}
1309#[derive(prost_helpers::AnyPB)]
1310#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1311pub struct GetCompactionScoreRequest {
1312    #[prost(uint64, tag = "1")]
1313    pub compaction_group_id: u64,
1314}
1315#[derive(prost_helpers::AnyPB)]
1316#[derive(Clone, PartialEq, ::prost::Message)]
1317pub struct GetCompactionScoreResponse {
1318    #[prost(uint64, tag = "1")]
1319    pub compaction_group_id: u64,
1320    #[prost(message, repeated, tag = "2")]
1321    pub scores: ::prost::alloc::vec::Vec<get_compaction_score_response::PickerInfo>,
1322}
1323/// Nested message and enum types in `GetCompactionScoreResponse`.
1324pub mod get_compaction_score_response {
1325    #[derive(prost_helpers::AnyPB)]
1326    #[derive(Clone, PartialEq, ::prost::Message)]
1327    pub struct PickerInfo {
1328        #[prost(uint64, tag = "1")]
1329        pub score: u64,
1330        #[prost(uint64, tag = "2")]
1331        pub select_level: u64,
1332        #[prost(uint64, tag = "3")]
1333        pub target_level: u64,
1334        #[prost(string, tag = "4")]
1335        pub picker_type: ::prost::alloc::string::String,
1336    }
1337}
1338#[derive(prost_helpers::AnyPB)]
1339#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1340pub struct ListCompactTaskAssignmentRequest {}
1341#[derive(prost_helpers::AnyPB)]
1342#[derive(Clone, PartialEq, ::prost::Message)]
1343pub struct ListCompactTaskAssignmentResponse {
1344    #[prost(message, repeated, tag = "1")]
1345    pub task_assignment: ::prost::alloc::vec::Vec<CompactTaskAssignment>,
1346}
1347#[derive(prost_helpers::AnyPB)]
1348#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1349pub struct ListCompactTaskProgressRequest {}
1350#[derive(prost_helpers::AnyPB)]
1351#[derive(Clone, PartialEq, ::prost::Message)]
1352pub struct ListCompactTaskProgressResponse {
1353    #[prost(message, repeated, tag = "1")]
1354    pub task_progress: ::prost::alloc::vec::Vec<CompactTaskProgress>,
1355}
1356#[derive(prost_helpers::AnyPB)]
1357#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1358pub struct CancelCompactTaskRequest {
1359    #[prost(uint64, tag = "1")]
1360    pub task_id: u64,
1361    #[prost(enumeration = "compact_task::TaskStatus", tag = "2")]
1362    pub task_status: i32,
1363}
1364#[derive(prost_helpers::AnyPB)]
1365#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1366pub struct CancelCompactTaskResponse {
1367    #[prost(bool, tag = "1")]
1368    pub ret: bool,
1369}
1370#[derive(prost_helpers::AnyPB)]
1371#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1372pub struct GetVersionByEpochRequest {
1373    #[prost(uint64, tag = "1")]
1374    pub epoch: u64,
1375    #[prost(uint32, tag = "2")]
1376    pub table_id: u32,
1377}
1378#[derive(prost_helpers::AnyPB)]
1379#[derive(Clone, PartialEq, ::prost::Message)]
1380pub struct GetVersionByEpochResponse {
1381    #[prost(message, optional, tag = "1")]
1382    pub version: ::core::option::Option<HummockVersion>,
1383}
1384#[derive(prost_helpers::AnyPB)]
1385#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1386pub struct MergeCompactionGroupRequest {
1387    #[prost(uint64, tag = "1")]
1388    pub left_group_id: u64,
1389    #[prost(uint64, tag = "2")]
1390    pub right_group_id: u64,
1391}
1392#[derive(prost_helpers::AnyPB)]
1393#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1394pub struct MergeCompactionGroupResponse {}
1395#[derive(prost_helpers::AnyPB)]
1396#[derive(Eq)]
1397#[derive(Clone, PartialEq, ::prost::Message)]
1398pub struct CompactionConfig {
1399    #[prost(uint64, tag = "1")]
1400    pub max_bytes_for_level_base: u64,
1401    #[prost(uint64, tag = "2")]
1402    pub max_level: u64,
1403    #[prost(uint64, tag = "3")]
1404    pub max_bytes_for_level_multiplier: u64,
1405    #[prost(uint64, tag = "4")]
1406    pub max_compaction_bytes: u64,
1407    #[prost(uint64, tag = "5")]
1408    pub sub_level_max_compaction_bytes: u64,
1409    #[prost(uint64, tag = "7")]
1410    pub level0_tier_compact_file_number: u64,
1411    #[prost(enumeration = "compaction_config::CompactionMode", tag = "8")]
1412    pub compaction_mode: i32,
1413    #[prost(string, repeated, tag = "9")]
1414    pub compression_algorithm: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
1415    #[prost(uint64, tag = "10")]
1416    pub target_file_size_base: u64,
1417    #[prost(uint32, tag = "11")]
1418    pub compaction_filter_mask: u32,
1419    #[prost(uint32, tag = "12")]
1420    pub max_sub_compaction: u32,
1421    #[prost(uint64, tag = "13")]
1422    pub max_space_reclaim_bytes: u64,
1423    #[prost(bool, tag = "14")]
1424    pub split_by_state_table: bool,
1425    /// Compaction needs to cut the state table every time 1/weight of vnodes in the table have been processed.
1426    #[prost(uint32, tag = "6")]
1427    pub split_weight_by_vnode: u32,
1428    /// soft limit for max number of sub level number
1429    #[prost(uint64, tag = "15")]
1430    pub level0_stop_write_threshold_sub_level_number: u64,
1431    #[prost(uint64, tag = "16")]
1432    pub level0_max_compact_file_number: u64,
1433    #[prost(uint32, tag = "17")]
1434    pub level0_sub_level_compact_level_count: u32,
1435    /// for tier compaction pick overlapping level
1436    #[prost(uint32, tag = "18")]
1437    pub level0_overlapping_sub_level_compact_level_count: u32,
1438    #[prost(uint32, tag = "19")]
1439    pub tombstone_reclaim_ratio: u32,
1440    #[prost(bool, tag = "20")]
1441    pub enable_emergency_picker: bool,
1442    /// The limitation of the level count of l0 compaction
1443    #[prost(uint32, optional, tag = "21")]
1444    pub max_l0_compact_level_count: ::core::option::Option<u32>,
1445    /// The limitation of base level trivial move sst size
1446    #[prost(uint64, optional, tag = "22")]
1447    pub sst_allowed_trivial_move_min_size: ::core::option::Option<u64>,
1448    /// The limitation of auto group scheduling
1449    #[prost(bool, optional, tag = "23")]
1450    pub disable_auto_group_scheduling: ::core::option::Option<bool>,
1451    /// The limitation of the max size of the overlapping-level for the compaction
1452    /// hummock will reorg the commit-sstables to the multi overlapping-level if the size of the commit-sstables is larger than `max_overlapping_level_size`
1453    #[prost(uint64, optional, tag = "24")]
1454    pub max_overlapping_level_size: ::core::option::Option<u64>,
1455    /// The emergency compaction limitations for the level0 sstables file count
1456    #[prost(uint32, optional, tag = "25")]
1457    pub emergency_level0_sst_file_count: ::core::option::Option<u32>,
1458    /// The emergency compaction limitations for the level0 sub level partition
1459    #[prost(uint32, optional, tag = "26")]
1460    pub emergency_level0_sub_level_partition: ::core::option::Option<u32>,
1461    /// The limitation of the max sst count of the level0 to trigger the write stop
1462    #[prost(uint32, optional, tag = "27")]
1463    pub level0_stop_write_threshold_max_sst_count: ::core::option::Option<u32>,
1464    /// The limitation of the max sst size of the level0 to trigger the write stop
1465    #[prost(uint64, optional, tag = "28")]
1466    pub level0_stop_write_threshold_max_size: ::core::option::Option<u64>,
1467    /// The limitation of the max sst count of the trivial move task
1468    #[prost(uint32, optional, tag = "29")]
1469    pub sst_allowed_trivial_move_max_count: ::core::option::Option<u32>,
1470}
1471/// Nested message and enum types in `CompactionConfig`.
1472pub mod compaction_config {
1473    #[derive(prost_helpers::AnyPB)]
1474    #[derive(
1475        Clone,
1476        Copy,
1477        Debug,
1478        PartialEq,
1479        Eq,
1480        Hash,
1481        PartialOrd,
1482        Ord,
1483        ::prost::Enumeration
1484    )]
1485    #[repr(i32)]
1486    pub enum CompactionMode {
1487        Unspecified = 0,
1488        Range = 1,
1489    }
1490    impl CompactionMode {
1491        /// String value of the enum field names used in the ProtoBuf definition.
1492        ///
1493        /// The values are not transformed in any way and thus are considered stable
1494        /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1495        pub fn as_str_name(&self) -> &'static str {
1496            match self {
1497                Self::Unspecified => "UNSPECIFIED",
1498                Self::Range => "RANGE",
1499            }
1500        }
1501        /// Creates an enum from field names used in the ProtoBuf definition.
1502        pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1503            match value {
1504                "UNSPECIFIED" => Some(Self::Unspecified),
1505                "RANGE" => Some(Self::Range),
1506                _ => None,
1507            }
1508        }
1509    }
1510}
1511#[derive(prost_helpers::AnyPB)]
1512#[derive(Eq)]
1513#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1514pub struct TableStats {
1515    #[prost(int64, tag = "1")]
1516    pub total_key_size: i64,
1517    #[prost(int64, tag = "2")]
1518    pub total_value_size: i64,
1519    #[prost(int64, tag = "3")]
1520    pub total_key_count: i64,
1521    /// `total_compressed_size`` represents the size that the table takes up in the output sst
1522    ///   and this field is only filled and used by CN flushes, not compactor compaction
1523    #[prost(uint64, tag = "4")]
1524    pub total_compressed_size: u64,
1525}
1526#[derive(prost_helpers::AnyPB)]
1527#[derive(Clone, PartialEq, ::prost::Message)]
1528pub struct HummockVersionStats {
1529    #[prost(uint64, tag = "1")]
1530    pub hummock_version_id: u64,
1531    #[prost(map = "uint32, message", tag = "2")]
1532    pub table_stats: ::std::collections::HashMap<u32, TableStats>,
1533}
1534#[derive(prost_helpers::AnyPB)]
1535#[derive(Clone, PartialEq, ::prost::Message)]
1536pub struct WriteLimits {
1537    /// < compaction group id, write limit info >
1538    #[prost(map = "uint64, message", tag = "1")]
1539    pub write_limits: ::std::collections::HashMap<u64, write_limits::WriteLimit>,
1540}
1541/// Nested message and enum types in `WriteLimits`.
1542pub mod write_limits {
1543    #[derive(prost_helpers::AnyPB)]
1544    #[derive(Clone, PartialEq, ::prost::Message)]
1545    pub struct WriteLimit {
1546        #[prost(uint32, repeated, tag = "1")]
1547        pub table_ids: ::prost::alloc::vec::Vec<u32>,
1548        #[prost(string, tag = "2")]
1549        pub reason: ::prost::alloc::string::String,
1550    }
1551}
1552#[derive(prost_helpers::AnyPB)]
1553#[derive(Clone, PartialEq, ::prost::Message)]
1554pub struct BranchedObject {
1555    #[prost(uint64, tag = "1")]
1556    pub object_id: u64,
1557    #[prost(uint64, repeated, tag = "2")]
1558    pub sst_id: ::prost::alloc::vec::Vec<u64>,
1559    /// Compaction group id the SST belongs to.
1560    #[prost(uint64, tag = "3")]
1561    pub compaction_group_id: u64,
1562}
1563#[derive(prost_helpers::AnyPB)]
1564#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1565#[repr(i32)]
1566pub enum BloomFilterType {
1567    BloomFilterUnspecified = 0,
1568    Sstable = 1,
1569    Blocked = 2,
1570}
1571impl BloomFilterType {
1572    /// String value of the enum field names used in the ProtoBuf definition.
1573    ///
1574    /// The values are not transformed in any way and thus are considered stable
1575    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1576    pub fn as_str_name(&self) -> &'static str {
1577        match self {
1578            Self::BloomFilterUnspecified => "BLOOM_FILTER_UNSPECIFIED",
1579            Self::Sstable => "SSTABLE",
1580            Self::Blocked => "BLOCKED",
1581        }
1582    }
1583    /// Creates an enum from field names used in the ProtoBuf definition.
1584    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1585        match value {
1586            "BLOOM_FILTER_UNSPECIFIED" => Some(Self::BloomFilterUnspecified),
1587            "SSTABLE" => Some(Self::Sstable),
1588            "BLOCKED" => Some(Self::Blocked),
1589            _ => None,
1590        }
1591    }
1592}
1593#[derive(prost_helpers::AnyPB)]
1594#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1595#[repr(i32)]
1596pub enum LevelType {
1597    Unspecified = 0,
1598    Nonoverlapping = 1,
1599    Overlapping = 2,
1600}
1601impl LevelType {
1602    /// String value of the enum field names used in the ProtoBuf definition.
1603    ///
1604    /// The values are not transformed in any way and thus are considered stable
1605    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1606    pub fn as_str_name(&self) -> &'static str {
1607        match self {
1608            Self::Unspecified => "LEVEL_TYPE_UNSPECIFIED",
1609            Self::Nonoverlapping => "LEVEL_TYPE_NONOVERLAPPING",
1610            Self::Overlapping => "LEVEL_TYPE_OVERLAPPING",
1611        }
1612    }
1613    /// Creates an enum from field names used in the ProtoBuf definition.
1614    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1615        match value {
1616            "LEVEL_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
1617            "LEVEL_TYPE_NONOVERLAPPING" => Some(Self::Nonoverlapping),
1618            "LEVEL_TYPE_OVERLAPPING" => Some(Self::Overlapping),
1619            _ => None,
1620        }
1621    }
1622}
1623#[derive(prost_helpers::AnyPB)]
1624#[derive(prost_helpers::Version)]
1625#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1626#[repr(i32)]
1627pub enum CompatibilityVersion {
1628    VersionUnspecified = 0,
1629    NoTrivialSplit = 1,
1630    NoMemberTableIds = 2,
1631    SplitGroupByTableId = 3,
1632}
1633impl CompatibilityVersion {
1634    /// String value of the enum field names used in the ProtoBuf definition.
1635    ///
1636    /// The values are not transformed in any way and thus are considered stable
1637    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1638    pub fn as_str_name(&self) -> &'static str {
1639        match self {
1640            Self::VersionUnspecified => "VERSION_UNSPECIFIED",
1641            Self::NoTrivialSplit => "NO_TRIVIAL_SPLIT",
1642            Self::NoMemberTableIds => "NO_MEMBER_TABLE_IDS",
1643            Self::SplitGroupByTableId => "SPLIT_GROUP_BY_TABLE_ID",
1644        }
1645    }
1646    /// Creates an enum from field names used in the ProtoBuf definition.
1647    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1648        match value {
1649            "VERSION_UNSPECIFIED" => Some(Self::VersionUnspecified),
1650            "NO_TRIVIAL_SPLIT" => Some(Self::NoTrivialSplit),
1651            "NO_MEMBER_TABLE_IDS" => Some(Self::NoMemberTableIds),
1652            "SPLIT_GROUP_BY_TABLE_ID" => Some(Self::SplitGroupByTableId),
1653            _ => None,
1654        }
1655    }
1656}
1657/// Generated client implementations.
1658pub mod hummock_manager_service_client {
1659    #![allow(
1660        unused_variables,
1661        dead_code,
1662        missing_docs,
1663        clippy::wildcard_imports,
1664        clippy::let_unit_value,
1665    )]
1666    use tonic::codegen::*;
1667    use tonic::codegen::http::Uri;
1668    #[derive(Debug, Clone)]
1669    pub struct HummockManagerServiceClient<T> {
1670        inner: tonic::client::Grpc<T>,
1671    }
1672    impl HummockManagerServiceClient<tonic::transport::Channel> {
1673        /// Attempt to create a new client by connecting to a given endpoint.
1674        pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
1675        where
1676            D: TryInto<tonic::transport::Endpoint>,
1677            D::Error: Into<StdError>,
1678        {
1679            let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
1680            Ok(Self::new(conn))
1681        }
1682    }
1683    impl<T> HummockManagerServiceClient<T>
1684    where
1685        T: tonic::client::GrpcService<tonic::body::BoxBody>,
1686        T::Error: Into<StdError>,
1687        T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
1688        <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
1689    {
1690        pub fn new(inner: T) -> Self {
1691            let inner = tonic::client::Grpc::new(inner);
1692            Self { inner }
1693        }
1694        pub fn with_origin(inner: T, origin: Uri) -> Self {
1695            let inner = tonic::client::Grpc::with_origin(inner, origin);
1696            Self { inner }
1697        }
1698        pub fn with_interceptor<F>(
1699            inner: T,
1700            interceptor: F,
1701        ) -> HummockManagerServiceClient<InterceptedService<T, F>>
1702        where
1703            F: tonic::service::Interceptor,
1704            T::ResponseBody: Default,
1705            T: tonic::codegen::Service<
1706                http::Request<tonic::body::BoxBody>,
1707                Response = http::Response<
1708                    <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
1709                >,
1710            >,
1711            <T as tonic::codegen::Service<
1712                http::Request<tonic::body::BoxBody>,
1713            >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
1714        {
1715            HummockManagerServiceClient::new(InterceptedService::new(inner, interceptor))
1716        }
1717        /// Compress requests with the given encoding.
1718        ///
1719        /// This requires the server to support it otherwise it might respond with an
1720        /// error.
1721        #[must_use]
1722        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
1723            self.inner = self.inner.send_compressed(encoding);
1724            self
1725        }
1726        /// Enable decompressing responses.
1727        #[must_use]
1728        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
1729            self.inner = self.inner.accept_compressed(encoding);
1730            self
1731        }
1732        /// Limits the maximum size of a decoded message.
1733        ///
1734        /// Default: `4MB`
1735        #[must_use]
1736        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
1737            self.inner = self.inner.max_decoding_message_size(limit);
1738            self
1739        }
1740        /// Limits the maximum size of an encoded message.
1741        ///
1742        /// Default: `usize::MAX`
1743        #[must_use]
1744        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
1745            self.inner = self.inner.max_encoding_message_size(limit);
1746            self
1747        }
1748        pub async fn unpin_version_before(
1749            &mut self,
1750            request: impl tonic::IntoRequest<super::UnpinVersionBeforeRequest>,
1751        ) -> std::result::Result<
1752            tonic::Response<super::UnpinVersionBeforeResponse>,
1753            tonic::Status,
1754        > {
1755            self.inner
1756                .ready()
1757                .await
1758                .map_err(|e| {
1759                    tonic::Status::unknown(
1760                        format!("Service was not ready: {}", e.into()),
1761                    )
1762                })?;
1763            let codec = tonic::codec::ProstCodec::default();
1764            let path = http::uri::PathAndQuery::from_static(
1765                "/hummock.HummockManagerService/UnpinVersionBefore",
1766            );
1767            let mut req = request.into_request();
1768            req.extensions_mut()
1769                .insert(
1770                    GrpcMethod::new(
1771                        "hummock.HummockManagerService",
1772                        "UnpinVersionBefore",
1773                    ),
1774                );
1775            self.inner.unary(req, path, codec).await
1776        }
1777        pub async fn get_current_version(
1778            &mut self,
1779            request: impl tonic::IntoRequest<super::GetCurrentVersionRequest>,
1780        ) -> std::result::Result<
1781            tonic::Response<super::GetCurrentVersionResponse>,
1782            tonic::Status,
1783        > {
1784            self.inner
1785                .ready()
1786                .await
1787                .map_err(|e| {
1788                    tonic::Status::unknown(
1789                        format!("Service was not ready: {}", e.into()),
1790                    )
1791                })?;
1792            let codec = tonic::codec::ProstCodec::default();
1793            let path = http::uri::PathAndQuery::from_static(
1794                "/hummock.HummockManagerService/GetCurrentVersion",
1795            );
1796            let mut req = request.into_request();
1797            req.extensions_mut()
1798                .insert(
1799                    GrpcMethod::new("hummock.HummockManagerService", "GetCurrentVersion"),
1800                );
1801            self.inner.unary(req, path, codec).await
1802        }
1803        pub async fn list_version_deltas(
1804            &mut self,
1805            request: impl tonic::IntoRequest<super::ListVersionDeltasRequest>,
1806        ) -> std::result::Result<
1807            tonic::Response<super::ListVersionDeltasResponse>,
1808            tonic::Status,
1809        > {
1810            self.inner
1811                .ready()
1812                .await
1813                .map_err(|e| {
1814                    tonic::Status::unknown(
1815                        format!("Service was not ready: {}", e.into()),
1816                    )
1817                })?;
1818            let codec = tonic::codec::ProstCodec::default();
1819            let path = http::uri::PathAndQuery::from_static(
1820                "/hummock.HummockManagerService/ListVersionDeltas",
1821            );
1822            let mut req = request.into_request();
1823            req.extensions_mut()
1824                .insert(
1825                    GrpcMethod::new("hummock.HummockManagerService", "ListVersionDeltas"),
1826                );
1827            self.inner.unary(req, path, codec).await
1828        }
1829        pub async fn replay_version_delta(
1830            &mut self,
1831            request: impl tonic::IntoRequest<super::ReplayVersionDeltaRequest>,
1832        ) -> std::result::Result<
1833            tonic::Response<super::ReplayVersionDeltaResponse>,
1834            tonic::Status,
1835        > {
1836            self.inner
1837                .ready()
1838                .await
1839                .map_err(|e| {
1840                    tonic::Status::unknown(
1841                        format!("Service was not ready: {}", e.into()),
1842                    )
1843                })?;
1844            let codec = tonic::codec::ProstCodec::default();
1845            let path = http::uri::PathAndQuery::from_static(
1846                "/hummock.HummockManagerService/ReplayVersionDelta",
1847            );
1848            let mut req = request.into_request();
1849            req.extensions_mut()
1850                .insert(
1851                    GrpcMethod::new(
1852                        "hummock.HummockManagerService",
1853                        "ReplayVersionDelta",
1854                    ),
1855                );
1856            self.inner.unary(req, path, codec).await
1857        }
1858        pub async fn get_assigned_compact_task_num(
1859            &mut self,
1860            request: impl tonic::IntoRequest<super::GetAssignedCompactTaskNumRequest>,
1861        ) -> std::result::Result<
1862            tonic::Response<super::GetAssignedCompactTaskNumResponse>,
1863            tonic::Status,
1864        > {
1865            self.inner
1866                .ready()
1867                .await
1868                .map_err(|e| {
1869                    tonic::Status::unknown(
1870                        format!("Service was not ready: {}", e.into()),
1871                    )
1872                })?;
1873            let codec = tonic::codec::ProstCodec::default();
1874            let path = http::uri::PathAndQuery::from_static(
1875                "/hummock.HummockManagerService/GetAssignedCompactTaskNum",
1876            );
1877            let mut req = request.into_request();
1878            req.extensions_mut()
1879                .insert(
1880                    GrpcMethod::new(
1881                        "hummock.HummockManagerService",
1882                        "GetAssignedCompactTaskNum",
1883                    ),
1884                );
1885            self.inner.unary(req, path, codec).await
1886        }
1887        pub async fn trigger_compaction_deterministic(
1888            &mut self,
1889            request: impl tonic::IntoRequest<
1890                super::TriggerCompactionDeterministicRequest,
1891            >,
1892        ) -> std::result::Result<
1893            tonic::Response<super::TriggerCompactionDeterministicResponse>,
1894            tonic::Status,
1895        > {
1896            self.inner
1897                .ready()
1898                .await
1899                .map_err(|e| {
1900                    tonic::Status::unknown(
1901                        format!("Service was not ready: {}", e.into()),
1902                    )
1903                })?;
1904            let codec = tonic::codec::ProstCodec::default();
1905            let path = http::uri::PathAndQuery::from_static(
1906                "/hummock.HummockManagerService/TriggerCompactionDeterministic",
1907            );
1908            let mut req = request.into_request();
1909            req.extensions_mut()
1910                .insert(
1911                    GrpcMethod::new(
1912                        "hummock.HummockManagerService",
1913                        "TriggerCompactionDeterministic",
1914                    ),
1915                );
1916            self.inner.unary(req, path, codec).await
1917        }
1918        pub async fn disable_commit_epoch(
1919            &mut self,
1920            request: impl tonic::IntoRequest<super::DisableCommitEpochRequest>,
1921        ) -> std::result::Result<
1922            tonic::Response<super::DisableCommitEpochResponse>,
1923            tonic::Status,
1924        > {
1925            self.inner
1926                .ready()
1927                .await
1928                .map_err(|e| {
1929                    tonic::Status::unknown(
1930                        format!("Service was not ready: {}", e.into()),
1931                    )
1932                })?;
1933            let codec = tonic::codec::ProstCodec::default();
1934            let path = http::uri::PathAndQuery::from_static(
1935                "/hummock.HummockManagerService/DisableCommitEpoch",
1936            );
1937            let mut req = request.into_request();
1938            req.extensions_mut()
1939                .insert(
1940                    GrpcMethod::new(
1941                        "hummock.HummockManagerService",
1942                        "DisableCommitEpoch",
1943                    ),
1944                );
1945            self.inner.unary(req, path, codec).await
1946        }
1947        pub async fn get_new_sst_ids(
1948            &mut self,
1949            request: impl tonic::IntoRequest<super::GetNewSstIdsRequest>,
1950        ) -> std::result::Result<
1951            tonic::Response<super::GetNewSstIdsResponse>,
1952            tonic::Status,
1953        > {
1954            self.inner
1955                .ready()
1956                .await
1957                .map_err(|e| {
1958                    tonic::Status::unknown(
1959                        format!("Service was not ready: {}", e.into()),
1960                    )
1961                })?;
1962            let codec = tonic::codec::ProstCodec::default();
1963            let path = http::uri::PathAndQuery::from_static(
1964                "/hummock.HummockManagerService/GetNewSstIds",
1965            );
1966            let mut req = request.into_request();
1967            req.extensions_mut()
1968                .insert(
1969                    GrpcMethod::new("hummock.HummockManagerService", "GetNewSstIds"),
1970                );
1971            self.inner.unary(req, path, codec).await
1972        }
1973        pub async fn trigger_manual_compaction(
1974            &mut self,
1975            request: impl tonic::IntoRequest<super::TriggerManualCompactionRequest>,
1976        ) -> std::result::Result<
1977            tonic::Response<super::TriggerManualCompactionResponse>,
1978            tonic::Status,
1979        > {
1980            self.inner
1981                .ready()
1982                .await
1983                .map_err(|e| {
1984                    tonic::Status::unknown(
1985                        format!("Service was not ready: {}", e.into()),
1986                    )
1987                })?;
1988            let codec = tonic::codec::ProstCodec::default();
1989            let path = http::uri::PathAndQuery::from_static(
1990                "/hummock.HummockManagerService/TriggerManualCompaction",
1991            );
1992            let mut req = request.into_request();
1993            req.extensions_mut()
1994                .insert(
1995                    GrpcMethod::new(
1996                        "hummock.HummockManagerService",
1997                        "TriggerManualCompaction",
1998                    ),
1999                );
2000            self.inner.unary(req, path, codec).await
2001        }
2002        pub async fn trigger_full_gc(
2003            &mut self,
2004            request: impl tonic::IntoRequest<super::TriggerFullGcRequest>,
2005        ) -> std::result::Result<
2006            tonic::Response<super::TriggerFullGcResponse>,
2007            tonic::Status,
2008        > {
2009            self.inner
2010                .ready()
2011                .await
2012                .map_err(|e| {
2013                    tonic::Status::unknown(
2014                        format!("Service was not ready: {}", e.into()),
2015                    )
2016                })?;
2017            let codec = tonic::codec::ProstCodec::default();
2018            let path = http::uri::PathAndQuery::from_static(
2019                "/hummock.HummockManagerService/TriggerFullGC",
2020            );
2021            let mut req = request.into_request();
2022            req.extensions_mut()
2023                .insert(
2024                    GrpcMethod::new("hummock.HummockManagerService", "TriggerFullGC"),
2025                );
2026            self.inner.unary(req, path, codec).await
2027        }
2028        pub async fn rise_ctl_get_pinned_versions_summary(
2029            &mut self,
2030            request: impl tonic::IntoRequest<
2031                super::RiseCtlGetPinnedVersionsSummaryRequest,
2032            >,
2033        ) -> std::result::Result<
2034            tonic::Response<super::RiseCtlGetPinnedVersionsSummaryResponse>,
2035            tonic::Status,
2036        > {
2037            self.inner
2038                .ready()
2039                .await
2040                .map_err(|e| {
2041                    tonic::Status::unknown(
2042                        format!("Service was not ready: {}", e.into()),
2043                    )
2044                })?;
2045            let codec = tonic::codec::ProstCodec::default();
2046            let path = http::uri::PathAndQuery::from_static(
2047                "/hummock.HummockManagerService/RiseCtlGetPinnedVersionsSummary",
2048            );
2049            let mut req = request.into_request();
2050            req.extensions_mut()
2051                .insert(
2052                    GrpcMethod::new(
2053                        "hummock.HummockManagerService",
2054                        "RiseCtlGetPinnedVersionsSummary",
2055                    ),
2056                );
2057            self.inner.unary(req, path, codec).await
2058        }
2059        pub async fn rise_ctl_list_compaction_group(
2060            &mut self,
2061            request: impl tonic::IntoRequest<super::RiseCtlListCompactionGroupRequest>,
2062        ) -> std::result::Result<
2063            tonic::Response<super::RiseCtlListCompactionGroupResponse>,
2064            tonic::Status,
2065        > {
2066            self.inner
2067                .ready()
2068                .await
2069                .map_err(|e| {
2070                    tonic::Status::unknown(
2071                        format!("Service was not ready: {}", e.into()),
2072                    )
2073                })?;
2074            let codec = tonic::codec::ProstCodec::default();
2075            let path = http::uri::PathAndQuery::from_static(
2076                "/hummock.HummockManagerService/RiseCtlListCompactionGroup",
2077            );
2078            let mut req = request.into_request();
2079            req.extensions_mut()
2080                .insert(
2081                    GrpcMethod::new(
2082                        "hummock.HummockManagerService",
2083                        "RiseCtlListCompactionGroup",
2084                    ),
2085                );
2086            self.inner.unary(req, path, codec).await
2087        }
2088        pub async fn rise_ctl_update_compaction_config(
2089            &mut self,
2090            request: impl tonic::IntoRequest<super::RiseCtlUpdateCompactionConfigRequest>,
2091        ) -> std::result::Result<
2092            tonic::Response<super::RiseCtlUpdateCompactionConfigResponse>,
2093            tonic::Status,
2094        > {
2095            self.inner
2096                .ready()
2097                .await
2098                .map_err(|e| {
2099                    tonic::Status::unknown(
2100                        format!("Service was not ready: {}", e.into()),
2101                    )
2102                })?;
2103            let codec = tonic::codec::ProstCodec::default();
2104            let path = http::uri::PathAndQuery::from_static(
2105                "/hummock.HummockManagerService/RiseCtlUpdateCompactionConfig",
2106            );
2107            let mut req = request.into_request();
2108            req.extensions_mut()
2109                .insert(
2110                    GrpcMethod::new(
2111                        "hummock.HummockManagerService",
2112                        "RiseCtlUpdateCompactionConfig",
2113                    ),
2114                );
2115            self.inner.unary(req, path, codec).await
2116        }
2117        pub async fn rise_ctl_pause_version_checkpoint(
2118            &mut self,
2119            request: impl tonic::IntoRequest<super::RiseCtlPauseVersionCheckpointRequest>,
2120        ) -> std::result::Result<
2121            tonic::Response<super::RiseCtlPauseVersionCheckpointResponse>,
2122            tonic::Status,
2123        > {
2124            self.inner
2125                .ready()
2126                .await
2127                .map_err(|e| {
2128                    tonic::Status::unknown(
2129                        format!("Service was not ready: {}", e.into()),
2130                    )
2131                })?;
2132            let codec = tonic::codec::ProstCodec::default();
2133            let path = http::uri::PathAndQuery::from_static(
2134                "/hummock.HummockManagerService/RiseCtlPauseVersionCheckpoint",
2135            );
2136            let mut req = request.into_request();
2137            req.extensions_mut()
2138                .insert(
2139                    GrpcMethod::new(
2140                        "hummock.HummockManagerService",
2141                        "RiseCtlPauseVersionCheckpoint",
2142                    ),
2143                );
2144            self.inner.unary(req, path, codec).await
2145        }
2146        pub async fn rise_ctl_resume_version_checkpoint(
2147            &mut self,
2148            request: impl tonic::IntoRequest<
2149                super::RiseCtlResumeVersionCheckpointRequest,
2150            >,
2151        ) -> std::result::Result<
2152            tonic::Response<super::RiseCtlResumeVersionCheckpointResponse>,
2153            tonic::Status,
2154        > {
2155            self.inner
2156                .ready()
2157                .await
2158                .map_err(|e| {
2159                    tonic::Status::unknown(
2160                        format!("Service was not ready: {}", e.into()),
2161                    )
2162                })?;
2163            let codec = tonic::codec::ProstCodec::default();
2164            let path = http::uri::PathAndQuery::from_static(
2165                "/hummock.HummockManagerService/RiseCtlResumeVersionCheckpoint",
2166            );
2167            let mut req = request.into_request();
2168            req.extensions_mut()
2169                .insert(
2170                    GrpcMethod::new(
2171                        "hummock.HummockManagerService",
2172                        "RiseCtlResumeVersionCheckpoint",
2173                    ),
2174                );
2175            self.inner.unary(req, path, codec).await
2176        }
2177        pub async fn rise_ctl_get_checkpoint_version(
2178            &mut self,
2179            request: impl tonic::IntoRequest<super::RiseCtlGetCheckpointVersionRequest>,
2180        ) -> std::result::Result<
2181            tonic::Response<super::RiseCtlGetCheckpointVersionResponse>,
2182            tonic::Status,
2183        > {
2184            self.inner
2185                .ready()
2186                .await
2187                .map_err(|e| {
2188                    tonic::Status::unknown(
2189                        format!("Service was not ready: {}", e.into()),
2190                    )
2191                })?;
2192            let codec = tonic::codec::ProstCodec::default();
2193            let path = http::uri::PathAndQuery::from_static(
2194                "/hummock.HummockManagerService/RiseCtlGetCheckpointVersion",
2195            );
2196            let mut req = request.into_request();
2197            req.extensions_mut()
2198                .insert(
2199                    GrpcMethod::new(
2200                        "hummock.HummockManagerService",
2201                        "RiseCtlGetCheckpointVersion",
2202                    ),
2203                );
2204            self.inner.unary(req, path, codec).await
2205        }
2206        pub async fn rise_ctl_rebuild_table_stats(
2207            &mut self,
2208            request: impl tonic::IntoRequest<super::RiseCtlRebuildTableStatsRequest>,
2209        ) -> std::result::Result<
2210            tonic::Response<super::RiseCtlRebuildTableStatsResponse>,
2211            tonic::Status,
2212        > {
2213            self.inner
2214                .ready()
2215                .await
2216                .map_err(|e| {
2217                    tonic::Status::unknown(
2218                        format!("Service was not ready: {}", e.into()),
2219                    )
2220                })?;
2221            let codec = tonic::codec::ProstCodec::default();
2222            let path = http::uri::PathAndQuery::from_static(
2223                "/hummock.HummockManagerService/RiseCtlRebuildTableStats",
2224            );
2225            let mut req = request.into_request();
2226            req.extensions_mut()
2227                .insert(
2228                    GrpcMethod::new(
2229                        "hummock.HummockManagerService",
2230                        "RiseCtlRebuildTableStats",
2231                    ),
2232                );
2233            self.inner.unary(req, path, codec).await
2234        }
2235        pub async fn init_metadata_for_replay(
2236            &mut self,
2237            request: impl tonic::IntoRequest<super::InitMetadataForReplayRequest>,
2238        ) -> std::result::Result<
2239            tonic::Response<super::InitMetadataForReplayResponse>,
2240            tonic::Status,
2241        > {
2242            self.inner
2243                .ready()
2244                .await
2245                .map_err(|e| {
2246                    tonic::Status::unknown(
2247                        format!("Service was not ready: {}", e.into()),
2248                    )
2249                })?;
2250            let codec = tonic::codec::ProstCodec::default();
2251            let path = http::uri::PathAndQuery::from_static(
2252                "/hummock.HummockManagerService/InitMetadataForReplay",
2253            );
2254            let mut req = request.into_request();
2255            req.extensions_mut()
2256                .insert(
2257                    GrpcMethod::new(
2258                        "hummock.HummockManagerService",
2259                        "InitMetadataForReplay",
2260                    ),
2261                );
2262            self.inner.unary(req, path, codec).await
2263        }
2264        pub async fn pin_version(
2265            &mut self,
2266            request: impl tonic::IntoRequest<super::PinVersionRequest>,
2267        ) -> std::result::Result<
2268            tonic::Response<super::PinVersionResponse>,
2269            tonic::Status,
2270        > {
2271            self.inner
2272                .ready()
2273                .await
2274                .map_err(|e| {
2275                    tonic::Status::unknown(
2276                        format!("Service was not ready: {}", e.into()),
2277                    )
2278                })?;
2279            let codec = tonic::codec::ProstCodec::default();
2280            let path = http::uri::PathAndQuery::from_static(
2281                "/hummock.HummockManagerService/PinVersion",
2282            );
2283            let mut req = request.into_request();
2284            req.extensions_mut()
2285                .insert(GrpcMethod::new("hummock.HummockManagerService", "PinVersion"));
2286            self.inner.unary(req, path, codec).await
2287        }
2288        pub async fn split_compaction_group(
2289            &mut self,
2290            request: impl tonic::IntoRequest<super::SplitCompactionGroupRequest>,
2291        ) -> std::result::Result<
2292            tonic::Response<super::SplitCompactionGroupResponse>,
2293            tonic::Status,
2294        > {
2295            self.inner
2296                .ready()
2297                .await
2298                .map_err(|e| {
2299                    tonic::Status::unknown(
2300                        format!("Service was not ready: {}", e.into()),
2301                    )
2302                })?;
2303            let codec = tonic::codec::ProstCodec::default();
2304            let path = http::uri::PathAndQuery::from_static(
2305                "/hummock.HummockManagerService/SplitCompactionGroup",
2306            );
2307            let mut req = request.into_request();
2308            req.extensions_mut()
2309                .insert(
2310                    GrpcMethod::new(
2311                        "hummock.HummockManagerService",
2312                        "SplitCompactionGroup",
2313                    ),
2314                );
2315            self.inner.unary(req, path, codec).await
2316        }
2317        pub async fn rise_ctl_list_compaction_status(
2318            &mut self,
2319            request: impl tonic::IntoRequest<super::RiseCtlListCompactionStatusRequest>,
2320        ) -> std::result::Result<
2321            tonic::Response<super::RiseCtlListCompactionStatusResponse>,
2322            tonic::Status,
2323        > {
2324            self.inner
2325                .ready()
2326                .await
2327                .map_err(|e| {
2328                    tonic::Status::unknown(
2329                        format!("Service was not ready: {}", e.into()),
2330                    )
2331                })?;
2332            let codec = tonic::codec::ProstCodec::default();
2333            let path = http::uri::PathAndQuery::from_static(
2334                "/hummock.HummockManagerService/RiseCtlListCompactionStatus",
2335            );
2336            let mut req = request.into_request();
2337            req.extensions_mut()
2338                .insert(
2339                    GrpcMethod::new(
2340                        "hummock.HummockManagerService",
2341                        "RiseCtlListCompactionStatus",
2342                    ),
2343                );
2344            self.inner.unary(req, path, codec).await
2345        }
2346        pub async fn subscribe_compaction_event(
2347            &mut self,
2348            request: impl tonic::IntoStreamingRequest<
2349                Message = super::SubscribeCompactionEventRequest,
2350            >,
2351        ) -> std::result::Result<
2352            tonic::Response<
2353                tonic::codec::Streaming<super::SubscribeCompactionEventResponse>,
2354            >,
2355            tonic::Status,
2356        > {
2357            self.inner
2358                .ready()
2359                .await
2360                .map_err(|e| {
2361                    tonic::Status::unknown(
2362                        format!("Service was not ready: {}", e.into()),
2363                    )
2364                })?;
2365            let codec = tonic::codec::ProstCodec::default();
2366            let path = http::uri::PathAndQuery::from_static(
2367                "/hummock.HummockManagerService/SubscribeCompactionEvent",
2368            );
2369            let mut req = request.into_streaming_request();
2370            req.extensions_mut()
2371                .insert(
2372                    GrpcMethod::new(
2373                        "hummock.HummockManagerService",
2374                        "SubscribeCompactionEvent",
2375                    ),
2376                );
2377            self.inner.streaming(req, path, codec).await
2378        }
2379        pub async fn report_compaction_task(
2380            &mut self,
2381            request: impl tonic::IntoRequest<super::ReportCompactionTaskRequest>,
2382        ) -> std::result::Result<
2383            tonic::Response<super::ReportCompactionTaskResponse>,
2384            tonic::Status,
2385        > {
2386            self.inner
2387                .ready()
2388                .await
2389                .map_err(|e| {
2390                    tonic::Status::unknown(
2391                        format!("Service was not ready: {}", e.into()),
2392                    )
2393                })?;
2394            let codec = tonic::codec::ProstCodec::default();
2395            let path = http::uri::PathAndQuery::from_static(
2396                "/hummock.HummockManagerService/ReportCompactionTask",
2397            );
2398            let mut req = request.into_request();
2399            req.extensions_mut()
2400                .insert(
2401                    GrpcMethod::new(
2402                        "hummock.HummockManagerService",
2403                        "ReportCompactionTask",
2404                    ),
2405                );
2406            self.inner.unary(req, path, codec).await
2407        }
2408        pub async fn list_branched_object(
2409            &mut self,
2410            request: impl tonic::IntoRequest<super::ListBranchedObjectRequest>,
2411        ) -> std::result::Result<
2412            tonic::Response<super::ListBranchedObjectResponse>,
2413            tonic::Status,
2414        > {
2415            self.inner
2416                .ready()
2417                .await
2418                .map_err(|e| {
2419                    tonic::Status::unknown(
2420                        format!("Service was not ready: {}", e.into()),
2421                    )
2422                })?;
2423            let codec = tonic::codec::ProstCodec::default();
2424            let path = http::uri::PathAndQuery::from_static(
2425                "/hummock.HummockManagerService/ListBranchedObject",
2426            );
2427            let mut req = request.into_request();
2428            req.extensions_mut()
2429                .insert(
2430                    GrpcMethod::new(
2431                        "hummock.HummockManagerService",
2432                        "ListBranchedObject",
2433                    ),
2434                );
2435            self.inner.unary(req, path, codec).await
2436        }
2437        pub async fn list_active_write_limit(
2438            &mut self,
2439            request: impl tonic::IntoRequest<super::ListActiveWriteLimitRequest>,
2440        ) -> std::result::Result<
2441            tonic::Response<super::ListActiveWriteLimitResponse>,
2442            tonic::Status,
2443        > {
2444            self.inner
2445                .ready()
2446                .await
2447                .map_err(|e| {
2448                    tonic::Status::unknown(
2449                        format!("Service was not ready: {}", e.into()),
2450                    )
2451                })?;
2452            let codec = tonic::codec::ProstCodec::default();
2453            let path = http::uri::PathAndQuery::from_static(
2454                "/hummock.HummockManagerService/ListActiveWriteLimit",
2455            );
2456            let mut req = request.into_request();
2457            req.extensions_mut()
2458                .insert(
2459                    GrpcMethod::new(
2460                        "hummock.HummockManagerService",
2461                        "ListActiveWriteLimit",
2462                    ),
2463                );
2464            self.inner.unary(req, path, codec).await
2465        }
2466        pub async fn list_hummock_meta_config(
2467            &mut self,
2468            request: impl tonic::IntoRequest<super::ListHummockMetaConfigRequest>,
2469        ) -> std::result::Result<
2470            tonic::Response<super::ListHummockMetaConfigResponse>,
2471            tonic::Status,
2472        > {
2473            self.inner
2474                .ready()
2475                .await
2476                .map_err(|e| {
2477                    tonic::Status::unknown(
2478                        format!("Service was not ready: {}", e.into()),
2479                    )
2480                })?;
2481            let codec = tonic::codec::ProstCodec::default();
2482            let path = http::uri::PathAndQuery::from_static(
2483                "/hummock.HummockManagerService/ListHummockMetaConfig",
2484            );
2485            let mut req = request.into_request();
2486            req.extensions_mut()
2487                .insert(
2488                    GrpcMethod::new(
2489                        "hummock.HummockManagerService",
2490                        "ListHummockMetaConfig",
2491                    ),
2492                );
2493            self.inner.unary(req, path, codec).await
2494        }
2495        pub async fn get_compaction_score(
2496            &mut self,
2497            request: impl tonic::IntoRequest<super::GetCompactionScoreRequest>,
2498        ) -> std::result::Result<
2499            tonic::Response<super::GetCompactionScoreResponse>,
2500            tonic::Status,
2501        > {
2502            self.inner
2503                .ready()
2504                .await
2505                .map_err(|e| {
2506                    tonic::Status::unknown(
2507                        format!("Service was not ready: {}", e.into()),
2508                    )
2509                })?;
2510            let codec = tonic::codec::ProstCodec::default();
2511            let path = http::uri::PathAndQuery::from_static(
2512                "/hummock.HummockManagerService/GetCompactionScore",
2513            );
2514            let mut req = request.into_request();
2515            req.extensions_mut()
2516                .insert(
2517                    GrpcMethod::new(
2518                        "hummock.HummockManagerService",
2519                        "GetCompactionScore",
2520                    ),
2521                );
2522            self.inner.unary(req, path, codec).await
2523        }
2524        pub async fn list_compact_task_assignment(
2525            &mut self,
2526            request: impl tonic::IntoRequest<super::ListCompactTaskAssignmentRequest>,
2527        ) -> std::result::Result<
2528            tonic::Response<super::ListCompactTaskAssignmentResponse>,
2529            tonic::Status,
2530        > {
2531            self.inner
2532                .ready()
2533                .await
2534                .map_err(|e| {
2535                    tonic::Status::unknown(
2536                        format!("Service was not ready: {}", e.into()),
2537                    )
2538                })?;
2539            let codec = tonic::codec::ProstCodec::default();
2540            let path = http::uri::PathAndQuery::from_static(
2541                "/hummock.HummockManagerService/ListCompactTaskAssignment",
2542            );
2543            let mut req = request.into_request();
2544            req.extensions_mut()
2545                .insert(
2546                    GrpcMethod::new(
2547                        "hummock.HummockManagerService",
2548                        "ListCompactTaskAssignment",
2549                    ),
2550                );
2551            self.inner.unary(req, path, codec).await
2552        }
2553        pub async fn list_compact_task_progress(
2554            &mut self,
2555            request: impl tonic::IntoRequest<super::ListCompactTaskProgressRequest>,
2556        ) -> std::result::Result<
2557            tonic::Response<super::ListCompactTaskProgressResponse>,
2558            tonic::Status,
2559        > {
2560            self.inner
2561                .ready()
2562                .await
2563                .map_err(|e| {
2564                    tonic::Status::unknown(
2565                        format!("Service was not ready: {}", e.into()),
2566                    )
2567                })?;
2568            let codec = tonic::codec::ProstCodec::default();
2569            let path = http::uri::PathAndQuery::from_static(
2570                "/hummock.HummockManagerService/ListCompactTaskProgress",
2571            );
2572            let mut req = request.into_request();
2573            req.extensions_mut()
2574                .insert(
2575                    GrpcMethod::new(
2576                        "hummock.HummockManagerService",
2577                        "ListCompactTaskProgress",
2578                    ),
2579                );
2580            self.inner.unary(req, path, codec).await
2581        }
2582        pub async fn cancel_compact_task(
2583            &mut self,
2584            request: impl tonic::IntoRequest<super::CancelCompactTaskRequest>,
2585        ) -> std::result::Result<
2586            tonic::Response<super::CancelCompactTaskResponse>,
2587            tonic::Status,
2588        > {
2589            self.inner
2590                .ready()
2591                .await
2592                .map_err(|e| {
2593                    tonic::Status::unknown(
2594                        format!("Service was not ready: {}", e.into()),
2595                    )
2596                })?;
2597            let codec = tonic::codec::ProstCodec::default();
2598            let path = http::uri::PathAndQuery::from_static(
2599                "/hummock.HummockManagerService/CancelCompactTask",
2600            );
2601            let mut req = request.into_request();
2602            req.extensions_mut()
2603                .insert(
2604                    GrpcMethod::new("hummock.HummockManagerService", "CancelCompactTask"),
2605                );
2606            self.inner.unary(req, path, codec).await
2607        }
2608        pub async fn get_version_by_epoch(
2609            &mut self,
2610            request: impl tonic::IntoRequest<super::GetVersionByEpochRequest>,
2611        ) -> std::result::Result<
2612            tonic::Response<super::GetVersionByEpochResponse>,
2613            tonic::Status,
2614        > {
2615            self.inner
2616                .ready()
2617                .await
2618                .map_err(|e| {
2619                    tonic::Status::unknown(
2620                        format!("Service was not ready: {}", e.into()),
2621                    )
2622                })?;
2623            let codec = tonic::codec::ProstCodec::default();
2624            let path = http::uri::PathAndQuery::from_static(
2625                "/hummock.HummockManagerService/GetVersionByEpoch",
2626            );
2627            let mut req = request.into_request();
2628            req.extensions_mut()
2629                .insert(
2630                    GrpcMethod::new("hummock.HummockManagerService", "GetVersionByEpoch"),
2631                );
2632            self.inner.unary(req, path, codec).await
2633        }
2634        pub async fn merge_compaction_group(
2635            &mut self,
2636            request: impl tonic::IntoRequest<super::MergeCompactionGroupRequest>,
2637        ) -> std::result::Result<
2638            tonic::Response<super::MergeCompactionGroupResponse>,
2639            tonic::Status,
2640        > {
2641            self.inner
2642                .ready()
2643                .await
2644                .map_err(|e| {
2645                    tonic::Status::unknown(
2646                        format!("Service was not ready: {}", e.into()),
2647                    )
2648                })?;
2649            let codec = tonic::codec::ProstCodec::default();
2650            let path = http::uri::PathAndQuery::from_static(
2651                "/hummock.HummockManagerService/MergeCompactionGroup",
2652            );
2653            let mut req = request.into_request();
2654            req.extensions_mut()
2655                .insert(
2656                    GrpcMethod::new(
2657                        "hummock.HummockManagerService",
2658                        "MergeCompactionGroup",
2659                    ),
2660                );
2661            self.inner.unary(req, path, codec).await
2662        }
2663    }
2664}
2665/// Generated server implementations.
2666pub mod hummock_manager_service_server {
2667    #![allow(
2668        unused_variables,
2669        dead_code,
2670        missing_docs,
2671        clippy::wildcard_imports,
2672        clippy::let_unit_value,
2673    )]
2674    use tonic::codegen::*;
2675    /// Generated trait containing gRPC methods that should be implemented for use with HummockManagerServiceServer.
2676    #[async_trait]
2677    pub trait HummockManagerService: std::marker::Send + std::marker::Sync + 'static {
2678        async fn unpin_version_before(
2679            &self,
2680            request: tonic::Request<super::UnpinVersionBeforeRequest>,
2681        ) -> std::result::Result<
2682            tonic::Response<super::UnpinVersionBeforeResponse>,
2683            tonic::Status,
2684        >;
2685        async fn get_current_version(
2686            &self,
2687            request: tonic::Request<super::GetCurrentVersionRequest>,
2688        ) -> std::result::Result<
2689            tonic::Response<super::GetCurrentVersionResponse>,
2690            tonic::Status,
2691        >;
2692        async fn list_version_deltas(
2693            &self,
2694            request: tonic::Request<super::ListVersionDeltasRequest>,
2695        ) -> std::result::Result<
2696            tonic::Response<super::ListVersionDeltasResponse>,
2697            tonic::Status,
2698        >;
2699        async fn replay_version_delta(
2700            &self,
2701            request: tonic::Request<super::ReplayVersionDeltaRequest>,
2702        ) -> std::result::Result<
2703            tonic::Response<super::ReplayVersionDeltaResponse>,
2704            tonic::Status,
2705        >;
2706        async fn get_assigned_compact_task_num(
2707            &self,
2708            request: tonic::Request<super::GetAssignedCompactTaskNumRequest>,
2709        ) -> std::result::Result<
2710            tonic::Response<super::GetAssignedCompactTaskNumResponse>,
2711            tonic::Status,
2712        >;
2713        async fn trigger_compaction_deterministic(
2714            &self,
2715            request: tonic::Request<super::TriggerCompactionDeterministicRequest>,
2716        ) -> std::result::Result<
2717            tonic::Response<super::TriggerCompactionDeterministicResponse>,
2718            tonic::Status,
2719        >;
2720        async fn disable_commit_epoch(
2721            &self,
2722            request: tonic::Request<super::DisableCommitEpochRequest>,
2723        ) -> std::result::Result<
2724            tonic::Response<super::DisableCommitEpochResponse>,
2725            tonic::Status,
2726        >;
2727        async fn get_new_sst_ids(
2728            &self,
2729            request: tonic::Request<super::GetNewSstIdsRequest>,
2730        ) -> std::result::Result<
2731            tonic::Response<super::GetNewSstIdsResponse>,
2732            tonic::Status,
2733        >;
2734        async fn trigger_manual_compaction(
2735            &self,
2736            request: tonic::Request<super::TriggerManualCompactionRequest>,
2737        ) -> std::result::Result<
2738            tonic::Response<super::TriggerManualCompactionResponse>,
2739            tonic::Status,
2740        >;
2741        async fn trigger_full_gc(
2742            &self,
2743            request: tonic::Request<super::TriggerFullGcRequest>,
2744        ) -> std::result::Result<
2745            tonic::Response<super::TriggerFullGcResponse>,
2746            tonic::Status,
2747        >;
2748        async fn rise_ctl_get_pinned_versions_summary(
2749            &self,
2750            request: tonic::Request<super::RiseCtlGetPinnedVersionsSummaryRequest>,
2751        ) -> std::result::Result<
2752            tonic::Response<super::RiseCtlGetPinnedVersionsSummaryResponse>,
2753            tonic::Status,
2754        >;
2755        async fn rise_ctl_list_compaction_group(
2756            &self,
2757            request: tonic::Request<super::RiseCtlListCompactionGroupRequest>,
2758        ) -> std::result::Result<
2759            tonic::Response<super::RiseCtlListCompactionGroupResponse>,
2760            tonic::Status,
2761        >;
2762        async fn rise_ctl_update_compaction_config(
2763            &self,
2764            request: tonic::Request<super::RiseCtlUpdateCompactionConfigRequest>,
2765        ) -> std::result::Result<
2766            tonic::Response<super::RiseCtlUpdateCompactionConfigResponse>,
2767            tonic::Status,
2768        >;
2769        async fn rise_ctl_pause_version_checkpoint(
2770            &self,
2771            request: tonic::Request<super::RiseCtlPauseVersionCheckpointRequest>,
2772        ) -> std::result::Result<
2773            tonic::Response<super::RiseCtlPauseVersionCheckpointResponse>,
2774            tonic::Status,
2775        >;
2776        async fn rise_ctl_resume_version_checkpoint(
2777            &self,
2778            request: tonic::Request<super::RiseCtlResumeVersionCheckpointRequest>,
2779        ) -> std::result::Result<
2780            tonic::Response<super::RiseCtlResumeVersionCheckpointResponse>,
2781            tonic::Status,
2782        >;
2783        async fn rise_ctl_get_checkpoint_version(
2784            &self,
2785            request: tonic::Request<super::RiseCtlGetCheckpointVersionRequest>,
2786        ) -> std::result::Result<
2787            tonic::Response<super::RiseCtlGetCheckpointVersionResponse>,
2788            tonic::Status,
2789        >;
2790        async fn rise_ctl_rebuild_table_stats(
2791            &self,
2792            request: tonic::Request<super::RiseCtlRebuildTableStatsRequest>,
2793        ) -> std::result::Result<
2794            tonic::Response<super::RiseCtlRebuildTableStatsResponse>,
2795            tonic::Status,
2796        >;
2797        async fn init_metadata_for_replay(
2798            &self,
2799            request: tonic::Request<super::InitMetadataForReplayRequest>,
2800        ) -> std::result::Result<
2801            tonic::Response<super::InitMetadataForReplayResponse>,
2802            tonic::Status,
2803        >;
2804        async fn pin_version(
2805            &self,
2806            request: tonic::Request<super::PinVersionRequest>,
2807        ) -> std::result::Result<
2808            tonic::Response<super::PinVersionResponse>,
2809            tonic::Status,
2810        >;
2811        async fn split_compaction_group(
2812            &self,
2813            request: tonic::Request<super::SplitCompactionGroupRequest>,
2814        ) -> std::result::Result<
2815            tonic::Response<super::SplitCompactionGroupResponse>,
2816            tonic::Status,
2817        >;
2818        async fn rise_ctl_list_compaction_status(
2819            &self,
2820            request: tonic::Request<super::RiseCtlListCompactionStatusRequest>,
2821        ) -> std::result::Result<
2822            tonic::Response<super::RiseCtlListCompactionStatusResponse>,
2823            tonic::Status,
2824        >;
2825        /// Server streaming response type for the SubscribeCompactionEvent method.
2826        type SubscribeCompactionEventStream: tonic::codegen::tokio_stream::Stream<
2827                Item = std::result::Result<
2828                    super::SubscribeCompactionEventResponse,
2829                    tonic::Status,
2830                >,
2831            >
2832            + std::marker::Send
2833            + 'static;
2834        async fn subscribe_compaction_event(
2835            &self,
2836            request: tonic::Request<
2837                tonic::Streaming<super::SubscribeCompactionEventRequest>,
2838            >,
2839        ) -> std::result::Result<
2840            tonic::Response<Self::SubscribeCompactionEventStream>,
2841            tonic::Status,
2842        >;
2843        async fn report_compaction_task(
2844            &self,
2845            request: tonic::Request<super::ReportCompactionTaskRequest>,
2846        ) -> std::result::Result<
2847            tonic::Response<super::ReportCompactionTaskResponse>,
2848            tonic::Status,
2849        >;
2850        async fn list_branched_object(
2851            &self,
2852            request: tonic::Request<super::ListBranchedObjectRequest>,
2853        ) -> std::result::Result<
2854            tonic::Response<super::ListBranchedObjectResponse>,
2855            tonic::Status,
2856        >;
2857        async fn list_active_write_limit(
2858            &self,
2859            request: tonic::Request<super::ListActiveWriteLimitRequest>,
2860        ) -> std::result::Result<
2861            tonic::Response<super::ListActiveWriteLimitResponse>,
2862            tonic::Status,
2863        >;
2864        async fn list_hummock_meta_config(
2865            &self,
2866            request: tonic::Request<super::ListHummockMetaConfigRequest>,
2867        ) -> std::result::Result<
2868            tonic::Response<super::ListHummockMetaConfigResponse>,
2869            tonic::Status,
2870        >;
2871        async fn get_compaction_score(
2872            &self,
2873            request: tonic::Request<super::GetCompactionScoreRequest>,
2874        ) -> std::result::Result<
2875            tonic::Response<super::GetCompactionScoreResponse>,
2876            tonic::Status,
2877        >;
2878        async fn list_compact_task_assignment(
2879            &self,
2880            request: tonic::Request<super::ListCompactTaskAssignmentRequest>,
2881        ) -> std::result::Result<
2882            tonic::Response<super::ListCompactTaskAssignmentResponse>,
2883            tonic::Status,
2884        >;
2885        async fn list_compact_task_progress(
2886            &self,
2887            request: tonic::Request<super::ListCompactTaskProgressRequest>,
2888        ) -> std::result::Result<
2889            tonic::Response<super::ListCompactTaskProgressResponse>,
2890            tonic::Status,
2891        >;
2892        async fn cancel_compact_task(
2893            &self,
2894            request: tonic::Request<super::CancelCompactTaskRequest>,
2895        ) -> std::result::Result<
2896            tonic::Response<super::CancelCompactTaskResponse>,
2897            tonic::Status,
2898        >;
2899        async fn get_version_by_epoch(
2900            &self,
2901            request: tonic::Request<super::GetVersionByEpochRequest>,
2902        ) -> std::result::Result<
2903            tonic::Response<super::GetVersionByEpochResponse>,
2904            tonic::Status,
2905        >;
2906        async fn merge_compaction_group(
2907            &self,
2908            request: tonic::Request<super::MergeCompactionGroupRequest>,
2909        ) -> std::result::Result<
2910            tonic::Response<super::MergeCompactionGroupResponse>,
2911            tonic::Status,
2912        >;
2913    }
2914    #[derive(Debug)]
2915    pub struct HummockManagerServiceServer<T> {
2916        inner: Arc<T>,
2917        accept_compression_encodings: EnabledCompressionEncodings,
2918        send_compression_encodings: EnabledCompressionEncodings,
2919        max_decoding_message_size: Option<usize>,
2920        max_encoding_message_size: Option<usize>,
2921    }
2922    impl<T> HummockManagerServiceServer<T> {
2923        pub fn new(inner: T) -> Self {
2924            Self::from_arc(Arc::new(inner))
2925        }
2926        pub fn from_arc(inner: Arc<T>) -> Self {
2927            Self {
2928                inner,
2929                accept_compression_encodings: Default::default(),
2930                send_compression_encodings: Default::default(),
2931                max_decoding_message_size: None,
2932                max_encoding_message_size: None,
2933            }
2934        }
2935        pub fn with_interceptor<F>(
2936            inner: T,
2937            interceptor: F,
2938        ) -> InterceptedService<Self, F>
2939        where
2940            F: tonic::service::Interceptor,
2941        {
2942            InterceptedService::new(Self::new(inner), interceptor)
2943        }
2944        /// Enable decompressing requests with the given encoding.
2945        #[must_use]
2946        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
2947            self.accept_compression_encodings.enable(encoding);
2948            self
2949        }
2950        /// Compress responses with the given encoding, if the client supports it.
2951        #[must_use]
2952        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
2953            self.send_compression_encodings.enable(encoding);
2954            self
2955        }
2956        /// Limits the maximum size of a decoded message.
2957        ///
2958        /// Default: `4MB`
2959        #[must_use]
2960        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
2961            self.max_decoding_message_size = Some(limit);
2962            self
2963        }
2964        /// Limits the maximum size of an encoded message.
2965        ///
2966        /// Default: `usize::MAX`
2967        #[must_use]
2968        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
2969            self.max_encoding_message_size = Some(limit);
2970            self
2971        }
2972    }
2973    impl<T, B> tonic::codegen::Service<http::Request<B>>
2974    for HummockManagerServiceServer<T>
2975    where
2976        T: HummockManagerService,
2977        B: Body + std::marker::Send + 'static,
2978        B::Error: Into<StdError> + std::marker::Send + 'static,
2979    {
2980        type Response = http::Response<tonic::body::BoxBody>;
2981        type Error = std::convert::Infallible;
2982        type Future = BoxFuture<Self::Response, Self::Error>;
2983        fn poll_ready(
2984            &mut self,
2985            _cx: &mut Context<'_>,
2986        ) -> Poll<std::result::Result<(), Self::Error>> {
2987            Poll::Ready(Ok(()))
2988        }
2989        fn call(&mut self, req: http::Request<B>) -> Self::Future {
2990            match req.uri().path() {
2991                "/hummock.HummockManagerService/UnpinVersionBefore" => {
2992                    #[allow(non_camel_case_types)]
2993                    struct UnpinVersionBeforeSvc<T: HummockManagerService>(pub Arc<T>);
2994                    impl<
2995                        T: HummockManagerService,
2996                    > tonic::server::UnaryService<super::UnpinVersionBeforeRequest>
2997                    for UnpinVersionBeforeSvc<T> {
2998                        type Response = super::UnpinVersionBeforeResponse;
2999                        type Future = BoxFuture<
3000                            tonic::Response<Self::Response>,
3001                            tonic::Status,
3002                        >;
3003                        fn call(
3004                            &mut self,
3005                            request: tonic::Request<super::UnpinVersionBeforeRequest>,
3006                        ) -> Self::Future {
3007                            let inner = Arc::clone(&self.0);
3008                            let fut = async move {
3009                                <T as HummockManagerService>::unpin_version_before(
3010                                        &inner,
3011                                        request,
3012                                    )
3013                                    .await
3014                            };
3015                            Box::pin(fut)
3016                        }
3017                    }
3018                    let accept_compression_encodings = self.accept_compression_encodings;
3019                    let send_compression_encodings = self.send_compression_encodings;
3020                    let max_decoding_message_size = self.max_decoding_message_size;
3021                    let max_encoding_message_size = self.max_encoding_message_size;
3022                    let inner = self.inner.clone();
3023                    let fut = async move {
3024                        let method = UnpinVersionBeforeSvc(inner);
3025                        let codec = tonic::codec::ProstCodec::default();
3026                        let mut grpc = tonic::server::Grpc::new(codec)
3027                            .apply_compression_config(
3028                                accept_compression_encodings,
3029                                send_compression_encodings,
3030                            )
3031                            .apply_max_message_size_config(
3032                                max_decoding_message_size,
3033                                max_encoding_message_size,
3034                            );
3035                        let res = grpc.unary(method, req).await;
3036                        Ok(res)
3037                    };
3038                    Box::pin(fut)
3039                }
3040                "/hummock.HummockManagerService/GetCurrentVersion" => {
3041                    #[allow(non_camel_case_types)]
3042                    struct GetCurrentVersionSvc<T: HummockManagerService>(pub Arc<T>);
3043                    impl<
3044                        T: HummockManagerService,
3045                    > tonic::server::UnaryService<super::GetCurrentVersionRequest>
3046                    for GetCurrentVersionSvc<T> {
3047                        type Response = super::GetCurrentVersionResponse;
3048                        type Future = BoxFuture<
3049                            tonic::Response<Self::Response>,
3050                            tonic::Status,
3051                        >;
3052                        fn call(
3053                            &mut self,
3054                            request: tonic::Request<super::GetCurrentVersionRequest>,
3055                        ) -> Self::Future {
3056                            let inner = Arc::clone(&self.0);
3057                            let fut = async move {
3058                                <T as HummockManagerService>::get_current_version(
3059                                        &inner,
3060                                        request,
3061                                    )
3062                                    .await
3063                            };
3064                            Box::pin(fut)
3065                        }
3066                    }
3067                    let accept_compression_encodings = self.accept_compression_encodings;
3068                    let send_compression_encodings = self.send_compression_encodings;
3069                    let max_decoding_message_size = self.max_decoding_message_size;
3070                    let max_encoding_message_size = self.max_encoding_message_size;
3071                    let inner = self.inner.clone();
3072                    let fut = async move {
3073                        let method = GetCurrentVersionSvc(inner);
3074                        let codec = tonic::codec::ProstCodec::default();
3075                        let mut grpc = tonic::server::Grpc::new(codec)
3076                            .apply_compression_config(
3077                                accept_compression_encodings,
3078                                send_compression_encodings,
3079                            )
3080                            .apply_max_message_size_config(
3081                                max_decoding_message_size,
3082                                max_encoding_message_size,
3083                            );
3084                        let res = grpc.unary(method, req).await;
3085                        Ok(res)
3086                    };
3087                    Box::pin(fut)
3088                }
3089                "/hummock.HummockManagerService/ListVersionDeltas" => {
3090                    #[allow(non_camel_case_types)]
3091                    struct ListVersionDeltasSvc<T: HummockManagerService>(pub Arc<T>);
3092                    impl<
3093                        T: HummockManagerService,
3094                    > tonic::server::UnaryService<super::ListVersionDeltasRequest>
3095                    for ListVersionDeltasSvc<T> {
3096                        type Response = super::ListVersionDeltasResponse;
3097                        type Future = BoxFuture<
3098                            tonic::Response<Self::Response>,
3099                            tonic::Status,
3100                        >;
3101                        fn call(
3102                            &mut self,
3103                            request: tonic::Request<super::ListVersionDeltasRequest>,
3104                        ) -> Self::Future {
3105                            let inner = Arc::clone(&self.0);
3106                            let fut = async move {
3107                                <T as HummockManagerService>::list_version_deltas(
3108                                        &inner,
3109                                        request,
3110                                    )
3111                                    .await
3112                            };
3113                            Box::pin(fut)
3114                        }
3115                    }
3116                    let accept_compression_encodings = self.accept_compression_encodings;
3117                    let send_compression_encodings = self.send_compression_encodings;
3118                    let max_decoding_message_size = self.max_decoding_message_size;
3119                    let max_encoding_message_size = self.max_encoding_message_size;
3120                    let inner = self.inner.clone();
3121                    let fut = async move {
3122                        let method = ListVersionDeltasSvc(inner);
3123                        let codec = tonic::codec::ProstCodec::default();
3124                        let mut grpc = tonic::server::Grpc::new(codec)
3125                            .apply_compression_config(
3126                                accept_compression_encodings,
3127                                send_compression_encodings,
3128                            )
3129                            .apply_max_message_size_config(
3130                                max_decoding_message_size,
3131                                max_encoding_message_size,
3132                            );
3133                        let res = grpc.unary(method, req).await;
3134                        Ok(res)
3135                    };
3136                    Box::pin(fut)
3137                }
3138                "/hummock.HummockManagerService/ReplayVersionDelta" => {
3139                    #[allow(non_camel_case_types)]
3140                    struct ReplayVersionDeltaSvc<T: HummockManagerService>(pub Arc<T>);
3141                    impl<
3142                        T: HummockManagerService,
3143                    > tonic::server::UnaryService<super::ReplayVersionDeltaRequest>
3144                    for ReplayVersionDeltaSvc<T> {
3145                        type Response = super::ReplayVersionDeltaResponse;
3146                        type Future = BoxFuture<
3147                            tonic::Response<Self::Response>,
3148                            tonic::Status,
3149                        >;
3150                        fn call(
3151                            &mut self,
3152                            request: tonic::Request<super::ReplayVersionDeltaRequest>,
3153                        ) -> Self::Future {
3154                            let inner = Arc::clone(&self.0);
3155                            let fut = async move {
3156                                <T as HummockManagerService>::replay_version_delta(
3157                                        &inner,
3158                                        request,
3159                                    )
3160                                    .await
3161                            };
3162                            Box::pin(fut)
3163                        }
3164                    }
3165                    let accept_compression_encodings = self.accept_compression_encodings;
3166                    let send_compression_encodings = self.send_compression_encodings;
3167                    let max_decoding_message_size = self.max_decoding_message_size;
3168                    let max_encoding_message_size = self.max_encoding_message_size;
3169                    let inner = self.inner.clone();
3170                    let fut = async move {
3171                        let method = ReplayVersionDeltaSvc(inner);
3172                        let codec = tonic::codec::ProstCodec::default();
3173                        let mut grpc = tonic::server::Grpc::new(codec)
3174                            .apply_compression_config(
3175                                accept_compression_encodings,
3176                                send_compression_encodings,
3177                            )
3178                            .apply_max_message_size_config(
3179                                max_decoding_message_size,
3180                                max_encoding_message_size,
3181                            );
3182                        let res = grpc.unary(method, req).await;
3183                        Ok(res)
3184                    };
3185                    Box::pin(fut)
3186                }
3187                "/hummock.HummockManagerService/GetAssignedCompactTaskNum" => {
3188                    #[allow(non_camel_case_types)]
3189                    struct GetAssignedCompactTaskNumSvc<T: HummockManagerService>(
3190                        pub Arc<T>,
3191                    );
3192                    impl<
3193                        T: HummockManagerService,
3194                    > tonic::server::UnaryService<
3195                        super::GetAssignedCompactTaskNumRequest,
3196                    > for GetAssignedCompactTaskNumSvc<T> {
3197                        type Response = super::GetAssignedCompactTaskNumResponse;
3198                        type Future = BoxFuture<
3199                            tonic::Response<Self::Response>,
3200                            tonic::Status,
3201                        >;
3202                        fn call(
3203                            &mut self,
3204                            request: tonic::Request<
3205                                super::GetAssignedCompactTaskNumRequest,
3206                            >,
3207                        ) -> Self::Future {
3208                            let inner = Arc::clone(&self.0);
3209                            let fut = async move {
3210                                <T as HummockManagerService>::get_assigned_compact_task_num(
3211                                        &inner,
3212                                        request,
3213                                    )
3214                                    .await
3215                            };
3216                            Box::pin(fut)
3217                        }
3218                    }
3219                    let accept_compression_encodings = self.accept_compression_encodings;
3220                    let send_compression_encodings = self.send_compression_encodings;
3221                    let max_decoding_message_size = self.max_decoding_message_size;
3222                    let max_encoding_message_size = self.max_encoding_message_size;
3223                    let inner = self.inner.clone();
3224                    let fut = async move {
3225                        let method = GetAssignedCompactTaskNumSvc(inner);
3226                        let codec = tonic::codec::ProstCodec::default();
3227                        let mut grpc = tonic::server::Grpc::new(codec)
3228                            .apply_compression_config(
3229                                accept_compression_encodings,
3230                                send_compression_encodings,
3231                            )
3232                            .apply_max_message_size_config(
3233                                max_decoding_message_size,
3234                                max_encoding_message_size,
3235                            );
3236                        let res = grpc.unary(method, req).await;
3237                        Ok(res)
3238                    };
3239                    Box::pin(fut)
3240                }
3241                "/hummock.HummockManagerService/TriggerCompactionDeterministic" => {
3242                    #[allow(non_camel_case_types)]
3243                    struct TriggerCompactionDeterministicSvc<T: HummockManagerService>(
3244                        pub Arc<T>,
3245                    );
3246                    impl<
3247                        T: HummockManagerService,
3248                    > tonic::server::UnaryService<
3249                        super::TriggerCompactionDeterministicRequest,
3250                    > for TriggerCompactionDeterministicSvc<T> {
3251                        type Response = super::TriggerCompactionDeterministicResponse;
3252                        type Future = BoxFuture<
3253                            tonic::Response<Self::Response>,
3254                            tonic::Status,
3255                        >;
3256                        fn call(
3257                            &mut self,
3258                            request: tonic::Request<
3259                                super::TriggerCompactionDeterministicRequest,
3260                            >,
3261                        ) -> Self::Future {
3262                            let inner = Arc::clone(&self.0);
3263                            let fut = async move {
3264                                <T as HummockManagerService>::trigger_compaction_deterministic(
3265                                        &inner,
3266                                        request,
3267                                    )
3268                                    .await
3269                            };
3270                            Box::pin(fut)
3271                        }
3272                    }
3273                    let accept_compression_encodings = self.accept_compression_encodings;
3274                    let send_compression_encodings = self.send_compression_encodings;
3275                    let max_decoding_message_size = self.max_decoding_message_size;
3276                    let max_encoding_message_size = self.max_encoding_message_size;
3277                    let inner = self.inner.clone();
3278                    let fut = async move {
3279                        let method = TriggerCompactionDeterministicSvc(inner);
3280                        let codec = tonic::codec::ProstCodec::default();
3281                        let mut grpc = tonic::server::Grpc::new(codec)
3282                            .apply_compression_config(
3283                                accept_compression_encodings,
3284                                send_compression_encodings,
3285                            )
3286                            .apply_max_message_size_config(
3287                                max_decoding_message_size,
3288                                max_encoding_message_size,
3289                            );
3290                        let res = grpc.unary(method, req).await;
3291                        Ok(res)
3292                    };
3293                    Box::pin(fut)
3294                }
3295                "/hummock.HummockManagerService/DisableCommitEpoch" => {
3296                    #[allow(non_camel_case_types)]
3297                    struct DisableCommitEpochSvc<T: HummockManagerService>(pub Arc<T>);
3298                    impl<
3299                        T: HummockManagerService,
3300                    > tonic::server::UnaryService<super::DisableCommitEpochRequest>
3301                    for DisableCommitEpochSvc<T> {
3302                        type Response = super::DisableCommitEpochResponse;
3303                        type Future = BoxFuture<
3304                            tonic::Response<Self::Response>,
3305                            tonic::Status,
3306                        >;
3307                        fn call(
3308                            &mut self,
3309                            request: tonic::Request<super::DisableCommitEpochRequest>,
3310                        ) -> Self::Future {
3311                            let inner = Arc::clone(&self.0);
3312                            let fut = async move {
3313                                <T as HummockManagerService>::disable_commit_epoch(
3314                                        &inner,
3315                                        request,
3316                                    )
3317                                    .await
3318                            };
3319                            Box::pin(fut)
3320                        }
3321                    }
3322                    let accept_compression_encodings = self.accept_compression_encodings;
3323                    let send_compression_encodings = self.send_compression_encodings;
3324                    let max_decoding_message_size = self.max_decoding_message_size;
3325                    let max_encoding_message_size = self.max_encoding_message_size;
3326                    let inner = self.inner.clone();
3327                    let fut = async move {
3328                        let method = DisableCommitEpochSvc(inner);
3329                        let codec = tonic::codec::ProstCodec::default();
3330                        let mut grpc = tonic::server::Grpc::new(codec)
3331                            .apply_compression_config(
3332                                accept_compression_encodings,
3333                                send_compression_encodings,
3334                            )
3335                            .apply_max_message_size_config(
3336                                max_decoding_message_size,
3337                                max_encoding_message_size,
3338                            );
3339                        let res = grpc.unary(method, req).await;
3340                        Ok(res)
3341                    };
3342                    Box::pin(fut)
3343                }
3344                "/hummock.HummockManagerService/GetNewSstIds" => {
3345                    #[allow(non_camel_case_types)]
3346                    struct GetNewSstIdsSvc<T: HummockManagerService>(pub Arc<T>);
3347                    impl<
3348                        T: HummockManagerService,
3349                    > tonic::server::UnaryService<super::GetNewSstIdsRequest>
3350                    for GetNewSstIdsSvc<T> {
3351                        type Response = super::GetNewSstIdsResponse;
3352                        type Future = BoxFuture<
3353                            tonic::Response<Self::Response>,
3354                            tonic::Status,
3355                        >;
3356                        fn call(
3357                            &mut self,
3358                            request: tonic::Request<super::GetNewSstIdsRequest>,
3359                        ) -> Self::Future {
3360                            let inner = Arc::clone(&self.0);
3361                            let fut = async move {
3362                                <T as HummockManagerService>::get_new_sst_ids(
3363                                        &inner,
3364                                        request,
3365                                    )
3366                                    .await
3367                            };
3368                            Box::pin(fut)
3369                        }
3370                    }
3371                    let accept_compression_encodings = self.accept_compression_encodings;
3372                    let send_compression_encodings = self.send_compression_encodings;
3373                    let max_decoding_message_size = self.max_decoding_message_size;
3374                    let max_encoding_message_size = self.max_encoding_message_size;
3375                    let inner = self.inner.clone();
3376                    let fut = async move {
3377                        let method = GetNewSstIdsSvc(inner);
3378                        let codec = tonic::codec::ProstCodec::default();
3379                        let mut grpc = tonic::server::Grpc::new(codec)
3380                            .apply_compression_config(
3381                                accept_compression_encodings,
3382                                send_compression_encodings,
3383                            )
3384                            .apply_max_message_size_config(
3385                                max_decoding_message_size,
3386                                max_encoding_message_size,
3387                            );
3388                        let res = grpc.unary(method, req).await;
3389                        Ok(res)
3390                    };
3391                    Box::pin(fut)
3392                }
3393                "/hummock.HummockManagerService/TriggerManualCompaction" => {
3394                    #[allow(non_camel_case_types)]
3395                    struct TriggerManualCompactionSvc<T: HummockManagerService>(
3396                        pub Arc<T>,
3397                    );
3398                    impl<
3399                        T: HummockManagerService,
3400                    > tonic::server::UnaryService<super::TriggerManualCompactionRequest>
3401                    for TriggerManualCompactionSvc<T> {
3402                        type Response = super::TriggerManualCompactionResponse;
3403                        type Future = BoxFuture<
3404                            tonic::Response<Self::Response>,
3405                            tonic::Status,
3406                        >;
3407                        fn call(
3408                            &mut self,
3409                            request: tonic::Request<
3410                                super::TriggerManualCompactionRequest,
3411                            >,
3412                        ) -> Self::Future {
3413                            let inner = Arc::clone(&self.0);
3414                            let fut = async move {
3415                                <T as HummockManagerService>::trigger_manual_compaction(
3416                                        &inner,
3417                                        request,
3418                                    )
3419                                    .await
3420                            };
3421                            Box::pin(fut)
3422                        }
3423                    }
3424                    let accept_compression_encodings = self.accept_compression_encodings;
3425                    let send_compression_encodings = self.send_compression_encodings;
3426                    let max_decoding_message_size = self.max_decoding_message_size;
3427                    let max_encoding_message_size = self.max_encoding_message_size;
3428                    let inner = self.inner.clone();
3429                    let fut = async move {
3430                        let method = TriggerManualCompactionSvc(inner);
3431                        let codec = tonic::codec::ProstCodec::default();
3432                        let mut grpc = tonic::server::Grpc::new(codec)
3433                            .apply_compression_config(
3434                                accept_compression_encodings,
3435                                send_compression_encodings,
3436                            )
3437                            .apply_max_message_size_config(
3438                                max_decoding_message_size,
3439                                max_encoding_message_size,
3440                            );
3441                        let res = grpc.unary(method, req).await;
3442                        Ok(res)
3443                    };
3444                    Box::pin(fut)
3445                }
3446                "/hummock.HummockManagerService/TriggerFullGC" => {
3447                    #[allow(non_camel_case_types)]
3448                    struct TriggerFullGCSvc<T: HummockManagerService>(pub Arc<T>);
3449                    impl<
3450                        T: HummockManagerService,
3451                    > tonic::server::UnaryService<super::TriggerFullGcRequest>
3452                    for TriggerFullGCSvc<T> {
3453                        type Response = super::TriggerFullGcResponse;
3454                        type Future = BoxFuture<
3455                            tonic::Response<Self::Response>,
3456                            tonic::Status,
3457                        >;
3458                        fn call(
3459                            &mut self,
3460                            request: tonic::Request<super::TriggerFullGcRequest>,
3461                        ) -> Self::Future {
3462                            let inner = Arc::clone(&self.0);
3463                            let fut = async move {
3464                                <T as HummockManagerService>::trigger_full_gc(
3465                                        &inner,
3466                                        request,
3467                                    )
3468                                    .await
3469                            };
3470                            Box::pin(fut)
3471                        }
3472                    }
3473                    let accept_compression_encodings = self.accept_compression_encodings;
3474                    let send_compression_encodings = self.send_compression_encodings;
3475                    let max_decoding_message_size = self.max_decoding_message_size;
3476                    let max_encoding_message_size = self.max_encoding_message_size;
3477                    let inner = self.inner.clone();
3478                    let fut = async move {
3479                        let method = TriggerFullGCSvc(inner);
3480                        let codec = tonic::codec::ProstCodec::default();
3481                        let mut grpc = tonic::server::Grpc::new(codec)
3482                            .apply_compression_config(
3483                                accept_compression_encodings,
3484                                send_compression_encodings,
3485                            )
3486                            .apply_max_message_size_config(
3487                                max_decoding_message_size,
3488                                max_encoding_message_size,
3489                            );
3490                        let res = grpc.unary(method, req).await;
3491                        Ok(res)
3492                    };
3493                    Box::pin(fut)
3494                }
3495                "/hummock.HummockManagerService/RiseCtlGetPinnedVersionsSummary" => {
3496                    #[allow(non_camel_case_types)]
3497                    struct RiseCtlGetPinnedVersionsSummarySvc<T: HummockManagerService>(
3498                        pub Arc<T>,
3499                    );
3500                    impl<
3501                        T: HummockManagerService,
3502                    > tonic::server::UnaryService<
3503                        super::RiseCtlGetPinnedVersionsSummaryRequest,
3504                    > for RiseCtlGetPinnedVersionsSummarySvc<T> {
3505                        type Response = super::RiseCtlGetPinnedVersionsSummaryResponse;
3506                        type Future = BoxFuture<
3507                            tonic::Response<Self::Response>,
3508                            tonic::Status,
3509                        >;
3510                        fn call(
3511                            &mut self,
3512                            request: tonic::Request<
3513                                super::RiseCtlGetPinnedVersionsSummaryRequest,
3514                            >,
3515                        ) -> Self::Future {
3516                            let inner = Arc::clone(&self.0);
3517                            let fut = async move {
3518                                <T as HummockManagerService>::rise_ctl_get_pinned_versions_summary(
3519                                        &inner,
3520                                        request,
3521                                    )
3522                                    .await
3523                            };
3524                            Box::pin(fut)
3525                        }
3526                    }
3527                    let accept_compression_encodings = self.accept_compression_encodings;
3528                    let send_compression_encodings = self.send_compression_encodings;
3529                    let max_decoding_message_size = self.max_decoding_message_size;
3530                    let max_encoding_message_size = self.max_encoding_message_size;
3531                    let inner = self.inner.clone();
3532                    let fut = async move {
3533                        let method = RiseCtlGetPinnedVersionsSummarySvc(inner);
3534                        let codec = tonic::codec::ProstCodec::default();
3535                        let mut grpc = tonic::server::Grpc::new(codec)
3536                            .apply_compression_config(
3537                                accept_compression_encodings,
3538                                send_compression_encodings,
3539                            )
3540                            .apply_max_message_size_config(
3541                                max_decoding_message_size,
3542                                max_encoding_message_size,
3543                            );
3544                        let res = grpc.unary(method, req).await;
3545                        Ok(res)
3546                    };
3547                    Box::pin(fut)
3548                }
3549                "/hummock.HummockManagerService/RiseCtlListCompactionGroup" => {
3550                    #[allow(non_camel_case_types)]
3551                    struct RiseCtlListCompactionGroupSvc<T: HummockManagerService>(
3552                        pub Arc<T>,
3553                    );
3554                    impl<
3555                        T: HummockManagerService,
3556                    > tonic::server::UnaryService<
3557                        super::RiseCtlListCompactionGroupRequest,
3558                    > for RiseCtlListCompactionGroupSvc<T> {
3559                        type Response = super::RiseCtlListCompactionGroupResponse;
3560                        type Future = BoxFuture<
3561                            tonic::Response<Self::Response>,
3562                            tonic::Status,
3563                        >;
3564                        fn call(
3565                            &mut self,
3566                            request: tonic::Request<
3567                                super::RiseCtlListCompactionGroupRequest,
3568                            >,
3569                        ) -> Self::Future {
3570                            let inner = Arc::clone(&self.0);
3571                            let fut = async move {
3572                                <T as HummockManagerService>::rise_ctl_list_compaction_group(
3573                                        &inner,
3574                                        request,
3575                                    )
3576                                    .await
3577                            };
3578                            Box::pin(fut)
3579                        }
3580                    }
3581                    let accept_compression_encodings = self.accept_compression_encodings;
3582                    let send_compression_encodings = self.send_compression_encodings;
3583                    let max_decoding_message_size = self.max_decoding_message_size;
3584                    let max_encoding_message_size = self.max_encoding_message_size;
3585                    let inner = self.inner.clone();
3586                    let fut = async move {
3587                        let method = RiseCtlListCompactionGroupSvc(inner);
3588                        let codec = tonic::codec::ProstCodec::default();
3589                        let mut grpc = tonic::server::Grpc::new(codec)
3590                            .apply_compression_config(
3591                                accept_compression_encodings,
3592                                send_compression_encodings,
3593                            )
3594                            .apply_max_message_size_config(
3595                                max_decoding_message_size,
3596                                max_encoding_message_size,
3597                            );
3598                        let res = grpc.unary(method, req).await;
3599                        Ok(res)
3600                    };
3601                    Box::pin(fut)
3602                }
3603                "/hummock.HummockManagerService/RiseCtlUpdateCompactionConfig" => {
3604                    #[allow(non_camel_case_types)]
3605                    struct RiseCtlUpdateCompactionConfigSvc<T: HummockManagerService>(
3606                        pub Arc<T>,
3607                    );
3608                    impl<
3609                        T: HummockManagerService,
3610                    > tonic::server::UnaryService<
3611                        super::RiseCtlUpdateCompactionConfigRequest,
3612                    > for RiseCtlUpdateCompactionConfigSvc<T> {
3613                        type Response = super::RiseCtlUpdateCompactionConfigResponse;
3614                        type Future = BoxFuture<
3615                            tonic::Response<Self::Response>,
3616                            tonic::Status,
3617                        >;
3618                        fn call(
3619                            &mut self,
3620                            request: tonic::Request<
3621                                super::RiseCtlUpdateCompactionConfigRequest,
3622                            >,
3623                        ) -> Self::Future {
3624                            let inner = Arc::clone(&self.0);
3625                            let fut = async move {
3626                                <T as HummockManagerService>::rise_ctl_update_compaction_config(
3627                                        &inner,
3628                                        request,
3629                                    )
3630                                    .await
3631                            };
3632                            Box::pin(fut)
3633                        }
3634                    }
3635                    let accept_compression_encodings = self.accept_compression_encodings;
3636                    let send_compression_encodings = self.send_compression_encodings;
3637                    let max_decoding_message_size = self.max_decoding_message_size;
3638                    let max_encoding_message_size = self.max_encoding_message_size;
3639                    let inner = self.inner.clone();
3640                    let fut = async move {
3641                        let method = RiseCtlUpdateCompactionConfigSvc(inner);
3642                        let codec = tonic::codec::ProstCodec::default();
3643                        let mut grpc = tonic::server::Grpc::new(codec)
3644                            .apply_compression_config(
3645                                accept_compression_encodings,
3646                                send_compression_encodings,
3647                            )
3648                            .apply_max_message_size_config(
3649                                max_decoding_message_size,
3650                                max_encoding_message_size,
3651                            );
3652                        let res = grpc.unary(method, req).await;
3653                        Ok(res)
3654                    };
3655                    Box::pin(fut)
3656                }
3657                "/hummock.HummockManagerService/RiseCtlPauseVersionCheckpoint" => {
3658                    #[allow(non_camel_case_types)]
3659                    struct RiseCtlPauseVersionCheckpointSvc<T: HummockManagerService>(
3660                        pub Arc<T>,
3661                    );
3662                    impl<
3663                        T: HummockManagerService,
3664                    > tonic::server::UnaryService<
3665                        super::RiseCtlPauseVersionCheckpointRequest,
3666                    > for RiseCtlPauseVersionCheckpointSvc<T> {
3667                        type Response = super::RiseCtlPauseVersionCheckpointResponse;
3668                        type Future = BoxFuture<
3669                            tonic::Response<Self::Response>,
3670                            tonic::Status,
3671                        >;
3672                        fn call(
3673                            &mut self,
3674                            request: tonic::Request<
3675                                super::RiseCtlPauseVersionCheckpointRequest,
3676                            >,
3677                        ) -> Self::Future {
3678                            let inner = Arc::clone(&self.0);
3679                            let fut = async move {
3680                                <T as HummockManagerService>::rise_ctl_pause_version_checkpoint(
3681                                        &inner,
3682                                        request,
3683                                    )
3684                                    .await
3685                            };
3686                            Box::pin(fut)
3687                        }
3688                    }
3689                    let accept_compression_encodings = self.accept_compression_encodings;
3690                    let send_compression_encodings = self.send_compression_encodings;
3691                    let max_decoding_message_size = self.max_decoding_message_size;
3692                    let max_encoding_message_size = self.max_encoding_message_size;
3693                    let inner = self.inner.clone();
3694                    let fut = async move {
3695                        let method = RiseCtlPauseVersionCheckpointSvc(inner);
3696                        let codec = tonic::codec::ProstCodec::default();
3697                        let mut grpc = tonic::server::Grpc::new(codec)
3698                            .apply_compression_config(
3699                                accept_compression_encodings,
3700                                send_compression_encodings,
3701                            )
3702                            .apply_max_message_size_config(
3703                                max_decoding_message_size,
3704                                max_encoding_message_size,
3705                            );
3706                        let res = grpc.unary(method, req).await;
3707                        Ok(res)
3708                    };
3709                    Box::pin(fut)
3710                }
3711                "/hummock.HummockManagerService/RiseCtlResumeVersionCheckpoint" => {
3712                    #[allow(non_camel_case_types)]
3713                    struct RiseCtlResumeVersionCheckpointSvc<T: HummockManagerService>(
3714                        pub Arc<T>,
3715                    );
3716                    impl<
3717                        T: HummockManagerService,
3718                    > tonic::server::UnaryService<
3719                        super::RiseCtlResumeVersionCheckpointRequest,
3720                    > for RiseCtlResumeVersionCheckpointSvc<T> {
3721                        type Response = super::RiseCtlResumeVersionCheckpointResponse;
3722                        type Future = BoxFuture<
3723                            tonic::Response<Self::Response>,
3724                            tonic::Status,
3725                        >;
3726                        fn call(
3727                            &mut self,
3728                            request: tonic::Request<
3729                                super::RiseCtlResumeVersionCheckpointRequest,
3730                            >,
3731                        ) -> Self::Future {
3732                            let inner = Arc::clone(&self.0);
3733                            let fut = async move {
3734                                <T as HummockManagerService>::rise_ctl_resume_version_checkpoint(
3735                                        &inner,
3736                                        request,
3737                                    )
3738                                    .await
3739                            };
3740                            Box::pin(fut)
3741                        }
3742                    }
3743                    let accept_compression_encodings = self.accept_compression_encodings;
3744                    let send_compression_encodings = self.send_compression_encodings;
3745                    let max_decoding_message_size = self.max_decoding_message_size;
3746                    let max_encoding_message_size = self.max_encoding_message_size;
3747                    let inner = self.inner.clone();
3748                    let fut = async move {
3749                        let method = RiseCtlResumeVersionCheckpointSvc(inner);
3750                        let codec = tonic::codec::ProstCodec::default();
3751                        let mut grpc = tonic::server::Grpc::new(codec)
3752                            .apply_compression_config(
3753                                accept_compression_encodings,
3754                                send_compression_encodings,
3755                            )
3756                            .apply_max_message_size_config(
3757                                max_decoding_message_size,
3758                                max_encoding_message_size,
3759                            );
3760                        let res = grpc.unary(method, req).await;
3761                        Ok(res)
3762                    };
3763                    Box::pin(fut)
3764                }
3765                "/hummock.HummockManagerService/RiseCtlGetCheckpointVersion" => {
3766                    #[allow(non_camel_case_types)]
3767                    struct RiseCtlGetCheckpointVersionSvc<T: HummockManagerService>(
3768                        pub Arc<T>,
3769                    );
3770                    impl<
3771                        T: HummockManagerService,
3772                    > tonic::server::UnaryService<
3773                        super::RiseCtlGetCheckpointVersionRequest,
3774                    > for RiseCtlGetCheckpointVersionSvc<T> {
3775                        type Response = super::RiseCtlGetCheckpointVersionResponse;
3776                        type Future = BoxFuture<
3777                            tonic::Response<Self::Response>,
3778                            tonic::Status,
3779                        >;
3780                        fn call(
3781                            &mut self,
3782                            request: tonic::Request<
3783                                super::RiseCtlGetCheckpointVersionRequest,
3784                            >,
3785                        ) -> Self::Future {
3786                            let inner = Arc::clone(&self.0);
3787                            let fut = async move {
3788                                <T as HummockManagerService>::rise_ctl_get_checkpoint_version(
3789                                        &inner,
3790                                        request,
3791                                    )
3792                                    .await
3793                            };
3794                            Box::pin(fut)
3795                        }
3796                    }
3797                    let accept_compression_encodings = self.accept_compression_encodings;
3798                    let send_compression_encodings = self.send_compression_encodings;
3799                    let max_decoding_message_size = self.max_decoding_message_size;
3800                    let max_encoding_message_size = self.max_encoding_message_size;
3801                    let inner = self.inner.clone();
3802                    let fut = async move {
3803                        let method = RiseCtlGetCheckpointVersionSvc(inner);
3804                        let codec = tonic::codec::ProstCodec::default();
3805                        let mut grpc = tonic::server::Grpc::new(codec)
3806                            .apply_compression_config(
3807                                accept_compression_encodings,
3808                                send_compression_encodings,
3809                            )
3810                            .apply_max_message_size_config(
3811                                max_decoding_message_size,
3812                                max_encoding_message_size,
3813                            );
3814                        let res = grpc.unary(method, req).await;
3815                        Ok(res)
3816                    };
3817                    Box::pin(fut)
3818                }
3819                "/hummock.HummockManagerService/RiseCtlRebuildTableStats" => {
3820                    #[allow(non_camel_case_types)]
3821                    struct RiseCtlRebuildTableStatsSvc<T: HummockManagerService>(
3822                        pub Arc<T>,
3823                    );
3824                    impl<
3825                        T: HummockManagerService,
3826                    > tonic::server::UnaryService<super::RiseCtlRebuildTableStatsRequest>
3827                    for RiseCtlRebuildTableStatsSvc<T> {
3828                        type Response = super::RiseCtlRebuildTableStatsResponse;
3829                        type Future = BoxFuture<
3830                            tonic::Response<Self::Response>,
3831                            tonic::Status,
3832                        >;
3833                        fn call(
3834                            &mut self,
3835                            request: tonic::Request<
3836                                super::RiseCtlRebuildTableStatsRequest,
3837                            >,
3838                        ) -> Self::Future {
3839                            let inner = Arc::clone(&self.0);
3840                            let fut = async move {
3841                                <T as HummockManagerService>::rise_ctl_rebuild_table_stats(
3842                                        &inner,
3843                                        request,
3844                                    )
3845                                    .await
3846                            };
3847                            Box::pin(fut)
3848                        }
3849                    }
3850                    let accept_compression_encodings = self.accept_compression_encodings;
3851                    let send_compression_encodings = self.send_compression_encodings;
3852                    let max_decoding_message_size = self.max_decoding_message_size;
3853                    let max_encoding_message_size = self.max_encoding_message_size;
3854                    let inner = self.inner.clone();
3855                    let fut = async move {
3856                        let method = RiseCtlRebuildTableStatsSvc(inner);
3857                        let codec = tonic::codec::ProstCodec::default();
3858                        let mut grpc = tonic::server::Grpc::new(codec)
3859                            .apply_compression_config(
3860                                accept_compression_encodings,
3861                                send_compression_encodings,
3862                            )
3863                            .apply_max_message_size_config(
3864                                max_decoding_message_size,
3865                                max_encoding_message_size,
3866                            );
3867                        let res = grpc.unary(method, req).await;
3868                        Ok(res)
3869                    };
3870                    Box::pin(fut)
3871                }
3872                "/hummock.HummockManagerService/InitMetadataForReplay" => {
3873                    #[allow(non_camel_case_types)]
3874                    struct InitMetadataForReplaySvc<T: HummockManagerService>(
3875                        pub Arc<T>,
3876                    );
3877                    impl<
3878                        T: HummockManagerService,
3879                    > tonic::server::UnaryService<super::InitMetadataForReplayRequest>
3880                    for InitMetadataForReplaySvc<T> {
3881                        type Response = super::InitMetadataForReplayResponse;
3882                        type Future = BoxFuture<
3883                            tonic::Response<Self::Response>,
3884                            tonic::Status,
3885                        >;
3886                        fn call(
3887                            &mut self,
3888                            request: tonic::Request<super::InitMetadataForReplayRequest>,
3889                        ) -> Self::Future {
3890                            let inner = Arc::clone(&self.0);
3891                            let fut = async move {
3892                                <T as HummockManagerService>::init_metadata_for_replay(
3893                                        &inner,
3894                                        request,
3895                                    )
3896                                    .await
3897                            };
3898                            Box::pin(fut)
3899                        }
3900                    }
3901                    let accept_compression_encodings = self.accept_compression_encodings;
3902                    let send_compression_encodings = self.send_compression_encodings;
3903                    let max_decoding_message_size = self.max_decoding_message_size;
3904                    let max_encoding_message_size = self.max_encoding_message_size;
3905                    let inner = self.inner.clone();
3906                    let fut = async move {
3907                        let method = InitMetadataForReplaySvc(inner);
3908                        let codec = tonic::codec::ProstCodec::default();
3909                        let mut grpc = tonic::server::Grpc::new(codec)
3910                            .apply_compression_config(
3911                                accept_compression_encodings,
3912                                send_compression_encodings,
3913                            )
3914                            .apply_max_message_size_config(
3915                                max_decoding_message_size,
3916                                max_encoding_message_size,
3917                            );
3918                        let res = grpc.unary(method, req).await;
3919                        Ok(res)
3920                    };
3921                    Box::pin(fut)
3922                }
3923                "/hummock.HummockManagerService/PinVersion" => {
3924                    #[allow(non_camel_case_types)]
3925                    struct PinVersionSvc<T: HummockManagerService>(pub Arc<T>);
3926                    impl<
3927                        T: HummockManagerService,
3928                    > tonic::server::UnaryService<super::PinVersionRequest>
3929                    for PinVersionSvc<T> {
3930                        type Response = super::PinVersionResponse;
3931                        type Future = BoxFuture<
3932                            tonic::Response<Self::Response>,
3933                            tonic::Status,
3934                        >;
3935                        fn call(
3936                            &mut self,
3937                            request: tonic::Request<super::PinVersionRequest>,
3938                        ) -> Self::Future {
3939                            let inner = Arc::clone(&self.0);
3940                            let fut = async move {
3941                                <T as HummockManagerService>::pin_version(&inner, request)
3942                                    .await
3943                            };
3944                            Box::pin(fut)
3945                        }
3946                    }
3947                    let accept_compression_encodings = self.accept_compression_encodings;
3948                    let send_compression_encodings = self.send_compression_encodings;
3949                    let max_decoding_message_size = self.max_decoding_message_size;
3950                    let max_encoding_message_size = self.max_encoding_message_size;
3951                    let inner = self.inner.clone();
3952                    let fut = async move {
3953                        let method = PinVersionSvc(inner);
3954                        let codec = tonic::codec::ProstCodec::default();
3955                        let mut grpc = tonic::server::Grpc::new(codec)
3956                            .apply_compression_config(
3957                                accept_compression_encodings,
3958                                send_compression_encodings,
3959                            )
3960                            .apply_max_message_size_config(
3961                                max_decoding_message_size,
3962                                max_encoding_message_size,
3963                            );
3964                        let res = grpc.unary(method, req).await;
3965                        Ok(res)
3966                    };
3967                    Box::pin(fut)
3968                }
3969                "/hummock.HummockManagerService/SplitCompactionGroup" => {
3970                    #[allow(non_camel_case_types)]
3971                    struct SplitCompactionGroupSvc<T: HummockManagerService>(pub Arc<T>);
3972                    impl<
3973                        T: HummockManagerService,
3974                    > tonic::server::UnaryService<super::SplitCompactionGroupRequest>
3975                    for SplitCompactionGroupSvc<T> {
3976                        type Response = super::SplitCompactionGroupResponse;
3977                        type Future = BoxFuture<
3978                            tonic::Response<Self::Response>,
3979                            tonic::Status,
3980                        >;
3981                        fn call(
3982                            &mut self,
3983                            request: tonic::Request<super::SplitCompactionGroupRequest>,
3984                        ) -> Self::Future {
3985                            let inner = Arc::clone(&self.0);
3986                            let fut = async move {
3987                                <T as HummockManagerService>::split_compaction_group(
3988                                        &inner,
3989                                        request,
3990                                    )
3991                                    .await
3992                            };
3993                            Box::pin(fut)
3994                        }
3995                    }
3996                    let accept_compression_encodings = self.accept_compression_encodings;
3997                    let send_compression_encodings = self.send_compression_encodings;
3998                    let max_decoding_message_size = self.max_decoding_message_size;
3999                    let max_encoding_message_size = self.max_encoding_message_size;
4000                    let inner = self.inner.clone();
4001                    let fut = async move {
4002                        let method = SplitCompactionGroupSvc(inner);
4003                        let codec = tonic::codec::ProstCodec::default();
4004                        let mut grpc = tonic::server::Grpc::new(codec)
4005                            .apply_compression_config(
4006                                accept_compression_encodings,
4007                                send_compression_encodings,
4008                            )
4009                            .apply_max_message_size_config(
4010                                max_decoding_message_size,
4011                                max_encoding_message_size,
4012                            );
4013                        let res = grpc.unary(method, req).await;
4014                        Ok(res)
4015                    };
4016                    Box::pin(fut)
4017                }
4018                "/hummock.HummockManagerService/RiseCtlListCompactionStatus" => {
4019                    #[allow(non_camel_case_types)]
4020                    struct RiseCtlListCompactionStatusSvc<T: HummockManagerService>(
4021                        pub Arc<T>,
4022                    );
4023                    impl<
4024                        T: HummockManagerService,
4025                    > tonic::server::UnaryService<
4026                        super::RiseCtlListCompactionStatusRequest,
4027                    > for RiseCtlListCompactionStatusSvc<T> {
4028                        type Response = super::RiseCtlListCompactionStatusResponse;
4029                        type Future = BoxFuture<
4030                            tonic::Response<Self::Response>,
4031                            tonic::Status,
4032                        >;
4033                        fn call(
4034                            &mut self,
4035                            request: tonic::Request<
4036                                super::RiseCtlListCompactionStatusRequest,
4037                            >,
4038                        ) -> Self::Future {
4039                            let inner = Arc::clone(&self.0);
4040                            let fut = async move {
4041                                <T as HummockManagerService>::rise_ctl_list_compaction_status(
4042                                        &inner,
4043                                        request,
4044                                    )
4045                                    .await
4046                            };
4047                            Box::pin(fut)
4048                        }
4049                    }
4050                    let accept_compression_encodings = self.accept_compression_encodings;
4051                    let send_compression_encodings = self.send_compression_encodings;
4052                    let max_decoding_message_size = self.max_decoding_message_size;
4053                    let max_encoding_message_size = self.max_encoding_message_size;
4054                    let inner = self.inner.clone();
4055                    let fut = async move {
4056                        let method = RiseCtlListCompactionStatusSvc(inner);
4057                        let codec = tonic::codec::ProstCodec::default();
4058                        let mut grpc = tonic::server::Grpc::new(codec)
4059                            .apply_compression_config(
4060                                accept_compression_encodings,
4061                                send_compression_encodings,
4062                            )
4063                            .apply_max_message_size_config(
4064                                max_decoding_message_size,
4065                                max_encoding_message_size,
4066                            );
4067                        let res = grpc.unary(method, req).await;
4068                        Ok(res)
4069                    };
4070                    Box::pin(fut)
4071                }
4072                "/hummock.HummockManagerService/SubscribeCompactionEvent" => {
4073                    #[allow(non_camel_case_types)]
4074                    struct SubscribeCompactionEventSvc<T: HummockManagerService>(
4075                        pub Arc<T>,
4076                    );
4077                    impl<
4078                        T: HummockManagerService,
4079                    > tonic::server::StreamingService<
4080                        super::SubscribeCompactionEventRequest,
4081                    > for SubscribeCompactionEventSvc<T> {
4082                        type Response = super::SubscribeCompactionEventResponse;
4083                        type ResponseStream = T::SubscribeCompactionEventStream;
4084                        type Future = BoxFuture<
4085                            tonic::Response<Self::ResponseStream>,
4086                            tonic::Status,
4087                        >;
4088                        fn call(
4089                            &mut self,
4090                            request: tonic::Request<
4091                                tonic::Streaming<super::SubscribeCompactionEventRequest>,
4092                            >,
4093                        ) -> Self::Future {
4094                            let inner = Arc::clone(&self.0);
4095                            let fut = async move {
4096                                <T as HummockManagerService>::subscribe_compaction_event(
4097                                        &inner,
4098                                        request,
4099                                    )
4100                                    .await
4101                            };
4102                            Box::pin(fut)
4103                        }
4104                    }
4105                    let accept_compression_encodings = self.accept_compression_encodings;
4106                    let send_compression_encodings = self.send_compression_encodings;
4107                    let max_decoding_message_size = self.max_decoding_message_size;
4108                    let max_encoding_message_size = self.max_encoding_message_size;
4109                    let inner = self.inner.clone();
4110                    let fut = async move {
4111                        let method = SubscribeCompactionEventSvc(inner);
4112                        let codec = tonic::codec::ProstCodec::default();
4113                        let mut grpc = tonic::server::Grpc::new(codec)
4114                            .apply_compression_config(
4115                                accept_compression_encodings,
4116                                send_compression_encodings,
4117                            )
4118                            .apply_max_message_size_config(
4119                                max_decoding_message_size,
4120                                max_encoding_message_size,
4121                            );
4122                        let res = grpc.streaming(method, req).await;
4123                        Ok(res)
4124                    };
4125                    Box::pin(fut)
4126                }
4127                "/hummock.HummockManagerService/ReportCompactionTask" => {
4128                    #[allow(non_camel_case_types)]
4129                    struct ReportCompactionTaskSvc<T: HummockManagerService>(pub Arc<T>);
4130                    impl<
4131                        T: HummockManagerService,
4132                    > tonic::server::UnaryService<super::ReportCompactionTaskRequest>
4133                    for ReportCompactionTaskSvc<T> {
4134                        type Response = super::ReportCompactionTaskResponse;
4135                        type Future = BoxFuture<
4136                            tonic::Response<Self::Response>,
4137                            tonic::Status,
4138                        >;
4139                        fn call(
4140                            &mut self,
4141                            request: tonic::Request<super::ReportCompactionTaskRequest>,
4142                        ) -> Self::Future {
4143                            let inner = Arc::clone(&self.0);
4144                            let fut = async move {
4145                                <T as HummockManagerService>::report_compaction_task(
4146                                        &inner,
4147                                        request,
4148                                    )
4149                                    .await
4150                            };
4151                            Box::pin(fut)
4152                        }
4153                    }
4154                    let accept_compression_encodings = self.accept_compression_encodings;
4155                    let send_compression_encodings = self.send_compression_encodings;
4156                    let max_decoding_message_size = self.max_decoding_message_size;
4157                    let max_encoding_message_size = self.max_encoding_message_size;
4158                    let inner = self.inner.clone();
4159                    let fut = async move {
4160                        let method = ReportCompactionTaskSvc(inner);
4161                        let codec = tonic::codec::ProstCodec::default();
4162                        let mut grpc = tonic::server::Grpc::new(codec)
4163                            .apply_compression_config(
4164                                accept_compression_encodings,
4165                                send_compression_encodings,
4166                            )
4167                            .apply_max_message_size_config(
4168                                max_decoding_message_size,
4169                                max_encoding_message_size,
4170                            );
4171                        let res = grpc.unary(method, req).await;
4172                        Ok(res)
4173                    };
4174                    Box::pin(fut)
4175                }
4176                "/hummock.HummockManagerService/ListBranchedObject" => {
4177                    #[allow(non_camel_case_types)]
4178                    struct ListBranchedObjectSvc<T: HummockManagerService>(pub Arc<T>);
4179                    impl<
4180                        T: HummockManagerService,
4181                    > tonic::server::UnaryService<super::ListBranchedObjectRequest>
4182                    for ListBranchedObjectSvc<T> {
4183                        type Response = super::ListBranchedObjectResponse;
4184                        type Future = BoxFuture<
4185                            tonic::Response<Self::Response>,
4186                            tonic::Status,
4187                        >;
4188                        fn call(
4189                            &mut self,
4190                            request: tonic::Request<super::ListBranchedObjectRequest>,
4191                        ) -> Self::Future {
4192                            let inner = Arc::clone(&self.0);
4193                            let fut = async move {
4194                                <T as HummockManagerService>::list_branched_object(
4195                                        &inner,
4196                                        request,
4197                                    )
4198                                    .await
4199                            };
4200                            Box::pin(fut)
4201                        }
4202                    }
4203                    let accept_compression_encodings = self.accept_compression_encodings;
4204                    let send_compression_encodings = self.send_compression_encodings;
4205                    let max_decoding_message_size = self.max_decoding_message_size;
4206                    let max_encoding_message_size = self.max_encoding_message_size;
4207                    let inner = self.inner.clone();
4208                    let fut = async move {
4209                        let method = ListBranchedObjectSvc(inner);
4210                        let codec = tonic::codec::ProstCodec::default();
4211                        let mut grpc = tonic::server::Grpc::new(codec)
4212                            .apply_compression_config(
4213                                accept_compression_encodings,
4214                                send_compression_encodings,
4215                            )
4216                            .apply_max_message_size_config(
4217                                max_decoding_message_size,
4218                                max_encoding_message_size,
4219                            );
4220                        let res = grpc.unary(method, req).await;
4221                        Ok(res)
4222                    };
4223                    Box::pin(fut)
4224                }
4225                "/hummock.HummockManagerService/ListActiveWriteLimit" => {
4226                    #[allow(non_camel_case_types)]
4227                    struct ListActiveWriteLimitSvc<T: HummockManagerService>(pub Arc<T>);
4228                    impl<
4229                        T: HummockManagerService,
4230                    > tonic::server::UnaryService<super::ListActiveWriteLimitRequest>
4231                    for ListActiveWriteLimitSvc<T> {
4232                        type Response = super::ListActiveWriteLimitResponse;
4233                        type Future = BoxFuture<
4234                            tonic::Response<Self::Response>,
4235                            tonic::Status,
4236                        >;
4237                        fn call(
4238                            &mut self,
4239                            request: tonic::Request<super::ListActiveWriteLimitRequest>,
4240                        ) -> Self::Future {
4241                            let inner = Arc::clone(&self.0);
4242                            let fut = async move {
4243                                <T as HummockManagerService>::list_active_write_limit(
4244                                        &inner,
4245                                        request,
4246                                    )
4247                                    .await
4248                            };
4249                            Box::pin(fut)
4250                        }
4251                    }
4252                    let accept_compression_encodings = self.accept_compression_encodings;
4253                    let send_compression_encodings = self.send_compression_encodings;
4254                    let max_decoding_message_size = self.max_decoding_message_size;
4255                    let max_encoding_message_size = self.max_encoding_message_size;
4256                    let inner = self.inner.clone();
4257                    let fut = async move {
4258                        let method = ListActiveWriteLimitSvc(inner);
4259                        let codec = tonic::codec::ProstCodec::default();
4260                        let mut grpc = tonic::server::Grpc::new(codec)
4261                            .apply_compression_config(
4262                                accept_compression_encodings,
4263                                send_compression_encodings,
4264                            )
4265                            .apply_max_message_size_config(
4266                                max_decoding_message_size,
4267                                max_encoding_message_size,
4268                            );
4269                        let res = grpc.unary(method, req).await;
4270                        Ok(res)
4271                    };
4272                    Box::pin(fut)
4273                }
4274                "/hummock.HummockManagerService/ListHummockMetaConfig" => {
4275                    #[allow(non_camel_case_types)]
4276                    struct ListHummockMetaConfigSvc<T: HummockManagerService>(
4277                        pub Arc<T>,
4278                    );
4279                    impl<
4280                        T: HummockManagerService,
4281                    > tonic::server::UnaryService<super::ListHummockMetaConfigRequest>
4282                    for ListHummockMetaConfigSvc<T> {
4283                        type Response = super::ListHummockMetaConfigResponse;
4284                        type Future = BoxFuture<
4285                            tonic::Response<Self::Response>,
4286                            tonic::Status,
4287                        >;
4288                        fn call(
4289                            &mut self,
4290                            request: tonic::Request<super::ListHummockMetaConfigRequest>,
4291                        ) -> Self::Future {
4292                            let inner = Arc::clone(&self.0);
4293                            let fut = async move {
4294                                <T as HummockManagerService>::list_hummock_meta_config(
4295                                        &inner,
4296                                        request,
4297                                    )
4298                                    .await
4299                            };
4300                            Box::pin(fut)
4301                        }
4302                    }
4303                    let accept_compression_encodings = self.accept_compression_encodings;
4304                    let send_compression_encodings = self.send_compression_encodings;
4305                    let max_decoding_message_size = self.max_decoding_message_size;
4306                    let max_encoding_message_size = self.max_encoding_message_size;
4307                    let inner = self.inner.clone();
4308                    let fut = async move {
4309                        let method = ListHummockMetaConfigSvc(inner);
4310                        let codec = tonic::codec::ProstCodec::default();
4311                        let mut grpc = tonic::server::Grpc::new(codec)
4312                            .apply_compression_config(
4313                                accept_compression_encodings,
4314                                send_compression_encodings,
4315                            )
4316                            .apply_max_message_size_config(
4317                                max_decoding_message_size,
4318                                max_encoding_message_size,
4319                            );
4320                        let res = grpc.unary(method, req).await;
4321                        Ok(res)
4322                    };
4323                    Box::pin(fut)
4324                }
4325                "/hummock.HummockManagerService/GetCompactionScore" => {
4326                    #[allow(non_camel_case_types)]
4327                    struct GetCompactionScoreSvc<T: HummockManagerService>(pub Arc<T>);
4328                    impl<
4329                        T: HummockManagerService,
4330                    > tonic::server::UnaryService<super::GetCompactionScoreRequest>
4331                    for GetCompactionScoreSvc<T> {
4332                        type Response = super::GetCompactionScoreResponse;
4333                        type Future = BoxFuture<
4334                            tonic::Response<Self::Response>,
4335                            tonic::Status,
4336                        >;
4337                        fn call(
4338                            &mut self,
4339                            request: tonic::Request<super::GetCompactionScoreRequest>,
4340                        ) -> Self::Future {
4341                            let inner = Arc::clone(&self.0);
4342                            let fut = async move {
4343                                <T as HummockManagerService>::get_compaction_score(
4344                                        &inner,
4345                                        request,
4346                                    )
4347                                    .await
4348                            };
4349                            Box::pin(fut)
4350                        }
4351                    }
4352                    let accept_compression_encodings = self.accept_compression_encodings;
4353                    let send_compression_encodings = self.send_compression_encodings;
4354                    let max_decoding_message_size = self.max_decoding_message_size;
4355                    let max_encoding_message_size = self.max_encoding_message_size;
4356                    let inner = self.inner.clone();
4357                    let fut = async move {
4358                        let method = GetCompactionScoreSvc(inner);
4359                        let codec = tonic::codec::ProstCodec::default();
4360                        let mut grpc = tonic::server::Grpc::new(codec)
4361                            .apply_compression_config(
4362                                accept_compression_encodings,
4363                                send_compression_encodings,
4364                            )
4365                            .apply_max_message_size_config(
4366                                max_decoding_message_size,
4367                                max_encoding_message_size,
4368                            );
4369                        let res = grpc.unary(method, req).await;
4370                        Ok(res)
4371                    };
4372                    Box::pin(fut)
4373                }
4374                "/hummock.HummockManagerService/ListCompactTaskAssignment" => {
4375                    #[allow(non_camel_case_types)]
4376                    struct ListCompactTaskAssignmentSvc<T: HummockManagerService>(
4377                        pub Arc<T>,
4378                    );
4379                    impl<
4380                        T: HummockManagerService,
4381                    > tonic::server::UnaryService<
4382                        super::ListCompactTaskAssignmentRequest,
4383                    > for ListCompactTaskAssignmentSvc<T> {
4384                        type Response = super::ListCompactTaskAssignmentResponse;
4385                        type Future = BoxFuture<
4386                            tonic::Response<Self::Response>,
4387                            tonic::Status,
4388                        >;
4389                        fn call(
4390                            &mut self,
4391                            request: tonic::Request<
4392                                super::ListCompactTaskAssignmentRequest,
4393                            >,
4394                        ) -> Self::Future {
4395                            let inner = Arc::clone(&self.0);
4396                            let fut = async move {
4397                                <T as HummockManagerService>::list_compact_task_assignment(
4398                                        &inner,
4399                                        request,
4400                                    )
4401                                    .await
4402                            };
4403                            Box::pin(fut)
4404                        }
4405                    }
4406                    let accept_compression_encodings = self.accept_compression_encodings;
4407                    let send_compression_encodings = self.send_compression_encodings;
4408                    let max_decoding_message_size = self.max_decoding_message_size;
4409                    let max_encoding_message_size = self.max_encoding_message_size;
4410                    let inner = self.inner.clone();
4411                    let fut = async move {
4412                        let method = ListCompactTaskAssignmentSvc(inner);
4413                        let codec = tonic::codec::ProstCodec::default();
4414                        let mut grpc = tonic::server::Grpc::new(codec)
4415                            .apply_compression_config(
4416                                accept_compression_encodings,
4417                                send_compression_encodings,
4418                            )
4419                            .apply_max_message_size_config(
4420                                max_decoding_message_size,
4421                                max_encoding_message_size,
4422                            );
4423                        let res = grpc.unary(method, req).await;
4424                        Ok(res)
4425                    };
4426                    Box::pin(fut)
4427                }
4428                "/hummock.HummockManagerService/ListCompactTaskProgress" => {
4429                    #[allow(non_camel_case_types)]
4430                    struct ListCompactTaskProgressSvc<T: HummockManagerService>(
4431                        pub Arc<T>,
4432                    );
4433                    impl<
4434                        T: HummockManagerService,
4435                    > tonic::server::UnaryService<super::ListCompactTaskProgressRequest>
4436                    for ListCompactTaskProgressSvc<T> {
4437                        type Response = super::ListCompactTaskProgressResponse;
4438                        type Future = BoxFuture<
4439                            tonic::Response<Self::Response>,
4440                            tonic::Status,
4441                        >;
4442                        fn call(
4443                            &mut self,
4444                            request: tonic::Request<
4445                                super::ListCompactTaskProgressRequest,
4446                            >,
4447                        ) -> Self::Future {
4448                            let inner = Arc::clone(&self.0);
4449                            let fut = async move {
4450                                <T as HummockManagerService>::list_compact_task_progress(
4451                                        &inner,
4452                                        request,
4453                                    )
4454                                    .await
4455                            };
4456                            Box::pin(fut)
4457                        }
4458                    }
4459                    let accept_compression_encodings = self.accept_compression_encodings;
4460                    let send_compression_encodings = self.send_compression_encodings;
4461                    let max_decoding_message_size = self.max_decoding_message_size;
4462                    let max_encoding_message_size = self.max_encoding_message_size;
4463                    let inner = self.inner.clone();
4464                    let fut = async move {
4465                        let method = ListCompactTaskProgressSvc(inner);
4466                        let codec = tonic::codec::ProstCodec::default();
4467                        let mut grpc = tonic::server::Grpc::new(codec)
4468                            .apply_compression_config(
4469                                accept_compression_encodings,
4470                                send_compression_encodings,
4471                            )
4472                            .apply_max_message_size_config(
4473                                max_decoding_message_size,
4474                                max_encoding_message_size,
4475                            );
4476                        let res = grpc.unary(method, req).await;
4477                        Ok(res)
4478                    };
4479                    Box::pin(fut)
4480                }
4481                "/hummock.HummockManagerService/CancelCompactTask" => {
4482                    #[allow(non_camel_case_types)]
4483                    struct CancelCompactTaskSvc<T: HummockManagerService>(pub Arc<T>);
4484                    impl<
4485                        T: HummockManagerService,
4486                    > tonic::server::UnaryService<super::CancelCompactTaskRequest>
4487                    for CancelCompactTaskSvc<T> {
4488                        type Response = super::CancelCompactTaskResponse;
4489                        type Future = BoxFuture<
4490                            tonic::Response<Self::Response>,
4491                            tonic::Status,
4492                        >;
4493                        fn call(
4494                            &mut self,
4495                            request: tonic::Request<super::CancelCompactTaskRequest>,
4496                        ) -> Self::Future {
4497                            let inner = Arc::clone(&self.0);
4498                            let fut = async move {
4499                                <T as HummockManagerService>::cancel_compact_task(
4500                                        &inner,
4501                                        request,
4502                                    )
4503                                    .await
4504                            };
4505                            Box::pin(fut)
4506                        }
4507                    }
4508                    let accept_compression_encodings = self.accept_compression_encodings;
4509                    let send_compression_encodings = self.send_compression_encodings;
4510                    let max_decoding_message_size = self.max_decoding_message_size;
4511                    let max_encoding_message_size = self.max_encoding_message_size;
4512                    let inner = self.inner.clone();
4513                    let fut = async move {
4514                        let method = CancelCompactTaskSvc(inner);
4515                        let codec = tonic::codec::ProstCodec::default();
4516                        let mut grpc = tonic::server::Grpc::new(codec)
4517                            .apply_compression_config(
4518                                accept_compression_encodings,
4519                                send_compression_encodings,
4520                            )
4521                            .apply_max_message_size_config(
4522                                max_decoding_message_size,
4523                                max_encoding_message_size,
4524                            );
4525                        let res = grpc.unary(method, req).await;
4526                        Ok(res)
4527                    };
4528                    Box::pin(fut)
4529                }
4530                "/hummock.HummockManagerService/GetVersionByEpoch" => {
4531                    #[allow(non_camel_case_types)]
4532                    struct GetVersionByEpochSvc<T: HummockManagerService>(pub Arc<T>);
4533                    impl<
4534                        T: HummockManagerService,
4535                    > tonic::server::UnaryService<super::GetVersionByEpochRequest>
4536                    for GetVersionByEpochSvc<T> {
4537                        type Response = super::GetVersionByEpochResponse;
4538                        type Future = BoxFuture<
4539                            tonic::Response<Self::Response>,
4540                            tonic::Status,
4541                        >;
4542                        fn call(
4543                            &mut self,
4544                            request: tonic::Request<super::GetVersionByEpochRequest>,
4545                        ) -> Self::Future {
4546                            let inner = Arc::clone(&self.0);
4547                            let fut = async move {
4548                                <T as HummockManagerService>::get_version_by_epoch(
4549                                        &inner,
4550                                        request,
4551                                    )
4552                                    .await
4553                            };
4554                            Box::pin(fut)
4555                        }
4556                    }
4557                    let accept_compression_encodings = self.accept_compression_encodings;
4558                    let send_compression_encodings = self.send_compression_encodings;
4559                    let max_decoding_message_size = self.max_decoding_message_size;
4560                    let max_encoding_message_size = self.max_encoding_message_size;
4561                    let inner = self.inner.clone();
4562                    let fut = async move {
4563                        let method = GetVersionByEpochSvc(inner);
4564                        let codec = tonic::codec::ProstCodec::default();
4565                        let mut grpc = tonic::server::Grpc::new(codec)
4566                            .apply_compression_config(
4567                                accept_compression_encodings,
4568                                send_compression_encodings,
4569                            )
4570                            .apply_max_message_size_config(
4571                                max_decoding_message_size,
4572                                max_encoding_message_size,
4573                            );
4574                        let res = grpc.unary(method, req).await;
4575                        Ok(res)
4576                    };
4577                    Box::pin(fut)
4578                }
4579                "/hummock.HummockManagerService/MergeCompactionGroup" => {
4580                    #[allow(non_camel_case_types)]
4581                    struct MergeCompactionGroupSvc<T: HummockManagerService>(pub Arc<T>);
4582                    impl<
4583                        T: HummockManagerService,
4584                    > tonic::server::UnaryService<super::MergeCompactionGroupRequest>
4585                    for MergeCompactionGroupSvc<T> {
4586                        type Response = super::MergeCompactionGroupResponse;
4587                        type Future = BoxFuture<
4588                            tonic::Response<Self::Response>,
4589                            tonic::Status,
4590                        >;
4591                        fn call(
4592                            &mut self,
4593                            request: tonic::Request<super::MergeCompactionGroupRequest>,
4594                        ) -> Self::Future {
4595                            let inner = Arc::clone(&self.0);
4596                            let fut = async move {
4597                                <T as HummockManagerService>::merge_compaction_group(
4598                                        &inner,
4599                                        request,
4600                                    )
4601                                    .await
4602                            };
4603                            Box::pin(fut)
4604                        }
4605                    }
4606                    let accept_compression_encodings = self.accept_compression_encodings;
4607                    let send_compression_encodings = self.send_compression_encodings;
4608                    let max_decoding_message_size = self.max_decoding_message_size;
4609                    let max_encoding_message_size = self.max_encoding_message_size;
4610                    let inner = self.inner.clone();
4611                    let fut = async move {
4612                        let method = MergeCompactionGroupSvc(inner);
4613                        let codec = tonic::codec::ProstCodec::default();
4614                        let mut grpc = tonic::server::Grpc::new(codec)
4615                            .apply_compression_config(
4616                                accept_compression_encodings,
4617                                send_compression_encodings,
4618                            )
4619                            .apply_max_message_size_config(
4620                                max_decoding_message_size,
4621                                max_encoding_message_size,
4622                            );
4623                        let res = grpc.unary(method, req).await;
4624                        Ok(res)
4625                    };
4626                    Box::pin(fut)
4627                }
4628                _ => {
4629                    Box::pin(async move {
4630                        let mut response = http::Response::new(empty_body());
4631                        let headers = response.headers_mut();
4632                        headers
4633                            .insert(
4634                                tonic::Status::GRPC_STATUS,
4635                                (tonic::Code::Unimplemented as i32).into(),
4636                            );
4637                        headers
4638                            .insert(
4639                                http::header::CONTENT_TYPE,
4640                                tonic::metadata::GRPC_CONTENT_TYPE,
4641                            );
4642                        Ok(response)
4643                    })
4644                }
4645            }
4646        }
4647    }
4648    impl<T> Clone for HummockManagerServiceServer<T> {
4649        fn clone(&self) -> Self {
4650            let inner = self.inner.clone();
4651            Self {
4652                inner,
4653                accept_compression_encodings: self.accept_compression_encodings,
4654                send_compression_encodings: self.send_compression_encodings,
4655                max_decoding_message_size: self.max_decoding_message_size,
4656                max_encoding_message_size: self.max_encoding_message_size,
4657            }
4658        }
4659    }
4660    /// Generated gRPC service name
4661    pub const SERVICE_NAME: &str = "hummock.HummockManagerService";
4662    impl<T> tonic::server::NamedService for HummockManagerServiceServer<T> {
4663        const NAME: &'static str = SERVICE_NAME;
4664    }
4665}