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