1#[derive(prost_helpers::AnyPB)]
3#[derive(Clone, Copy, PartialEq, ::prost::Message)]
4pub struct GetTelemetryInfoRequest {}
5#[derive(prost_helpers::AnyPB)]
6#[derive(Clone, PartialEq, ::prost::Message)]
7pub struct TelemetryInfoResponse {
8 #[prost(string, optional, tag = "1")]
9 pub tracking_id: ::core::option::Option<::prost::alloc::string::String>,
10}
11#[derive(prost_helpers::AnyPB)]
12#[derive(Clone, Copy, PartialEq, ::prost::Message)]
13pub struct HeartbeatRequest {
14 #[prost(uint32, tag = "1")]
15 pub node_id: u32,
16}
17#[derive(prost_helpers::AnyPB)]
18#[derive(Clone, PartialEq, ::prost::Message)]
19pub struct HeartbeatResponse {
20 #[prost(message, optional, tag = "1")]
21 pub status: ::core::option::Option<super::common::Status>,
22}
23#[derive(prost_helpers::AnyPB)]
27#[derive(Clone, PartialEq, ::prost::Message)]
28pub struct TableFragments {
29 #[prost(uint32, tag = "1")]
31 pub table_id: u32,
32 #[prost(enumeration = "table_fragments::State", tag = "2")]
33 pub state: i32,
34 #[prost(map = "uint32, message", tag = "3")]
35 pub fragments: ::std::collections::HashMap<u32, table_fragments::Fragment>,
36 #[prost(map = "uint32, message", tag = "4")]
37 pub actor_status: ::std::collections::HashMap<u32, table_fragments::ActorStatus>,
38 #[prost(map = "uint32, message", tag = "5")]
40 pub actor_splits: ::std::collections::HashMap<u32, super::source::ConnectorSplits>,
41 #[prost(message, optional, tag = "6")]
42 pub ctx: ::core::option::Option<super::stream_plan::StreamContext>,
43 #[prost(message, optional, tag = "7")]
44 pub parallelism: ::core::option::Option<TableParallelism>,
45 #[prost(uint32, optional, tag = "10")]
59 pub max_parallelism: ::core::option::Option<u32>,
60 #[prost(string, tag = "8")]
62 pub node_label: ::prost::alloc::string::String,
63 #[prost(bool, tag = "9")]
66 pub backfill_done: bool,
67}
68pub mod table_fragments {
70 #[derive(prost_helpers::AnyPB)]
72 #[derive(Clone, Copy, PartialEq, ::prost::Message)]
73 pub struct ActorStatus {
74 #[prost(message, optional, tag = "1")]
76 pub location: ::core::option::Option<super::super::common::ActorLocation>,
77 #[prost(enumeration = "actor_status::ActorState", tag = "2")]
79 pub state: i32,
80 }
81 pub mod actor_status {
83 #[derive(prost_helpers::AnyPB)]
85 #[derive(
86 Clone,
87 Copy,
88 Debug,
89 PartialEq,
90 Eq,
91 Hash,
92 PartialOrd,
93 Ord,
94 ::prost::Enumeration
95 )]
96 #[repr(i32)]
97 pub enum ActorState {
98 Unspecified = 0,
99 Inactive = 1,
101 Running = 2,
103 }
104 impl ActorState {
105 pub fn as_str_name(&self) -> &'static str {
110 match self {
111 Self::Unspecified => "UNSPECIFIED",
112 Self::Inactive => "INACTIVE",
113 Self::Running => "RUNNING",
114 }
115 }
116 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
118 match value {
119 "UNSPECIFIED" => Some(Self::Unspecified),
120 "INACTIVE" => Some(Self::Inactive),
121 "RUNNING" => Some(Self::Running),
122 _ => None,
123 }
124 }
125 }
126 }
127 #[derive(prost_helpers::AnyPB)]
128 #[derive(Clone, PartialEq, ::prost::Message)]
129 pub struct Fragment {
130 #[prost(uint32, tag = "1")]
131 pub fragment_id: u32,
132 #[prost(uint32, tag = "2")]
134 pub fragment_type_mask: u32,
135 #[prost(enumeration = "fragment::FragmentDistributionType", tag = "3")]
136 pub distribution_type: i32,
137 #[prost(message, repeated, tag = "4")]
138 pub actors: ::prost::alloc::vec::Vec<super::super::stream_plan::StreamActor>,
139 #[prost(uint32, repeated, tag = "6")]
140 pub state_table_ids: ::prost::alloc::vec::Vec<u32>,
141 #[prost(uint32, repeated, tag = "7")]
146 pub upstream_fragment_ids: ::prost::alloc::vec::Vec<u32>,
147 #[prost(uint32, optional, tag = "8")]
154 pub maybe_vnode_count: ::core::option::Option<u32>,
155 #[prost(message, optional, tag = "9")]
156 pub nodes: ::core::option::Option<super::super::stream_plan::StreamNode>,
157 }
158 pub mod fragment {
160 #[derive(prost_helpers::AnyPB)]
161 #[derive(
162 Clone,
163 Copy,
164 Debug,
165 PartialEq,
166 Eq,
167 Hash,
168 PartialOrd,
169 Ord,
170 ::prost::Enumeration
171 )]
172 #[repr(i32)]
173 pub enum FragmentDistributionType {
174 Unspecified = 0,
175 Single = 1,
176 Hash = 2,
177 }
178 impl FragmentDistributionType {
179 pub fn as_str_name(&self) -> &'static str {
184 match self {
185 Self::Unspecified => "UNSPECIFIED",
186 Self::Single => "SINGLE",
187 Self::Hash => "HASH",
188 }
189 }
190 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
192 match value {
193 "UNSPECIFIED" => Some(Self::Unspecified),
194 "SINGLE" => Some(Self::Single),
195 "HASH" => Some(Self::Hash),
196 _ => None,
197 }
198 }
199 }
200 }
201 #[derive(prost_helpers::AnyPB)]
203 #[derive(
204 Clone,
205 Copy,
206 Debug,
207 PartialEq,
208 Eq,
209 Hash,
210 PartialOrd,
211 Ord,
212 ::prost::Enumeration
213 )]
214 #[repr(i32)]
215 pub enum State {
216 Unspecified = 0,
217 Initial = 1,
219 Creating = 2,
221 Created = 3,
223 }
224 impl State {
225 pub fn as_str_name(&self) -> &'static str {
230 match self {
231 Self::Unspecified => "UNSPECIFIED",
232 Self::Initial => "INITIAL",
233 Self::Creating => "CREATING",
234 Self::Created => "CREATED",
235 }
236 }
237 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
239 match value {
240 "UNSPECIFIED" => Some(Self::Unspecified),
241 "INITIAL" => Some(Self::Initial),
242 "CREATING" => Some(Self::Creating),
243 "CREATED" => Some(Self::Created),
244 _ => None,
245 }
246 }
247 }
248}
249#[derive(prost_helpers::AnyPB)]
251#[derive(Clone, PartialEq, ::prost::Message)]
252pub struct FragmentWorkerSlotMapping {
253 #[prost(uint32, tag = "1")]
254 pub fragment_id: u32,
255 #[prost(message, optional, tag = "2")]
256 pub mapping: ::core::option::Option<super::common::WorkerSlotMapping>,
257}
258#[derive(prost_helpers::AnyPB)]
259#[derive(Clone, PartialEq, ::prost::Message)]
260pub struct FragmentWorkerSlotMappings {
261 #[prost(message, repeated, tag = "1")]
262 pub mappings: ::prost::alloc::vec::Vec<FragmentWorkerSlotMapping>,
263}
264#[derive(prost_helpers::AnyPB)]
266#[derive(Clone, PartialEq, ::prost::Message)]
267pub struct ActorLocation {
268 #[prost(message, optional, tag = "1")]
269 pub node: ::core::option::Option<super::common::WorkerNode>,
270 #[prost(message, repeated, tag = "2")]
271 pub actors: ::prost::alloc::vec::Vec<super::stream_plan::StreamActor>,
272}
273#[derive(prost_helpers::AnyPB)]
274#[derive(Clone, PartialEq, ::prost::Message)]
275pub struct MigrationPlan {
276 #[prost(map = "uint64, uint64", tag = "2")]
278 pub worker_slot_migration_plan: ::std::collections::HashMap<u64, u64>,
279}
280#[derive(prost_helpers::AnyPB)]
281#[derive(Clone, Copy, PartialEq, ::prost::Message)]
282pub struct FlushRequest {
283 #[prost(uint32, tag = "1")]
284 pub database_id: u32,
285}
286#[derive(prost_helpers::AnyPB)]
287#[derive(Clone, PartialEq, ::prost::Message)]
288pub struct FlushResponse {
289 #[prost(message, optional, tag = "1")]
290 pub status: ::core::option::Option<super::common::Status>,
291 #[prost(uint64, tag = "2")]
292 pub hummock_version_id: u64,
293}
294#[derive(prost_helpers::AnyPB)]
295#[derive(Clone, Copy, PartialEq, ::prost::Message)]
296pub struct PauseRequest {}
297#[derive(prost_helpers::AnyPB)]
298#[derive(Clone, Copy, PartialEq, ::prost::Message)]
299pub struct PauseResponse {}
300#[derive(prost_helpers::AnyPB)]
301#[derive(Clone, Copy, PartialEq, ::prost::Message)]
302pub struct ResumeRequest {}
303#[derive(prost_helpers::AnyPB)]
304#[derive(Clone, Copy, PartialEq, ::prost::Message)]
305pub struct ResumeResponse {}
306#[derive(prost_helpers::AnyPB)]
307#[derive(Clone, PartialEq, ::prost::Message)]
308pub struct CancelCreatingJobsRequest {
309 #[prost(oneof = "cancel_creating_jobs_request::Jobs", tags = "1, 2")]
310 pub jobs: ::core::option::Option<cancel_creating_jobs_request::Jobs>,
311}
312pub mod cancel_creating_jobs_request {
314 #[derive(prost_helpers::AnyPB)]
315 #[derive(Clone, PartialEq, ::prost::Message)]
316 pub struct CreatingJobInfo {
317 #[prost(uint32, tag = "1")]
318 pub database_id: u32,
319 #[prost(uint32, tag = "2")]
320 pub schema_id: u32,
321 #[prost(string, tag = "3")]
322 pub name: ::prost::alloc::string::String,
323 }
324 #[derive(prost_helpers::AnyPB)]
325 #[derive(Clone, PartialEq, ::prost::Message)]
326 pub struct CreatingJobInfos {
327 #[prost(message, repeated, tag = "1")]
328 pub infos: ::prost::alloc::vec::Vec<CreatingJobInfo>,
329 }
330 #[derive(prost_helpers::AnyPB)]
331 #[derive(Clone, PartialEq, ::prost::Message)]
332 pub struct CreatingJobIds {
333 #[prost(uint32, repeated, tag = "1")]
334 pub job_ids: ::prost::alloc::vec::Vec<u32>,
335 }
336 #[derive(prost_helpers::AnyPB)]
337 #[derive(Clone, PartialEq, ::prost::Oneof)]
338 pub enum Jobs {
339 #[prost(message, tag = "1")]
340 Infos(CreatingJobInfos),
341 #[prost(message, tag = "2")]
342 Ids(CreatingJobIds),
343 }
344}
345#[derive(prost_helpers::AnyPB)]
346#[derive(Clone, PartialEq, ::prost::Message)]
347pub struct CancelCreatingJobsResponse {
348 #[prost(message, optional, tag = "1")]
349 pub status: ::core::option::Option<super::common::Status>,
350 #[prost(uint32, repeated, tag = "2")]
351 pub canceled_jobs: ::prost::alloc::vec::Vec<u32>,
352}
353#[derive(prost_helpers::AnyPB)]
354#[derive(Clone, PartialEq, ::prost::Message)]
355pub struct ListTableFragmentsRequest {
356 #[prost(uint32, repeated, tag = "1")]
357 pub table_ids: ::prost::alloc::vec::Vec<u32>,
358}
359#[derive(prost_helpers::AnyPB)]
360#[derive(Clone, PartialEq, ::prost::Message)]
361pub struct ListTableFragmentsResponse {
362 #[prost(map = "uint32, message", tag = "1")]
363 pub table_fragments: ::std::collections::HashMap<
364 u32,
365 list_table_fragments_response::TableFragmentInfo,
366 >,
367}
368pub mod list_table_fragments_response {
370 #[derive(prost_helpers::AnyPB)]
371 #[derive(Clone, PartialEq, ::prost::Message)]
372 pub struct ActorInfo {
373 #[prost(uint32, tag = "1")]
374 pub id: u32,
375 #[prost(message, optional, tag = "2")]
376 pub node: ::core::option::Option<super::super::stream_plan::StreamNode>,
377 #[prost(message, repeated, tag = "3")]
378 pub dispatcher: ::prost::alloc::vec::Vec<super::super::stream_plan::Dispatcher>,
379 }
380 #[derive(prost_helpers::AnyPB)]
381 #[derive(Clone, PartialEq, ::prost::Message)]
382 pub struct FragmentInfo {
383 #[prost(uint32, tag = "1")]
384 pub id: u32,
385 #[prost(message, repeated, tag = "4")]
386 pub actors: ::prost::alloc::vec::Vec<ActorInfo>,
387 }
388 #[derive(prost_helpers::AnyPB)]
389 #[derive(Clone, PartialEq, ::prost::Message)]
390 pub struct TableFragmentInfo {
391 #[prost(message, repeated, tag = "1")]
392 pub fragments: ::prost::alloc::vec::Vec<FragmentInfo>,
393 #[prost(message, optional, tag = "2")]
394 pub ctx: ::core::option::Option<super::super::stream_plan::StreamContext>,
395 }
396}
397#[derive(prost_helpers::AnyPB)]
398#[derive(Clone, Copy, PartialEq, ::prost::Message)]
399pub struct GetFragmentByIdRequest {
400 #[prost(uint32, tag = "1")]
401 pub fragment_id: u32,
402}
403#[derive(prost_helpers::AnyPB)]
404#[derive(Clone, PartialEq, ::prost::Message)]
405pub struct GetFragmentByIdResponse {
406 #[prost(message, optional, tag = "1")]
407 pub distribution: ::core::option::Option<FragmentDistribution>,
408}
409#[derive(prost_helpers::AnyPB)]
410#[derive(Clone, Copy, PartialEq, ::prost::Message)]
411pub struct ListStreamingJobStatesRequest {}
412#[derive(prost_helpers::AnyPB)]
413#[derive(Clone, PartialEq, ::prost::Message)]
414pub struct ListStreamingJobStatesResponse {
415 #[prost(message, repeated, tag = "1")]
416 pub states: ::prost::alloc::vec::Vec<
417 list_streaming_job_states_response::StreamingJobState,
418 >,
419}
420pub mod list_streaming_job_states_response {
422 #[derive(prost_helpers::AnyPB)]
423 #[derive(Clone, PartialEq, ::prost::Message)]
424 pub struct StreamingJobState {
425 #[prost(uint32, tag = "1")]
426 pub table_id: u32,
427 #[prost(enumeration = "super::table_fragments::State", tag = "2")]
428 pub state: i32,
429 #[prost(message, optional, tag = "3")]
430 pub parallelism: ::core::option::Option<super::TableParallelism>,
431 #[prost(uint32, tag = "4")]
432 pub max_parallelism: u32,
433 #[prost(string, tag = "5")]
434 pub name: ::prost::alloc::string::String,
435 #[prost(string, tag = "6")]
436 pub resource_group: ::prost::alloc::string::String,
437 #[prost(uint32, tag = "7")]
438 pub database_id: u32,
439 #[prost(uint32, tag = "8")]
440 pub schema_id: u32,
441 }
442}
443#[derive(prost_helpers::AnyPB)]
444#[derive(Clone, Copy, PartialEq, ::prost::Message)]
445pub struct ListFragmentDistributionRequest {}
446#[derive(prost_helpers::AnyPB)]
447#[derive(Clone, PartialEq, ::prost::Message)]
448pub struct FragmentDistribution {
449 #[prost(uint32, tag = "1")]
450 pub fragment_id: u32,
451 #[prost(uint32, tag = "2")]
452 pub table_id: u32,
453 #[prost(
454 enumeration = "table_fragments::fragment::FragmentDistributionType",
455 tag = "3"
456 )]
457 pub distribution_type: i32,
458 #[prost(uint32, repeated, tag = "4")]
459 pub state_table_ids: ::prost::alloc::vec::Vec<u32>,
460 #[prost(uint32, repeated, tag = "5")]
461 pub upstream_fragment_ids: ::prost::alloc::vec::Vec<u32>,
462 #[prost(uint32, tag = "6")]
463 pub fragment_type_mask: u32,
464 #[prost(uint32, tag = "7")]
465 pub parallelism: u32,
466 #[prost(uint32, tag = "8")]
467 pub vnode_count: u32,
468 #[prost(message, optional, tag = "9")]
469 pub node: ::core::option::Option<super::stream_plan::StreamNode>,
470}
471#[derive(prost_helpers::AnyPB)]
472#[derive(Clone, PartialEq, ::prost::Message)]
473pub struct ListFragmentDistributionResponse {
474 #[prost(message, repeated, tag = "1")]
475 pub distributions: ::prost::alloc::vec::Vec<FragmentDistribution>,
476}
477#[derive(prost_helpers::AnyPB)]
480#[derive(Clone, Copy, PartialEq, ::prost::Message)]
481pub struct ListCreatingFragmentDistributionRequest {}
482#[derive(prost_helpers::AnyPB)]
485#[derive(Clone, PartialEq, ::prost::Message)]
486pub struct ListCreatingFragmentDistributionResponse {
487 #[prost(message, repeated, tag = "1")]
488 pub distributions: ::prost::alloc::vec::Vec<FragmentDistribution>,
489}
490#[derive(prost_helpers::AnyPB)]
491#[derive(Clone, Copy, PartialEq, ::prost::Message)]
492pub struct ListActorStatesRequest {}
493#[derive(prost_helpers::AnyPB)]
494#[derive(Clone, PartialEq, ::prost::Message)]
495pub struct ListActorStatesResponse {
496 #[prost(message, repeated, tag = "1")]
497 pub states: ::prost::alloc::vec::Vec<list_actor_states_response::ActorState>,
498}
499pub mod list_actor_states_response {
501 #[derive(prost_helpers::AnyPB)]
502 #[derive(Clone, Copy, PartialEq, ::prost::Message)]
503 pub struct ActorState {
504 #[prost(uint32, tag = "1")]
505 pub actor_id: u32,
506 #[prost(uint32, tag = "2")]
507 pub fragment_id: u32,
508 #[prost(
509 enumeration = "super::table_fragments::actor_status::ActorState",
510 tag = "4"
511 )]
512 pub state: i32,
513 #[prost(uint32, tag = "5")]
514 pub worker_id: u32,
515 }
516}
517#[derive(prost_helpers::AnyPB)]
518#[derive(Clone, Copy, PartialEq, ::prost::Message)]
519pub struct ListActorSplitsRequest {}
520#[derive(prost_helpers::AnyPB)]
521#[derive(Clone, PartialEq, ::prost::Message)]
522pub struct ListActorSplitsResponse {
523 #[prost(message, repeated, tag = "1")]
524 pub actor_splits: ::prost::alloc::vec::Vec<list_actor_splits_response::ActorSplit>,
525}
526pub mod list_actor_splits_response {
528 #[derive(prost_helpers::AnyPB)]
529 #[derive(Clone, PartialEq, ::prost::Message)]
530 pub struct ActorSplit {
531 #[prost(uint32, tag = "1")]
532 pub actor_id: u32,
533 #[prost(uint32, tag = "2")]
534 pub fragment_id: u32,
535 #[prost(uint32, tag = "3")]
536 pub source_id: u32,
537 #[prost(string, tag = "4")]
538 pub split_id: ::prost::alloc::string::String,
539 #[prost(enumeration = "FragmentType", tag = "5")]
540 pub fragment_type: i32,
541 }
542 #[derive(prost_helpers::AnyPB)]
543 #[derive(
544 Clone,
545 Copy,
546 Debug,
547 PartialEq,
548 Eq,
549 Hash,
550 PartialOrd,
551 Ord,
552 ::prost::Enumeration
553 )]
554 #[repr(i32)]
555 pub enum FragmentType {
556 Unspecified = 0,
557 NonSharedSource = 1,
558 SharedSource = 2,
559 SharedSourceBackfill = 3,
560 }
561 impl FragmentType {
562 pub fn as_str_name(&self) -> &'static str {
567 match self {
568 Self::Unspecified => "UNSPECIFIED",
569 Self::NonSharedSource => "NON_SHARED_SOURCE",
570 Self::SharedSource => "SHARED_SOURCE",
571 Self::SharedSourceBackfill => "SHARED_SOURCE_BACKFILL",
572 }
573 }
574 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
576 match value {
577 "UNSPECIFIED" => Some(Self::Unspecified),
578 "NON_SHARED_SOURCE" => Some(Self::NonSharedSource),
579 "SHARED_SOURCE" => Some(Self::SharedSource),
580 "SHARED_SOURCE_BACKFILL" => Some(Self::SharedSourceBackfill),
581 _ => None,
582 }
583 }
584 }
585}
586#[derive(prost_helpers::AnyPB)]
587#[derive(Clone, Copy, PartialEq, ::prost::Message)]
588pub struct ListObjectDependenciesRequest {}
589#[derive(prost_helpers::AnyPB)]
590#[derive(Clone, PartialEq, ::prost::Message)]
591pub struct ListObjectDependenciesResponse {
592 #[prost(message, repeated, tag = "1")]
593 pub dependencies: ::prost::alloc::vec::Vec<
594 list_object_dependencies_response::ObjectDependencies,
595 >,
596}
597pub mod list_object_dependencies_response {
599 #[derive(prost_helpers::AnyPB)]
600 #[derive(Clone, Copy, PartialEq, ::prost::Message)]
601 pub struct ObjectDependencies {
602 #[prost(uint32, tag = "1")]
603 pub object_id: u32,
604 #[prost(uint32, tag = "2")]
605 pub referenced_object_id: u32,
606 }
607}
608#[derive(prost_helpers::AnyPB)]
609#[derive(Clone, Copy, PartialEq, ::prost::Message)]
610pub struct ApplyThrottleRequest {
611 #[prost(enumeration = "ThrottleTarget", tag = "1")]
612 pub kind: i32,
613 #[prost(uint32, tag = "2")]
614 pub id: u32,
615 #[prost(uint32, optional, tag = "3")]
616 pub rate: ::core::option::Option<u32>,
617}
618#[derive(prost_helpers::AnyPB)]
619#[derive(Clone, PartialEq, ::prost::Message)]
620pub struct ApplyThrottleResponse {
621 #[prost(message, optional, tag = "1")]
622 pub status: ::core::option::Option<super::common::Status>,
623}
624#[derive(prost_helpers::AnyPB)]
625#[derive(Clone, Copy, PartialEq, ::prost::Message)]
626pub struct RecoverRequest {}
627#[derive(prost_helpers::AnyPB)]
628#[derive(Clone, Copy, PartialEq, ::prost::Message)]
629pub struct RecoverResponse {}
630#[derive(prost_helpers::AnyPB)]
631#[derive(Clone, PartialEq, ::prost::Message)]
632pub struct AlterConnectorPropsRequest {
633 #[prost(uint32, tag = "1")]
634 pub object_id: u32,
635 #[prost(map = "string, string", tag = "2")]
636 pub changed_props: ::std::collections::HashMap<
637 ::prost::alloc::string::String,
638 ::prost::alloc::string::String,
639 >,
640 #[prost(map = "string, message", tag = "3")]
641 pub changed_secret_refs: ::std::collections::HashMap<
642 ::prost::alloc::string::String,
643 super::secret::SecretRef,
644 >,
645 #[prost(uint32, optional, tag = "4")]
646 pub connector_conn_ref: ::core::option::Option<u32>,
647 #[prost(
648 enumeration = "alter_connector_props_request::AlterConnectorPropsObject",
649 tag = "5"
650 )]
651 pub object_type: i32,
652}
653pub mod alter_connector_props_request {
655 #[derive(prost_helpers::AnyPB)]
656 #[derive(
657 Clone,
658 Copy,
659 Debug,
660 PartialEq,
661 Eq,
662 Hash,
663 PartialOrd,
664 Ord,
665 ::prost::Enumeration
666 )]
667 #[repr(i32)]
668 pub enum AlterConnectorPropsObject {
669 Unspecified = 0,
670 Source = 1,
671 Sink = 2,
672 Connection = 3,
673 }
674 impl AlterConnectorPropsObject {
675 pub fn as_str_name(&self) -> &'static str {
680 match self {
681 Self::Unspecified => "UNSPECIFIED",
682 Self::Source => "SOURCE",
683 Self::Sink => "SINK",
684 Self::Connection => "CONNECTION",
685 }
686 }
687 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
689 match value {
690 "UNSPECIFIED" => Some(Self::Unspecified),
691 "SOURCE" => Some(Self::Source),
692 "SINK" => Some(Self::Sink),
693 "CONNECTION" => Some(Self::Connection),
694 _ => None,
695 }
696 }
697 }
698}
699#[derive(prost_helpers::AnyPB)]
700#[derive(Clone, Copy, PartialEq, ::prost::Message)]
701pub struct AlterConnectorPropsResponse {}
702#[derive(prost_helpers::AnyPB)]
704#[derive(Clone, PartialEq, ::prost::Message)]
705pub struct AddWorkerNodeRequest {
706 #[prost(enumeration = "super::common::WorkerType", tag = "1")]
707 pub worker_type: i32,
708 #[prost(message, optional, tag = "2")]
709 pub host: ::core::option::Option<super::common::HostAddress>,
710 #[prost(message, optional, tag = "5")]
711 pub resource: ::core::option::Option<super::common::worker_node::Resource>,
712 #[prost(message, optional, tag = "6")]
713 pub property: ::core::option::Option<super::common::worker_node::Property>,
714}
715#[derive(prost_helpers::AnyPB)]
716#[derive(Clone, PartialEq, ::prost::Message)]
717pub struct AddWorkerNodeResponse {
718 #[prost(uint32, optional, tag = "2")]
719 pub node_id: ::core::option::Option<u32>,
720 #[prost(string, tag = "4")]
721 pub cluster_id: ::prost::alloc::string::String,
722}
723#[derive(prost_helpers::AnyPB)]
724#[derive(Clone, PartialEq, ::prost::Message)]
725pub struct ActivateWorkerNodeRequest {
726 #[prost(message, optional, tag = "1")]
727 pub host: ::core::option::Option<super::common::HostAddress>,
728 #[prost(uint32, tag = "2")]
729 pub node_id: u32,
730}
731#[derive(prost_helpers::AnyPB)]
732#[derive(Clone, PartialEq, ::prost::Message)]
733pub struct ActivateWorkerNodeResponse {
734 #[prost(message, optional, tag = "1")]
735 pub status: ::core::option::Option<super::common::Status>,
736}
737#[derive(prost_helpers::AnyPB)]
738#[derive(Clone, PartialEq, ::prost::Message)]
739pub struct DeleteWorkerNodeRequest {
740 #[prost(message, optional, tag = "1")]
741 pub host: ::core::option::Option<super::common::HostAddress>,
742}
743#[derive(prost_helpers::AnyPB)]
744#[derive(Clone, PartialEq, ::prost::Message)]
745pub struct DeleteWorkerNodeResponse {
746 #[prost(message, optional, tag = "1")]
747 pub status: ::core::option::Option<super::common::Status>,
748}
749#[derive(prost_helpers::AnyPB)]
751#[derive(Clone, PartialEq, ::prost::Message)]
752pub struct UpdateWorkerNodeSchedulabilityRequest {
753 #[prost(uint32, repeated, tag = "1")]
754 pub worker_ids: ::prost::alloc::vec::Vec<u32>,
755 #[prost(
756 enumeration = "update_worker_node_schedulability_request::Schedulability",
757 tag = "2"
758 )]
759 pub schedulability: i32,
760}
761pub mod update_worker_node_schedulability_request {
763 #[derive(prost_helpers::AnyPB)]
764 #[derive(
765 Clone,
766 Copy,
767 Debug,
768 PartialEq,
769 Eq,
770 Hash,
771 PartialOrd,
772 Ord,
773 ::prost::Enumeration
774 )]
775 #[repr(i32)]
776 pub enum Schedulability {
777 Unspecified = 0,
778 Schedulable = 1,
779 Unschedulable = 2,
780 }
781 impl Schedulability {
782 pub fn as_str_name(&self) -> &'static str {
787 match self {
788 Self::Unspecified => "UNSPECIFIED",
789 Self::Schedulable => "SCHEDULABLE",
790 Self::Unschedulable => "UNSCHEDULABLE",
791 }
792 }
793 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
795 match value {
796 "UNSPECIFIED" => Some(Self::Unspecified),
797 "SCHEDULABLE" => Some(Self::Schedulable),
798 "UNSCHEDULABLE" => Some(Self::Unschedulable),
799 _ => None,
800 }
801 }
802 }
803}
804#[derive(prost_helpers::AnyPB)]
805#[derive(Clone, PartialEq, ::prost::Message)]
806pub struct UpdateWorkerNodeSchedulabilityResponse {
807 #[prost(message, optional, tag = "1")]
808 pub status: ::core::option::Option<super::common::Status>,
809}
810#[derive(prost_helpers::AnyPB)]
811#[derive(Clone, Copy, PartialEq, ::prost::Message)]
812pub struct ListAllNodesRequest {
813 #[prost(enumeration = "super::common::WorkerType", optional, tag = "1")]
814 pub worker_type: ::core::option::Option<i32>,
815 #[prost(bool, tag = "2")]
817 pub include_starting_nodes: bool,
818}
819#[derive(prost_helpers::AnyPB)]
820#[derive(Clone, PartialEq, ::prost::Message)]
821pub struct ListAllNodesResponse {
822 #[prost(message, optional, tag = "1")]
823 pub status: ::core::option::Option<super::common::Status>,
824 #[prost(message, repeated, tag = "2")]
825 pub nodes: ::prost::alloc::vec::Vec<super::common::WorkerNode>,
826}
827#[derive(prost_helpers::AnyPB)]
828#[derive(Clone, Copy, PartialEq, ::prost::Message)]
829pub struct GetClusterRecoveryStatusRequest {}
830#[derive(prost_helpers::AnyPB)]
831#[derive(Clone, Copy, PartialEq, ::prost::Message)]
832pub struct GetClusterRecoveryStatusResponse {
833 #[prost(enumeration = "RecoveryStatus", tag = "1")]
834 pub status: i32,
835}
836#[derive(prost_helpers::AnyPB)]
837#[derive(Clone, Copy, PartialEq, ::prost::Message)]
838pub struct GetMetaStoreInfoRequest {}
839#[derive(prost_helpers::AnyPB)]
840#[derive(Clone, PartialEq, ::prost::Message)]
841pub struct GetMetaStoreInfoResponse {
842 #[prost(string, tag = "1")]
843 pub meta_store_endpoint: ::prost::alloc::string::String,
844}
845#[derive(prost_helpers::AnyPB)]
847#[derive(Clone, PartialEq, ::prost::Message)]
848pub struct SubscribeRequest {
849 #[prost(enumeration = "SubscribeType", tag = "1")]
850 pub subscribe_type: i32,
851 #[prost(message, optional, tag = "2")]
852 pub host: ::core::option::Option<super::common::HostAddress>,
853 #[prost(uint32, tag = "3")]
854 pub worker_id: u32,
855}
856#[derive(prost_helpers::AnyPB)]
857#[derive(Clone, PartialEq, ::prost::Message)]
858pub struct MetaSnapshot {
859 #[prost(message, repeated, tag = "1")]
860 pub databases: ::prost::alloc::vec::Vec<super::catalog::Database>,
861 #[prost(message, repeated, tag = "2")]
862 pub schemas: ::prost::alloc::vec::Vec<super::catalog::Schema>,
863 #[prost(message, repeated, tag = "3")]
864 pub sources: ::prost::alloc::vec::Vec<super::catalog::Source>,
865 #[prost(message, repeated, tag = "4")]
866 pub sinks: ::prost::alloc::vec::Vec<super::catalog::Sink>,
867 #[prost(message, repeated, tag = "5")]
868 pub tables: ::prost::alloc::vec::Vec<super::catalog::Table>,
869 #[prost(message, repeated, tag = "6")]
870 pub indexes: ::prost::alloc::vec::Vec<super::catalog::Index>,
871 #[prost(message, repeated, tag = "7")]
872 pub views: ::prost::alloc::vec::Vec<super::catalog::View>,
873 #[prost(message, repeated, tag = "15")]
874 pub functions: ::prost::alloc::vec::Vec<super::catalog::Function>,
875 #[prost(message, repeated, tag = "17")]
876 pub connections: ::prost::alloc::vec::Vec<super::catalog::Connection>,
877 #[prost(message, repeated, tag = "19")]
878 pub subscriptions: ::prost::alloc::vec::Vec<super::catalog::Subscription>,
879 #[prost(message, repeated, tag = "8")]
880 pub users: ::prost::alloc::vec::Vec<super::user::UserInfo>,
881 #[prost(message, optional, tag = "20")]
882 pub session_params: ::core::option::Option<GetSessionParamsResponse>,
883 #[prost(message, repeated, tag = "23")]
884 pub secrets: ::prost::alloc::vec::Vec<super::catalog::Secret>,
885 #[prost(uint64, tag = "24")]
886 pub compute_node_total_cpu_count: u64,
887 #[prost(message, repeated, tag = "10")]
888 pub nodes: ::prost::alloc::vec::Vec<super::common::WorkerNode>,
889 #[prost(message, optional, tag = "12")]
890 pub hummock_version: ::core::option::Option<super::hummock::HummockVersion>,
891 #[prost(message, optional, tag = "14")]
892 pub meta_backup_manifest_id: ::core::option::Option<
893 super::backup_service::MetaBackupManifestId,
894 >,
895 #[prost(message, optional, tag = "16")]
896 pub hummock_write_limits: ::core::option::Option<super::hummock::WriteLimits>,
897 #[prost(message, repeated, tag = "21")]
899 pub streaming_worker_slot_mappings: ::prost::alloc::vec::Vec<
900 FragmentWorkerSlotMapping,
901 >,
902 #[prost(message, repeated, tag = "22")]
903 pub serving_worker_slot_mappings: ::prost::alloc::vec::Vec<
904 FragmentWorkerSlotMapping,
905 >,
906 #[prost(message, optional, tag = "13")]
907 pub version: ::core::option::Option<meta_snapshot::SnapshotVersion>,
908}
909pub mod meta_snapshot {
911 #[derive(prost_helpers::AnyPB)]
912 #[derive(Clone, Copy, PartialEq, ::prost::Message)]
913 pub struct SnapshotVersion {
914 #[prost(uint64, tag = "1")]
915 pub catalog_version: u64,
916 #[prost(uint64, tag = "3")]
917 pub worker_node_version: u64,
918 #[prost(uint64, tag = "4")]
919 pub streaming_worker_slot_mapping_version: u64,
920 }
921}
922#[derive(prost_helpers::AnyPB)]
923#[derive(Clone, PartialEq, ::prost::Message)]
924pub struct Object {
925 #[prost(oneof = "object::ObjectInfo", tags = "1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11")]
926 pub object_info: ::core::option::Option<object::ObjectInfo>,
927}
928pub mod object {
930 #[derive(prost_helpers::AnyPB)]
931 #[derive(Clone, PartialEq, ::prost::Oneof)]
932 pub enum ObjectInfo {
933 #[prost(message, tag = "1")]
934 Database(super::super::catalog::Database),
935 #[prost(message, tag = "2")]
936 Schema(super::super::catalog::Schema),
937 #[prost(message, tag = "3")]
938 Table(super::super::catalog::Table),
939 #[prost(message, tag = "4")]
940 Index(super::super::catalog::Index),
941 #[prost(message, tag = "5")]
942 Source(super::super::catalog::Source),
943 #[prost(message, tag = "6")]
944 Sink(super::super::catalog::Sink),
945 #[prost(message, tag = "7")]
946 View(super::super::catalog::View),
947 #[prost(message, tag = "8")]
948 Function(super::super::catalog::Function),
949 #[prost(message, tag = "9")]
950 Connection(super::super::catalog::Connection),
951 #[prost(message, tag = "10")]
952 Subscription(super::super::catalog::Subscription),
953 #[prost(message, tag = "11")]
954 Secret(super::super::catalog::Secret),
955 }
956}
957#[derive(prost_helpers::AnyPB)]
958#[derive(Clone, PartialEq, ::prost::Message)]
959pub struct ObjectGroup {
960 #[prost(message, repeated, tag = "1")]
961 pub objects: ::prost::alloc::vec::Vec<Object>,
962}
963#[derive(prost_helpers::AnyPB)]
964#[derive(Clone, Copy, PartialEq, ::prost::Message)]
965pub struct Recovery {}
966#[derive(prost_helpers::AnyPB)]
967#[derive(Clone, PartialEq, ::prost::Message)]
968pub struct SubscribeResponse {
969 #[prost(message, optional, tag = "1")]
970 pub status: ::core::option::Option<super::common::Status>,
971 #[prost(enumeration = "subscribe_response::Operation", tag = "2")]
972 pub operation: i32,
973 #[prost(uint64, tag = "3")]
975 pub version: u64,
976 #[prost(
977 oneof = "subscribe_response::Info",
978 tags = "4, 5, 6, 11, 26, 13, 15, 16, 17, 19, 20, 21, 22, 24, 25, 27, 28, 29, 30"
979 )]
980 pub info: ::core::option::Option<subscribe_response::Info>,
981}
982pub mod subscribe_response {
984 #[derive(prost_helpers::AnyPB)]
985 #[derive(
986 Clone,
987 Copy,
988 Debug,
989 PartialEq,
990 Eq,
991 Hash,
992 PartialOrd,
993 Ord,
994 ::prost::Enumeration
995 )]
996 #[repr(i32)]
997 pub enum Operation {
998 Unspecified = 0,
999 Add = 1,
1000 Delete = 2,
1001 Update = 3,
1002 Snapshot = 4,
1003 }
1004 impl Operation {
1005 pub fn as_str_name(&self) -> &'static str {
1010 match self {
1011 Self::Unspecified => "UNSPECIFIED",
1012 Self::Add => "ADD",
1013 Self::Delete => "DELETE",
1014 Self::Update => "UPDATE",
1015 Self::Snapshot => "SNAPSHOT",
1016 }
1017 }
1018 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1020 match value {
1021 "UNSPECIFIED" => Some(Self::Unspecified),
1022 "ADD" => Some(Self::Add),
1023 "DELETE" => Some(Self::Delete),
1024 "UPDATE" => Some(Self::Update),
1025 "SNAPSHOT" => Some(Self::Snapshot),
1026 _ => None,
1027 }
1028 }
1029 }
1030 #[derive(prost_helpers::AnyPB)]
1031 #[derive(Clone, PartialEq, ::prost::Oneof)]
1032 pub enum Info {
1033 #[prost(message, tag = "4")]
1034 Database(super::super::catalog::Database),
1035 #[prost(message, tag = "5")]
1036 Schema(super::super::catalog::Schema),
1037 #[prost(message, tag = "6")]
1038 Function(super::super::catalog::Function),
1039 #[prost(message, tag = "11")]
1040 User(super::super::user::UserInfo),
1041 #[prost(message, tag = "26")]
1042 SessionParam(super::SetSessionParamRequest),
1043 #[prost(message, tag = "13")]
1044 Node(super::super::common::WorkerNode),
1045 #[prost(message, tag = "15")]
1046 HummockVersionDeltas(super::super::hummock::HummockVersionDeltas),
1047 #[prost(message, tag = "16")]
1048 Snapshot(super::MetaSnapshot),
1049 #[prost(message, tag = "17")]
1050 MetaBackupManifestId(super::super::backup_service::MetaBackupManifestId),
1051 #[prost(message, tag = "19")]
1052 SystemParams(super::SystemParams),
1053 #[prost(message, tag = "20")]
1054 HummockWriteLimits(super::super::hummock::WriteLimits),
1055 #[prost(message, tag = "21")]
1056 ObjectGroup(super::ObjectGroup),
1057 #[prost(message, tag = "22")]
1058 Connection(super::super::catalog::Connection),
1059 #[prost(message, tag = "24")]
1060 HummockStats(super::super::hummock::HummockVersionStats),
1061 #[prost(message, tag = "25")]
1062 Recovery(super::Recovery),
1063 #[prost(message, tag = "27")]
1064 StreamingWorkerSlotMapping(super::FragmentWorkerSlotMapping),
1065 #[prost(message, tag = "28")]
1066 ServingWorkerSlotMappings(super::FragmentWorkerSlotMappings),
1067 #[prost(message, tag = "29")]
1068 Secret(super::super::catalog::Secret),
1069 #[prost(uint64, tag = "30")]
1070 ComputeNodeTotalCpuCount(u64),
1071 }
1072}
1073#[derive(prost_helpers::AnyPB)]
1074#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1075pub struct GetClusterInfoRequest {}
1076#[derive(prost_helpers::AnyPB)]
1077#[derive(Clone, PartialEq, ::prost::Message)]
1078pub struct GetClusterInfoResponse {
1079 #[prost(message, repeated, tag = "1")]
1080 pub worker_nodes: ::prost::alloc::vec::Vec<super::common::WorkerNode>,
1081 #[prost(message, repeated, tag = "2")]
1082 pub table_fragments: ::prost::alloc::vec::Vec<TableFragments>,
1083 #[prost(map = "uint32, message", tag = "3")]
1085 pub actor_splits: ::std::collections::HashMap<u32, super::source::ConnectorSplits>,
1086 #[prost(map = "uint32, message", tag = "4")]
1087 pub source_infos: ::std::collections::HashMap<u32, super::catalog::Source>,
1088 #[prost(uint64, tag = "5")]
1089 pub revision: u64,
1090}
1091#[derive(prost_helpers::AnyPB)]
1094#[derive(Clone, PartialEq, ::prost::Message)]
1095pub struct WorkerReschedule {
1096 #[prost(map = "uint32, int32", tag = "1")]
1098 pub worker_actor_diff: ::std::collections::HashMap<u32, i32>,
1099}
1100#[derive(prost_helpers::AnyPB)]
1101#[derive(Clone, PartialEq, ::prost::Message)]
1102pub struct RescheduleRequest {
1103 #[prost(uint64, tag = "2")]
1104 pub revision: u64,
1105 #[prost(bool, tag = "3")]
1106 pub resolve_no_shuffle_upstream: bool,
1107 #[prost(map = "uint32, message", tag = "4")]
1108 pub worker_reschedules: ::std::collections::HashMap<u32, WorkerReschedule>,
1109}
1110#[derive(prost_helpers::AnyPB)]
1111#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1112pub struct RescheduleResponse {
1113 #[prost(bool, tag = "1")]
1114 pub success: bool,
1115 #[prost(uint64, tag = "2")]
1116 pub revision: u64,
1117}
1118#[derive(prost_helpers::AnyPB)]
1119#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1120pub struct TableParallelism {
1121 #[prost(oneof = "table_parallelism::Parallelism", tags = "1, 2, 3, 4")]
1122 pub parallelism: ::core::option::Option<table_parallelism::Parallelism>,
1123}
1124pub mod table_parallelism {
1126 #[derive(prost_helpers::AnyPB)]
1127 #[derive(Clone, Copy, PartialEq, ::prost::Message)]
1128 pub struct FixedParallelism {
1129 #[prost(uint32, tag = "1")]
1130 pub parallelism: u32,
1131 }
1132 #[derive(prost_helpers::AnyPB)]
1134 #[derive(Clone, Copy, PartialEq, ::prost::Message)]
1135 pub struct AutoParallelism {}
1136 #[derive(prost_helpers::AnyPB)]
1137 #[derive(Clone, Copy, PartialEq, ::prost::Message)]
1138 pub struct AdaptiveParallelism {}
1139 #[derive(prost_helpers::AnyPB)]
1140 #[derive(Clone, Copy, PartialEq, ::prost::Message)]
1141 pub struct CustomParallelism {}
1142 #[derive(prost_helpers::AnyPB)]
1143 #[derive(Clone, Copy, PartialEq, ::prost::Oneof)]
1144 pub enum Parallelism {
1145 #[prost(message, tag = "1")]
1146 Fixed(FixedParallelism),
1147 #[prost(message, tag = "2")]
1148 Auto(AutoParallelism),
1149 #[prost(message, tag = "3")]
1150 Custom(CustomParallelism),
1151 #[prost(message, tag = "4")]
1152 Adaptive(AdaptiveParallelism),
1153 }
1154}
1155#[derive(prost_helpers::AnyPB)]
1158#[derive(Clone, PartialEq, ::prost::Message)]
1159pub struct UpdateStreamingJobNodeLabelsRequest {
1160 #[prost(uint32, tag = "1")]
1162 pub id: u32,
1163 #[prost(string, tag = "2")]
1165 pub node_label: ::prost::alloc::string::String,
1166}
1167#[derive(prost_helpers::AnyPB)]
1169#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1170pub struct UpdateStreamingJobNodeLabelsResponse {}
1171#[derive(prost_helpers::AnyPB)]
1172#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1173pub struct GetServerlessStreamingJobsStatusRequest {}
1174#[derive(prost_helpers::AnyPB)]
1176#[derive(Clone, PartialEq, ::prost::Message)]
1177pub struct GetServerlessStreamingJobsStatusResponse {
1178 #[prost(message, repeated, tag = "1")]
1179 pub streaming_job_statuses: ::prost::alloc::vec::Vec<
1180 get_serverless_streaming_jobs_status_response::Status,
1181 >,
1182}
1183pub mod get_serverless_streaming_jobs_status_response {
1185 #[derive(prost_helpers::AnyPB)]
1186 #[derive(Clone, PartialEq, ::prost::Message)]
1187 pub struct Status {
1188 #[prost(uint32, tag = "1")]
1189 pub table_id: u32,
1190 #[prost(string, tag = "2")]
1191 pub node_label: ::prost::alloc::string::String,
1192 #[prost(bool, tag = "3")]
1193 pub backfill_done: bool,
1194 }
1195}
1196#[derive(prost_helpers::AnyPB)]
1197#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1198pub struct MembersRequest {}
1199#[derive(prost_helpers::AnyPB)]
1200#[derive(Clone, PartialEq, ::prost::Message)]
1201pub struct MetaMember {
1202 #[prost(message, optional, tag = "1")]
1203 pub address: ::core::option::Option<super::common::HostAddress>,
1204 #[prost(bool, tag = "2")]
1205 pub is_leader: bool,
1206}
1207#[derive(prost_helpers::AnyPB)]
1208#[derive(Clone, PartialEq, ::prost::Message)]
1209pub struct MembersResponse {
1210 #[prost(message, repeated, tag = "1")]
1211 pub members: ::prost::alloc::vec::Vec<MetaMember>,
1212}
1213#[derive(prost_helpers::AnyPB)]
1219#[derive(Clone, PartialEq, ::prost::Message)]
1220#[prost(skip_debug)]
1221pub struct SystemParams {
1222 #[prost(uint32, optional, tag = "1")]
1223 pub barrier_interval_ms: ::core::option::Option<u32>,
1224 #[prost(uint64, optional, tag = "2")]
1225 pub checkpoint_frequency: ::core::option::Option<u64>,
1226 #[prost(uint32, optional, tag = "3")]
1227 pub sstable_size_mb: ::core::option::Option<u32>,
1228 #[prost(uint32, optional, tag = "4")]
1229 pub block_size_kb: ::core::option::Option<u32>,
1230 #[prost(double, optional, tag = "5")]
1231 pub bloom_false_positive: ::core::option::Option<f64>,
1232 #[prost(string, optional, tag = "6")]
1233 pub state_store: ::core::option::Option<::prost::alloc::string::String>,
1234 #[prost(string, optional, tag = "7")]
1235 pub data_directory: ::core::option::Option<::prost::alloc::string::String>,
1236 #[prost(string, optional, tag = "8")]
1237 pub backup_storage_url: ::core::option::Option<::prost::alloc::string::String>,
1238 #[prost(string, optional, tag = "9")]
1239 pub backup_storage_directory: ::core::option::Option<::prost::alloc::string::String>,
1240 #[deprecated]
1242 #[prost(bool, optional, tag = "10")]
1243 pub telemetry_enabled: ::core::option::Option<bool>,
1244 #[prost(uint32, optional, tag = "11")]
1245 pub parallel_compact_size_mb: ::core::option::Option<u32>,
1246 #[prost(uint32, optional, tag = "12")]
1247 pub max_concurrent_creating_streaming_jobs: ::core::option::Option<u32>,
1248 #[prost(bool, optional, tag = "13")]
1249 pub pause_on_next_bootstrap: ::core::option::Option<bool>,
1250 #[deprecated]
1251 #[prost(string, optional, tag = "14")]
1252 pub wasm_storage_url: ::core::option::Option<::prost::alloc::string::String>,
1253 #[prost(bool, optional, tag = "15")]
1254 pub enable_tracing: ::core::option::Option<bool>,
1255 #[prost(bool, optional, tag = "16")]
1256 pub use_new_object_prefix_strategy: ::core::option::Option<bool>,
1257 #[prost(string, optional, tag = "17")]
1258 pub license_key: ::core::option::Option<::prost::alloc::string::String>,
1259 #[prost(uint64, optional, tag = "18")]
1260 pub time_travel_retention_ms: ::core::option::Option<u64>,
1261 #[prost(string, optional, tag = "19")]
1262 pub adaptive_parallelism_strategy: ::core::option::Option<
1263 ::prost::alloc::string::String,
1264 >,
1265 #[prost(bool, optional, tag = "20")]
1266 pub per_database_isolation: ::core::option::Option<bool>,
1267 #[prost(bool, optional, tag = "21")]
1268 pub enforce_secret: ::core::option::Option<bool>,
1269}
1270#[derive(prost_helpers::AnyPB)]
1271#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1272pub struct GetSystemParamsRequest {}
1273#[derive(prost_helpers::AnyPB)]
1274#[derive(Clone, PartialEq, ::prost::Message)]
1275pub struct GetSystemParamsResponse {
1276 #[prost(message, optional, tag = "1")]
1277 pub params: ::core::option::Option<SystemParams>,
1278}
1279#[derive(prost_helpers::AnyPB)]
1280#[derive(Clone, PartialEq, ::prost::Message)]
1281pub struct SetSystemParamRequest {
1282 #[prost(string, tag = "1")]
1283 pub param: ::prost::alloc::string::String,
1284 #[prost(string, optional, tag = "2")]
1286 pub value: ::core::option::Option<::prost::alloc::string::String>,
1287}
1288#[derive(prost_helpers::AnyPB)]
1289#[derive(Clone, PartialEq, ::prost::Message)]
1290pub struct SetSystemParamResponse {
1291 #[prost(message, optional, tag = "1")]
1292 pub params: ::core::option::Option<SystemParams>,
1293}
1294#[derive(prost_helpers::AnyPB)]
1295#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1296pub struct GetSessionParamsRequest {}
1297#[derive(prost_helpers::AnyPB)]
1298#[derive(Clone, PartialEq, ::prost::Message)]
1299pub struct GetSessionParamsResponse {
1300 #[prost(string, tag = "1")]
1301 pub params: ::prost::alloc::string::String,
1302}
1303#[derive(prost_helpers::AnyPB)]
1304#[derive(Clone, PartialEq, ::prost::Message)]
1305pub struct SetSessionParamRequest {
1306 #[prost(string, tag = "1")]
1307 pub param: ::prost::alloc::string::String,
1308 #[prost(string, optional, tag = "2")]
1310 pub value: ::core::option::Option<::prost::alloc::string::String>,
1311}
1312#[derive(prost_helpers::AnyPB)]
1313#[derive(Clone, PartialEq, ::prost::Message)]
1314pub struct SetSessionParamResponse {
1315 #[prost(string, tag = "1")]
1316 pub param: ::prost::alloc::string::String,
1317}
1318#[derive(prost_helpers::AnyPB)]
1319#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1320pub struct GetServingVnodeMappingsRequest {}
1321#[derive(prost_helpers::AnyPB)]
1322#[derive(Clone, PartialEq, ::prost::Message)]
1323pub struct GetServingVnodeMappingsResponse {
1324 #[prost(map = "uint32, uint32", tag = "2")]
1325 pub fragment_to_table: ::std::collections::HashMap<u32, u32>,
1326 #[prost(message, repeated, tag = "3")]
1327 pub worker_slot_mappings: ::prost::alloc::vec::Vec<FragmentWorkerSlotMapping>,
1328}
1329#[derive(prost_helpers::AnyPB)]
1330#[derive(Clone, PartialEq, ::prost::Message)]
1331pub struct EventLog {
1332 #[prost(string, optional, tag = "1")]
1334 pub unique_id: ::core::option::Option<::prost::alloc::string::String>,
1335 #[prost(uint64, optional, tag = "2")]
1337 pub timestamp: ::core::option::Option<u64>,
1338 #[prost(oneof = "event_log::Event", tags = "3, 4, 5, 6, 7, 8, 9, 10, 11, 12")]
1339 pub event: ::core::option::Option<event_log::Event>,
1340}
1341pub mod event_log {
1343 #[derive(prost_helpers::AnyPB)]
1344 #[derive(Clone, PartialEq, ::prost::Message)]
1345 pub struct EventMetaNodeStart {
1346 #[prost(string, tag = "1")]
1347 pub advertise_addr: ::prost::alloc::string::String,
1348 #[prost(string, tag = "2")]
1349 pub listen_addr: ::prost::alloc::string::String,
1350 #[prost(string, tag = "3")]
1351 pub opts: ::prost::alloc::string::String,
1352 }
1353 #[derive(prost_helpers::AnyPB)]
1354 #[derive(Clone, PartialEq, ::prost::Message)]
1355 pub struct EventCreateStreamJobFail {
1356 #[prost(uint32, tag = "1")]
1357 pub id: u32,
1358 #[prost(string, tag = "2")]
1359 pub name: ::prost::alloc::string::String,
1360 #[prost(string, tag = "3")]
1361 pub definition: ::prost::alloc::string::String,
1362 #[prost(string, tag = "4")]
1363 pub error: ::prost::alloc::string::String,
1364 }
1365 #[derive(prost_helpers::AnyPB)]
1366 #[derive(Clone, PartialEq, ::prost::Message)]
1367 pub struct EventDirtyStreamJobClear {
1368 #[prost(uint32, tag = "1")]
1369 pub id: u32,
1370 #[prost(string, tag = "2")]
1371 pub name: ::prost::alloc::string::String,
1372 #[prost(string, tag = "3")]
1373 pub definition: ::prost::alloc::string::String,
1374 #[prost(string, tag = "4")]
1375 pub error: ::prost::alloc::string::String,
1376 }
1377 #[derive(prost_helpers::AnyPB)]
1378 #[derive(Clone, PartialEq, ::prost::Message)]
1379 pub struct EventBarrierComplete {
1380 #[prost(uint64, tag = "1")]
1381 pub prev_epoch: u64,
1382 #[prost(uint64, tag = "2")]
1383 pub cur_epoch: u64,
1384 #[prost(double, tag = "3")]
1385 pub duration_sec: f64,
1386 #[prost(string, tag = "4")]
1387 pub command: ::prost::alloc::string::String,
1388 #[prost(string, tag = "5")]
1389 pub barrier_kind: ::prost::alloc::string::String,
1390 }
1391 #[derive(prost_helpers::AnyPB)]
1392 #[derive(Clone, PartialEq, ::prost::Message)]
1393 pub struct EventInjectBarrierFail {
1394 #[prost(uint64, tag = "1")]
1395 pub prev_epoch: u64,
1396 #[prost(uint64, tag = "2")]
1397 pub cur_epoch: u64,
1398 #[prost(string, tag = "3")]
1399 pub error: ::prost::alloc::string::String,
1400 }
1401 #[derive(prost_helpers::AnyPB)]
1402 #[derive(Clone, PartialEq, ::prost::Message)]
1403 pub struct EventCollectBarrierFail {
1404 #[prost(string, tag = "3")]
1405 pub error: ::prost::alloc::string::String,
1406 }
1407 #[derive(prost_helpers::AnyPB)]
1408 #[derive(Clone, PartialEq, ::prost::Message)]
1409 pub struct EventWorkerNodePanic {
1410 #[prost(uint32, tag = "1")]
1411 pub worker_id: u32,
1412 #[prost(enumeration = "super::super::common::WorkerType", tag = "2")]
1413 pub worker_type: i32,
1414 #[prost(message, optional, tag = "3")]
1415 pub host_addr: ::core::option::Option<super::super::common::HostAddress>,
1416 #[prost(string, tag = "4")]
1417 pub panic_info: ::prost::alloc::string::String,
1418 }
1419 #[derive(prost_helpers::AnyPB)]
1420 #[derive(Clone, PartialEq, ::prost::Message)]
1421 pub struct EventAutoSchemaChangeFail {
1422 #[prost(uint32, tag = "1")]
1423 pub table_id: u32,
1424 #[prost(string, tag = "2")]
1425 pub table_name: ::prost::alloc::string::String,
1426 #[prost(string, tag = "3")]
1427 pub cdc_table_id: ::prost::alloc::string::String,
1428 #[prost(string, tag = "4")]
1429 pub upstream_ddl: ::prost::alloc::string::String,
1430 }
1431 #[derive(prost_helpers::AnyPB)]
1432 #[derive(Clone, PartialEq, ::prost::Message)]
1433 pub struct EventSinkFail {
1434 #[prost(uint32, tag = "1")]
1435 pub sink_id: u32,
1436 #[prost(string, tag = "2")]
1437 pub sink_name: ::prost::alloc::string::String,
1438 #[prost(string, tag = "3")]
1439 pub connector: ::prost::alloc::string::String,
1440 #[prost(string, tag = "4")]
1441 pub error: ::prost::alloc::string::String,
1442 }
1443 #[derive(prost_helpers::AnyPB)]
1444 #[derive(Clone, PartialEq, ::prost::Message)]
1445 pub struct EventRecovery {
1446 #[prost(oneof = "event_recovery::RecoveryEvent", tags = "1, 2, 3, 4, 5, 6")]
1447 pub recovery_event: ::core::option::Option<event_recovery::RecoveryEvent>,
1448 }
1449 pub mod event_recovery {
1451 #[derive(prost_helpers::AnyPB)]
1452 #[derive(Clone, PartialEq, ::prost::Message)]
1453 pub struct GlobalRecoveryStart {
1454 #[prost(string, tag = "1")]
1455 pub reason: ::prost::alloc::string::String,
1456 }
1457 #[derive(prost_helpers::AnyPB)]
1458 #[derive(Clone, PartialEq, ::prost::Message)]
1459 pub struct GlobalRecoverySuccess {
1460 #[prost(string, tag = "1")]
1461 pub reason: ::prost::alloc::string::String,
1462 #[prost(float, tag = "2")]
1463 pub duration_secs: f32,
1464 #[prost(uint32, repeated, tag = "3")]
1465 pub running_database_ids: ::prost::alloc::vec::Vec<u32>,
1466 #[prost(uint32, repeated, tag = "4")]
1467 pub recovering_database_ids: ::prost::alloc::vec::Vec<u32>,
1468 }
1469 #[derive(prost_helpers::AnyPB)]
1470 #[derive(Clone, PartialEq, ::prost::Message)]
1471 pub struct GlobalRecoveryFailure {
1472 #[prost(string, tag = "1")]
1473 pub reason: ::prost::alloc::string::String,
1474 #[prost(string, tag = "2")]
1475 pub error: ::prost::alloc::string::String,
1476 }
1477 #[derive(prost_helpers::AnyPB)]
1478 #[derive(Clone, Copy, PartialEq, ::prost::Message)]
1479 pub struct DatabaseRecoveryStart {
1480 #[prost(uint32, tag = "1")]
1481 pub database_id: u32,
1482 }
1483 #[derive(prost_helpers::AnyPB)]
1484 #[derive(Clone, Copy, PartialEq, ::prost::Message)]
1485 pub struct DatabaseRecoveryFailure {
1486 #[prost(uint32, tag = "1")]
1487 pub database_id: u32,
1488 }
1489 #[derive(prost_helpers::AnyPB)]
1490 #[derive(Clone, Copy, PartialEq, ::prost::Message)]
1491 pub struct DatabaseRecoverySuccess {
1492 #[prost(uint32, tag = "1")]
1493 pub database_id: u32,
1494 }
1495 #[derive(prost_helpers::AnyPB)]
1496 #[derive(Clone, PartialEq, ::prost::Oneof)]
1497 pub enum RecoveryEvent {
1498 #[prost(message, tag = "1")]
1499 GlobalStart(GlobalRecoveryStart),
1500 #[prost(message, tag = "2")]
1501 GlobalSuccess(GlobalRecoverySuccess),
1502 #[prost(message, tag = "3")]
1503 GlobalFailure(GlobalRecoveryFailure),
1504 #[prost(message, tag = "4")]
1505 DatabaseStart(DatabaseRecoveryStart),
1506 #[prost(message, tag = "5")]
1507 DatabaseFailure(DatabaseRecoveryFailure),
1508 #[prost(message, tag = "6")]
1509 DatabaseSuccess(DatabaseRecoverySuccess),
1510 }
1511 }
1512 #[derive(prost_helpers::AnyPB)]
1513 #[derive(Clone, PartialEq, ::prost::Oneof)]
1514 pub enum Event {
1515 #[prost(message, tag = "3")]
1516 CreateStreamJobFail(EventCreateStreamJobFail),
1517 #[prost(message, tag = "4")]
1518 DirtyStreamJobClear(EventDirtyStreamJobClear),
1519 #[prost(message, tag = "5")]
1520 MetaNodeStart(EventMetaNodeStart),
1521 #[prost(message, tag = "6")]
1522 BarrierComplete(EventBarrierComplete),
1523 #[prost(message, tag = "7")]
1524 InjectBarrierFail(EventInjectBarrierFail),
1525 #[prost(message, tag = "8")]
1526 CollectBarrierFail(EventCollectBarrierFail),
1527 #[prost(message, tag = "9")]
1528 WorkerNodePanic(EventWorkerNodePanic),
1529 #[prost(message, tag = "10")]
1530 AutoSchemaChangeFail(EventAutoSchemaChangeFail),
1531 #[prost(message, tag = "11")]
1532 SinkFail(EventSinkFail),
1533 #[prost(message, tag = "12")]
1534 Recovery(EventRecovery),
1535 }
1536}
1537#[derive(prost_helpers::AnyPB)]
1538#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1539pub struct ListEventLogRequest {}
1540#[derive(prost_helpers::AnyPB)]
1541#[derive(Clone, PartialEq, ::prost::Message)]
1542pub struct ListEventLogResponse {
1543 #[prost(message, repeated, tag = "1")]
1544 pub event_logs: ::prost::alloc::vec::Vec<EventLog>,
1545}
1546#[derive(prost_helpers::AnyPB)]
1547#[derive(Clone, PartialEq, ::prost::Message)]
1548pub struct AddEventLogRequest {
1549 #[prost(oneof = "add_event_log_request::Event", tags = "1, 2")]
1551 pub event: ::core::option::Option<add_event_log_request::Event>,
1552}
1553pub mod add_event_log_request {
1555 #[derive(prost_helpers::AnyPB)]
1557 #[derive(Clone, PartialEq, ::prost::Oneof)]
1558 pub enum Event {
1559 #[prost(message, tag = "1")]
1560 WorkerNodePanic(super::event_log::EventWorkerNodePanic),
1561 #[prost(message, tag = "2")]
1562 SinkFail(super::event_log::EventSinkFail),
1563 }
1564}
1565#[derive(prost_helpers::AnyPB)]
1566#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1567pub struct AddEventLogResponse {}
1568#[derive(prost_helpers::AnyPB)]
1569#[derive(Clone, PartialEq, ::prost::Message)]
1570pub struct ActorIds {
1571 #[prost(uint32, repeated, tag = "1")]
1572 pub ids: ::prost::alloc::vec::Vec<u32>,
1573}
1574#[derive(prost_helpers::AnyPB)]
1575#[derive(Clone, PartialEq, ::prost::Message)]
1576pub struct FragmentIdToActorIdMap {
1577 #[prost(map = "uint32, message", tag = "1")]
1578 pub map: ::std::collections::HashMap<u32, ActorIds>,
1579}
1580#[derive(prost_helpers::AnyPB)]
1585#[derive(Clone, PartialEq, ::prost::Message)]
1586pub struct RelationIdInfos {
1587 #[prost(map = "uint32, message", tag = "1")]
1589 pub map: ::std::collections::HashMap<u32, FragmentIdToActorIdMap>,
1590}
1591#[derive(prost_helpers::AnyPB)]
1592#[derive(Clone, PartialEq, ::prost::Message)]
1593pub struct FragmentToRelationMap {
1594 #[prost(map = "uint32, uint32", tag = "1")]
1596 pub in_map: ::std::collections::HashMap<u32, u32>,
1597 #[prost(map = "uint32, uint32", tag = "2")]
1599 pub out_map: ::std::collections::HashMap<u32, u32>,
1600}
1601#[derive(prost_helpers::AnyPB)]
1602#[derive(Clone, PartialEq, ::prost::Message)]
1603pub struct ActorCountPerParallelism {
1604 #[prost(map = "uint32, message", tag = "1")]
1605 pub worker_id_to_actor_count: ::std::collections::HashMap<
1606 u32,
1607 actor_count_per_parallelism::WorkerActorCount,
1608 >,
1609 #[prost(uint64, tag = "2")]
1610 pub hard_limit: u64,
1611 #[prost(uint64, tag = "3")]
1612 pub soft_limit: u64,
1613}
1614pub mod actor_count_per_parallelism {
1616 #[derive(prost_helpers::AnyPB)]
1617 #[derive(Clone, Copy, PartialEq, ::prost::Message)]
1618 pub struct WorkerActorCount {
1619 #[prost(uint64, tag = "1")]
1620 pub actor_count: u64,
1621 #[prost(uint64, tag = "2")]
1622 pub parallelism: u64,
1623 }
1624}
1625#[derive(prost_helpers::AnyPB)]
1626#[derive(Clone, PartialEq, ::prost::Message)]
1627pub struct ClusterLimit {
1628 #[prost(oneof = "cluster_limit::Limit", tags = "1")]
1629 pub limit: ::core::option::Option<cluster_limit::Limit>,
1630}
1631pub mod cluster_limit {
1633 #[derive(prost_helpers::AnyPB)]
1634 #[derive(Clone, PartialEq, ::prost::Oneof)]
1635 pub enum Limit {
1636 #[prost(message, tag = "1")]
1638 ActorCount(super::ActorCountPerParallelism),
1639 }
1640}
1641#[derive(prost_helpers::AnyPB)]
1642#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1643pub struct GetClusterLimitsRequest {}
1644#[derive(prost_helpers::AnyPB)]
1645#[derive(Clone, PartialEq, ::prost::Message)]
1646pub struct GetClusterLimitsResponse {
1647 #[prost(message, repeated, tag = "1")]
1648 pub active_limits: ::prost::alloc::vec::Vec<ClusterLimit>,
1649}
1650#[derive(prost_helpers::AnyPB)]
1651#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1652pub struct ListRateLimitsRequest {}
1653#[derive(prost_helpers::AnyPB)]
1654#[derive(Clone, PartialEq, ::prost::Message)]
1655pub struct ListRateLimitsResponse {
1656 #[prost(message, repeated, tag = "1")]
1657 pub rate_limits: ::prost::alloc::vec::Vec<list_rate_limits_response::RateLimitInfo>,
1658}
1659pub mod list_rate_limits_response {
1661 #[derive(prost_helpers::AnyPB)]
1662 #[derive(Clone, PartialEq, ::prost::Message)]
1663 pub struct RateLimitInfo {
1664 #[prost(uint32, tag = "1")]
1665 pub fragment_id: u32,
1666 #[prost(uint32, tag = "2")]
1667 pub job_id: u32,
1668 #[prost(uint32, tag = "3")]
1669 pub fragment_type_mask: u32,
1670 #[prost(uint32, tag = "4")]
1671 pub rate_limit: u32,
1672 #[prost(string, tag = "5")]
1673 pub node_name: ::prost::alloc::string::String,
1674 }
1675}
1676#[derive(prost_helpers::AnyPB)]
1677#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1678pub struct ListIcebergTablesRequest {}
1679#[derive(prost_helpers::AnyPB)]
1680#[derive(Clone, PartialEq, ::prost::Message)]
1681pub struct ListIcebergTablesResponse {
1682 #[prost(message, repeated, tag = "1")]
1683 pub iceberg_tables: ::prost::alloc::vec::Vec<
1684 list_iceberg_tables_response::IcebergTable,
1685 >,
1686}
1687pub mod list_iceberg_tables_response {
1689 #[derive(prost_helpers::AnyPB)]
1690 #[derive(Clone, PartialEq, ::prost::Message)]
1691 pub struct IcebergTable {
1692 #[prost(string, tag = "1")]
1693 pub catalog_name: ::prost::alloc::string::String,
1694 #[prost(string, tag = "2")]
1695 pub table_namespace: ::prost::alloc::string::String,
1696 #[prost(string, tag = "3")]
1697 pub table_name: ::prost::alloc::string::String,
1698 #[prost(string, optional, tag = "4")]
1699 pub metadata_location: ::core::option::Option<::prost::alloc::string::String>,
1700 #[prost(string, optional, tag = "5")]
1701 pub previous_metadata_location: ::core::option::Option<
1702 ::prost::alloc::string::String,
1703 >,
1704 #[prost(string, optional, tag = "6")]
1705 pub iceberg_type: ::core::option::Option<::prost::alloc::string::String>,
1706 }
1707}
1708#[derive(prost_helpers::AnyPB)]
1709#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1710pub struct SetSyncLogStoreAlignedRequest {
1711 #[prost(uint32, tag = "1")]
1712 pub job_id: u32,
1713 #[prost(bool, tag = "2")]
1714 pub aligned: bool,
1715}
1716#[derive(prost_helpers::AnyPB)]
1717#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1718pub struct SetSyncLogStoreAlignedResponse {}
1719#[derive(prost_helpers::AnyPB)]
1720#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1721#[repr(i32)]
1722pub enum ThrottleTarget {
1723 Unspecified = 0,
1724 Source = 1,
1725 Mv = 2,
1726 TableWithSource = 3,
1727 CdcTable = 4,
1728 TableDml = 5,
1729 Sink = 6,
1730 Fragment = 7,
1731}
1732impl ThrottleTarget {
1733 pub fn as_str_name(&self) -> &'static str {
1738 match self {
1739 Self::Unspecified => "THROTTLE_TARGET_UNSPECIFIED",
1740 Self::Source => "SOURCE",
1741 Self::Mv => "MV",
1742 Self::TableWithSource => "TABLE_WITH_SOURCE",
1743 Self::CdcTable => "CDC_TABLE",
1744 Self::TableDml => "TABLE_DML",
1745 Self::Sink => "SINK",
1746 Self::Fragment => "FRAGMENT",
1747 }
1748 }
1749 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1751 match value {
1752 "THROTTLE_TARGET_UNSPECIFIED" => Some(Self::Unspecified),
1753 "SOURCE" => Some(Self::Source),
1754 "MV" => Some(Self::Mv),
1755 "TABLE_WITH_SOURCE" => Some(Self::TableWithSource),
1756 "CDC_TABLE" => Some(Self::CdcTable),
1757 "TABLE_DML" => Some(Self::TableDml),
1758 "SINK" => Some(Self::Sink),
1759 "FRAGMENT" => Some(Self::Fragment),
1760 _ => None,
1761 }
1762 }
1763}
1764#[derive(prost_helpers::AnyPB)]
1765#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1766#[repr(i32)]
1767pub enum RecoveryStatus {
1768 StatusUnspecified = 0,
1769 StatusStarting = 1,
1770 StatusRecovering = 2,
1771 StatusRunning = 3,
1772}
1773impl RecoveryStatus {
1774 pub fn as_str_name(&self) -> &'static str {
1779 match self {
1780 Self::StatusUnspecified => "STATUS_UNSPECIFIED",
1781 Self::StatusStarting => "STATUS_STARTING",
1782 Self::StatusRecovering => "STATUS_RECOVERING",
1783 Self::StatusRunning => "STATUS_RUNNING",
1784 }
1785 }
1786 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1788 match value {
1789 "STATUS_UNSPECIFIED" => Some(Self::StatusUnspecified),
1790 "STATUS_STARTING" => Some(Self::StatusStarting),
1791 "STATUS_RECOVERING" => Some(Self::StatusRecovering),
1792 "STATUS_RUNNING" => Some(Self::StatusRunning),
1793 _ => None,
1794 }
1795 }
1796}
1797#[derive(prost_helpers::AnyPB)]
1798#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1799#[repr(i32)]
1800pub enum SubscribeType {
1801 Unspecified = 0,
1802 Frontend = 1,
1803 Hummock = 2,
1804 Compactor = 3,
1805 Compute = 4,
1806}
1807impl SubscribeType {
1808 pub fn as_str_name(&self) -> &'static str {
1813 match self {
1814 Self::Unspecified => "UNSPECIFIED",
1815 Self::Frontend => "FRONTEND",
1816 Self::Hummock => "HUMMOCK",
1817 Self::Compactor => "COMPACTOR",
1818 Self::Compute => "COMPUTE",
1819 }
1820 }
1821 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1823 match value {
1824 "UNSPECIFIED" => Some(Self::Unspecified),
1825 "FRONTEND" => Some(Self::Frontend),
1826 "HUMMOCK" => Some(Self::Hummock),
1827 "COMPACTOR" => Some(Self::Compactor),
1828 "COMPUTE" => Some(Self::Compute),
1829 _ => None,
1830 }
1831 }
1832}
1833pub mod telemetry_info_service_client {
1835 #![allow(
1836 unused_variables,
1837 dead_code,
1838 missing_docs,
1839 clippy::wildcard_imports,
1840 clippy::let_unit_value,
1841 )]
1842 use tonic::codegen::*;
1843 use tonic::codegen::http::Uri;
1844 #[derive(Debug, Clone)]
1845 pub struct TelemetryInfoServiceClient<T> {
1846 inner: tonic::client::Grpc<T>,
1847 }
1848 impl TelemetryInfoServiceClient<tonic::transport::Channel> {
1849 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
1851 where
1852 D: TryInto<tonic::transport::Endpoint>,
1853 D::Error: Into<StdError>,
1854 {
1855 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
1856 Ok(Self::new(conn))
1857 }
1858 }
1859 impl<T> TelemetryInfoServiceClient<T>
1860 where
1861 T: tonic::client::GrpcService<tonic::body::BoxBody>,
1862 T::Error: Into<StdError>,
1863 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
1864 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
1865 {
1866 pub fn new(inner: T) -> Self {
1867 let inner = tonic::client::Grpc::new(inner);
1868 Self { inner }
1869 }
1870 pub fn with_origin(inner: T, origin: Uri) -> Self {
1871 let inner = tonic::client::Grpc::with_origin(inner, origin);
1872 Self { inner }
1873 }
1874 pub fn with_interceptor<F>(
1875 inner: T,
1876 interceptor: F,
1877 ) -> TelemetryInfoServiceClient<InterceptedService<T, F>>
1878 where
1879 F: tonic::service::Interceptor,
1880 T::ResponseBody: Default,
1881 T: tonic::codegen::Service<
1882 http::Request<tonic::body::BoxBody>,
1883 Response = http::Response<
1884 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
1885 >,
1886 >,
1887 <T as tonic::codegen::Service<
1888 http::Request<tonic::body::BoxBody>,
1889 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
1890 {
1891 TelemetryInfoServiceClient::new(InterceptedService::new(inner, interceptor))
1892 }
1893 #[must_use]
1898 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
1899 self.inner = self.inner.send_compressed(encoding);
1900 self
1901 }
1902 #[must_use]
1904 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
1905 self.inner = self.inner.accept_compressed(encoding);
1906 self
1907 }
1908 #[must_use]
1912 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
1913 self.inner = self.inner.max_decoding_message_size(limit);
1914 self
1915 }
1916 #[must_use]
1920 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
1921 self.inner = self.inner.max_encoding_message_size(limit);
1922 self
1923 }
1924 pub async fn get_telemetry_info(
1926 &mut self,
1927 request: impl tonic::IntoRequest<super::GetTelemetryInfoRequest>,
1928 ) -> std::result::Result<
1929 tonic::Response<super::TelemetryInfoResponse>,
1930 tonic::Status,
1931 > {
1932 self.inner
1933 .ready()
1934 .await
1935 .map_err(|e| {
1936 tonic::Status::unknown(
1937 format!("Service was not ready: {}", e.into()),
1938 )
1939 })?;
1940 let codec = tonic::codec::ProstCodec::default();
1941 let path = http::uri::PathAndQuery::from_static(
1942 "/meta.TelemetryInfoService/GetTelemetryInfo",
1943 );
1944 let mut req = request.into_request();
1945 req.extensions_mut()
1946 .insert(
1947 GrpcMethod::new("meta.TelemetryInfoService", "GetTelemetryInfo"),
1948 );
1949 self.inner.unary(req, path, codec).await
1950 }
1951 }
1952}
1953pub mod heartbeat_service_client {
1955 #![allow(
1956 unused_variables,
1957 dead_code,
1958 missing_docs,
1959 clippy::wildcard_imports,
1960 clippy::let_unit_value,
1961 )]
1962 use tonic::codegen::*;
1963 use tonic::codegen::http::Uri;
1964 #[derive(Debug, Clone)]
1965 pub struct HeartbeatServiceClient<T> {
1966 inner: tonic::client::Grpc<T>,
1967 }
1968 impl HeartbeatServiceClient<tonic::transport::Channel> {
1969 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
1971 where
1972 D: TryInto<tonic::transport::Endpoint>,
1973 D::Error: Into<StdError>,
1974 {
1975 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
1976 Ok(Self::new(conn))
1977 }
1978 }
1979 impl<T> HeartbeatServiceClient<T>
1980 where
1981 T: tonic::client::GrpcService<tonic::body::BoxBody>,
1982 T::Error: Into<StdError>,
1983 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
1984 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
1985 {
1986 pub fn new(inner: T) -> Self {
1987 let inner = tonic::client::Grpc::new(inner);
1988 Self { inner }
1989 }
1990 pub fn with_origin(inner: T, origin: Uri) -> Self {
1991 let inner = tonic::client::Grpc::with_origin(inner, origin);
1992 Self { inner }
1993 }
1994 pub fn with_interceptor<F>(
1995 inner: T,
1996 interceptor: F,
1997 ) -> HeartbeatServiceClient<InterceptedService<T, F>>
1998 where
1999 F: tonic::service::Interceptor,
2000 T::ResponseBody: Default,
2001 T: tonic::codegen::Service<
2002 http::Request<tonic::body::BoxBody>,
2003 Response = http::Response<
2004 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
2005 >,
2006 >,
2007 <T as tonic::codegen::Service<
2008 http::Request<tonic::body::BoxBody>,
2009 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
2010 {
2011 HeartbeatServiceClient::new(InterceptedService::new(inner, interceptor))
2012 }
2013 #[must_use]
2018 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
2019 self.inner = self.inner.send_compressed(encoding);
2020 self
2021 }
2022 #[must_use]
2024 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
2025 self.inner = self.inner.accept_compressed(encoding);
2026 self
2027 }
2028 #[must_use]
2032 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
2033 self.inner = self.inner.max_decoding_message_size(limit);
2034 self
2035 }
2036 #[must_use]
2040 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
2041 self.inner = self.inner.max_encoding_message_size(limit);
2042 self
2043 }
2044 pub async fn heartbeat(
2045 &mut self,
2046 request: impl tonic::IntoRequest<super::HeartbeatRequest>,
2047 ) -> std::result::Result<
2048 tonic::Response<super::HeartbeatResponse>,
2049 tonic::Status,
2050 > {
2051 self.inner
2052 .ready()
2053 .await
2054 .map_err(|e| {
2055 tonic::Status::unknown(
2056 format!("Service was not ready: {}", e.into()),
2057 )
2058 })?;
2059 let codec = tonic::codec::ProstCodec::default();
2060 let path = http::uri::PathAndQuery::from_static(
2061 "/meta.HeartbeatService/Heartbeat",
2062 );
2063 let mut req = request.into_request();
2064 req.extensions_mut()
2065 .insert(GrpcMethod::new("meta.HeartbeatService", "Heartbeat"));
2066 self.inner.unary(req, path, codec).await
2067 }
2068 }
2069}
2070pub mod stream_manager_service_client {
2072 #![allow(
2073 unused_variables,
2074 dead_code,
2075 missing_docs,
2076 clippy::wildcard_imports,
2077 clippy::let_unit_value,
2078 )]
2079 use tonic::codegen::*;
2080 use tonic::codegen::http::Uri;
2081 #[derive(Debug, Clone)]
2082 pub struct StreamManagerServiceClient<T> {
2083 inner: tonic::client::Grpc<T>,
2084 }
2085 impl StreamManagerServiceClient<tonic::transport::Channel> {
2086 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
2088 where
2089 D: TryInto<tonic::transport::Endpoint>,
2090 D::Error: Into<StdError>,
2091 {
2092 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
2093 Ok(Self::new(conn))
2094 }
2095 }
2096 impl<T> StreamManagerServiceClient<T>
2097 where
2098 T: tonic::client::GrpcService<tonic::body::BoxBody>,
2099 T::Error: Into<StdError>,
2100 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
2101 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
2102 {
2103 pub fn new(inner: T) -> Self {
2104 let inner = tonic::client::Grpc::new(inner);
2105 Self { inner }
2106 }
2107 pub fn with_origin(inner: T, origin: Uri) -> Self {
2108 let inner = tonic::client::Grpc::with_origin(inner, origin);
2109 Self { inner }
2110 }
2111 pub fn with_interceptor<F>(
2112 inner: T,
2113 interceptor: F,
2114 ) -> StreamManagerServiceClient<InterceptedService<T, F>>
2115 where
2116 F: tonic::service::Interceptor,
2117 T::ResponseBody: Default,
2118 T: tonic::codegen::Service<
2119 http::Request<tonic::body::BoxBody>,
2120 Response = http::Response<
2121 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
2122 >,
2123 >,
2124 <T as tonic::codegen::Service<
2125 http::Request<tonic::body::BoxBody>,
2126 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
2127 {
2128 StreamManagerServiceClient::new(InterceptedService::new(inner, interceptor))
2129 }
2130 #[must_use]
2135 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
2136 self.inner = self.inner.send_compressed(encoding);
2137 self
2138 }
2139 #[must_use]
2141 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
2142 self.inner = self.inner.accept_compressed(encoding);
2143 self
2144 }
2145 #[must_use]
2149 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
2150 self.inner = self.inner.max_decoding_message_size(limit);
2151 self
2152 }
2153 #[must_use]
2157 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
2158 self.inner = self.inner.max_encoding_message_size(limit);
2159 self
2160 }
2161 pub async fn flush(
2162 &mut self,
2163 request: impl tonic::IntoRequest<super::FlushRequest>,
2164 ) -> std::result::Result<tonic::Response<super::FlushResponse>, tonic::Status> {
2165 self.inner
2166 .ready()
2167 .await
2168 .map_err(|e| {
2169 tonic::Status::unknown(
2170 format!("Service was not ready: {}", e.into()),
2171 )
2172 })?;
2173 let codec = tonic::codec::ProstCodec::default();
2174 let path = http::uri::PathAndQuery::from_static(
2175 "/meta.StreamManagerService/Flush",
2176 );
2177 let mut req = request.into_request();
2178 req.extensions_mut()
2179 .insert(GrpcMethod::new("meta.StreamManagerService", "Flush"));
2180 self.inner.unary(req, path, codec).await
2181 }
2182 pub async fn pause(
2183 &mut self,
2184 request: impl tonic::IntoRequest<super::PauseRequest>,
2185 ) -> std::result::Result<tonic::Response<super::PauseResponse>, tonic::Status> {
2186 self.inner
2187 .ready()
2188 .await
2189 .map_err(|e| {
2190 tonic::Status::unknown(
2191 format!("Service was not ready: {}", e.into()),
2192 )
2193 })?;
2194 let codec = tonic::codec::ProstCodec::default();
2195 let path = http::uri::PathAndQuery::from_static(
2196 "/meta.StreamManagerService/Pause",
2197 );
2198 let mut req = request.into_request();
2199 req.extensions_mut()
2200 .insert(GrpcMethod::new("meta.StreamManagerService", "Pause"));
2201 self.inner.unary(req, path, codec).await
2202 }
2203 pub async fn resume(
2204 &mut self,
2205 request: impl tonic::IntoRequest<super::ResumeRequest>,
2206 ) -> std::result::Result<tonic::Response<super::ResumeResponse>, tonic::Status> {
2207 self.inner
2208 .ready()
2209 .await
2210 .map_err(|e| {
2211 tonic::Status::unknown(
2212 format!("Service was not ready: {}", e.into()),
2213 )
2214 })?;
2215 let codec = tonic::codec::ProstCodec::default();
2216 let path = http::uri::PathAndQuery::from_static(
2217 "/meta.StreamManagerService/Resume",
2218 );
2219 let mut req = request.into_request();
2220 req.extensions_mut()
2221 .insert(GrpcMethod::new("meta.StreamManagerService", "Resume"));
2222 self.inner.unary(req, path, codec).await
2223 }
2224 pub async fn cancel_creating_jobs(
2225 &mut self,
2226 request: impl tonic::IntoRequest<super::CancelCreatingJobsRequest>,
2227 ) -> std::result::Result<
2228 tonic::Response<super::CancelCreatingJobsResponse>,
2229 tonic::Status,
2230 > {
2231 self.inner
2232 .ready()
2233 .await
2234 .map_err(|e| {
2235 tonic::Status::unknown(
2236 format!("Service was not ready: {}", e.into()),
2237 )
2238 })?;
2239 let codec = tonic::codec::ProstCodec::default();
2240 let path = http::uri::PathAndQuery::from_static(
2241 "/meta.StreamManagerService/CancelCreatingJobs",
2242 );
2243 let mut req = request.into_request();
2244 req.extensions_mut()
2245 .insert(
2246 GrpcMethod::new("meta.StreamManagerService", "CancelCreatingJobs"),
2247 );
2248 self.inner.unary(req, path, codec).await
2249 }
2250 pub async fn list_table_fragments(
2251 &mut self,
2252 request: impl tonic::IntoRequest<super::ListTableFragmentsRequest>,
2253 ) -> std::result::Result<
2254 tonic::Response<super::ListTableFragmentsResponse>,
2255 tonic::Status,
2256 > {
2257 self.inner
2258 .ready()
2259 .await
2260 .map_err(|e| {
2261 tonic::Status::unknown(
2262 format!("Service was not ready: {}", e.into()),
2263 )
2264 })?;
2265 let codec = tonic::codec::ProstCodec::default();
2266 let path = http::uri::PathAndQuery::from_static(
2267 "/meta.StreamManagerService/ListTableFragments",
2268 );
2269 let mut req = request.into_request();
2270 req.extensions_mut()
2271 .insert(
2272 GrpcMethod::new("meta.StreamManagerService", "ListTableFragments"),
2273 );
2274 self.inner.unary(req, path, codec).await
2275 }
2276 pub async fn list_streaming_job_states(
2277 &mut self,
2278 request: impl tonic::IntoRequest<super::ListStreamingJobStatesRequest>,
2279 ) -> std::result::Result<
2280 tonic::Response<super::ListStreamingJobStatesResponse>,
2281 tonic::Status,
2282 > {
2283 self.inner
2284 .ready()
2285 .await
2286 .map_err(|e| {
2287 tonic::Status::unknown(
2288 format!("Service was not ready: {}", e.into()),
2289 )
2290 })?;
2291 let codec = tonic::codec::ProstCodec::default();
2292 let path = http::uri::PathAndQuery::from_static(
2293 "/meta.StreamManagerService/ListStreamingJobStates",
2294 );
2295 let mut req = request.into_request();
2296 req.extensions_mut()
2297 .insert(
2298 GrpcMethod::new(
2299 "meta.StreamManagerService",
2300 "ListStreamingJobStates",
2301 ),
2302 );
2303 self.inner.unary(req, path, codec).await
2304 }
2305 pub async fn list_fragment_distribution(
2306 &mut self,
2307 request: impl tonic::IntoRequest<super::ListFragmentDistributionRequest>,
2308 ) -> std::result::Result<
2309 tonic::Response<super::ListFragmentDistributionResponse>,
2310 tonic::Status,
2311 > {
2312 self.inner
2313 .ready()
2314 .await
2315 .map_err(|e| {
2316 tonic::Status::unknown(
2317 format!("Service was not ready: {}", e.into()),
2318 )
2319 })?;
2320 let codec = tonic::codec::ProstCodec::default();
2321 let path = http::uri::PathAndQuery::from_static(
2322 "/meta.StreamManagerService/ListFragmentDistribution",
2323 );
2324 let mut req = request.into_request();
2325 req.extensions_mut()
2326 .insert(
2327 GrpcMethod::new(
2328 "meta.StreamManagerService",
2329 "ListFragmentDistribution",
2330 ),
2331 );
2332 self.inner.unary(req, path, codec).await
2333 }
2334 pub async fn list_creating_fragment_distribution(
2335 &mut self,
2336 request: impl tonic::IntoRequest<
2337 super::ListCreatingFragmentDistributionRequest,
2338 >,
2339 ) -> std::result::Result<
2340 tonic::Response<super::ListCreatingFragmentDistributionResponse>,
2341 tonic::Status,
2342 > {
2343 self.inner
2344 .ready()
2345 .await
2346 .map_err(|e| {
2347 tonic::Status::unknown(
2348 format!("Service was not ready: {}", e.into()),
2349 )
2350 })?;
2351 let codec = tonic::codec::ProstCodec::default();
2352 let path = http::uri::PathAndQuery::from_static(
2353 "/meta.StreamManagerService/ListCreatingFragmentDistribution",
2354 );
2355 let mut req = request.into_request();
2356 req.extensions_mut()
2357 .insert(
2358 GrpcMethod::new(
2359 "meta.StreamManagerService",
2360 "ListCreatingFragmentDistribution",
2361 ),
2362 );
2363 self.inner.unary(req, path, codec).await
2364 }
2365 pub async fn list_actor_states(
2366 &mut self,
2367 request: impl tonic::IntoRequest<super::ListActorStatesRequest>,
2368 ) -> std::result::Result<
2369 tonic::Response<super::ListActorStatesResponse>,
2370 tonic::Status,
2371 > {
2372 self.inner
2373 .ready()
2374 .await
2375 .map_err(|e| {
2376 tonic::Status::unknown(
2377 format!("Service was not ready: {}", e.into()),
2378 )
2379 })?;
2380 let codec = tonic::codec::ProstCodec::default();
2381 let path = http::uri::PathAndQuery::from_static(
2382 "/meta.StreamManagerService/ListActorStates",
2383 );
2384 let mut req = request.into_request();
2385 req.extensions_mut()
2386 .insert(GrpcMethod::new("meta.StreamManagerService", "ListActorStates"));
2387 self.inner.unary(req, path, codec).await
2388 }
2389 pub async fn list_actor_splits(
2390 &mut self,
2391 request: impl tonic::IntoRequest<super::ListActorSplitsRequest>,
2392 ) -> std::result::Result<
2393 tonic::Response<super::ListActorSplitsResponse>,
2394 tonic::Status,
2395 > {
2396 self.inner
2397 .ready()
2398 .await
2399 .map_err(|e| {
2400 tonic::Status::unknown(
2401 format!("Service was not ready: {}", e.into()),
2402 )
2403 })?;
2404 let codec = tonic::codec::ProstCodec::default();
2405 let path = http::uri::PathAndQuery::from_static(
2406 "/meta.StreamManagerService/ListActorSplits",
2407 );
2408 let mut req = request.into_request();
2409 req.extensions_mut()
2410 .insert(GrpcMethod::new("meta.StreamManagerService", "ListActorSplits"));
2411 self.inner.unary(req, path, codec).await
2412 }
2413 pub async fn list_object_dependencies(
2414 &mut self,
2415 request: impl tonic::IntoRequest<super::ListObjectDependenciesRequest>,
2416 ) -> std::result::Result<
2417 tonic::Response<super::ListObjectDependenciesResponse>,
2418 tonic::Status,
2419 > {
2420 self.inner
2421 .ready()
2422 .await
2423 .map_err(|e| {
2424 tonic::Status::unknown(
2425 format!("Service was not ready: {}", e.into()),
2426 )
2427 })?;
2428 let codec = tonic::codec::ProstCodec::default();
2429 let path = http::uri::PathAndQuery::from_static(
2430 "/meta.StreamManagerService/ListObjectDependencies",
2431 );
2432 let mut req = request.into_request();
2433 req.extensions_mut()
2434 .insert(
2435 GrpcMethod::new(
2436 "meta.StreamManagerService",
2437 "ListObjectDependencies",
2438 ),
2439 );
2440 self.inner.unary(req, path, codec).await
2441 }
2442 pub async fn apply_throttle(
2443 &mut self,
2444 request: impl tonic::IntoRequest<super::ApplyThrottleRequest>,
2445 ) -> std::result::Result<
2446 tonic::Response<super::ApplyThrottleResponse>,
2447 tonic::Status,
2448 > {
2449 self.inner
2450 .ready()
2451 .await
2452 .map_err(|e| {
2453 tonic::Status::unknown(
2454 format!("Service was not ready: {}", e.into()),
2455 )
2456 })?;
2457 let codec = tonic::codec::ProstCodec::default();
2458 let path = http::uri::PathAndQuery::from_static(
2459 "/meta.StreamManagerService/ApplyThrottle",
2460 );
2461 let mut req = request.into_request();
2462 req.extensions_mut()
2463 .insert(GrpcMethod::new("meta.StreamManagerService", "ApplyThrottle"));
2464 self.inner.unary(req, path, codec).await
2465 }
2466 pub async fn recover(
2467 &mut self,
2468 request: impl tonic::IntoRequest<super::RecoverRequest>,
2469 ) -> std::result::Result<
2470 tonic::Response<super::RecoverResponse>,
2471 tonic::Status,
2472 > {
2473 self.inner
2474 .ready()
2475 .await
2476 .map_err(|e| {
2477 tonic::Status::unknown(
2478 format!("Service was not ready: {}", e.into()),
2479 )
2480 })?;
2481 let codec = tonic::codec::ProstCodec::default();
2482 let path = http::uri::PathAndQuery::from_static(
2483 "/meta.StreamManagerService/Recover",
2484 );
2485 let mut req = request.into_request();
2486 req.extensions_mut()
2487 .insert(GrpcMethod::new("meta.StreamManagerService", "Recover"));
2488 self.inner.unary(req, path, codec).await
2489 }
2490 pub async fn list_rate_limits(
2491 &mut self,
2492 request: impl tonic::IntoRequest<super::ListRateLimitsRequest>,
2493 ) -> std::result::Result<
2494 tonic::Response<super::ListRateLimitsResponse>,
2495 tonic::Status,
2496 > {
2497 self.inner
2498 .ready()
2499 .await
2500 .map_err(|e| {
2501 tonic::Status::unknown(
2502 format!("Service was not ready: {}", e.into()),
2503 )
2504 })?;
2505 let codec = tonic::codec::ProstCodec::default();
2506 let path = http::uri::PathAndQuery::from_static(
2507 "/meta.StreamManagerService/ListRateLimits",
2508 );
2509 let mut req = request.into_request();
2510 req.extensions_mut()
2511 .insert(GrpcMethod::new("meta.StreamManagerService", "ListRateLimits"));
2512 self.inner.unary(req, path, codec).await
2513 }
2514 pub async fn alter_connector_props(
2515 &mut self,
2516 request: impl tonic::IntoRequest<super::AlterConnectorPropsRequest>,
2517 ) -> std::result::Result<
2518 tonic::Response<super::AlterConnectorPropsResponse>,
2519 tonic::Status,
2520 > {
2521 self.inner
2522 .ready()
2523 .await
2524 .map_err(|e| {
2525 tonic::Status::unknown(
2526 format!("Service was not ready: {}", e.into()),
2527 )
2528 })?;
2529 let codec = tonic::codec::ProstCodec::default();
2530 let path = http::uri::PathAndQuery::from_static(
2531 "/meta.StreamManagerService/AlterConnectorProps",
2532 );
2533 let mut req = request.into_request();
2534 req.extensions_mut()
2535 .insert(
2536 GrpcMethod::new("meta.StreamManagerService", "AlterConnectorProps"),
2537 );
2538 self.inner.unary(req, path, codec).await
2539 }
2540 pub async fn get_fragment_by_id(
2541 &mut self,
2542 request: impl tonic::IntoRequest<super::GetFragmentByIdRequest>,
2543 ) -> std::result::Result<
2544 tonic::Response<super::GetFragmentByIdResponse>,
2545 tonic::Status,
2546 > {
2547 self.inner
2548 .ready()
2549 .await
2550 .map_err(|e| {
2551 tonic::Status::unknown(
2552 format!("Service was not ready: {}", e.into()),
2553 )
2554 })?;
2555 let codec = tonic::codec::ProstCodec::default();
2556 let path = http::uri::PathAndQuery::from_static(
2557 "/meta.StreamManagerService/GetFragmentById",
2558 );
2559 let mut req = request.into_request();
2560 req.extensions_mut()
2561 .insert(GrpcMethod::new("meta.StreamManagerService", "GetFragmentById"));
2562 self.inner.unary(req, path, codec).await
2563 }
2564 pub async fn set_sync_log_store_aligned(
2565 &mut self,
2566 request: impl tonic::IntoRequest<super::SetSyncLogStoreAlignedRequest>,
2567 ) -> std::result::Result<
2568 tonic::Response<super::SetSyncLogStoreAlignedResponse>,
2569 tonic::Status,
2570 > {
2571 self.inner
2572 .ready()
2573 .await
2574 .map_err(|e| {
2575 tonic::Status::unknown(
2576 format!("Service was not ready: {}", e.into()),
2577 )
2578 })?;
2579 let codec = tonic::codec::ProstCodec::default();
2580 let path = http::uri::PathAndQuery::from_static(
2581 "/meta.StreamManagerService/SetSyncLogStoreAligned",
2582 );
2583 let mut req = request.into_request();
2584 req.extensions_mut()
2585 .insert(
2586 GrpcMethod::new(
2587 "meta.StreamManagerService",
2588 "SetSyncLogStoreAligned",
2589 ),
2590 );
2591 self.inner.unary(req, path, codec).await
2592 }
2593 }
2594}
2595pub mod cluster_service_client {
2597 #![allow(
2598 unused_variables,
2599 dead_code,
2600 missing_docs,
2601 clippy::wildcard_imports,
2602 clippy::let_unit_value,
2603 )]
2604 use tonic::codegen::*;
2605 use tonic::codegen::http::Uri;
2606 #[derive(Debug, Clone)]
2607 pub struct ClusterServiceClient<T> {
2608 inner: tonic::client::Grpc<T>,
2609 }
2610 impl ClusterServiceClient<tonic::transport::Channel> {
2611 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
2613 where
2614 D: TryInto<tonic::transport::Endpoint>,
2615 D::Error: Into<StdError>,
2616 {
2617 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
2618 Ok(Self::new(conn))
2619 }
2620 }
2621 impl<T> ClusterServiceClient<T>
2622 where
2623 T: tonic::client::GrpcService<tonic::body::BoxBody>,
2624 T::Error: Into<StdError>,
2625 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
2626 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
2627 {
2628 pub fn new(inner: T) -> Self {
2629 let inner = tonic::client::Grpc::new(inner);
2630 Self { inner }
2631 }
2632 pub fn with_origin(inner: T, origin: Uri) -> Self {
2633 let inner = tonic::client::Grpc::with_origin(inner, origin);
2634 Self { inner }
2635 }
2636 pub fn with_interceptor<F>(
2637 inner: T,
2638 interceptor: F,
2639 ) -> ClusterServiceClient<InterceptedService<T, F>>
2640 where
2641 F: tonic::service::Interceptor,
2642 T::ResponseBody: Default,
2643 T: tonic::codegen::Service<
2644 http::Request<tonic::body::BoxBody>,
2645 Response = http::Response<
2646 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
2647 >,
2648 >,
2649 <T as tonic::codegen::Service<
2650 http::Request<tonic::body::BoxBody>,
2651 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
2652 {
2653 ClusterServiceClient::new(InterceptedService::new(inner, interceptor))
2654 }
2655 #[must_use]
2660 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
2661 self.inner = self.inner.send_compressed(encoding);
2662 self
2663 }
2664 #[must_use]
2666 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
2667 self.inner = self.inner.accept_compressed(encoding);
2668 self
2669 }
2670 #[must_use]
2674 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
2675 self.inner = self.inner.max_decoding_message_size(limit);
2676 self
2677 }
2678 #[must_use]
2682 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
2683 self.inner = self.inner.max_encoding_message_size(limit);
2684 self
2685 }
2686 pub async fn add_worker_node(
2687 &mut self,
2688 request: impl tonic::IntoRequest<super::AddWorkerNodeRequest>,
2689 ) -> std::result::Result<
2690 tonic::Response<super::AddWorkerNodeResponse>,
2691 tonic::Status,
2692 > {
2693 self.inner
2694 .ready()
2695 .await
2696 .map_err(|e| {
2697 tonic::Status::unknown(
2698 format!("Service was not ready: {}", e.into()),
2699 )
2700 })?;
2701 let codec = tonic::codec::ProstCodec::default();
2702 let path = http::uri::PathAndQuery::from_static(
2703 "/meta.ClusterService/AddWorkerNode",
2704 );
2705 let mut req = request.into_request();
2706 req.extensions_mut()
2707 .insert(GrpcMethod::new("meta.ClusterService", "AddWorkerNode"));
2708 self.inner.unary(req, path, codec).await
2709 }
2710 pub async fn activate_worker_node(
2711 &mut self,
2712 request: impl tonic::IntoRequest<super::ActivateWorkerNodeRequest>,
2713 ) -> std::result::Result<
2714 tonic::Response<super::ActivateWorkerNodeResponse>,
2715 tonic::Status,
2716 > {
2717 self.inner
2718 .ready()
2719 .await
2720 .map_err(|e| {
2721 tonic::Status::unknown(
2722 format!("Service was not ready: {}", e.into()),
2723 )
2724 })?;
2725 let codec = tonic::codec::ProstCodec::default();
2726 let path = http::uri::PathAndQuery::from_static(
2727 "/meta.ClusterService/ActivateWorkerNode",
2728 );
2729 let mut req = request.into_request();
2730 req.extensions_mut()
2731 .insert(GrpcMethod::new("meta.ClusterService", "ActivateWorkerNode"));
2732 self.inner.unary(req, path, codec).await
2733 }
2734 pub async fn delete_worker_node(
2735 &mut self,
2736 request: impl tonic::IntoRequest<super::DeleteWorkerNodeRequest>,
2737 ) -> std::result::Result<
2738 tonic::Response<super::DeleteWorkerNodeResponse>,
2739 tonic::Status,
2740 > {
2741 self.inner
2742 .ready()
2743 .await
2744 .map_err(|e| {
2745 tonic::Status::unknown(
2746 format!("Service was not ready: {}", e.into()),
2747 )
2748 })?;
2749 let codec = tonic::codec::ProstCodec::default();
2750 let path = http::uri::PathAndQuery::from_static(
2751 "/meta.ClusterService/DeleteWorkerNode",
2752 );
2753 let mut req = request.into_request();
2754 req.extensions_mut()
2755 .insert(GrpcMethod::new("meta.ClusterService", "DeleteWorkerNode"));
2756 self.inner.unary(req, path, codec).await
2757 }
2758 pub async fn update_worker_node_schedulability(
2759 &mut self,
2760 request: impl tonic::IntoRequest<
2761 super::UpdateWorkerNodeSchedulabilityRequest,
2762 >,
2763 ) -> std::result::Result<
2764 tonic::Response<super::UpdateWorkerNodeSchedulabilityResponse>,
2765 tonic::Status,
2766 > {
2767 self.inner
2768 .ready()
2769 .await
2770 .map_err(|e| {
2771 tonic::Status::unknown(
2772 format!("Service was not ready: {}", e.into()),
2773 )
2774 })?;
2775 let codec = tonic::codec::ProstCodec::default();
2776 let path = http::uri::PathAndQuery::from_static(
2777 "/meta.ClusterService/UpdateWorkerNodeSchedulability",
2778 );
2779 let mut req = request.into_request();
2780 req.extensions_mut()
2781 .insert(
2782 GrpcMethod::new(
2783 "meta.ClusterService",
2784 "UpdateWorkerNodeSchedulability",
2785 ),
2786 );
2787 self.inner.unary(req, path, codec).await
2788 }
2789 pub async fn list_all_nodes(
2790 &mut self,
2791 request: impl tonic::IntoRequest<super::ListAllNodesRequest>,
2792 ) -> std::result::Result<
2793 tonic::Response<super::ListAllNodesResponse>,
2794 tonic::Status,
2795 > {
2796 self.inner
2797 .ready()
2798 .await
2799 .map_err(|e| {
2800 tonic::Status::unknown(
2801 format!("Service was not ready: {}", e.into()),
2802 )
2803 })?;
2804 let codec = tonic::codec::ProstCodec::default();
2805 let path = http::uri::PathAndQuery::from_static(
2806 "/meta.ClusterService/ListAllNodes",
2807 );
2808 let mut req = request.into_request();
2809 req.extensions_mut()
2810 .insert(GrpcMethod::new("meta.ClusterService", "ListAllNodes"));
2811 self.inner.unary(req, path, codec).await
2812 }
2813 pub async fn get_cluster_recovery_status(
2814 &mut self,
2815 request: impl tonic::IntoRequest<super::GetClusterRecoveryStatusRequest>,
2816 ) -> std::result::Result<
2817 tonic::Response<super::GetClusterRecoveryStatusResponse>,
2818 tonic::Status,
2819 > {
2820 self.inner
2821 .ready()
2822 .await
2823 .map_err(|e| {
2824 tonic::Status::unknown(
2825 format!("Service was not ready: {}", e.into()),
2826 )
2827 })?;
2828 let codec = tonic::codec::ProstCodec::default();
2829 let path = http::uri::PathAndQuery::from_static(
2830 "/meta.ClusterService/GetClusterRecoveryStatus",
2831 );
2832 let mut req = request.into_request();
2833 req.extensions_mut()
2834 .insert(
2835 GrpcMethod::new("meta.ClusterService", "GetClusterRecoveryStatus"),
2836 );
2837 self.inner.unary(req, path, codec).await
2838 }
2839 pub async fn get_meta_store_info(
2840 &mut self,
2841 request: impl tonic::IntoRequest<super::GetMetaStoreInfoRequest>,
2842 ) -> std::result::Result<
2843 tonic::Response<super::GetMetaStoreInfoResponse>,
2844 tonic::Status,
2845 > {
2846 self.inner
2847 .ready()
2848 .await
2849 .map_err(|e| {
2850 tonic::Status::unknown(
2851 format!("Service was not ready: {}", e.into()),
2852 )
2853 })?;
2854 let codec = tonic::codec::ProstCodec::default();
2855 let path = http::uri::PathAndQuery::from_static(
2856 "/meta.ClusterService/GetMetaStoreInfo",
2857 );
2858 let mut req = request.into_request();
2859 req.extensions_mut()
2860 .insert(GrpcMethod::new("meta.ClusterService", "GetMetaStoreInfo"));
2861 self.inner.unary(req, path, codec).await
2862 }
2863 }
2864}
2865pub mod notification_service_client {
2867 #![allow(
2868 unused_variables,
2869 dead_code,
2870 missing_docs,
2871 clippy::wildcard_imports,
2872 clippy::let_unit_value,
2873 )]
2874 use tonic::codegen::*;
2875 use tonic::codegen::http::Uri;
2876 #[derive(Debug, Clone)]
2877 pub struct NotificationServiceClient<T> {
2878 inner: tonic::client::Grpc<T>,
2879 }
2880 impl NotificationServiceClient<tonic::transport::Channel> {
2881 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
2883 where
2884 D: TryInto<tonic::transport::Endpoint>,
2885 D::Error: Into<StdError>,
2886 {
2887 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
2888 Ok(Self::new(conn))
2889 }
2890 }
2891 impl<T> NotificationServiceClient<T>
2892 where
2893 T: tonic::client::GrpcService<tonic::body::BoxBody>,
2894 T::Error: Into<StdError>,
2895 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
2896 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
2897 {
2898 pub fn new(inner: T) -> Self {
2899 let inner = tonic::client::Grpc::new(inner);
2900 Self { inner }
2901 }
2902 pub fn with_origin(inner: T, origin: Uri) -> Self {
2903 let inner = tonic::client::Grpc::with_origin(inner, origin);
2904 Self { inner }
2905 }
2906 pub fn with_interceptor<F>(
2907 inner: T,
2908 interceptor: F,
2909 ) -> NotificationServiceClient<InterceptedService<T, F>>
2910 where
2911 F: tonic::service::Interceptor,
2912 T::ResponseBody: Default,
2913 T: tonic::codegen::Service<
2914 http::Request<tonic::body::BoxBody>,
2915 Response = http::Response<
2916 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
2917 >,
2918 >,
2919 <T as tonic::codegen::Service<
2920 http::Request<tonic::body::BoxBody>,
2921 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
2922 {
2923 NotificationServiceClient::new(InterceptedService::new(inner, interceptor))
2924 }
2925 #[must_use]
2930 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
2931 self.inner = self.inner.send_compressed(encoding);
2932 self
2933 }
2934 #[must_use]
2936 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
2937 self.inner = self.inner.accept_compressed(encoding);
2938 self
2939 }
2940 #[must_use]
2944 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
2945 self.inner = self.inner.max_decoding_message_size(limit);
2946 self
2947 }
2948 #[must_use]
2952 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
2953 self.inner = self.inner.max_encoding_message_size(limit);
2954 self
2955 }
2956 pub async fn subscribe(
2957 &mut self,
2958 request: impl tonic::IntoRequest<super::SubscribeRequest>,
2959 ) -> std::result::Result<
2960 tonic::Response<tonic::codec::Streaming<super::SubscribeResponse>>,
2961 tonic::Status,
2962 > {
2963 self.inner
2964 .ready()
2965 .await
2966 .map_err(|e| {
2967 tonic::Status::unknown(
2968 format!("Service was not ready: {}", e.into()),
2969 )
2970 })?;
2971 let codec = tonic::codec::ProstCodec::default();
2972 let path = http::uri::PathAndQuery::from_static(
2973 "/meta.NotificationService/Subscribe",
2974 );
2975 let mut req = request.into_request();
2976 req.extensions_mut()
2977 .insert(GrpcMethod::new("meta.NotificationService", "Subscribe"));
2978 self.inner.server_streaming(req, path, codec).await
2979 }
2980 }
2981}
2982pub mod scale_service_client {
2984 #![allow(
2985 unused_variables,
2986 dead_code,
2987 missing_docs,
2988 clippy::wildcard_imports,
2989 clippy::let_unit_value,
2990 )]
2991 use tonic::codegen::*;
2992 use tonic::codegen::http::Uri;
2993 #[derive(Debug, Clone)]
2995 pub struct ScaleServiceClient<T> {
2996 inner: tonic::client::Grpc<T>,
2997 }
2998 impl ScaleServiceClient<tonic::transport::Channel> {
2999 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
3001 where
3002 D: TryInto<tonic::transport::Endpoint>,
3003 D::Error: Into<StdError>,
3004 {
3005 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
3006 Ok(Self::new(conn))
3007 }
3008 }
3009 impl<T> ScaleServiceClient<T>
3010 where
3011 T: tonic::client::GrpcService<tonic::body::BoxBody>,
3012 T::Error: Into<StdError>,
3013 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
3014 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
3015 {
3016 pub fn new(inner: T) -> Self {
3017 let inner = tonic::client::Grpc::new(inner);
3018 Self { inner }
3019 }
3020 pub fn with_origin(inner: T, origin: Uri) -> Self {
3021 let inner = tonic::client::Grpc::with_origin(inner, origin);
3022 Self { inner }
3023 }
3024 pub fn with_interceptor<F>(
3025 inner: T,
3026 interceptor: F,
3027 ) -> ScaleServiceClient<InterceptedService<T, F>>
3028 where
3029 F: tonic::service::Interceptor,
3030 T::ResponseBody: Default,
3031 T: tonic::codegen::Service<
3032 http::Request<tonic::body::BoxBody>,
3033 Response = http::Response<
3034 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
3035 >,
3036 >,
3037 <T as tonic::codegen::Service<
3038 http::Request<tonic::body::BoxBody>,
3039 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
3040 {
3041 ScaleServiceClient::new(InterceptedService::new(inner, interceptor))
3042 }
3043 #[must_use]
3048 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
3049 self.inner = self.inner.send_compressed(encoding);
3050 self
3051 }
3052 #[must_use]
3054 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
3055 self.inner = self.inner.accept_compressed(encoding);
3056 self
3057 }
3058 #[must_use]
3062 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
3063 self.inner = self.inner.max_decoding_message_size(limit);
3064 self
3065 }
3066 #[must_use]
3070 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
3071 self.inner = self.inner.max_encoding_message_size(limit);
3072 self
3073 }
3074 pub async fn get_cluster_info(
3075 &mut self,
3076 request: impl tonic::IntoRequest<super::GetClusterInfoRequest>,
3077 ) -> std::result::Result<
3078 tonic::Response<super::GetClusterInfoResponse>,
3079 tonic::Status,
3080 > {
3081 self.inner
3082 .ready()
3083 .await
3084 .map_err(|e| {
3085 tonic::Status::unknown(
3086 format!("Service was not ready: {}", e.into()),
3087 )
3088 })?;
3089 let codec = tonic::codec::ProstCodec::default();
3090 let path = http::uri::PathAndQuery::from_static(
3091 "/meta.ScaleService/GetClusterInfo",
3092 );
3093 let mut req = request.into_request();
3094 req.extensions_mut()
3095 .insert(GrpcMethod::new("meta.ScaleService", "GetClusterInfo"));
3096 self.inner.unary(req, path, codec).await
3097 }
3098 pub async fn reschedule(
3099 &mut self,
3100 request: impl tonic::IntoRequest<super::RescheduleRequest>,
3101 ) -> std::result::Result<
3102 tonic::Response<super::RescheduleResponse>,
3103 tonic::Status,
3104 > {
3105 self.inner
3106 .ready()
3107 .await
3108 .map_err(|e| {
3109 tonic::Status::unknown(
3110 format!("Service was not ready: {}", e.into()),
3111 )
3112 })?;
3113 let codec = tonic::codec::ProstCodec::default();
3114 let path = http::uri::PathAndQuery::from_static(
3115 "/meta.ScaleService/Reschedule",
3116 );
3117 let mut req = request.into_request();
3118 req.extensions_mut()
3119 .insert(GrpcMethod::new("meta.ScaleService", "Reschedule"));
3120 self.inner.unary(req, path, codec).await
3121 }
3122 pub async fn update_streaming_job_node_labels(
3123 &mut self,
3124 request: impl tonic::IntoRequest<super::UpdateStreamingJobNodeLabelsRequest>,
3125 ) -> std::result::Result<
3126 tonic::Response<super::UpdateStreamingJobNodeLabelsResponse>,
3127 tonic::Status,
3128 > {
3129 self.inner
3130 .ready()
3131 .await
3132 .map_err(|e| {
3133 tonic::Status::unknown(
3134 format!("Service was not ready: {}", e.into()),
3135 )
3136 })?;
3137 let codec = tonic::codec::ProstCodec::default();
3138 let path = http::uri::PathAndQuery::from_static(
3139 "/meta.ScaleService/UpdateStreamingJobNodeLabels",
3140 );
3141 let mut req = request.into_request();
3142 req.extensions_mut()
3143 .insert(
3144 GrpcMethod::new("meta.ScaleService", "UpdateStreamingJobNodeLabels"),
3145 );
3146 self.inner.unary(req, path, codec).await
3147 }
3148 pub async fn get_serverless_streaming_jobs_status(
3149 &mut self,
3150 request: impl tonic::IntoRequest<
3151 super::GetServerlessStreamingJobsStatusRequest,
3152 >,
3153 ) -> std::result::Result<
3154 tonic::Response<super::GetServerlessStreamingJobsStatusResponse>,
3155 tonic::Status,
3156 > {
3157 self.inner
3158 .ready()
3159 .await
3160 .map_err(|e| {
3161 tonic::Status::unknown(
3162 format!("Service was not ready: {}", e.into()),
3163 )
3164 })?;
3165 let codec = tonic::codec::ProstCodec::default();
3166 let path = http::uri::PathAndQuery::from_static(
3167 "/meta.ScaleService/GetServerlessStreamingJobsStatus",
3168 );
3169 let mut req = request.into_request();
3170 req.extensions_mut()
3171 .insert(
3172 GrpcMethod::new(
3173 "meta.ScaleService",
3174 "GetServerlessStreamingJobsStatus",
3175 ),
3176 );
3177 self.inner.unary(req, path, codec).await
3178 }
3179 }
3180}
3181pub mod meta_member_service_client {
3183 #![allow(
3184 unused_variables,
3185 dead_code,
3186 missing_docs,
3187 clippy::wildcard_imports,
3188 clippy::let_unit_value,
3189 )]
3190 use tonic::codegen::*;
3191 use tonic::codegen::http::Uri;
3192 #[derive(Debug, Clone)]
3193 pub struct MetaMemberServiceClient<T> {
3194 inner: tonic::client::Grpc<T>,
3195 }
3196 impl MetaMemberServiceClient<tonic::transport::Channel> {
3197 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
3199 where
3200 D: TryInto<tonic::transport::Endpoint>,
3201 D::Error: Into<StdError>,
3202 {
3203 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
3204 Ok(Self::new(conn))
3205 }
3206 }
3207 impl<T> MetaMemberServiceClient<T>
3208 where
3209 T: tonic::client::GrpcService<tonic::body::BoxBody>,
3210 T::Error: Into<StdError>,
3211 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
3212 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
3213 {
3214 pub fn new(inner: T) -> Self {
3215 let inner = tonic::client::Grpc::new(inner);
3216 Self { inner }
3217 }
3218 pub fn with_origin(inner: T, origin: Uri) -> Self {
3219 let inner = tonic::client::Grpc::with_origin(inner, origin);
3220 Self { inner }
3221 }
3222 pub fn with_interceptor<F>(
3223 inner: T,
3224 interceptor: F,
3225 ) -> MetaMemberServiceClient<InterceptedService<T, F>>
3226 where
3227 F: tonic::service::Interceptor,
3228 T::ResponseBody: Default,
3229 T: tonic::codegen::Service<
3230 http::Request<tonic::body::BoxBody>,
3231 Response = http::Response<
3232 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
3233 >,
3234 >,
3235 <T as tonic::codegen::Service<
3236 http::Request<tonic::body::BoxBody>,
3237 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
3238 {
3239 MetaMemberServiceClient::new(InterceptedService::new(inner, interceptor))
3240 }
3241 #[must_use]
3246 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
3247 self.inner = self.inner.send_compressed(encoding);
3248 self
3249 }
3250 #[must_use]
3252 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
3253 self.inner = self.inner.accept_compressed(encoding);
3254 self
3255 }
3256 #[must_use]
3260 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
3261 self.inner = self.inner.max_decoding_message_size(limit);
3262 self
3263 }
3264 #[must_use]
3268 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
3269 self.inner = self.inner.max_encoding_message_size(limit);
3270 self
3271 }
3272 pub async fn members(
3273 &mut self,
3274 request: impl tonic::IntoRequest<super::MembersRequest>,
3275 ) -> std::result::Result<
3276 tonic::Response<super::MembersResponse>,
3277 tonic::Status,
3278 > {
3279 self.inner
3280 .ready()
3281 .await
3282 .map_err(|e| {
3283 tonic::Status::unknown(
3284 format!("Service was not ready: {}", e.into()),
3285 )
3286 })?;
3287 let codec = tonic::codec::ProstCodec::default();
3288 let path = http::uri::PathAndQuery::from_static(
3289 "/meta.MetaMemberService/Members",
3290 );
3291 let mut req = request.into_request();
3292 req.extensions_mut()
3293 .insert(GrpcMethod::new("meta.MetaMemberService", "Members"));
3294 self.inner.unary(req, path, codec).await
3295 }
3296 }
3297}
3298pub mod system_params_service_client {
3300 #![allow(
3301 unused_variables,
3302 dead_code,
3303 missing_docs,
3304 clippy::wildcard_imports,
3305 clippy::let_unit_value,
3306 )]
3307 use tonic::codegen::*;
3308 use tonic::codegen::http::Uri;
3309 #[derive(Debug, Clone)]
3310 pub struct SystemParamsServiceClient<T> {
3311 inner: tonic::client::Grpc<T>,
3312 }
3313 impl SystemParamsServiceClient<tonic::transport::Channel> {
3314 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
3316 where
3317 D: TryInto<tonic::transport::Endpoint>,
3318 D::Error: Into<StdError>,
3319 {
3320 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
3321 Ok(Self::new(conn))
3322 }
3323 }
3324 impl<T> SystemParamsServiceClient<T>
3325 where
3326 T: tonic::client::GrpcService<tonic::body::BoxBody>,
3327 T::Error: Into<StdError>,
3328 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
3329 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
3330 {
3331 pub fn new(inner: T) -> Self {
3332 let inner = tonic::client::Grpc::new(inner);
3333 Self { inner }
3334 }
3335 pub fn with_origin(inner: T, origin: Uri) -> Self {
3336 let inner = tonic::client::Grpc::with_origin(inner, origin);
3337 Self { inner }
3338 }
3339 pub fn with_interceptor<F>(
3340 inner: T,
3341 interceptor: F,
3342 ) -> SystemParamsServiceClient<InterceptedService<T, F>>
3343 where
3344 F: tonic::service::Interceptor,
3345 T::ResponseBody: Default,
3346 T: tonic::codegen::Service<
3347 http::Request<tonic::body::BoxBody>,
3348 Response = http::Response<
3349 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
3350 >,
3351 >,
3352 <T as tonic::codegen::Service<
3353 http::Request<tonic::body::BoxBody>,
3354 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
3355 {
3356 SystemParamsServiceClient::new(InterceptedService::new(inner, interceptor))
3357 }
3358 #[must_use]
3363 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
3364 self.inner = self.inner.send_compressed(encoding);
3365 self
3366 }
3367 #[must_use]
3369 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
3370 self.inner = self.inner.accept_compressed(encoding);
3371 self
3372 }
3373 #[must_use]
3377 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
3378 self.inner = self.inner.max_decoding_message_size(limit);
3379 self
3380 }
3381 #[must_use]
3385 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
3386 self.inner = self.inner.max_encoding_message_size(limit);
3387 self
3388 }
3389 pub async fn get_system_params(
3390 &mut self,
3391 request: impl tonic::IntoRequest<super::GetSystemParamsRequest>,
3392 ) -> std::result::Result<
3393 tonic::Response<super::GetSystemParamsResponse>,
3394 tonic::Status,
3395 > {
3396 self.inner
3397 .ready()
3398 .await
3399 .map_err(|e| {
3400 tonic::Status::unknown(
3401 format!("Service was not ready: {}", e.into()),
3402 )
3403 })?;
3404 let codec = tonic::codec::ProstCodec::default();
3405 let path = http::uri::PathAndQuery::from_static(
3406 "/meta.SystemParamsService/GetSystemParams",
3407 );
3408 let mut req = request.into_request();
3409 req.extensions_mut()
3410 .insert(GrpcMethod::new("meta.SystemParamsService", "GetSystemParams"));
3411 self.inner.unary(req, path, codec).await
3412 }
3413 pub async fn set_system_param(
3414 &mut self,
3415 request: impl tonic::IntoRequest<super::SetSystemParamRequest>,
3416 ) -> std::result::Result<
3417 tonic::Response<super::SetSystemParamResponse>,
3418 tonic::Status,
3419 > {
3420 self.inner
3421 .ready()
3422 .await
3423 .map_err(|e| {
3424 tonic::Status::unknown(
3425 format!("Service was not ready: {}", e.into()),
3426 )
3427 })?;
3428 let codec = tonic::codec::ProstCodec::default();
3429 let path = http::uri::PathAndQuery::from_static(
3430 "/meta.SystemParamsService/SetSystemParam",
3431 );
3432 let mut req = request.into_request();
3433 req.extensions_mut()
3434 .insert(GrpcMethod::new("meta.SystemParamsService", "SetSystemParam"));
3435 self.inner.unary(req, path, codec).await
3436 }
3437 }
3438}
3439pub mod session_param_service_client {
3441 #![allow(
3442 unused_variables,
3443 dead_code,
3444 missing_docs,
3445 clippy::wildcard_imports,
3446 clippy::let_unit_value,
3447 )]
3448 use tonic::codegen::*;
3449 use tonic::codegen::http::Uri;
3450 #[derive(Debug, Clone)]
3452 pub struct SessionParamServiceClient<T> {
3453 inner: tonic::client::Grpc<T>,
3454 }
3455 impl SessionParamServiceClient<tonic::transport::Channel> {
3456 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
3458 where
3459 D: TryInto<tonic::transport::Endpoint>,
3460 D::Error: Into<StdError>,
3461 {
3462 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
3463 Ok(Self::new(conn))
3464 }
3465 }
3466 impl<T> SessionParamServiceClient<T>
3467 where
3468 T: tonic::client::GrpcService<tonic::body::BoxBody>,
3469 T::Error: Into<StdError>,
3470 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
3471 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
3472 {
3473 pub fn new(inner: T) -> Self {
3474 let inner = tonic::client::Grpc::new(inner);
3475 Self { inner }
3476 }
3477 pub fn with_origin(inner: T, origin: Uri) -> Self {
3478 let inner = tonic::client::Grpc::with_origin(inner, origin);
3479 Self { inner }
3480 }
3481 pub fn with_interceptor<F>(
3482 inner: T,
3483 interceptor: F,
3484 ) -> SessionParamServiceClient<InterceptedService<T, F>>
3485 where
3486 F: tonic::service::Interceptor,
3487 T::ResponseBody: Default,
3488 T: tonic::codegen::Service<
3489 http::Request<tonic::body::BoxBody>,
3490 Response = http::Response<
3491 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
3492 >,
3493 >,
3494 <T as tonic::codegen::Service<
3495 http::Request<tonic::body::BoxBody>,
3496 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
3497 {
3498 SessionParamServiceClient::new(InterceptedService::new(inner, interceptor))
3499 }
3500 #[must_use]
3505 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
3506 self.inner = self.inner.send_compressed(encoding);
3507 self
3508 }
3509 #[must_use]
3511 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
3512 self.inner = self.inner.accept_compressed(encoding);
3513 self
3514 }
3515 #[must_use]
3519 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
3520 self.inner = self.inner.max_decoding_message_size(limit);
3521 self
3522 }
3523 #[must_use]
3527 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
3528 self.inner = self.inner.max_encoding_message_size(limit);
3529 self
3530 }
3531 pub async fn get_session_params(
3532 &mut self,
3533 request: impl tonic::IntoRequest<super::GetSessionParamsRequest>,
3534 ) -> std::result::Result<
3535 tonic::Response<super::GetSessionParamsResponse>,
3536 tonic::Status,
3537 > {
3538 self.inner
3539 .ready()
3540 .await
3541 .map_err(|e| {
3542 tonic::Status::unknown(
3543 format!("Service was not ready: {}", e.into()),
3544 )
3545 })?;
3546 let codec = tonic::codec::ProstCodec::default();
3547 let path = http::uri::PathAndQuery::from_static(
3548 "/meta.SessionParamService/GetSessionParams",
3549 );
3550 let mut req = request.into_request();
3551 req.extensions_mut()
3552 .insert(GrpcMethod::new("meta.SessionParamService", "GetSessionParams"));
3553 self.inner.unary(req, path, codec).await
3554 }
3555 pub async fn set_session_param(
3556 &mut self,
3557 request: impl tonic::IntoRequest<super::SetSessionParamRequest>,
3558 ) -> std::result::Result<
3559 tonic::Response<super::SetSessionParamResponse>,
3560 tonic::Status,
3561 > {
3562 self.inner
3563 .ready()
3564 .await
3565 .map_err(|e| {
3566 tonic::Status::unknown(
3567 format!("Service was not ready: {}", e.into()),
3568 )
3569 })?;
3570 let codec = tonic::codec::ProstCodec::default();
3571 let path = http::uri::PathAndQuery::from_static(
3572 "/meta.SessionParamService/SetSessionParam",
3573 );
3574 let mut req = request.into_request();
3575 req.extensions_mut()
3576 .insert(GrpcMethod::new("meta.SessionParamService", "SetSessionParam"));
3577 self.inner.unary(req, path, codec).await
3578 }
3579 }
3580}
3581pub mod serving_service_client {
3583 #![allow(
3584 unused_variables,
3585 dead_code,
3586 missing_docs,
3587 clippy::wildcard_imports,
3588 clippy::let_unit_value,
3589 )]
3590 use tonic::codegen::*;
3591 use tonic::codegen::http::Uri;
3592 #[derive(Debug, Clone)]
3593 pub struct ServingServiceClient<T> {
3594 inner: tonic::client::Grpc<T>,
3595 }
3596 impl ServingServiceClient<tonic::transport::Channel> {
3597 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
3599 where
3600 D: TryInto<tonic::transport::Endpoint>,
3601 D::Error: Into<StdError>,
3602 {
3603 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
3604 Ok(Self::new(conn))
3605 }
3606 }
3607 impl<T> ServingServiceClient<T>
3608 where
3609 T: tonic::client::GrpcService<tonic::body::BoxBody>,
3610 T::Error: Into<StdError>,
3611 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
3612 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
3613 {
3614 pub fn new(inner: T) -> Self {
3615 let inner = tonic::client::Grpc::new(inner);
3616 Self { inner }
3617 }
3618 pub fn with_origin(inner: T, origin: Uri) -> Self {
3619 let inner = tonic::client::Grpc::with_origin(inner, origin);
3620 Self { inner }
3621 }
3622 pub fn with_interceptor<F>(
3623 inner: T,
3624 interceptor: F,
3625 ) -> ServingServiceClient<InterceptedService<T, F>>
3626 where
3627 F: tonic::service::Interceptor,
3628 T::ResponseBody: Default,
3629 T: tonic::codegen::Service<
3630 http::Request<tonic::body::BoxBody>,
3631 Response = http::Response<
3632 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
3633 >,
3634 >,
3635 <T as tonic::codegen::Service<
3636 http::Request<tonic::body::BoxBody>,
3637 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
3638 {
3639 ServingServiceClient::new(InterceptedService::new(inner, interceptor))
3640 }
3641 #[must_use]
3646 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
3647 self.inner = self.inner.send_compressed(encoding);
3648 self
3649 }
3650 #[must_use]
3652 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
3653 self.inner = self.inner.accept_compressed(encoding);
3654 self
3655 }
3656 #[must_use]
3660 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
3661 self.inner = self.inner.max_decoding_message_size(limit);
3662 self
3663 }
3664 #[must_use]
3668 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
3669 self.inner = self.inner.max_encoding_message_size(limit);
3670 self
3671 }
3672 pub async fn get_serving_vnode_mappings(
3673 &mut self,
3674 request: impl tonic::IntoRequest<super::GetServingVnodeMappingsRequest>,
3675 ) -> std::result::Result<
3676 tonic::Response<super::GetServingVnodeMappingsResponse>,
3677 tonic::Status,
3678 > {
3679 self.inner
3680 .ready()
3681 .await
3682 .map_err(|e| {
3683 tonic::Status::unknown(
3684 format!("Service was not ready: {}", e.into()),
3685 )
3686 })?;
3687 let codec = tonic::codec::ProstCodec::default();
3688 let path = http::uri::PathAndQuery::from_static(
3689 "/meta.ServingService/GetServingVnodeMappings",
3690 );
3691 let mut req = request.into_request();
3692 req.extensions_mut()
3693 .insert(
3694 GrpcMethod::new("meta.ServingService", "GetServingVnodeMappings"),
3695 );
3696 self.inner.unary(req, path, codec).await
3697 }
3698 }
3699}
3700pub mod event_log_service_client {
3702 #![allow(
3703 unused_variables,
3704 dead_code,
3705 missing_docs,
3706 clippy::wildcard_imports,
3707 clippy::let_unit_value,
3708 )]
3709 use tonic::codegen::*;
3710 use tonic::codegen::http::Uri;
3711 #[derive(Debug, Clone)]
3712 pub struct EventLogServiceClient<T> {
3713 inner: tonic::client::Grpc<T>,
3714 }
3715 impl EventLogServiceClient<tonic::transport::Channel> {
3716 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
3718 where
3719 D: TryInto<tonic::transport::Endpoint>,
3720 D::Error: Into<StdError>,
3721 {
3722 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
3723 Ok(Self::new(conn))
3724 }
3725 }
3726 impl<T> EventLogServiceClient<T>
3727 where
3728 T: tonic::client::GrpcService<tonic::body::BoxBody>,
3729 T::Error: Into<StdError>,
3730 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
3731 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
3732 {
3733 pub fn new(inner: T) -> Self {
3734 let inner = tonic::client::Grpc::new(inner);
3735 Self { inner }
3736 }
3737 pub fn with_origin(inner: T, origin: Uri) -> Self {
3738 let inner = tonic::client::Grpc::with_origin(inner, origin);
3739 Self { inner }
3740 }
3741 pub fn with_interceptor<F>(
3742 inner: T,
3743 interceptor: F,
3744 ) -> EventLogServiceClient<InterceptedService<T, F>>
3745 where
3746 F: tonic::service::Interceptor,
3747 T::ResponseBody: Default,
3748 T: tonic::codegen::Service<
3749 http::Request<tonic::body::BoxBody>,
3750 Response = http::Response<
3751 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
3752 >,
3753 >,
3754 <T as tonic::codegen::Service<
3755 http::Request<tonic::body::BoxBody>,
3756 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
3757 {
3758 EventLogServiceClient::new(InterceptedService::new(inner, interceptor))
3759 }
3760 #[must_use]
3765 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
3766 self.inner = self.inner.send_compressed(encoding);
3767 self
3768 }
3769 #[must_use]
3771 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
3772 self.inner = self.inner.accept_compressed(encoding);
3773 self
3774 }
3775 #[must_use]
3779 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
3780 self.inner = self.inner.max_decoding_message_size(limit);
3781 self
3782 }
3783 #[must_use]
3787 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
3788 self.inner = self.inner.max_encoding_message_size(limit);
3789 self
3790 }
3791 pub async fn list_event_log(
3792 &mut self,
3793 request: impl tonic::IntoRequest<super::ListEventLogRequest>,
3794 ) -> std::result::Result<
3795 tonic::Response<super::ListEventLogResponse>,
3796 tonic::Status,
3797 > {
3798 self.inner
3799 .ready()
3800 .await
3801 .map_err(|e| {
3802 tonic::Status::unknown(
3803 format!("Service was not ready: {}", e.into()),
3804 )
3805 })?;
3806 let codec = tonic::codec::ProstCodec::default();
3807 let path = http::uri::PathAndQuery::from_static(
3808 "/meta.EventLogService/ListEventLog",
3809 );
3810 let mut req = request.into_request();
3811 req.extensions_mut()
3812 .insert(GrpcMethod::new("meta.EventLogService", "ListEventLog"));
3813 self.inner.unary(req, path, codec).await
3814 }
3815 pub async fn add_event_log(
3816 &mut self,
3817 request: impl tonic::IntoRequest<super::AddEventLogRequest>,
3818 ) -> std::result::Result<
3819 tonic::Response<super::AddEventLogResponse>,
3820 tonic::Status,
3821 > {
3822 self.inner
3823 .ready()
3824 .await
3825 .map_err(|e| {
3826 tonic::Status::unknown(
3827 format!("Service was not ready: {}", e.into()),
3828 )
3829 })?;
3830 let codec = tonic::codec::ProstCodec::default();
3831 let path = http::uri::PathAndQuery::from_static(
3832 "/meta.EventLogService/AddEventLog",
3833 );
3834 let mut req = request.into_request();
3835 req.extensions_mut()
3836 .insert(GrpcMethod::new("meta.EventLogService", "AddEventLog"));
3837 self.inner.unary(req, path, codec).await
3838 }
3839 }
3840}
3841pub mod cluster_limit_service_client {
3843 #![allow(
3844 unused_variables,
3845 dead_code,
3846 missing_docs,
3847 clippy::wildcard_imports,
3848 clippy::let_unit_value,
3849 )]
3850 use tonic::codegen::*;
3851 use tonic::codegen::http::Uri;
3852 #[derive(Debug, Clone)]
3853 pub struct ClusterLimitServiceClient<T> {
3854 inner: tonic::client::Grpc<T>,
3855 }
3856 impl ClusterLimitServiceClient<tonic::transport::Channel> {
3857 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
3859 where
3860 D: TryInto<tonic::transport::Endpoint>,
3861 D::Error: Into<StdError>,
3862 {
3863 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
3864 Ok(Self::new(conn))
3865 }
3866 }
3867 impl<T> ClusterLimitServiceClient<T>
3868 where
3869 T: tonic::client::GrpcService<tonic::body::BoxBody>,
3870 T::Error: Into<StdError>,
3871 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
3872 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
3873 {
3874 pub fn new(inner: T) -> Self {
3875 let inner = tonic::client::Grpc::new(inner);
3876 Self { inner }
3877 }
3878 pub fn with_origin(inner: T, origin: Uri) -> Self {
3879 let inner = tonic::client::Grpc::with_origin(inner, origin);
3880 Self { inner }
3881 }
3882 pub fn with_interceptor<F>(
3883 inner: T,
3884 interceptor: F,
3885 ) -> ClusterLimitServiceClient<InterceptedService<T, F>>
3886 where
3887 F: tonic::service::Interceptor,
3888 T::ResponseBody: Default,
3889 T: tonic::codegen::Service<
3890 http::Request<tonic::body::BoxBody>,
3891 Response = http::Response<
3892 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
3893 >,
3894 >,
3895 <T as tonic::codegen::Service<
3896 http::Request<tonic::body::BoxBody>,
3897 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
3898 {
3899 ClusterLimitServiceClient::new(InterceptedService::new(inner, interceptor))
3900 }
3901 #[must_use]
3906 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
3907 self.inner = self.inner.send_compressed(encoding);
3908 self
3909 }
3910 #[must_use]
3912 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
3913 self.inner = self.inner.accept_compressed(encoding);
3914 self
3915 }
3916 #[must_use]
3920 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
3921 self.inner = self.inner.max_decoding_message_size(limit);
3922 self
3923 }
3924 #[must_use]
3928 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
3929 self.inner = self.inner.max_encoding_message_size(limit);
3930 self
3931 }
3932 pub async fn get_cluster_limits(
3933 &mut self,
3934 request: impl tonic::IntoRequest<super::GetClusterLimitsRequest>,
3935 ) -> std::result::Result<
3936 tonic::Response<super::GetClusterLimitsResponse>,
3937 tonic::Status,
3938 > {
3939 self.inner
3940 .ready()
3941 .await
3942 .map_err(|e| {
3943 tonic::Status::unknown(
3944 format!("Service was not ready: {}", e.into()),
3945 )
3946 })?;
3947 let codec = tonic::codec::ProstCodec::default();
3948 let path = http::uri::PathAndQuery::from_static(
3949 "/meta.ClusterLimitService/GetClusterLimits",
3950 );
3951 let mut req = request.into_request();
3952 req.extensions_mut()
3953 .insert(GrpcMethod::new("meta.ClusterLimitService", "GetClusterLimits"));
3954 self.inner.unary(req, path, codec).await
3955 }
3956 }
3957}
3958pub mod hosted_iceberg_catalog_service_client {
3960 #![allow(
3961 unused_variables,
3962 dead_code,
3963 missing_docs,
3964 clippy::wildcard_imports,
3965 clippy::let_unit_value,
3966 )]
3967 use tonic::codegen::*;
3968 use tonic::codegen::http::Uri;
3969 #[derive(Debug, Clone)]
3970 pub struct HostedIcebergCatalogServiceClient<T> {
3971 inner: tonic::client::Grpc<T>,
3972 }
3973 impl HostedIcebergCatalogServiceClient<tonic::transport::Channel> {
3974 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
3976 where
3977 D: TryInto<tonic::transport::Endpoint>,
3978 D::Error: Into<StdError>,
3979 {
3980 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
3981 Ok(Self::new(conn))
3982 }
3983 }
3984 impl<T> HostedIcebergCatalogServiceClient<T>
3985 where
3986 T: tonic::client::GrpcService<tonic::body::BoxBody>,
3987 T::Error: Into<StdError>,
3988 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
3989 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
3990 {
3991 pub fn new(inner: T) -> Self {
3992 let inner = tonic::client::Grpc::new(inner);
3993 Self { inner }
3994 }
3995 pub fn with_origin(inner: T, origin: Uri) -> Self {
3996 let inner = tonic::client::Grpc::with_origin(inner, origin);
3997 Self { inner }
3998 }
3999 pub fn with_interceptor<F>(
4000 inner: T,
4001 interceptor: F,
4002 ) -> HostedIcebergCatalogServiceClient<InterceptedService<T, F>>
4003 where
4004 F: tonic::service::Interceptor,
4005 T::ResponseBody: Default,
4006 T: tonic::codegen::Service<
4007 http::Request<tonic::body::BoxBody>,
4008 Response = http::Response<
4009 <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
4010 >,
4011 >,
4012 <T as tonic::codegen::Service<
4013 http::Request<tonic::body::BoxBody>,
4014 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
4015 {
4016 HostedIcebergCatalogServiceClient::new(
4017 InterceptedService::new(inner, interceptor),
4018 )
4019 }
4020 #[must_use]
4025 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
4026 self.inner = self.inner.send_compressed(encoding);
4027 self
4028 }
4029 #[must_use]
4031 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
4032 self.inner = self.inner.accept_compressed(encoding);
4033 self
4034 }
4035 #[must_use]
4039 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
4040 self.inner = self.inner.max_decoding_message_size(limit);
4041 self
4042 }
4043 #[must_use]
4047 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
4048 self.inner = self.inner.max_encoding_message_size(limit);
4049 self
4050 }
4051 pub async fn list_iceberg_tables(
4052 &mut self,
4053 request: impl tonic::IntoRequest<super::ListIcebergTablesRequest>,
4054 ) -> std::result::Result<
4055 tonic::Response<super::ListIcebergTablesResponse>,
4056 tonic::Status,
4057 > {
4058 self.inner
4059 .ready()
4060 .await
4061 .map_err(|e| {
4062 tonic::Status::unknown(
4063 format!("Service was not ready: {}", e.into()),
4064 )
4065 })?;
4066 let codec = tonic::codec::ProstCodec::default();
4067 let path = http::uri::PathAndQuery::from_static(
4068 "/meta.HostedIcebergCatalogService/ListIcebergTables",
4069 );
4070 let mut req = request.into_request();
4071 req.extensions_mut()
4072 .insert(
4073 GrpcMethod::new(
4074 "meta.HostedIcebergCatalogService",
4075 "ListIcebergTables",
4076 ),
4077 );
4078 self.inner.unary(req, path, codec).await
4079 }
4080 }
4081}
4082pub mod telemetry_info_service_server {
4084 #![allow(
4085 unused_variables,
4086 dead_code,
4087 missing_docs,
4088 clippy::wildcard_imports,
4089 clippy::let_unit_value,
4090 )]
4091 use tonic::codegen::*;
4092 #[async_trait]
4094 pub trait TelemetryInfoService: std::marker::Send + std::marker::Sync + 'static {
4095 async fn get_telemetry_info(
4097 &self,
4098 request: tonic::Request<super::GetTelemetryInfoRequest>,
4099 ) -> std::result::Result<
4100 tonic::Response<super::TelemetryInfoResponse>,
4101 tonic::Status,
4102 >;
4103 }
4104 #[derive(Debug)]
4105 pub struct TelemetryInfoServiceServer<T> {
4106 inner: Arc<T>,
4107 accept_compression_encodings: EnabledCompressionEncodings,
4108 send_compression_encodings: EnabledCompressionEncodings,
4109 max_decoding_message_size: Option<usize>,
4110 max_encoding_message_size: Option<usize>,
4111 }
4112 impl<T> TelemetryInfoServiceServer<T> {
4113 pub fn new(inner: T) -> Self {
4114 Self::from_arc(Arc::new(inner))
4115 }
4116 pub fn from_arc(inner: Arc<T>) -> Self {
4117 Self {
4118 inner,
4119 accept_compression_encodings: Default::default(),
4120 send_compression_encodings: Default::default(),
4121 max_decoding_message_size: None,
4122 max_encoding_message_size: None,
4123 }
4124 }
4125 pub fn with_interceptor<F>(
4126 inner: T,
4127 interceptor: F,
4128 ) -> InterceptedService<Self, F>
4129 where
4130 F: tonic::service::Interceptor,
4131 {
4132 InterceptedService::new(Self::new(inner), interceptor)
4133 }
4134 #[must_use]
4136 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
4137 self.accept_compression_encodings.enable(encoding);
4138 self
4139 }
4140 #[must_use]
4142 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
4143 self.send_compression_encodings.enable(encoding);
4144 self
4145 }
4146 #[must_use]
4150 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
4151 self.max_decoding_message_size = Some(limit);
4152 self
4153 }
4154 #[must_use]
4158 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
4159 self.max_encoding_message_size = Some(limit);
4160 self
4161 }
4162 }
4163 impl<T, B> tonic::codegen::Service<http::Request<B>>
4164 for TelemetryInfoServiceServer<T>
4165 where
4166 T: TelemetryInfoService,
4167 B: Body + std::marker::Send + 'static,
4168 B::Error: Into<StdError> + std::marker::Send + 'static,
4169 {
4170 type Response = http::Response<tonic::body::BoxBody>;
4171 type Error = std::convert::Infallible;
4172 type Future = BoxFuture<Self::Response, Self::Error>;
4173 fn poll_ready(
4174 &mut self,
4175 _cx: &mut Context<'_>,
4176 ) -> Poll<std::result::Result<(), Self::Error>> {
4177 Poll::Ready(Ok(()))
4178 }
4179 fn call(&mut self, req: http::Request<B>) -> Self::Future {
4180 match req.uri().path() {
4181 "/meta.TelemetryInfoService/GetTelemetryInfo" => {
4182 #[allow(non_camel_case_types)]
4183 struct GetTelemetryInfoSvc<T: TelemetryInfoService>(pub Arc<T>);
4184 impl<
4185 T: TelemetryInfoService,
4186 > tonic::server::UnaryService<super::GetTelemetryInfoRequest>
4187 for GetTelemetryInfoSvc<T> {
4188 type Response = super::TelemetryInfoResponse;
4189 type Future = BoxFuture<
4190 tonic::Response<Self::Response>,
4191 tonic::Status,
4192 >;
4193 fn call(
4194 &mut self,
4195 request: tonic::Request<super::GetTelemetryInfoRequest>,
4196 ) -> Self::Future {
4197 let inner = Arc::clone(&self.0);
4198 let fut = async move {
4199 <T as TelemetryInfoService>::get_telemetry_info(
4200 &inner,
4201 request,
4202 )
4203 .await
4204 };
4205 Box::pin(fut)
4206 }
4207 }
4208 let accept_compression_encodings = self.accept_compression_encodings;
4209 let send_compression_encodings = self.send_compression_encodings;
4210 let max_decoding_message_size = self.max_decoding_message_size;
4211 let max_encoding_message_size = self.max_encoding_message_size;
4212 let inner = self.inner.clone();
4213 let fut = async move {
4214 let method = GetTelemetryInfoSvc(inner);
4215 let codec = tonic::codec::ProstCodec::default();
4216 let mut grpc = tonic::server::Grpc::new(codec)
4217 .apply_compression_config(
4218 accept_compression_encodings,
4219 send_compression_encodings,
4220 )
4221 .apply_max_message_size_config(
4222 max_decoding_message_size,
4223 max_encoding_message_size,
4224 );
4225 let res = grpc.unary(method, req).await;
4226 Ok(res)
4227 };
4228 Box::pin(fut)
4229 }
4230 _ => {
4231 Box::pin(async move {
4232 let mut response = http::Response::new(empty_body());
4233 let headers = response.headers_mut();
4234 headers
4235 .insert(
4236 tonic::Status::GRPC_STATUS,
4237 (tonic::Code::Unimplemented as i32).into(),
4238 );
4239 headers
4240 .insert(
4241 http::header::CONTENT_TYPE,
4242 tonic::metadata::GRPC_CONTENT_TYPE,
4243 );
4244 Ok(response)
4245 })
4246 }
4247 }
4248 }
4249 }
4250 impl<T> Clone for TelemetryInfoServiceServer<T> {
4251 fn clone(&self) -> Self {
4252 let inner = self.inner.clone();
4253 Self {
4254 inner,
4255 accept_compression_encodings: self.accept_compression_encodings,
4256 send_compression_encodings: self.send_compression_encodings,
4257 max_decoding_message_size: self.max_decoding_message_size,
4258 max_encoding_message_size: self.max_encoding_message_size,
4259 }
4260 }
4261 }
4262 pub const SERVICE_NAME: &str = "meta.TelemetryInfoService";
4264 impl<T> tonic::server::NamedService for TelemetryInfoServiceServer<T> {
4265 const NAME: &'static str = SERVICE_NAME;
4266 }
4267}
4268pub mod heartbeat_service_server {
4270 #![allow(
4271 unused_variables,
4272 dead_code,
4273 missing_docs,
4274 clippy::wildcard_imports,
4275 clippy::let_unit_value,
4276 )]
4277 use tonic::codegen::*;
4278 #[async_trait]
4280 pub trait HeartbeatService: std::marker::Send + std::marker::Sync + 'static {
4281 async fn heartbeat(
4282 &self,
4283 request: tonic::Request<super::HeartbeatRequest>,
4284 ) -> std::result::Result<
4285 tonic::Response<super::HeartbeatResponse>,
4286 tonic::Status,
4287 >;
4288 }
4289 #[derive(Debug)]
4290 pub struct HeartbeatServiceServer<T> {
4291 inner: Arc<T>,
4292 accept_compression_encodings: EnabledCompressionEncodings,
4293 send_compression_encodings: EnabledCompressionEncodings,
4294 max_decoding_message_size: Option<usize>,
4295 max_encoding_message_size: Option<usize>,
4296 }
4297 impl<T> HeartbeatServiceServer<T> {
4298 pub fn new(inner: T) -> Self {
4299 Self::from_arc(Arc::new(inner))
4300 }
4301 pub fn from_arc(inner: Arc<T>) -> Self {
4302 Self {
4303 inner,
4304 accept_compression_encodings: Default::default(),
4305 send_compression_encodings: Default::default(),
4306 max_decoding_message_size: None,
4307 max_encoding_message_size: None,
4308 }
4309 }
4310 pub fn with_interceptor<F>(
4311 inner: T,
4312 interceptor: F,
4313 ) -> InterceptedService<Self, F>
4314 where
4315 F: tonic::service::Interceptor,
4316 {
4317 InterceptedService::new(Self::new(inner), interceptor)
4318 }
4319 #[must_use]
4321 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
4322 self.accept_compression_encodings.enable(encoding);
4323 self
4324 }
4325 #[must_use]
4327 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
4328 self.send_compression_encodings.enable(encoding);
4329 self
4330 }
4331 #[must_use]
4335 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
4336 self.max_decoding_message_size = Some(limit);
4337 self
4338 }
4339 #[must_use]
4343 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
4344 self.max_encoding_message_size = Some(limit);
4345 self
4346 }
4347 }
4348 impl<T, B> tonic::codegen::Service<http::Request<B>> for HeartbeatServiceServer<T>
4349 where
4350 T: HeartbeatService,
4351 B: Body + std::marker::Send + 'static,
4352 B::Error: Into<StdError> + std::marker::Send + 'static,
4353 {
4354 type Response = http::Response<tonic::body::BoxBody>;
4355 type Error = std::convert::Infallible;
4356 type Future = BoxFuture<Self::Response, Self::Error>;
4357 fn poll_ready(
4358 &mut self,
4359 _cx: &mut Context<'_>,
4360 ) -> Poll<std::result::Result<(), Self::Error>> {
4361 Poll::Ready(Ok(()))
4362 }
4363 fn call(&mut self, req: http::Request<B>) -> Self::Future {
4364 match req.uri().path() {
4365 "/meta.HeartbeatService/Heartbeat" => {
4366 #[allow(non_camel_case_types)]
4367 struct HeartbeatSvc<T: HeartbeatService>(pub Arc<T>);
4368 impl<
4369 T: HeartbeatService,
4370 > tonic::server::UnaryService<super::HeartbeatRequest>
4371 for HeartbeatSvc<T> {
4372 type Response = super::HeartbeatResponse;
4373 type Future = BoxFuture<
4374 tonic::Response<Self::Response>,
4375 tonic::Status,
4376 >;
4377 fn call(
4378 &mut self,
4379 request: tonic::Request<super::HeartbeatRequest>,
4380 ) -> Self::Future {
4381 let inner = Arc::clone(&self.0);
4382 let fut = async move {
4383 <T as HeartbeatService>::heartbeat(&inner, request).await
4384 };
4385 Box::pin(fut)
4386 }
4387 }
4388 let accept_compression_encodings = self.accept_compression_encodings;
4389 let send_compression_encodings = self.send_compression_encodings;
4390 let max_decoding_message_size = self.max_decoding_message_size;
4391 let max_encoding_message_size = self.max_encoding_message_size;
4392 let inner = self.inner.clone();
4393 let fut = async move {
4394 let method = HeartbeatSvc(inner);
4395 let codec = tonic::codec::ProstCodec::default();
4396 let mut grpc = tonic::server::Grpc::new(codec)
4397 .apply_compression_config(
4398 accept_compression_encodings,
4399 send_compression_encodings,
4400 )
4401 .apply_max_message_size_config(
4402 max_decoding_message_size,
4403 max_encoding_message_size,
4404 );
4405 let res = grpc.unary(method, req).await;
4406 Ok(res)
4407 };
4408 Box::pin(fut)
4409 }
4410 _ => {
4411 Box::pin(async move {
4412 let mut response = http::Response::new(empty_body());
4413 let headers = response.headers_mut();
4414 headers
4415 .insert(
4416 tonic::Status::GRPC_STATUS,
4417 (tonic::Code::Unimplemented as i32).into(),
4418 );
4419 headers
4420 .insert(
4421 http::header::CONTENT_TYPE,
4422 tonic::metadata::GRPC_CONTENT_TYPE,
4423 );
4424 Ok(response)
4425 })
4426 }
4427 }
4428 }
4429 }
4430 impl<T> Clone for HeartbeatServiceServer<T> {
4431 fn clone(&self) -> Self {
4432 let inner = self.inner.clone();
4433 Self {
4434 inner,
4435 accept_compression_encodings: self.accept_compression_encodings,
4436 send_compression_encodings: self.send_compression_encodings,
4437 max_decoding_message_size: self.max_decoding_message_size,
4438 max_encoding_message_size: self.max_encoding_message_size,
4439 }
4440 }
4441 }
4442 pub const SERVICE_NAME: &str = "meta.HeartbeatService";
4444 impl<T> tonic::server::NamedService for HeartbeatServiceServer<T> {
4445 const NAME: &'static str = SERVICE_NAME;
4446 }
4447}
4448pub mod stream_manager_service_server {
4450 #![allow(
4451 unused_variables,
4452 dead_code,
4453 missing_docs,
4454 clippy::wildcard_imports,
4455 clippy::let_unit_value,
4456 )]
4457 use tonic::codegen::*;
4458 #[async_trait]
4460 pub trait StreamManagerService: std::marker::Send + std::marker::Sync + 'static {
4461 async fn flush(
4462 &self,
4463 request: tonic::Request<super::FlushRequest>,
4464 ) -> std::result::Result<tonic::Response<super::FlushResponse>, tonic::Status>;
4465 async fn pause(
4466 &self,
4467 request: tonic::Request<super::PauseRequest>,
4468 ) -> std::result::Result<tonic::Response<super::PauseResponse>, tonic::Status>;
4469 async fn resume(
4470 &self,
4471 request: tonic::Request<super::ResumeRequest>,
4472 ) -> std::result::Result<tonic::Response<super::ResumeResponse>, tonic::Status>;
4473 async fn cancel_creating_jobs(
4474 &self,
4475 request: tonic::Request<super::CancelCreatingJobsRequest>,
4476 ) -> std::result::Result<
4477 tonic::Response<super::CancelCreatingJobsResponse>,
4478 tonic::Status,
4479 >;
4480 async fn list_table_fragments(
4481 &self,
4482 request: tonic::Request<super::ListTableFragmentsRequest>,
4483 ) -> std::result::Result<
4484 tonic::Response<super::ListTableFragmentsResponse>,
4485 tonic::Status,
4486 >;
4487 async fn list_streaming_job_states(
4488 &self,
4489 request: tonic::Request<super::ListStreamingJobStatesRequest>,
4490 ) -> std::result::Result<
4491 tonic::Response<super::ListStreamingJobStatesResponse>,
4492 tonic::Status,
4493 >;
4494 async fn list_fragment_distribution(
4495 &self,
4496 request: tonic::Request<super::ListFragmentDistributionRequest>,
4497 ) -> std::result::Result<
4498 tonic::Response<super::ListFragmentDistributionResponse>,
4499 tonic::Status,
4500 >;
4501 async fn list_creating_fragment_distribution(
4502 &self,
4503 request: tonic::Request<super::ListCreatingFragmentDistributionRequest>,
4504 ) -> std::result::Result<
4505 tonic::Response<super::ListCreatingFragmentDistributionResponse>,
4506 tonic::Status,
4507 >;
4508 async fn list_actor_states(
4509 &self,
4510 request: tonic::Request<super::ListActorStatesRequest>,
4511 ) -> std::result::Result<
4512 tonic::Response<super::ListActorStatesResponse>,
4513 tonic::Status,
4514 >;
4515 async fn list_actor_splits(
4516 &self,
4517 request: tonic::Request<super::ListActorSplitsRequest>,
4518 ) -> std::result::Result<
4519 tonic::Response<super::ListActorSplitsResponse>,
4520 tonic::Status,
4521 >;
4522 async fn list_object_dependencies(
4523 &self,
4524 request: tonic::Request<super::ListObjectDependenciesRequest>,
4525 ) -> std::result::Result<
4526 tonic::Response<super::ListObjectDependenciesResponse>,
4527 tonic::Status,
4528 >;
4529 async fn apply_throttle(
4530 &self,
4531 request: tonic::Request<super::ApplyThrottleRequest>,
4532 ) -> std::result::Result<
4533 tonic::Response<super::ApplyThrottleResponse>,
4534 tonic::Status,
4535 >;
4536 async fn recover(
4537 &self,
4538 request: tonic::Request<super::RecoverRequest>,
4539 ) -> std::result::Result<tonic::Response<super::RecoverResponse>, tonic::Status>;
4540 async fn list_rate_limits(
4541 &self,
4542 request: tonic::Request<super::ListRateLimitsRequest>,
4543 ) -> std::result::Result<
4544 tonic::Response<super::ListRateLimitsResponse>,
4545 tonic::Status,
4546 >;
4547 async fn alter_connector_props(
4548 &self,
4549 request: tonic::Request<super::AlterConnectorPropsRequest>,
4550 ) -> std::result::Result<
4551 tonic::Response<super::AlterConnectorPropsResponse>,
4552 tonic::Status,
4553 >;
4554 async fn get_fragment_by_id(
4555 &self,
4556 request: tonic::Request<super::GetFragmentByIdRequest>,
4557 ) -> std::result::Result<
4558 tonic::Response<super::GetFragmentByIdResponse>,
4559 tonic::Status,
4560 >;
4561 async fn set_sync_log_store_aligned(
4562 &self,
4563 request: tonic::Request<super::SetSyncLogStoreAlignedRequest>,
4564 ) -> std::result::Result<
4565 tonic::Response<super::SetSyncLogStoreAlignedResponse>,
4566 tonic::Status,
4567 >;
4568 }
4569 #[derive(Debug)]
4570 pub struct StreamManagerServiceServer<T> {
4571 inner: Arc<T>,
4572 accept_compression_encodings: EnabledCompressionEncodings,
4573 send_compression_encodings: EnabledCompressionEncodings,
4574 max_decoding_message_size: Option<usize>,
4575 max_encoding_message_size: Option<usize>,
4576 }
4577 impl<T> StreamManagerServiceServer<T> {
4578 pub fn new(inner: T) -> Self {
4579 Self::from_arc(Arc::new(inner))
4580 }
4581 pub fn from_arc(inner: Arc<T>) -> Self {
4582 Self {
4583 inner,
4584 accept_compression_encodings: Default::default(),
4585 send_compression_encodings: Default::default(),
4586 max_decoding_message_size: None,
4587 max_encoding_message_size: None,
4588 }
4589 }
4590 pub fn with_interceptor<F>(
4591 inner: T,
4592 interceptor: F,
4593 ) -> InterceptedService<Self, F>
4594 where
4595 F: tonic::service::Interceptor,
4596 {
4597 InterceptedService::new(Self::new(inner), interceptor)
4598 }
4599 #[must_use]
4601 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
4602 self.accept_compression_encodings.enable(encoding);
4603 self
4604 }
4605 #[must_use]
4607 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
4608 self.send_compression_encodings.enable(encoding);
4609 self
4610 }
4611 #[must_use]
4615 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
4616 self.max_decoding_message_size = Some(limit);
4617 self
4618 }
4619 #[must_use]
4623 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
4624 self.max_encoding_message_size = Some(limit);
4625 self
4626 }
4627 }
4628 impl<T, B> tonic::codegen::Service<http::Request<B>>
4629 for StreamManagerServiceServer<T>
4630 where
4631 T: StreamManagerService,
4632 B: Body + std::marker::Send + 'static,
4633 B::Error: Into<StdError> + std::marker::Send + 'static,
4634 {
4635 type Response = http::Response<tonic::body::BoxBody>;
4636 type Error = std::convert::Infallible;
4637 type Future = BoxFuture<Self::Response, Self::Error>;
4638 fn poll_ready(
4639 &mut self,
4640 _cx: &mut Context<'_>,
4641 ) -> Poll<std::result::Result<(), Self::Error>> {
4642 Poll::Ready(Ok(()))
4643 }
4644 fn call(&mut self, req: http::Request<B>) -> Self::Future {
4645 match req.uri().path() {
4646 "/meta.StreamManagerService/Flush" => {
4647 #[allow(non_camel_case_types)]
4648 struct FlushSvc<T: StreamManagerService>(pub Arc<T>);
4649 impl<
4650 T: StreamManagerService,
4651 > tonic::server::UnaryService<super::FlushRequest> for FlushSvc<T> {
4652 type Response = super::FlushResponse;
4653 type Future = BoxFuture<
4654 tonic::Response<Self::Response>,
4655 tonic::Status,
4656 >;
4657 fn call(
4658 &mut self,
4659 request: tonic::Request<super::FlushRequest>,
4660 ) -> Self::Future {
4661 let inner = Arc::clone(&self.0);
4662 let fut = async move {
4663 <T as StreamManagerService>::flush(&inner, request).await
4664 };
4665 Box::pin(fut)
4666 }
4667 }
4668 let accept_compression_encodings = self.accept_compression_encodings;
4669 let send_compression_encodings = self.send_compression_encodings;
4670 let max_decoding_message_size = self.max_decoding_message_size;
4671 let max_encoding_message_size = self.max_encoding_message_size;
4672 let inner = self.inner.clone();
4673 let fut = async move {
4674 let method = FlushSvc(inner);
4675 let codec = tonic::codec::ProstCodec::default();
4676 let mut grpc = tonic::server::Grpc::new(codec)
4677 .apply_compression_config(
4678 accept_compression_encodings,
4679 send_compression_encodings,
4680 )
4681 .apply_max_message_size_config(
4682 max_decoding_message_size,
4683 max_encoding_message_size,
4684 );
4685 let res = grpc.unary(method, req).await;
4686 Ok(res)
4687 };
4688 Box::pin(fut)
4689 }
4690 "/meta.StreamManagerService/Pause" => {
4691 #[allow(non_camel_case_types)]
4692 struct PauseSvc<T: StreamManagerService>(pub Arc<T>);
4693 impl<
4694 T: StreamManagerService,
4695 > tonic::server::UnaryService<super::PauseRequest> for PauseSvc<T> {
4696 type Response = super::PauseResponse;
4697 type Future = BoxFuture<
4698 tonic::Response<Self::Response>,
4699 tonic::Status,
4700 >;
4701 fn call(
4702 &mut self,
4703 request: tonic::Request<super::PauseRequest>,
4704 ) -> Self::Future {
4705 let inner = Arc::clone(&self.0);
4706 let fut = async move {
4707 <T as StreamManagerService>::pause(&inner, request).await
4708 };
4709 Box::pin(fut)
4710 }
4711 }
4712 let accept_compression_encodings = self.accept_compression_encodings;
4713 let send_compression_encodings = self.send_compression_encodings;
4714 let max_decoding_message_size = self.max_decoding_message_size;
4715 let max_encoding_message_size = self.max_encoding_message_size;
4716 let inner = self.inner.clone();
4717 let fut = async move {
4718 let method = PauseSvc(inner);
4719 let codec = tonic::codec::ProstCodec::default();
4720 let mut grpc = tonic::server::Grpc::new(codec)
4721 .apply_compression_config(
4722 accept_compression_encodings,
4723 send_compression_encodings,
4724 )
4725 .apply_max_message_size_config(
4726 max_decoding_message_size,
4727 max_encoding_message_size,
4728 );
4729 let res = grpc.unary(method, req).await;
4730 Ok(res)
4731 };
4732 Box::pin(fut)
4733 }
4734 "/meta.StreamManagerService/Resume" => {
4735 #[allow(non_camel_case_types)]
4736 struct ResumeSvc<T: StreamManagerService>(pub Arc<T>);
4737 impl<
4738 T: StreamManagerService,
4739 > tonic::server::UnaryService<super::ResumeRequest>
4740 for ResumeSvc<T> {
4741 type Response = super::ResumeResponse;
4742 type Future = BoxFuture<
4743 tonic::Response<Self::Response>,
4744 tonic::Status,
4745 >;
4746 fn call(
4747 &mut self,
4748 request: tonic::Request<super::ResumeRequest>,
4749 ) -> Self::Future {
4750 let inner = Arc::clone(&self.0);
4751 let fut = async move {
4752 <T as StreamManagerService>::resume(&inner, request).await
4753 };
4754 Box::pin(fut)
4755 }
4756 }
4757 let accept_compression_encodings = self.accept_compression_encodings;
4758 let send_compression_encodings = self.send_compression_encodings;
4759 let max_decoding_message_size = self.max_decoding_message_size;
4760 let max_encoding_message_size = self.max_encoding_message_size;
4761 let inner = self.inner.clone();
4762 let fut = async move {
4763 let method = ResumeSvc(inner);
4764 let codec = tonic::codec::ProstCodec::default();
4765 let mut grpc = tonic::server::Grpc::new(codec)
4766 .apply_compression_config(
4767 accept_compression_encodings,
4768 send_compression_encodings,
4769 )
4770 .apply_max_message_size_config(
4771 max_decoding_message_size,
4772 max_encoding_message_size,
4773 );
4774 let res = grpc.unary(method, req).await;
4775 Ok(res)
4776 };
4777 Box::pin(fut)
4778 }
4779 "/meta.StreamManagerService/CancelCreatingJobs" => {
4780 #[allow(non_camel_case_types)]
4781 struct CancelCreatingJobsSvc<T: StreamManagerService>(pub Arc<T>);
4782 impl<
4783 T: StreamManagerService,
4784 > tonic::server::UnaryService<super::CancelCreatingJobsRequest>
4785 for CancelCreatingJobsSvc<T> {
4786 type Response = super::CancelCreatingJobsResponse;
4787 type Future = BoxFuture<
4788 tonic::Response<Self::Response>,
4789 tonic::Status,
4790 >;
4791 fn call(
4792 &mut self,
4793 request: tonic::Request<super::CancelCreatingJobsRequest>,
4794 ) -> Self::Future {
4795 let inner = Arc::clone(&self.0);
4796 let fut = async move {
4797 <T as StreamManagerService>::cancel_creating_jobs(
4798 &inner,
4799 request,
4800 )
4801 .await
4802 };
4803 Box::pin(fut)
4804 }
4805 }
4806 let accept_compression_encodings = self.accept_compression_encodings;
4807 let send_compression_encodings = self.send_compression_encodings;
4808 let max_decoding_message_size = self.max_decoding_message_size;
4809 let max_encoding_message_size = self.max_encoding_message_size;
4810 let inner = self.inner.clone();
4811 let fut = async move {
4812 let method = CancelCreatingJobsSvc(inner);
4813 let codec = tonic::codec::ProstCodec::default();
4814 let mut grpc = tonic::server::Grpc::new(codec)
4815 .apply_compression_config(
4816 accept_compression_encodings,
4817 send_compression_encodings,
4818 )
4819 .apply_max_message_size_config(
4820 max_decoding_message_size,
4821 max_encoding_message_size,
4822 );
4823 let res = grpc.unary(method, req).await;
4824 Ok(res)
4825 };
4826 Box::pin(fut)
4827 }
4828 "/meta.StreamManagerService/ListTableFragments" => {
4829 #[allow(non_camel_case_types)]
4830 struct ListTableFragmentsSvc<T: StreamManagerService>(pub Arc<T>);
4831 impl<
4832 T: StreamManagerService,
4833 > tonic::server::UnaryService<super::ListTableFragmentsRequest>
4834 for ListTableFragmentsSvc<T> {
4835 type Response = super::ListTableFragmentsResponse;
4836 type Future = BoxFuture<
4837 tonic::Response<Self::Response>,
4838 tonic::Status,
4839 >;
4840 fn call(
4841 &mut self,
4842 request: tonic::Request<super::ListTableFragmentsRequest>,
4843 ) -> Self::Future {
4844 let inner = Arc::clone(&self.0);
4845 let fut = async move {
4846 <T as StreamManagerService>::list_table_fragments(
4847 &inner,
4848 request,
4849 )
4850 .await
4851 };
4852 Box::pin(fut)
4853 }
4854 }
4855 let accept_compression_encodings = self.accept_compression_encodings;
4856 let send_compression_encodings = self.send_compression_encodings;
4857 let max_decoding_message_size = self.max_decoding_message_size;
4858 let max_encoding_message_size = self.max_encoding_message_size;
4859 let inner = self.inner.clone();
4860 let fut = async move {
4861 let method = ListTableFragmentsSvc(inner);
4862 let codec = tonic::codec::ProstCodec::default();
4863 let mut grpc = tonic::server::Grpc::new(codec)
4864 .apply_compression_config(
4865 accept_compression_encodings,
4866 send_compression_encodings,
4867 )
4868 .apply_max_message_size_config(
4869 max_decoding_message_size,
4870 max_encoding_message_size,
4871 );
4872 let res = grpc.unary(method, req).await;
4873 Ok(res)
4874 };
4875 Box::pin(fut)
4876 }
4877 "/meta.StreamManagerService/ListStreamingJobStates" => {
4878 #[allow(non_camel_case_types)]
4879 struct ListStreamingJobStatesSvc<T: StreamManagerService>(
4880 pub Arc<T>,
4881 );
4882 impl<
4883 T: StreamManagerService,
4884 > tonic::server::UnaryService<super::ListStreamingJobStatesRequest>
4885 for ListStreamingJobStatesSvc<T> {
4886 type Response = super::ListStreamingJobStatesResponse;
4887 type Future = BoxFuture<
4888 tonic::Response<Self::Response>,
4889 tonic::Status,
4890 >;
4891 fn call(
4892 &mut self,
4893 request: tonic::Request<super::ListStreamingJobStatesRequest>,
4894 ) -> Self::Future {
4895 let inner = Arc::clone(&self.0);
4896 let fut = async move {
4897 <T as StreamManagerService>::list_streaming_job_states(
4898 &inner,
4899 request,
4900 )
4901 .await
4902 };
4903 Box::pin(fut)
4904 }
4905 }
4906 let accept_compression_encodings = self.accept_compression_encodings;
4907 let send_compression_encodings = self.send_compression_encodings;
4908 let max_decoding_message_size = self.max_decoding_message_size;
4909 let max_encoding_message_size = self.max_encoding_message_size;
4910 let inner = self.inner.clone();
4911 let fut = async move {
4912 let method = ListStreamingJobStatesSvc(inner);
4913 let codec = tonic::codec::ProstCodec::default();
4914 let mut grpc = tonic::server::Grpc::new(codec)
4915 .apply_compression_config(
4916 accept_compression_encodings,
4917 send_compression_encodings,
4918 )
4919 .apply_max_message_size_config(
4920 max_decoding_message_size,
4921 max_encoding_message_size,
4922 );
4923 let res = grpc.unary(method, req).await;
4924 Ok(res)
4925 };
4926 Box::pin(fut)
4927 }
4928 "/meta.StreamManagerService/ListFragmentDistribution" => {
4929 #[allow(non_camel_case_types)]
4930 struct ListFragmentDistributionSvc<T: StreamManagerService>(
4931 pub Arc<T>,
4932 );
4933 impl<
4934 T: StreamManagerService,
4935 > tonic::server::UnaryService<super::ListFragmentDistributionRequest>
4936 for ListFragmentDistributionSvc<T> {
4937 type Response = super::ListFragmentDistributionResponse;
4938 type Future = BoxFuture<
4939 tonic::Response<Self::Response>,
4940 tonic::Status,
4941 >;
4942 fn call(
4943 &mut self,
4944 request: tonic::Request<
4945 super::ListFragmentDistributionRequest,
4946 >,
4947 ) -> Self::Future {
4948 let inner = Arc::clone(&self.0);
4949 let fut = async move {
4950 <T as StreamManagerService>::list_fragment_distribution(
4951 &inner,
4952 request,
4953 )
4954 .await
4955 };
4956 Box::pin(fut)
4957 }
4958 }
4959 let accept_compression_encodings = self.accept_compression_encodings;
4960 let send_compression_encodings = self.send_compression_encodings;
4961 let max_decoding_message_size = self.max_decoding_message_size;
4962 let max_encoding_message_size = self.max_encoding_message_size;
4963 let inner = self.inner.clone();
4964 let fut = async move {
4965 let method = ListFragmentDistributionSvc(inner);
4966 let codec = tonic::codec::ProstCodec::default();
4967 let mut grpc = tonic::server::Grpc::new(codec)
4968 .apply_compression_config(
4969 accept_compression_encodings,
4970 send_compression_encodings,
4971 )
4972 .apply_max_message_size_config(
4973 max_decoding_message_size,
4974 max_encoding_message_size,
4975 );
4976 let res = grpc.unary(method, req).await;
4977 Ok(res)
4978 };
4979 Box::pin(fut)
4980 }
4981 "/meta.StreamManagerService/ListCreatingFragmentDistribution" => {
4982 #[allow(non_camel_case_types)]
4983 struct ListCreatingFragmentDistributionSvc<T: StreamManagerService>(
4984 pub Arc<T>,
4985 );
4986 impl<
4987 T: StreamManagerService,
4988 > tonic::server::UnaryService<
4989 super::ListCreatingFragmentDistributionRequest,
4990 > for ListCreatingFragmentDistributionSvc<T> {
4991 type Response = super::ListCreatingFragmentDistributionResponse;
4992 type Future = BoxFuture<
4993 tonic::Response<Self::Response>,
4994 tonic::Status,
4995 >;
4996 fn call(
4997 &mut self,
4998 request: tonic::Request<
4999 super::ListCreatingFragmentDistributionRequest,
5000 >,
5001 ) -> Self::Future {
5002 let inner = Arc::clone(&self.0);
5003 let fut = async move {
5004 <T as StreamManagerService>::list_creating_fragment_distribution(
5005 &inner,
5006 request,
5007 )
5008 .await
5009 };
5010 Box::pin(fut)
5011 }
5012 }
5013 let accept_compression_encodings = self.accept_compression_encodings;
5014 let send_compression_encodings = self.send_compression_encodings;
5015 let max_decoding_message_size = self.max_decoding_message_size;
5016 let max_encoding_message_size = self.max_encoding_message_size;
5017 let inner = self.inner.clone();
5018 let fut = async move {
5019 let method = ListCreatingFragmentDistributionSvc(inner);
5020 let codec = tonic::codec::ProstCodec::default();
5021 let mut grpc = tonic::server::Grpc::new(codec)
5022 .apply_compression_config(
5023 accept_compression_encodings,
5024 send_compression_encodings,
5025 )
5026 .apply_max_message_size_config(
5027 max_decoding_message_size,
5028 max_encoding_message_size,
5029 );
5030 let res = grpc.unary(method, req).await;
5031 Ok(res)
5032 };
5033 Box::pin(fut)
5034 }
5035 "/meta.StreamManagerService/ListActorStates" => {
5036 #[allow(non_camel_case_types)]
5037 struct ListActorStatesSvc<T: StreamManagerService>(pub Arc<T>);
5038 impl<
5039 T: StreamManagerService,
5040 > tonic::server::UnaryService<super::ListActorStatesRequest>
5041 for ListActorStatesSvc<T> {
5042 type Response = super::ListActorStatesResponse;
5043 type Future = BoxFuture<
5044 tonic::Response<Self::Response>,
5045 tonic::Status,
5046 >;
5047 fn call(
5048 &mut self,
5049 request: tonic::Request<super::ListActorStatesRequest>,
5050 ) -> Self::Future {
5051 let inner = Arc::clone(&self.0);
5052 let fut = async move {
5053 <T as StreamManagerService>::list_actor_states(
5054 &inner,
5055 request,
5056 )
5057 .await
5058 };
5059 Box::pin(fut)
5060 }
5061 }
5062 let accept_compression_encodings = self.accept_compression_encodings;
5063 let send_compression_encodings = self.send_compression_encodings;
5064 let max_decoding_message_size = self.max_decoding_message_size;
5065 let max_encoding_message_size = self.max_encoding_message_size;
5066 let inner = self.inner.clone();
5067 let fut = async move {
5068 let method = ListActorStatesSvc(inner);
5069 let codec = tonic::codec::ProstCodec::default();
5070 let mut grpc = tonic::server::Grpc::new(codec)
5071 .apply_compression_config(
5072 accept_compression_encodings,
5073 send_compression_encodings,
5074 )
5075 .apply_max_message_size_config(
5076 max_decoding_message_size,
5077 max_encoding_message_size,
5078 );
5079 let res = grpc.unary(method, req).await;
5080 Ok(res)
5081 };
5082 Box::pin(fut)
5083 }
5084 "/meta.StreamManagerService/ListActorSplits" => {
5085 #[allow(non_camel_case_types)]
5086 struct ListActorSplitsSvc<T: StreamManagerService>(pub Arc<T>);
5087 impl<
5088 T: StreamManagerService,
5089 > tonic::server::UnaryService<super::ListActorSplitsRequest>
5090 for ListActorSplitsSvc<T> {
5091 type Response = super::ListActorSplitsResponse;
5092 type Future = BoxFuture<
5093 tonic::Response<Self::Response>,
5094 tonic::Status,
5095 >;
5096 fn call(
5097 &mut self,
5098 request: tonic::Request<super::ListActorSplitsRequest>,
5099 ) -> Self::Future {
5100 let inner = Arc::clone(&self.0);
5101 let fut = async move {
5102 <T as StreamManagerService>::list_actor_splits(
5103 &inner,
5104 request,
5105 )
5106 .await
5107 };
5108 Box::pin(fut)
5109 }
5110 }
5111 let accept_compression_encodings = self.accept_compression_encodings;
5112 let send_compression_encodings = self.send_compression_encodings;
5113 let max_decoding_message_size = self.max_decoding_message_size;
5114 let max_encoding_message_size = self.max_encoding_message_size;
5115 let inner = self.inner.clone();
5116 let fut = async move {
5117 let method = ListActorSplitsSvc(inner);
5118 let codec = tonic::codec::ProstCodec::default();
5119 let mut grpc = tonic::server::Grpc::new(codec)
5120 .apply_compression_config(
5121 accept_compression_encodings,
5122 send_compression_encodings,
5123 )
5124 .apply_max_message_size_config(
5125 max_decoding_message_size,
5126 max_encoding_message_size,
5127 );
5128 let res = grpc.unary(method, req).await;
5129 Ok(res)
5130 };
5131 Box::pin(fut)
5132 }
5133 "/meta.StreamManagerService/ListObjectDependencies" => {
5134 #[allow(non_camel_case_types)]
5135 struct ListObjectDependenciesSvc<T: StreamManagerService>(
5136 pub Arc<T>,
5137 );
5138 impl<
5139 T: StreamManagerService,
5140 > tonic::server::UnaryService<super::ListObjectDependenciesRequest>
5141 for ListObjectDependenciesSvc<T> {
5142 type Response = super::ListObjectDependenciesResponse;
5143 type Future = BoxFuture<
5144 tonic::Response<Self::Response>,
5145 tonic::Status,
5146 >;
5147 fn call(
5148 &mut self,
5149 request: tonic::Request<super::ListObjectDependenciesRequest>,
5150 ) -> Self::Future {
5151 let inner = Arc::clone(&self.0);
5152 let fut = async move {
5153 <T as StreamManagerService>::list_object_dependencies(
5154 &inner,
5155 request,
5156 )
5157 .await
5158 };
5159 Box::pin(fut)
5160 }
5161 }
5162 let accept_compression_encodings = self.accept_compression_encodings;
5163 let send_compression_encodings = self.send_compression_encodings;
5164 let max_decoding_message_size = self.max_decoding_message_size;
5165 let max_encoding_message_size = self.max_encoding_message_size;
5166 let inner = self.inner.clone();
5167 let fut = async move {
5168 let method = ListObjectDependenciesSvc(inner);
5169 let codec = tonic::codec::ProstCodec::default();
5170 let mut grpc = tonic::server::Grpc::new(codec)
5171 .apply_compression_config(
5172 accept_compression_encodings,
5173 send_compression_encodings,
5174 )
5175 .apply_max_message_size_config(
5176 max_decoding_message_size,
5177 max_encoding_message_size,
5178 );
5179 let res = grpc.unary(method, req).await;
5180 Ok(res)
5181 };
5182 Box::pin(fut)
5183 }
5184 "/meta.StreamManagerService/ApplyThrottle" => {
5185 #[allow(non_camel_case_types)]
5186 struct ApplyThrottleSvc<T: StreamManagerService>(pub Arc<T>);
5187 impl<
5188 T: StreamManagerService,
5189 > tonic::server::UnaryService<super::ApplyThrottleRequest>
5190 for ApplyThrottleSvc<T> {
5191 type Response = super::ApplyThrottleResponse;
5192 type Future = BoxFuture<
5193 tonic::Response<Self::Response>,
5194 tonic::Status,
5195 >;
5196 fn call(
5197 &mut self,
5198 request: tonic::Request<super::ApplyThrottleRequest>,
5199 ) -> Self::Future {
5200 let inner = Arc::clone(&self.0);
5201 let fut = async move {
5202 <T as StreamManagerService>::apply_throttle(&inner, request)
5203 .await
5204 };
5205 Box::pin(fut)
5206 }
5207 }
5208 let accept_compression_encodings = self.accept_compression_encodings;
5209 let send_compression_encodings = self.send_compression_encodings;
5210 let max_decoding_message_size = self.max_decoding_message_size;
5211 let max_encoding_message_size = self.max_encoding_message_size;
5212 let inner = self.inner.clone();
5213 let fut = async move {
5214 let method = ApplyThrottleSvc(inner);
5215 let codec = tonic::codec::ProstCodec::default();
5216 let mut grpc = tonic::server::Grpc::new(codec)
5217 .apply_compression_config(
5218 accept_compression_encodings,
5219 send_compression_encodings,
5220 )
5221 .apply_max_message_size_config(
5222 max_decoding_message_size,
5223 max_encoding_message_size,
5224 );
5225 let res = grpc.unary(method, req).await;
5226 Ok(res)
5227 };
5228 Box::pin(fut)
5229 }
5230 "/meta.StreamManagerService/Recover" => {
5231 #[allow(non_camel_case_types)]
5232 struct RecoverSvc<T: StreamManagerService>(pub Arc<T>);
5233 impl<
5234 T: StreamManagerService,
5235 > tonic::server::UnaryService<super::RecoverRequest>
5236 for RecoverSvc<T> {
5237 type Response = super::RecoverResponse;
5238 type Future = BoxFuture<
5239 tonic::Response<Self::Response>,
5240 tonic::Status,
5241 >;
5242 fn call(
5243 &mut self,
5244 request: tonic::Request<super::RecoverRequest>,
5245 ) -> Self::Future {
5246 let inner = Arc::clone(&self.0);
5247 let fut = async move {
5248 <T as StreamManagerService>::recover(&inner, request).await
5249 };
5250 Box::pin(fut)
5251 }
5252 }
5253 let accept_compression_encodings = self.accept_compression_encodings;
5254 let send_compression_encodings = self.send_compression_encodings;
5255 let max_decoding_message_size = self.max_decoding_message_size;
5256 let max_encoding_message_size = self.max_encoding_message_size;
5257 let inner = self.inner.clone();
5258 let fut = async move {
5259 let method = RecoverSvc(inner);
5260 let codec = tonic::codec::ProstCodec::default();
5261 let mut grpc = tonic::server::Grpc::new(codec)
5262 .apply_compression_config(
5263 accept_compression_encodings,
5264 send_compression_encodings,
5265 )
5266 .apply_max_message_size_config(
5267 max_decoding_message_size,
5268 max_encoding_message_size,
5269 );
5270 let res = grpc.unary(method, req).await;
5271 Ok(res)
5272 };
5273 Box::pin(fut)
5274 }
5275 "/meta.StreamManagerService/ListRateLimits" => {
5276 #[allow(non_camel_case_types)]
5277 struct ListRateLimitsSvc<T: StreamManagerService>(pub Arc<T>);
5278 impl<
5279 T: StreamManagerService,
5280 > tonic::server::UnaryService<super::ListRateLimitsRequest>
5281 for ListRateLimitsSvc<T> {
5282 type Response = super::ListRateLimitsResponse;
5283 type Future = BoxFuture<
5284 tonic::Response<Self::Response>,
5285 tonic::Status,
5286 >;
5287 fn call(
5288 &mut self,
5289 request: tonic::Request<super::ListRateLimitsRequest>,
5290 ) -> Self::Future {
5291 let inner = Arc::clone(&self.0);
5292 let fut = async move {
5293 <T as StreamManagerService>::list_rate_limits(
5294 &inner,
5295 request,
5296 )
5297 .await
5298 };
5299 Box::pin(fut)
5300 }
5301 }
5302 let accept_compression_encodings = self.accept_compression_encodings;
5303 let send_compression_encodings = self.send_compression_encodings;
5304 let max_decoding_message_size = self.max_decoding_message_size;
5305 let max_encoding_message_size = self.max_encoding_message_size;
5306 let inner = self.inner.clone();
5307 let fut = async move {
5308 let method = ListRateLimitsSvc(inner);
5309 let codec = tonic::codec::ProstCodec::default();
5310 let mut grpc = tonic::server::Grpc::new(codec)
5311 .apply_compression_config(
5312 accept_compression_encodings,
5313 send_compression_encodings,
5314 )
5315 .apply_max_message_size_config(
5316 max_decoding_message_size,
5317 max_encoding_message_size,
5318 );
5319 let res = grpc.unary(method, req).await;
5320 Ok(res)
5321 };
5322 Box::pin(fut)
5323 }
5324 "/meta.StreamManagerService/AlterConnectorProps" => {
5325 #[allow(non_camel_case_types)]
5326 struct AlterConnectorPropsSvc<T: StreamManagerService>(pub Arc<T>);
5327 impl<
5328 T: StreamManagerService,
5329 > tonic::server::UnaryService<super::AlterConnectorPropsRequest>
5330 for AlterConnectorPropsSvc<T> {
5331 type Response = super::AlterConnectorPropsResponse;
5332 type Future = BoxFuture<
5333 tonic::Response<Self::Response>,
5334 tonic::Status,
5335 >;
5336 fn call(
5337 &mut self,
5338 request: tonic::Request<super::AlterConnectorPropsRequest>,
5339 ) -> Self::Future {
5340 let inner = Arc::clone(&self.0);
5341 let fut = async move {
5342 <T as StreamManagerService>::alter_connector_props(
5343 &inner,
5344 request,
5345 )
5346 .await
5347 };
5348 Box::pin(fut)
5349 }
5350 }
5351 let accept_compression_encodings = self.accept_compression_encodings;
5352 let send_compression_encodings = self.send_compression_encodings;
5353 let max_decoding_message_size = self.max_decoding_message_size;
5354 let max_encoding_message_size = self.max_encoding_message_size;
5355 let inner = self.inner.clone();
5356 let fut = async move {
5357 let method = AlterConnectorPropsSvc(inner);
5358 let codec = tonic::codec::ProstCodec::default();
5359 let mut grpc = tonic::server::Grpc::new(codec)
5360 .apply_compression_config(
5361 accept_compression_encodings,
5362 send_compression_encodings,
5363 )
5364 .apply_max_message_size_config(
5365 max_decoding_message_size,
5366 max_encoding_message_size,
5367 );
5368 let res = grpc.unary(method, req).await;
5369 Ok(res)
5370 };
5371 Box::pin(fut)
5372 }
5373 "/meta.StreamManagerService/GetFragmentById" => {
5374 #[allow(non_camel_case_types)]
5375 struct GetFragmentByIdSvc<T: StreamManagerService>(pub Arc<T>);
5376 impl<
5377 T: StreamManagerService,
5378 > tonic::server::UnaryService<super::GetFragmentByIdRequest>
5379 for GetFragmentByIdSvc<T> {
5380 type Response = super::GetFragmentByIdResponse;
5381 type Future = BoxFuture<
5382 tonic::Response<Self::Response>,
5383 tonic::Status,
5384 >;
5385 fn call(
5386 &mut self,
5387 request: tonic::Request<super::GetFragmentByIdRequest>,
5388 ) -> Self::Future {
5389 let inner = Arc::clone(&self.0);
5390 let fut = async move {
5391 <T as StreamManagerService>::get_fragment_by_id(
5392 &inner,
5393 request,
5394 )
5395 .await
5396 };
5397 Box::pin(fut)
5398 }
5399 }
5400 let accept_compression_encodings = self.accept_compression_encodings;
5401 let send_compression_encodings = self.send_compression_encodings;
5402 let max_decoding_message_size = self.max_decoding_message_size;
5403 let max_encoding_message_size = self.max_encoding_message_size;
5404 let inner = self.inner.clone();
5405 let fut = async move {
5406 let method = GetFragmentByIdSvc(inner);
5407 let codec = tonic::codec::ProstCodec::default();
5408 let mut grpc = tonic::server::Grpc::new(codec)
5409 .apply_compression_config(
5410 accept_compression_encodings,
5411 send_compression_encodings,
5412 )
5413 .apply_max_message_size_config(
5414 max_decoding_message_size,
5415 max_encoding_message_size,
5416 );
5417 let res = grpc.unary(method, req).await;
5418 Ok(res)
5419 };
5420 Box::pin(fut)
5421 }
5422 "/meta.StreamManagerService/SetSyncLogStoreAligned" => {
5423 #[allow(non_camel_case_types)]
5424 struct SetSyncLogStoreAlignedSvc<T: StreamManagerService>(
5425 pub Arc<T>,
5426 );
5427 impl<
5428 T: StreamManagerService,
5429 > tonic::server::UnaryService<super::SetSyncLogStoreAlignedRequest>
5430 for SetSyncLogStoreAlignedSvc<T> {
5431 type Response = super::SetSyncLogStoreAlignedResponse;
5432 type Future = BoxFuture<
5433 tonic::Response<Self::Response>,
5434 tonic::Status,
5435 >;
5436 fn call(
5437 &mut self,
5438 request: tonic::Request<super::SetSyncLogStoreAlignedRequest>,
5439 ) -> Self::Future {
5440 let inner = Arc::clone(&self.0);
5441 let fut = async move {
5442 <T as StreamManagerService>::set_sync_log_store_aligned(
5443 &inner,
5444 request,
5445 )
5446 .await
5447 };
5448 Box::pin(fut)
5449 }
5450 }
5451 let accept_compression_encodings = self.accept_compression_encodings;
5452 let send_compression_encodings = self.send_compression_encodings;
5453 let max_decoding_message_size = self.max_decoding_message_size;
5454 let max_encoding_message_size = self.max_encoding_message_size;
5455 let inner = self.inner.clone();
5456 let fut = async move {
5457 let method = SetSyncLogStoreAlignedSvc(inner);
5458 let codec = tonic::codec::ProstCodec::default();
5459 let mut grpc = tonic::server::Grpc::new(codec)
5460 .apply_compression_config(
5461 accept_compression_encodings,
5462 send_compression_encodings,
5463 )
5464 .apply_max_message_size_config(
5465 max_decoding_message_size,
5466 max_encoding_message_size,
5467 );
5468 let res = grpc.unary(method, req).await;
5469 Ok(res)
5470 };
5471 Box::pin(fut)
5472 }
5473 _ => {
5474 Box::pin(async move {
5475 let mut response = http::Response::new(empty_body());
5476 let headers = response.headers_mut();
5477 headers
5478 .insert(
5479 tonic::Status::GRPC_STATUS,
5480 (tonic::Code::Unimplemented as i32).into(),
5481 );
5482 headers
5483 .insert(
5484 http::header::CONTENT_TYPE,
5485 tonic::metadata::GRPC_CONTENT_TYPE,
5486 );
5487 Ok(response)
5488 })
5489 }
5490 }
5491 }
5492 }
5493 impl<T> Clone for StreamManagerServiceServer<T> {
5494 fn clone(&self) -> Self {
5495 let inner = self.inner.clone();
5496 Self {
5497 inner,
5498 accept_compression_encodings: self.accept_compression_encodings,
5499 send_compression_encodings: self.send_compression_encodings,
5500 max_decoding_message_size: self.max_decoding_message_size,
5501 max_encoding_message_size: self.max_encoding_message_size,
5502 }
5503 }
5504 }
5505 pub const SERVICE_NAME: &str = "meta.StreamManagerService";
5507 impl<T> tonic::server::NamedService for StreamManagerServiceServer<T> {
5508 const NAME: &'static str = SERVICE_NAME;
5509 }
5510}
5511pub mod cluster_service_server {
5513 #![allow(
5514 unused_variables,
5515 dead_code,
5516 missing_docs,
5517 clippy::wildcard_imports,
5518 clippy::let_unit_value,
5519 )]
5520 use tonic::codegen::*;
5521 #[async_trait]
5523 pub trait ClusterService: std::marker::Send + std::marker::Sync + 'static {
5524 async fn add_worker_node(
5525 &self,
5526 request: tonic::Request<super::AddWorkerNodeRequest>,
5527 ) -> std::result::Result<
5528 tonic::Response<super::AddWorkerNodeResponse>,
5529 tonic::Status,
5530 >;
5531 async fn activate_worker_node(
5532 &self,
5533 request: tonic::Request<super::ActivateWorkerNodeRequest>,
5534 ) -> std::result::Result<
5535 tonic::Response<super::ActivateWorkerNodeResponse>,
5536 tonic::Status,
5537 >;
5538 async fn delete_worker_node(
5539 &self,
5540 request: tonic::Request<super::DeleteWorkerNodeRequest>,
5541 ) -> std::result::Result<
5542 tonic::Response<super::DeleteWorkerNodeResponse>,
5543 tonic::Status,
5544 >;
5545 async fn update_worker_node_schedulability(
5546 &self,
5547 request: tonic::Request<super::UpdateWorkerNodeSchedulabilityRequest>,
5548 ) -> std::result::Result<
5549 tonic::Response<super::UpdateWorkerNodeSchedulabilityResponse>,
5550 tonic::Status,
5551 >;
5552 async fn list_all_nodes(
5553 &self,
5554 request: tonic::Request<super::ListAllNodesRequest>,
5555 ) -> std::result::Result<
5556 tonic::Response<super::ListAllNodesResponse>,
5557 tonic::Status,
5558 >;
5559 async fn get_cluster_recovery_status(
5560 &self,
5561 request: tonic::Request<super::GetClusterRecoveryStatusRequest>,
5562 ) -> std::result::Result<
5563 tonic::Response<super::GetClusterRecoveryStatusResponse>,
5564 tonic::Status,
5565 >;
5566 async fn get_meta_store_info(
5567 &self,
5568 request: tonic::Request<super::GetMetaStoreInfoRequest>,
5569 ) -> std::result::Result<
5570 tonic::Response<super::GetMetaStoreInfoResponse>,
5571 tonic::Status,
5572 >;
5573 }
5574 #[derive(Debug)]
5575 pub struct ClusterServiceServer<T> {
5576 inner: Arc<T>,
5577 accept_compression_encodings: EnabledCompressionEncodings,
5578 send_compression_encodings: EnabledCompressionEncodings,
5579 max_decoding_message_size: Option<usize>,
5580 max_encoding_message_size: Option<usize>,
5581 }
5582 impl<T> ClusterServiceServer<T> {
5583 pub fn new(inner: T) -> Self {
5584 Self::from_arc(Arc::new(inner))
5585 }
5586 pub fn from_arc(inner: Arc<T>) -> Self {
5587 Self {
5588 inner,
5589 accept_compression_encodings: Default::default(),
5590 send_compression_encodings: Default::default(),
5591 max_decoding_message_size: None,
5592 max_encoding_message_size: None,
5593 }
5594 }
5595 pub fn with_interceptor<F>(
5596 inner: T,
5597 interceptor: F,
5598 ) -> InterceptedService<Self, F>
5599 where
5600 F: tonic::service::Interceptor,
5601 {
5602 InterceptedService::new(Self::new(inner), interceptor)
5603 }
5604 #[must_use]
5606 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
5607 self.accept_compression_encodings.enable(encoding);
5608 self
5609 }
5610 #[must_use]
5612 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
5613 self.send_compression_encodings.enable(encoding);
5614 self
5615 }
5616 #[must_use]
5620 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
5621 self.max_decoding_message_size = Some(limit);
5622 self
5623 }
5624 #[must_use]
5628 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
5629 self.max_encoding_message_size = Some(limit);
5630 self
5631 }
5632 }
5633 impl<T, B> tonic::codegen::Service<http::Request<B>> for ClusterServiceServer<T>
5634 where
5635 T: ClusterService,
5636 B: Body + std::marker::Send + 'static,
5637 B::Error: Into<StdError> + std::marker::Send + 'static,
5638 {
5639 type Response = http::Response<tonic::body::BoxBody>;
5640 type Error = std::convert::Infallible;
5641 type Future = BoxFuture<Self::Response, Self::Error>;
5642 fn poll_ready(
5643 &mut self,
5644 _cx: &mut Context<'_>,
5645 ) -> Poll<std::result::Result<(), Self::Error>> {
5646 Poll::Ready(Ok(()))
5647 }
5648 fn call(&mut self, req: http::Request<B>) -> Self::Future {
5649 match req.uri().path() {
5650 "/meta.ClusterService/AddWorkerNode" => {
5651 #[allow(non_camel_case_types)]
5652 struct AddWorkerNodeSvc<T: ClusterService>(pub Arc<T>);
5653 impl<
5654 T: ClusterService,
5655 > tonic::server::UnaryService<super::AddWorkerNodeRequest>
5656 for AddWorkerNodeSvc<T> {
5657 type Response = super::AddWorkerNodeResponse;
5658 type Future = BoxFuture<
5659 tonic::Response<Self::Response>,
5660 tonic::Status,
5661 >;
5662 fn call(
5663 &mut self,
5664 request: tonic::Request<super::AddWorkerNodeRequest>,
5665 ) -> Self::Future {
5666 let inner = Arc::clone(&self.0);
5667 let fut = async move {
5668 <T as ClusterService>::add_worker_node(&inner, request)
5669 .await
5670 };
5671 Box::pin(fut)
5672 }
5673 }
5674 let accept_compression_encodings = self.accept_compression_encodings;
5675 let send_compression_encodings = self.send_compression_encodings;
5676 let max_decoding_message_size = self.max_decoding_message_size;
5677 let max_encoding_message_size = self.max_encoding_message_size;
5678 let inner = self.inner.clone();
5679 let fut = async move {
5680 let method = AddWorkerNodeSvc(inner);
5681 let codec = tonic::codec::ProstCodec::default();
5682 let mut grpc = tonic::server::Grpc::new(codec)
5683 .apply_compression_config(
5684 accept_compression_encodings,
5685 send_compression_encodings,
5686 )
5687 .apply_max_message_size_config(
5688 max_decoding_message_size,
5689 max_encoding_message_size,
5690 );
5691 let res = grpc.unary(method, req).await;
5692 Ok(res)
5693 };
5694 Box::pin(fut)
5695 }
5696 "/meta.ClusterService/ActivateWorkerNode" => {
5697 #[allow(non_camel_case_types)]
5698 struct ActivateWorkerNodeSvc<T: ClusterService>(pub Arc<T>);
5699 impl<
5700 T: ClusterService,
5701 > tonic::server::UnaryService<super::ActivateWorkerNodeRequest>
5702 for ActivateWorkerNodeSvc<T> {
5703 type Response = super::ActivateWorkerNodeResponse;
5704 type Future = BoxFuture<
5705 tonic::Response<Self::Response>,
5706 tonic::Status,
5707 >;
5708 fn call(
5709 &mut self,
5710 request: tonic::Request<super::ActivateWorkerNodeRequest>,
5711 ) -> Self::Future {
5712 let inner = Arc::clone(&self.0);
5713 let fut = async move {
5714 <T as ClusterService>::activate_worker_node(&inner, request)
5715 .await
5716 };
5717 Box::pin(fut)
5718 }
5719 }
5720 let accept_compression_encodings = self.accept_compression_encodings;
5721 let send_compression_encodings = self.send_compression_encodings;
5722 let max_decoding_message_size = self.max_decoding_message_size;
5723 let max_encoding_message_size = self.max_encoding_message_size;
5724 let inner = self.inner.clone();
5725 let fut = async move {
5726 let method = ActivateWorkerNodeSvc(inner);
5727 let codec = tonic::codec::ProstCodec::default();
5728 let mut grpc = tonic::server::Grpc::new(codec)
5729 .apply_compression_config(
5730 accept_compression_encodings,
5731 send_compression_encodings,
5732 )
5733 .apply_max_message_size_config(
5734 max_decoding_message_size,
5735 max_encoding_message_size,
5736 );
5737 let res = grpc.unary(method, req).await;
5738 Ok(res)
5739 };
5740 Box::pin(fut)
5741 }
5742 "/meta.ClusterService/DeleteWorkerNode" => {
5743 #[allow(non_camel_case_types)]
5744 struct DeleteWorkerNodeSvc<T: ClusterService>(pub Arc<T>);
5745 impl<
5746 T: ClusterService,
5747 > tonic::server::UnaryService<super::DeleteWorkerNodeRequest>
5748 for DeleteWorkerNodeSvc<T> {
5749 type Response = super::DeleteWorkerNodeResponse;
5750 type Future = BoxFuture<
5751 tonic::Response<Self::Response>,
5752 tonic::Status,
5753 >;
5754 fn call(
5755 &mut self,
5756 request: tonic::Request<super::DeleteWorkerNodeRequest>,
5757 ) -> Self::Future {
5758 let inner = Arc::clone(&self.0);
5759 let fut = async move {
5760 <T as ClusterService>::delete_worker_node(&inner, request)
5761 .await
5762 };
5763 Box::pin(fut)
5764 }
5765 }
5766 let accept_compression_encodings = self.accept_compression_encodings;
5767 let send_compression_encodings = self.send_compression_encodings;
5768 let max_decoding_message_size = self.max_decoding_message_size;
5769 let max_encoding_message_size = self.max_encoding_message_size;
5770 let inner = self.inner.clone();
5771 let fut = async move {
5772 let method = DeleteWorkerNodeSvc(inner);
5773 let codec = tonic::codec::ProstCodec::default();
5774 let mut grpc = tonic::server::Grpc::new(codec)
5775 .apply_compression_config(
5776 accept_compression_encodings,
5777 send_compression_encodings,
5778 )
5779 .apply_max_message_size_config(
5780 max_decoding_message_size,
5781 max_encoding_message_size,
5782 );
5783 let res = grpc.unary(method, req).await;
5784 Ok(res)
5785 };
5786 Box::pin(fut)
5787 }
5788 "/meta.ClusterService/UpdateWorkerNodeSchedulability" => {
5789 #[allow(non_camel_case_types)]
5790 struct UpdateWorkerNodeSchedulabilitySvc<T: ClusterService>(
5791 pub Arc<T>,
5792 );
5793 impl<
5794 T: ClusterService,
5795 > tonic::server::UnaryService<
5796 super::UpdateWorkerNodeSchedulabilityRequest,
5797 > for UpdateWorkerNodeSchedulabilitySvc<T> {
5798 type Response = super::UpdateWorkerNodeSchedulabilityResponse;
5799 type Future = BoxFuture<
5800 tonic::Response<Self::Response>,
5801 tonic::Status,
5802 >;
5803 fn call(
5804 &mut self,
5805 request: tonic::Request<
5806 super::UpdateWorkerNodeSchedulabilityRequest,
5807 >,
5808 ) -> Self::Future {
5809 let inner = Arc::clone(&self.0);
5810 let fut = async move {
5811 <T as ClusterService>::update_worker_node_schedulability(
5812 &inner,
5813 request,
5814 )
5815 .await
5816 };
5817 Box::pin(fut)
5818 }
5819 }
5820 let accept_compression_encodings = self.accept_compression_encodings;
5821 let send_compression_encodings = self.send_compression_encodings;
5822 let max_decoding_message_size = self.max_decoding_message_size;
5823 let max_encoding_message_size = self.max_encoding_message_size;
5824 let inner = self.inner.clone();
5825 let fut = async move {
5826 let method = UpdateWorkerNodeSchedulabilitySvc(inner);
5827 let codec = tonic::codec::ProstCodec::default();
5828 let mut grpc = tonic::server::Grpc::new(codec)
5829 .apply_compression_config(
5830 accept_compression_encodings,
5831 send_compression_encodings,
5832 )
5833 .apply_max_message_size_config(
5834 max_decoding_message_size,
5835 max_encoding_message_size,
5836 );
5837 let res = grpc.unary(method, req).await;
5838 Ok(res)
5839 };
5840 Box::pin(fut)
5841 }
5842 "/meta.ClusterService/ListAllNodes" => {
5843 #[allow(non_camel_case_types)]
5844 struct ListAllNodesSvc<T: ClusterService>(pub Arc<T>);
5845 impl<
5846 T: ClusterService,
5847 > tonic::server::UnaryService<super::ListAllNodesRequest>
5848 for ListAllNodesSvc<T> {
5849 type Response = super::ListAllNodesResponse;
5850 type Future = BoxFuture<
5851 tonic::Response<Self::Response>,
5852 tonic::Status,
5853 >;
5854 fn call(
5855 &mut self,
5856 request: tonic::Request<super::ListAllNodesRequest>,
5857 ) -> Self::Future {
5858 let inner = Arc::clone(&self.0);
5859 let fut = async move {
5860 <T as ClusterService>::list_all_nodes(&inner, request).await
5861 };
5862 Box::pin(fut)
5863 }
5864 }
5865 let accept_compression_encodings = self.accept_compression_encodings;
5866 let send_compression_encodings = self.send_compression_encodings;
5867 let max_decoding_message_size = self.max_decoding_message_size;
5868 let max_encoding_message_size = self.max_encoding_message_size;
5869 let inner = self.inner.clone();
5870 let fut = async move {
5871 let method = ListAllNodesSvc(inner);
5872 let codec = tonic::codec::ProstCodec::default();
5873 let mut grpc = tonic::server::Grpc::new(codec)
5874 .apply_compression_config(
5875 accept_compression_encodings,
5876 send_compression_encodings,
5877 )
5878 .apply_max_message_size_config(
5879 max_decoding_message_size,
5880 max_encoding_message_size,
5881 );
5882 let res = grpc.unary(method, req).await;
5883 Ok(res)
5884 };
5885 Box::pin(fut)
5886 }
5887 "/meta.ClusterService/GetClusterRecoveryStatus" => {
5888 #[allow(non_camel_case_types)]
5889 struct GetClusterRecoveryStatusSvc<T: ClusterService>(pub Arc<T>);
5890 impl<
5891 T: ClusterService,
5892 > tonic::server::UnaryService<super::GetClusterRecoveryStatusRequest>
5893 for GetClusterRecoveryStatusSvc<T> {
5894 type Response = super::GetClusterRecoveryStatusResponse;
5895 type Future = BoxFuture<
5896 tonic::Response<Self::Response>,
5897 tonic::Status,
5898 >;
5899 fn call(
5900 &mut self,
5901 request: tonic::Request<
5902 super::GetClusterRecoveryStatusRequest,
5903 >,
5904 ) -> Self::Future {
5905 let inner = Arc::clone(&self.0);
5906 let fut = async move {
5907 <T as ClusterService>::get_cluster_recovery_status(
5908 &inner,
5909 request,
5910 )
5911 .await
5912 };
5913 Box::pin(fut)
5914 }
5915 }
5916 let accept_compression_encodings = self.accept_compression_encodings;
5917 let send_compression_encodings = self.send_compression_encodings;
5918 let max_decoding_message_size = self.max_decoding_message_size;
5919 let max_encoding_message_size = self.max_encoding_message_size;
5920 let inner = self.inner.clone();
5921 let fut = async move {
5922 let method = GetClusterRecoveryStatusSvc(inner);
5923 let codec = tonic::codec::ProstCodec::default();
5924 let mut grpc = tonic::server::Grpc::new(codec)
5925 .apply_compression_config(
5926 accept_compression_encodings,
5927 send_compression_encodings,
5928 )
5929 .apply_max_message_size_config(
5930 max_decoding_message_size,
5931 max_encoding_message_size,
5932 );
5933 let res = grpc.unary(method, req).await;
5934 Ok(res)
5935 };
5936 Box::pin(fut)
5937 }
5938 "/meta.ClusterService/GetMetaStoreInfo" => {
5939 #[allow(non_camel_case_types)]
5940 struct GetMetaStoreInfoSvc<T: ClusterService>(pub Arc<T>);
5941 impl<
5942 T: ClusterService,
5943 > tonic::server::UnaryService<super::GetMetaStoreInfoRequest>
5944 for GetMetaStoreInfoSvc<T> {
5945 type Response = super::GetMetaStoreInfoResponse;
5946 type Future = BoxFuture<
5947 tonic::Response<Self::Response>,
5948 tonic::Status,
5949 >;
5950 fn call(
5951 &mut self,
5952 request: tonic::Request<super::GetMetaStoreInfoRequest>,
5953 ) -> Self::Future {
5954 let inner = Arc::clone(&self.0);
5955 let fut = async move {
5956 <T as ClusterService>::get_meta_store_info(&inner, request)
5957 .await
5958 };
5959 Box::pin(fut)
5960 }
5961 }
5962 let accept_compression_encodings = self.accept_compression_encodings;
5963 let send_compression_encodings = self.send_compression_encodings;
5964 let max_decoding_message_size = self.max_decoding_message_size;
5965 let max_encoding_message_size = self.max_encoding_message_size;
5966 let inner = self.inner.clone();
5967 let fut = async move {
5968 let method = GetMetaStoreInfoSvc(inner);
5969 let codec = tonic::codec::ProstCodec::default();
5970 let mut grpc = tonic::server::Grpc::new(codec)
5971 .apply_compression_config(
5972 accept_compression_encodings,
5973 send_compression_encodings,
5974 )
5975 .apply_max_message_size_config(
5976 max_decoding_message_size,
5977 max_encoding_message_size,
5978 );
5979 let res = grpc.unary(method, req).await;
5980 Ok(res)
5981 };
5982 Box::pin(fut)
5983 }
5984 _ => {
5985 Box::pin(async move {
5986 let mut response = http::Response::new(empty_body());
5987 let headers = response.headers_mut();
5988 headers
5989 .insert(
5990 tonic::Status::GRPC_STATUS,
5991 (tonic::Code::Unimplemented as i32).into(),
5992 );
5993 headers
5994 .insert(
5995 http::header::CONTENT_TYPE,
5996 tonic::metadata::GRPC_CONTENT_TYPE,
5997 );
5998 Ok(response)
5999 })
6000 }
6001 }
6002 }
6003 }
6004 impl<T> Clone for ClusterServiceServer<T> {
6005 fn clone(&self) -> Self {
6006 let inner = self.inner.clone();
6007 Self {
6008 inner,
6009 accept_compression_encodings: self.accept_compression_encodings,
6010 send_compression_encodings: self.send_compression_encodings,
6011 max_decoding_message_size: self.max_decoding_message_size,
6012 max_encoding_message_size: self.max_encoding_message_size,
6013 }
6014 }
6015 }
6016 pub const SERVICE_NAME: &str = "meta.ClusterService";
6018 impl<T> tonic::server::NamedService for ClusterServiceServer<T> {
6019 const NAME: &'static str = SERVICE_NAME;
6020 }
6021}
6022pub mod notification_service_server {
6024 #![allow(
6025 unused_variables,
6026 dead_code,
6027 missing_docs,
6028 clippy::wildcard_imports,
6029 clippy::let_unit_value,
6030 )]
6031 use tonic::codegen::*;
6032 #[async_trait]
6034 pub trait NotificationService: std::marker::Send + std::marker::Sync + 'static {
6035 type SubscribeStream: tonic::codegen::tokio_stream::Stream<
6037 Item = std::result::Result<super::SubscribeResponse, tonic::Status>,
6038 >
6039 + std::marker::Send
6040 + 'static;
6041 async fn subscribe(
6042 &self,
6043 request: tonic::Request<super::SubscribeRequest>,
6044 ) -> std::result::Result<tonic::Response<Self::SubscribeStream>, tonic::Status>;
6045 }
6046 #[derive(Debug)]
6047 pub struct NotificationServiceServer<T> {
6048 inner: Arc<T>,
6049 accept_compression_encodings: EnabledCompressionEncodings,
6050 send_compression_encodings: EnabledCompressionEncodings,
6051 max_decoding_message_size: Option<usize>,
6052 max_encoding_message_size: Option<usize>,
6053 }
6054 impl<T> NotificationServiceServer<T> {
6055 pub fn new(inner: T) -> Self {
6056 Self::from_arc(Arc::new(inner))
6057 }
6058 pub fn from_arc(inner: Arc<T>) -> Self {
6059 Self {
6060 inner,
6061 accept_compression_encodings: Default::default(),
6062 send_compression_encodings: Default::default(),
6063 max_decoding_message_size: None,
6064 max_encoding_message_size: None,
6065 }
6066 }
6067 pub fn with_interceptor<F>(
6068 inner: T,
6069 interceptor: F,
6070 ) -> InterceptedService<Self, F>
6071 where
6072 F: tonic::service::Interceptor,
6073 {
6074 InterceptedService::new(Self::new(inner), interceptor)
6075 }
6076 #[must_use]
6078 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
6079 self.accept_compression_encodings.enable(encoding);
6080 self
6081 }
6082 #[must_use]
6084 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
6085 self.send_compression_encodings.enable(encoding);
6086 self
6087 }
6088 #[must_use]
6092 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
6093 self.max_decoding_message_size = Some(limit);
6094 self
6095 }
6096 #[must_use]
6100 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
6101 self.max_encoding_message_size = Some(limit);
6102 self
6103 }
6104 }
6105 impl<T, B> tonic::codegen::Service<http::Request<B>> for NotificationServiceServer<T>
6106 where
6107 T: NotificationService,
6108 B: Body + std::marker::Send + 'static,
6109 B::Error: Into<StdError> + std::marker::Send + 'static,
6110 {
6111 type Response = http::Response<tonic::body::BoxBody>;
6112 type Error = std::convert::Infallible;
6113 type Future = BoxFuture<Self::Response, Self::Error>;
6114 fn poll_ready(
6115 &mut self,
6116 _cx: &mut Context<'_>,
6117 ) -> Poll<std::result::Result<(), Self::Error>> {
6118 Poll::Ready(Ok(()))
6119 }
6120 fn call(&mut self, req: http::Request<B>) -> Self::Future {
6121 match req.uri().path() {
6122 "/meta.NotificationService/Subscribe" => {
6123 #[allow(non_camel_case_types)]
6124 struct SubscribeSvc<T: NotificationService>(pub Arc<T>);
6125 impl<
6126 T: NotificationService,
6127 > tonic::server::ServerStreamingService<super::SubscribeRequest>
6128 for SubscribeSvc<T> {
6129 type Response = super::SubscribeResponse;
6130 type ResponseStream = T::SubscribeStream;
6131 type Future = BoxFuture<
6132 tonic::Response<Self::ResponseStream>,
6133 tonic::Status,
6134 >;
6135 fn call(
6136 &mut self,
6137 request: tonic::Request<super::SubscribeRequest>,
6138 ) -> Self::Future {
6139 let inner = Arc::clone(&self.0);
6140 let fut = async move {
6141 <T as NotificationService>::subscribe(&inner, request).await
6142 };
6143 Box::pin(fut)
6144 }
6145 }
6146 let accept_compression_encodings = self.accept_compression_encodings;
6147 let send_compression_encodings = self.send_compression_encodings;
6148 let max_decoding_message_size = self.max_decoding_message_size;
6149 let max_encoding_message_size = self.max_encoding_message_size;
6150 let inner = self.inner.clone();
6151 let fut = async move {
6152 let method = SubscribeSvc(inner);
6153 let codec = tonic::codec::ProstCodec::default();
6154 let mut grpc = tonic::server::Grpc::new(codec)
6155 .apply_compression_config(
6156 accept_compression_encodings,
6157 send_compression_encodings,
6158 )
6159 .apply_max_message_size_config(
6160 max_decoding_message_size,
6161 max_encoding_message_size,
6162 );
6163 let res = grpc.server_streaming(method, req).await;
6164 Ok(res)
6165 };
6166 Box::pin(fut)
6167 }
6168 _ => {
6169 Box::pin(async move {
6170 let mut response = http::Response::new(empty_body());
6171 let headers = response.headers_mut();
6172 headers
6173 .insert(
6174 tonic::Status::GRPC_STATUS,
6175 (tonic::Code::Unimplemented as i32).into(),
6176 );
6177 headers
6178 .insert(
6179 http::header::CONTENT_TYPE,
6180 tonic::metadata::GRPC_CONTENT_TYPE,
6181 );
6182 Ok(response)
6183 })
6184 }
6185 }
6186 }
6187 }
6188 impl<T> Clone for NotificationServiceServer<T> {
6189 fn clone(&self) -> Self {
6190 let inner = self.inner.clone();
6191 Self {
6192 inner,
6193 accept_compression_encodings: self.accept_compression_encodings,
6194 send_compression_encodings: self.send_compression_encodings,
6195 max_decoding_message_size: self.max_decoding_message_size,
6196 max_encoding_message_size: self.max_encoding_message_size,
6197 }
6198 }
6199 }
6200 pub const SERVICE_NAME: &str = "meta.NotificationService";
6202 impl<T> tonic::server::NamedService for NotificationServiceServer<T> {
6203 const NAME: &'static str = SERVICE_NAME;
6204 }
6205}
6206pub mod scale_service_server {
6208 #![allow(
6209 unused_variables,
6210 dead_code,
6211 missing_docs,
6212 clippy::wildcard_imports,
6213 clippy::let_unit_value,
6214 )]
6215 use tonic::codegen::*;
6216 #[async_trait]
6218 pub trait ScaleService: std::marker::Send + std::marker::Sync + 'static {
6219 async fn get_cluster_info(
6220 &self,
6221 request: tonic::Request<super::GetClusterInfoRequest>,
6222 ) -> std::result::Result<
6223 tonic::Response<super::GetClusterInfoResponse>,
6224 tonic::Status,
6225 >;
6226 async fn reschedule(
6227 &self,
6228 request: tonic::Request<super::RescheduleRequest>,
6229 ) -> std::result::Result<
6230 tonic::Response<super::RescheduleResponse>,
6231 tonic::Status,
6232 >;
6233 async fn update_streaming_job_node_labels(
6234 &self,
6235 request: tonic::Request<super::UpdateStreamingJobNodeLabelsRequest>,
6236 ) -> std::result::Result<
6237 tonic::Response<super::UpdateStreamingJobNodeLabelsResponse>,
6238 tonic::Status,
6239 >;
6240 async fn get_serverless_streaming_jobs_status(
6241 &self,
6242 request: tonic::Request<super::GetServerlessStreamingJobsStatusRequest>,
6243 ) -> std::result::Result<
6244 tonic::Response<super::GetServerlessStreamingJobsStatusResponse>,
6245 tonic::Status,
6246 >;
6247 }
6248 #[derive(Debug)]
6250 pub struct ScaleServiceServer<T> {
6251 inner: Arc<T>,
6252 accept_compression_encodings: EnabledCompressionEncodings,
6253 send_compression_encodings: EnabledCompressionEncodings,
6254 max_decoding_message_size: Option<usize>,
6255 max_encoding_message_size: Option<usize>,
6256 }
6257 impl<T> ScaleServiceServer<T> {
6258 pub fn new(inner: T) -> Self {
6259 Self::from_arc(Arc::new(inner))
6260 }
6261 pub fn from_arc(inner: Arc<T>) -> Self {
6262 Self {
6263 inner,
6264 accept_compression_encodings: Default::default(),
6265 send_compression_encodings: Default::default(),
6266 max_decoding_message_size: None,
6267 max_encoding_message_size: None,
6268 }
6269 }
6270 pub fn with_interceptor<F>(
6271 inner: T,
6272 interceptor: F,
6273 ) -> InterceptedService<Self, F>
6274 where
6275 F: tonic::service::Interceptor,
6276 {
6277 InterceptedService::new(Self::new(inner), interceptor)
6278 }
6279 #[must_use]
6281 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
6282 self.accept_compression_encodings.enable(encoding);
6283 self
6284 }
6285 #[must_use]
6287 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
6288 self.send_compression_encodings.enable(encoding);
6289 self
6290 }
6291 #[must_use]
6295 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
6296 self.max_decoding_message_size = Some(limit);
6297 self
6298 }
6299 #[must_use]
6303 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
6304 self.max_encoding_message_size = Some(limit);
6305 self
6306 }
6307 }
6308 impl<T, B> tonic::codegen::Service<http::Request<B>> for ScaleServiceServer<T>
6309 where
6310 T: ScaleService,
6311 B: Body + std::marker::Send + 'static,
6312 B::Error: Into<StdError> + std::marker::Send + 'static,
6313 {
6314 type Response = http::Response<tonic::body::BoxBody>;
6315 type Error = std::convert::Infallible;
6316 type Future = BoxFuture<Self::Response, Self::Error>;
6317 fn poll_ready(
6318 &mut self,
6319 _cx: &mut Context<'_>,
6320 ) -> Poll<std::result::Result<(), Self::Error>> {
6321 Poll::Ready(Ok(()))
6322 }
6323 fn call(&mut self, req: http::Request<B>) -> Self::Future {
6324 match req.uri().path() {
6325 "/meta.ScaleService/GetClusterInfo" => {
6326 #[allow(non_camel_case_types)]
6327 struct GetClusterInfoSvc<T: ScaleService>(pub Arc<T>);
6328 impl<
6329 T: ScaleService,
6330 > tonic::server::UnaryService<super::GetClusterInfoRequest>
6331 for GetClusterInfoSvc<T> {
6332 type Response = super::GetClusterInfoResponse;
6333 type Future = BoxFuture<
6334 tonic::Response<Self::Response>,
6335 tonic::Status,
6336 >;
6337 fn call(
6338 &mut self,
6339 request: tonic::Request<super::GetClusterInfoRequest>,
6340 ) -> Self::Future {
6341 let inner = Arc::clone(&self.0);
6342 let fut = async move {
6343 <T as ScaleService>::get_cluster_info(&inner, request).await
6344 };
6345 Box::pin(fut)
6346 }
6347 }
6348 let accept_compression_encodings = self.accept_compression_encodings;
6349 let send_compression_encodings = self.send_compression_encodings;
6350 let max_decoding_message_size = self.max_decoding_message_size;
6351 let max_encoding_message_size = self.max_encoding_message_size;
6352 let inner = self.inner.clone();
6353 let fut = async move {
6354 let method = GetClusterInfoSvc(inner);
6355 let codec = tonic::codec::ProstCodec::default();
6356 let mut grpc = tonic::server::Grpc::new(codec)
6357 .apply_compression_config(
6358 accept_compression_encodings,
6359 send_compression_encodings,
6360 )
6361 .apply_max_message_size_config(
6362 max_decoding_message_size,
6363 max_encoding_message_size,
6364 );
6365 let res = grpc.unary(method, req).await;
6366 Ok(res)
6367 };
6368 Box::pin(fut)
6369 }
6370 "/meta.ScaleService/Reschedule" => {
6371 #[allow(non_camel_case_types)]
6372 struct RescheduleSvc<T: ScaleService>(pub Arc<T>);
6373 impl<
6374 T: ScaleService,
6375 > tonic::server::UnaryService<super::RescheduleRequest>
6376 for RescheduleSvc<T> {
6377 type Response = super::RescheduleResponse;
6378 type Future = BoxFuture<
6379 tonic::Response<Self::Response>,
6380 tonic::Status,
6381 >;
6382 fn call(
6383 &mut self,
6384 request: tonic::Request<super::RescheduleRequest>,
6385 ) -> Self::Future {
6386 let inner = Arc::clone(&self.0);
6387 let fut = async move {
6388 <T as ScaleService>::reschedule(&inner, request).await
6389 };
6390 Box::pin(fut)
6391 }
6392 }
6393 let accept_compression_encodings = self.accept_compression_encodings;
6394 let send_compression_encodings = self.send_compression_encodings;
6395 let max_decoding_message_size = self.max_decoding_message_size;
6396 let max_encoding_message_size = self.max_encoding_message_size;
6397 let inner = self.inner.clone();
6398 let fut = async move {
6399 let method = RescheduleSvc(inner);
6400 let codec = tonic::codec::ProstCodec::default();
6401 let mut grpc = tonic::server::Grpc::new(codec)
6402 .apply_compression_config(
6403 accept_compression_encodings,
6404 send_compression_encodings,
6405 )
6406 .apply_max_message_size_config(
6407 max_decoding_message_size,
6408 max_encoding_message_size,
6409 );
6410 let res = grpc.unary(method, req).await;
6411 Ok(res)
6412 };
6413 Box::pin(fut)
6414 }
6415 "/meta.ScaleService/UpdateStreamingJobNodeLabels" => {
6416 #[allow(non_camel_case_types)]
6417 struct UpdateStreamingJobNodeLabelsSvc<T: ScaleService>(pub Arc<T>);
6418 impl<
6419 T: ScaleService,
6420 > tonic::server::UnaryService<
6421 super::UpdateStreamingJobNodeLabelsRequest,
6422 > for UpdateStreamingJobNodeLabelsSvc<T> {
6423 type Response = super::UpdateStreamingJobNodeLabelsResponse;
6424 type Future = BoxFuture<
6425 tonic::Response<Self::Response>,
6426 tonic::Status,
6427 >;
6428 fn call(
6429 &mut self,
6430 request: tonic::Request<
6431 super::UpdateStreamingJobNodeLabelsRequest,
6432 >,
6433 ) -> Self::Future {
6434 let inner = Arc::clone(&self.0);
6435 let fut = async move {
6436 <T as ScaleService>::update_streaming_job_node_labels(
6437 &inner,
6438 request,
6439 )
6440 .await
6441 };
6442 Box::pin(fut)
6443 }
6444 }
6445 let accept_compression_encodings = self.accept_compression_encodings;
6446 let send_compression_encodings = self.send_compression_encodings;
6447 let max_decoding_message_size = self.max_decoding_message_size;
6448 let max_encoding_message_size = self.max_encoding_message_size;
6449 let inner = self.inner.clone();
6450 let fut = async move {
6451 let method = UpdateStreamingJobNodeLabelsSvc(inner);
6452 let codec = tonic::codec::ProstCodec::default();
6453 let mut grpc = tonic::server::Grpc::new(codec)
6454 .apply_compression_config(
6455 accept_compression_encodings,
6456 send_compression_encodings,
6457 )
6458 .apply_max_message_size_config(
6459 max_decoding_message_size,
6460 max_encoding_message_size,
6461 );
6462 let res = grpc.unary(method, req).await;
6463 Ok(res)
6464 };
6465 Box::pin(fut)
6466 }
6467 "/meta.ScaleService/GetServerlessStreamingJobsStatus" => {
6468 #[allow(non_camel_case_types)]
6469 struct GetServerlessStreamingJobsStatusSvc<T: ScaleService>(
6470 pub Arc<T>,
6471 );
6472 impl<
6473 T: ScaleService,
6474 > tonic::server::UnaryService<
6475 super::GetServerlessStreamingJobsStatusRequest,
6476 > for GetServerlessStreamingJobsStatusSvc<T> {
6477 type Response = super::GetServerlessStreamingJobsStatusResponse;
6478 type Future = BoxFuture<
6479 tonic::Response<Self::Response>,
6480 tonic::Status,
6481 >;
6482 fn call(
6483 &mut self,
6484 request: tonic::Request<
6485 super::GetServerlessStreamingJobsStatusRequest,
6486 >,
6487 ) -> Self::Future {
6488 let inner = Arc::clone(&self.0);
6489 let fut = async move {
6490 <T as ScaleService>::get_serverless_streaming_jobs_status(
6491 &inner,
6492 request,
6493 )
6494 .await
6495 };
6496 Box::pin(fut)
6497 }
6498 }
6499 let accept_compression_encodings = self.accept_compression_encodings;
6500 let send_compression_encodings = self.send_compression_encodings;
6501 let max_decoding_message_size = self.max_decoding_message_size;
6502 let max_encoding_message_size = self.max_encoding_message_size;
6503 let inner = self.inner.clone();
6504 let fut = async move {
6505 let method = GetServerlessStreamingJobsStatusSvc(inner);
6506 let codec = tonic::codec::ProstCodec::default();
6507 let mut grpc = tonic::server::Grpc::new(codec)
6508 .apply_compression_config(
6509 accept_compression_encodings,
6510 send_compression_encodings,
6511 )
6512 .apply_max_message_size_config(
6513 max_decoding_message_size,
6514 max_encoding_message_size,
6515 );
6516 let res = grpc.unary(method, req).await;
6517 Ok(res)
6518 };
6519 Box::pin(fut)
6520 }
6521 _ => {
6522 Box::pin(async move {
6523 let mut response = http::Response::new(empty_body());
6524 let headers = response.headers_mut();
6525 headers
6526 .insert(
6527 tonic::Status::GRPC_STATUS,
6528 (tonic::Code::Unimplemented as i32).into(),
6529 );
6530 headers
6531 .insert(
6532 http::header::CONTENT_TYPE,
6533 tonic::metadata::GRPC_CONTENT_TYPE,
6534 );
6535 Ok(response)
6536 })
6537 }
6538 }
6539 }
6540 }
6541 impl<T> Clone for ScaleServiceServer<T> {
6542 fn clone(&self) -> Self {
6543 let inner = self.inner.clone();
6544 Self {
6545 inner,
6546 accept_compression_encodings: self.accept_compression_encodings,
6547 send_compression_encodings: self.send_compression_encodings,
6548 max_decoding_message_size: self.max_decoding_message_size,
6549 max_encoding_message_size: self.max_encoding_message_size,
6550 }
6551 }
6552 }
6553 pub const SERVICE_NAME: &str = "meta.ScaleService";
6555 impl<T> tonic::server::NamedService for ScaleServiceServer<T> {
6556 const NAME: &'static str = SERVICE_NAME;
6557 }
6558}
6559pub mod meta_member_service_server {
6561 #![allow(
6562 unused_variables,
6563 dead_code,
6564 missing_docs,
6565 clippy::wildcard_imports,
6566 clippy::let_unit_value,
6567 )]
6568 use tonic::codegen::*;
6569 #[async_trait]
6571 pub trait MetaMemberService: std::marker::Send + std::marker::Sync + 'static {
6572 async fn members(
6573 &self,
6574 request: tonic::Request<super::MembersRequest>,
6575 ) -> std::result::Result<tonic::Response<super::MembersResponse>, tonic::Status>;
6576 }
6577 #[derive(Debug)]
6578 pub struct MetaMemberServiceServer<T> {
6579 inner: Arc<T>,
6580 accept_compression_encodings: EnabledCompressionEncodings,
6581 send_compression_encodings: EnabledCompressionEncodings,
6582 max_decoding_message_size: Option<usize>,
6583 max_encoding_message_size: Option<usize>,
6584 }
6585 impl<T> MetaMemberServiceServer<T> {
6586 pub fn new(inner: T) -> Self {
6587 Self::from_arc(Arc::new(inner))
6588 }
6589 pub fn from_arc(inner: Arc<T>) -> Self {
6590 Self {
6591 inner,
6592 accept_compression_encodings: Default::default(),
6593 send_compression_encodings: Default::default(),
6594 max_decoding_message_size: None,
6595 max_encoding_message_size: None,
6596 }
6597 }
6598 pub fn with_interceptor<F>(
6599 inner: T,
6600 interceptor: F,
6601 ) -> InterceptedService<Self, F>
6602 where
6603 F: tonic::service::Interceptor,
6604 {
6605 InterceptedService::new(Self::new(inner), interceptor)
6606 }
6607 #[must_use]
6609 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
6610 self.accept_compression_encodings.enable(encoding);
6611 self
6612 }
6613 #[must_use]
6615 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
6616 self.send_compression_encodings.enable(encoding);
6617 self
6618 }
6619 #[must_use]
6623 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
6624 self.max_decoding_message_size = Some(limit);
6625 self
6626 }
6627 #[must_use]
6631 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
6632 self.max_encoding_message_size = Some(limit);
6633 self
6634 }
6635 }
6636 impl<T, B> tonic::codegen::Service<http::Request<B>> for MetaMemberServiceServer<T>
6637 where
6638 T: MetaMemberService,
6639 B: Body + std::marker::Send + 'static,
6640 B::Error: Into<StdError> + std::marker::Send + 'static,
6641 {
6642 type Response = http::Response<tonic::body::BoxBody>;
6643 type Error = std::convert::Infallible;
6644 type Future = BoxFuture<Self::Response, Self::Error>;
6645 fn poll_ready(
6646 &mut self,
6647 _cx: &mut Context<'_>,
6648 ) -> Poll<std::result::Result<(), Self::Error>> {
6649 Poll::Ready(Ok(()))
6650 }
6651 fn call(&mut self, req: http::Request<B>) -> Self::Future {
6652 match req.uri().path() {
6653 "/meta.MetaMemberService/Members" => {
6654 #[allow(non_camel_case_types)]
6655 struct MembersSvc<T: MetaMemberService>(pub Arc<T>);
6656 impl<
6657 T: MetaMemberService,
6658 > tonic::server::UnaryService<super::MembersRequest>
6659 for MembersSvc<T> {
6660 type Response = super::MembersResponse;
6661 type Future = BoxFuture<
6662 tonic::Response<Self::Response>,
6663 tonic::Status,
6664 >;
6665 fn call(
6666 &mut self,
6667 request: tonic::Request<super::MembersRequest>,
6668 ) -> Self::Future {
6669 let inner = Arc::clone(&self.0);
6670 let fut = async move {
6671 <T as MetaMemberService>::members(&inner, request).await
6672 };
6673 Box::pin(fut)
6674 }
6675 }
6676 let accept_compression_encodings = self.accept_compression_encodings;
6677 let send_compression_encodings = self.send_compression_encodings;
6678 let max_decoding_message_size = self.max_decoding_message_size;
6679 let max_encoding_message_size = self.max_encoding_message_size;
6680 let inner = self.inner.clone();
6681 let fut = async move {
6682 let method = MembersSvc(inner);
6683 let codec = tonic::codec::ProstCodec::default();
6684 let mut grpc = tonic::server::Grpc::new(codec)
6685 .apply_compression_config(
6686 accept_compression_encodings,
6687 send_compression_encodings,
6688 )
6689 .apply_max_message_size_config(
6690 max_decoding_message_size,
6691 max_encoding_message_size,
6692 );
6693 let res = grpc.unary(method, req).await;
6694 Ok(res)
6695 };
6696 Box::pin(fut)
6697 }
6698 _ => {
6699 Box::pin(async move {
6700 let mut response = http::Response::new(empty_body());
6701 let headers = response.headers_mut();
6702 headers
6703 .insert(
6704 tonic::Status::GRPC_STATUS,
6705 (tonic::Code::Unimplemented as i32).into(),
6706 );
6707 headers
6708 .insert(
6709 http::header::CONTENT_TYPE,
6710 tonic::metadata::GRPC_CONTENT_TYPE,
6711 );
6712 Ok(response)
6713 })
6714 }
6715 }
6716 }
6717 }
6718 impl<T> Clone for MetaMemberServiceServer<T> {
6719 fn clone(&self) -> Self {
6720 let inner = self.inner.clone();
6721 Self {
6722 inner,
6723 accept_compression_encodings: self.accept_compression_encodings,
6724 send_compression_encodings: self.send_compression_encodings,
6725 max_decoding_message_size: self.max_decoding_message_size,
6726 max_encoding_message_size: self.max_encoding_message_size,
6727 }
6728 }
6729 }
6730 pub const SERVICE_NAME: &str = "meta.MetaMemberService";
6732 impl<T> tonic::server::NamedService for MetaMemberServiceServer<T> {
6733 const NAME: &'static str = SERVICE_NAME;
6734 }
6735}
6736pub mod system_params_service_server {
6738 #![allow(
6739 unused_variables,
6740 dead_code,
6741 missing_docs,
6742 clippy::wildcard_imports,
6743 clippy::let_unit_value,
6744 )]
6745 use tonic::codegen::*;
6746 #[async_trait]
6748 pub trait SystemParamsService: std::marker::Send + std::marker::Sync + 'static {
6749 async fn get_system_params(
6750 &self,
6751 request: tonic::Request<super::GetSystemParamsRequest>,
6752 ) -> std::result::Result<
6753 tonic::Response<super::GetSystemParamsResponse>,
6754 tonic::Status,
6755 >;
6756 async fn set_system_param(
6757 &self,
6758 request: tonic::Request<super::SetSystemParamRequest>,
6759 ) -> std::result::Result<
6760 tonic::Response<super::SetSystemParamResponse>,
6761 tonic::Status,
6762 >;
6763 }
6764 #[derive(Debug)]
6765 pub struct SystemParamsServiceServer<T> {
6766 inner: Arc<T>,
6767 accept_compression_encodings: EnabledCompressionEncodings,
6768 send_compression_encodings: EnabledCompressionEncodings,
6769 max_decoding_message_size: Option<usize>,
6770 max_encoding_message_size: Option<usize>,
6771 }
6772 impl<T> SystemParamsServiceServer<T> {
6773 pub fn new(inner: T) -> Self {
6774 Self::from_arc(Arc::new(inner))
6775 }
6776 pub fn from_arc(inner: Arc<T>) -> Self {
6777 Self {
6778 inner,
6779 accept_compression_encodings: Default::default(),
6780 send_compression_encodings: Default::default(),
6781 max_decoding_message_size: None,
6782 max_encoding_message_size: None,
6783 }
6784 }
6785 pub fn with_interceptor<F>(
6786 inner: T,
6787 interceptor: F,
6788 ) -> InterceptedService<Self, F>
6789 where
6790 F: tonic::service::Interceptor,
6791 {
6792 InterceptedService::new(Self::new(inner), interceptor)
6793 }
6794 #[must_use]
6796 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
6797 self.accept_compression_encodings.enable(encoding);
6798 self
6799 }
6800 #[must_use]
6802 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
6803 self.send_compression_encodings.enable(encoding);
6804 self
6805 }
6806 #[must_use]
6810 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
6811 self.max_decoding_message_size = Some(limit);
6812 self
6813 }
6814 #[must_use]
6818 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
6819 self.max_encoding_message_size = Some(limit);
6820 self
6821 }
6822 }
6823 impl<T, B> tonic::codegen::Service<http::Request<B>> for SystemParamsServiceServer<T>
6824 where
6825 T: SystemParamsService,
6826 B: Body + std::marker::Send + 'static,
6827 B::Error: Into<StdError> + std::marker::Send + 'static,
6828 {
6829 type Response = http::Response<tonic::body::BoxBody>;
6830 type Error = std::convert::Infallible;
6831 type Future = BoxFuture<Self::Response, Self::Error>;
6832 fn poll_ready(
6833 &mut self,
6834 _cx: &mut Context<'_>,
6835 ) -> Poll<std::result::Result<(), Self::Error>> {
6836 Poll::Ready(Ok(()))
6837 }
6838 fn call(&mut self, req: http::Request<B>) -> Self::Future {
6839 match req.uri().path() {
6840 "/meta.SystemParamsService/GetSystemParams" => {
6841 #[allow(non_camel_case_types)]
6842 struct GetSystemParamsSvc<T: SystemParamsService>(pub Arc<T>);
6843 impl<
6844 T: SystemParamsService,
6845 > tonic::server::UnaryService<super::GetSystemParamsRequest>
6846 for GetSystemParamsSvc<T> {
6847 type Response = super::GetSystemParamsResponse;
6848 type Future = BoxFuture<
6849 tonic::Response<Self::Response>,
6850 tonic::Status,
6851 >;
6852 fn call(
6853 &mut self,
6854 request: tonic::Request<super::GetSystemParamsRequest>,
6855 ) -> Self::Future {
6856 let inner = Arc::clone(&self.0);
6857 let fut = async move {
6858 <T as SystemParamsService>::get_system_params(
6859 &inner,
6860 request,
6861 )
6862 .await
6863 };
6864 Box::pin(fut)
6865 }
6866 }
6867 let accept_compression_encodings = self.accept_compression_encodings;
6868 let send_compression_encodings = self.send_compression_encodings;
6869 let max_decoding_message_size = self.max_decoding_message_size;
6870 let max_encoding_message_size = self.max_encoding_message_size;
6871 let inner = self.inner.clone();
6872 let fut = async move {
6873 let method = GetSystemParamsSvc(inner);
6874 let codec = tonic::codec::ProstCodec::default();
6875 let mut grpc = tonic::server::Grpc::new(codec)
6876 .apply_compression_config(
6877 accept_compression_encodings,
6878 send_compression_encodings,
6879 )
6880 .apply_max_message_size_config(
6881 max_decoding_message_size,
6882 max_encoding_message_size,
6883 );
6884 let res = grpc.unary(method, req).await;
6885 Ok(res)
6886 };
6887 Box::pin(fut)
6888 }
6889 "/meta.SystemParamsService/SetSystemParam" => {
6890 #[allow(non_camel_case_types)]
6891 struct SetSystemParamSvc<T: SystemParamsService>(pub Arc<T>);
6892 impl<
6893 T: SystemParamsService,
6894 > tonic::server::UnaryService<super::SetSystemParamRequest>
6895 for SetSystemParamSvc<T> {
6896 type Response = super::SetSystemParamResponse;
6897 type Future = BoxFuture<
6898 tonic::Response<Self::Response>,
6899 tonic::Status,
6900 >;
6901 fn call(
6902 &mut self,
6903 request: tonic::Request<super::SetSystemParamRequest>,
6904 ) -> Self::Future {
6905 let inner = Arc::clone(&self.0);
6906 let fut = async move {
6907 <T as SystemParamsService>::set_system_param(
6908 &inner,
6909 request,
6910 )
6911 .await
6912 };
6913 Box::pin(fut)
6914 }
6915 }
6916 let accept_compression_encodings = self.accept_compression_encodings;
6917 let send_compression_encodings = self.send_compression_encodings;
6918 let max_decoding_message_size = self.max_decoding_message_size;
6919 let max_encoding_message_size = self.max_encoding_message_size;
6920 let inner = self.inner.clone();
6921 let fut = async move {
6922 let method = SetSystemParamSvc(inner);
6923 let codec = tonic::codec::ProstCodec::default();
6924 let mut grpc = tonic::server::Grpc::new(codec)
6925 .apply_compression_config(
6926 accept_compression_encodings,
6927 send_compression_encodings,
6928 )
6929 .apply_max_message_size_config(
6930 max_decoding_message_size,
6931 max_encoding_message_size,
6932 );
6933 let res = grpc.unary(method, req).await;
6934 Ok(res)
6935 };
6936 Box::pin(fut)
6937 }
6938 _ => {
6939 Box::pin(async move {
6940 let mut response = http::Response::new(empty_body());
6941 let headers = response.headers_mut();
6942 headers
6943 .insert(
6944 tonic::Status::GRPC_STATUS,
6945 (tonic::Code::Unimplemented as i32).into(),
6946 );
6947 headers
6948 .insert(
6949 http::header::CONTENT_TYPE,
6950 tonic::metadata::GRPC_CONTENT_TYPE,
6951 );
6952 Ok(response)
6953 })
6954 }
6955 }
6956 }
6957 }
6958 impl<T> Clone for SystemParamsServiceServer<T> {
6959 fn clone(&self) -> Self {
6960 let inner = self.inner.clone();
6961 Self {
6962 inner,
6963 accept_compression_encodings: self.accept_compression_encodings,
6964 send_compression_encodings: self.send_compression_encodings,
6965 max_decoding_message_size: self.max_decoding_message_size,
6966 max_encoding_message_size: self.max_encoding_message_size,
6967 }
6968 }
6969 }
6970 pub const SERVICE_NAME: &str = "meta.SystemParamsService";
6972 impl<T> tonic::server::NamedService for SystemParamsServiceServer<T> {
6973 const NAME: &'static str = SERVICE_NAME;
6974 }
6975}
6976pub mod session_param_service_server {
6978 #![allow(
6979 unused_variables,
6980 dead_code,
6981 missing_docs,
6982 clippy::wildcard_imports,
6983 clippy::let_unit_value,
6984 )]
6985 use tonic::codegen::*;
6986 #[async_trait]
6988 pub trait SessionParamService: std::marker::Send + std::marker::Sync + 'static {
6989 async fn get_session_params(
6990 &self,
6991 request: tonic::Request<super::GetSessionParamsRequest>,
6992 ) -> std::result::Result<
6993 tonic::Response<super::GetSessionParamsResponse>,
6994 tonic::Status,
6995 >;
6996 async fn set_session_param(
6997 &self,
6998 request: tonic::Request<super::SetSessionParamRequest>,
6999 ) -> std::result::Result<
7000 tonic::Response<super::SetSessionParamResponse>,
7001 tonic::Status,
7002 >;
7003 }
7004 #[derive(Debug)]
7006 pub struct SessionParamServiceServer<T> {
7007 inner: Arc<T>,
7008 accept_compression_encodings: EnabledCompressionEncodings,
7009 send_compression_encodings: EnabledCompressionEncodings,
7010 max_decoding_message_size: Option<usize>,
7011 max_encoding_message_size: Option<usize>,
7012 }
7013 impl<T> SessionParamServiceServer<T> {
7014 pub fn new(inner: T) -> Self {
7015 Self::from_arc(Arc::new(inner))
7016 }
7017 pub fn from_arc(inner: Arc<T>) -> Self {
7018 Self {
7019 inner,
7020 accept_compression_encodings: Default::default(),
7021 send_compression_encodings: Default::default(),
7022 max_decoding_message_size: None,
7023 max_encoding_message_size: None,
7024 }
7025 }
7026 pub fn with_interceptor<F>(
7027 inner: T,
7028 interceptor: F,
7029 ) -> InterceptedService<Self, F>
7030 where
7031 F: tonic::service::Interceptor,
7032 {
7033 InterceptedService::new(Self::new(inner), interceptor)
7034 }
7035 #[must_use]
7037 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
7038 self.accept_compression_encodings.enable(encoding);
7039 self
7040 }
7041 #[must_use]
7043 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
7044 self.send_compression_encodings.enable(encoding);
7045 self
7046 }
7047 #[must_use]
7051 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
7052 self.max_decoding_message_size = Some(limit);
7053 self
7054 }
7055 #[must_use]
7059 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
7060 self.max_encoding_message_size = Some(limit);
7061 self
7062 }
7063 }
7064 impl<T, B> tonic::codegen::Service<http::Request<B>> for SessionParamServiceServer<T>
7065 where
7066 T: SessionParamService,
7067 B: Body + std::marker::Send + 'static,
7068 B::Error: Into<StdError> + std::marker::Send + 'static,
7069 {
7070 type Response = http::Response<tonic::body::BoxBody>;
7071 type Error = std::convert::Infallible;
7072 type Future = BoxFuture<Self::Response, Self::Error>;
7073 fn poll_ready(
7074 &mut self,
7075 _cx: &mut Context<'_>,
7076 ) -> Poll<std::result::Result<(), Self::Error>> {
7077 Poll::Ready(Ok(()))
7078 }
7079 fn call(&mut self, req: http::Request<B>) -> Self::Future {
7080 match req.uri().path() {
7081 "/meta.SessionParamService/GetSessionParams" => {
7082 #[allow(non_camel_case_types)]
7083 struct GetSessionParamsSvc<T: SessionParamService>(pub Arc<T>);
7084 impl<
7085 T: SessionParamService,
7086 > tonic::server::UnaryService<super::GetSessionParamsRequest>
7087 for GetSessionParamsSvc<T> {
7088 type Response = super::GetSessionParamsResponse;
7089 type Future = BoxFuture<
7090 tonic::Response<Self::Response>,
7091 tonic::Status,
7092 >;
7093 fn call(
7094 &mut self,
7095 request: tonic::Request<super::GetSessionParamsRequest>,
7096 ) -> Self::Future {
7097 let inner = Arc::clone(&self.0);
7098 let fut = async move {
7099 <T as SessionParamService>::get_session_params(
7100 &inner,
7101 request,
7102 )
7103 .await
7104 };
7105 Box::pin(fut)
7106 }
7107 }
7108 let accept_compression_encodings = self.accept_compression_encodings;
7109 let send_compression_encodings = self.send_compression_encodings;
7110 let max_decoding_message_size = self.max_decoding_message_size;
7111 let max_encoding_message_size = self.max_encoding_message_size;
7112 let inner = self.inner.clone();
7113 let fut = async move {
7114 let method = GetSessionParamsSvc(inner);
7115 let codec = tonic::codec::ProstCodec::default();
7116 let mut grpc = tonic::server::Grpc::new(codec)
7117 .apply_compression_config(
7118 accept_compression_encodings,
7119 send_compression_encodings,
7120 )
7121 .apply_max_message_size_config(
7122 max_decoding_message_size,
7123 max_encoding_message_size,
7124 );
7125 let res = grpc.unary(method, req).await;
7126 Ok(res)
7127 };
7128 Box::pin(fut)
7129 }
7130 "/meta.SessionParamService/SetSessionParam" => {
7131 #[allow(non_camel_case_types)]
7132 struct SetSessionParamSvc<T: SessionParamService>(pub Arc<T>);
7133 impl<
7134 T: SessionParamService,
7135 > tonic::server::UnaryService<super::SetSessionParamRequest>
7136 for SetSessionParamSvc<T> {
7137 type Response = super::SetSessionParamResponse;
7138 type Future = BoxFuture<
7139 tonic::Response<Self::Response>,
7140 tonic::Status,
7141 >;
7142 fn call(
7143 &mut self,
7144 request: tonic::Request<super::SetSessionParamRequest>,
7145 ) -> Self::Future {
7146 let inner = Arc::clone(&self.0);
7147 let fut = async move {
7148 <T as SessionParamService>::set_session_param(
7149 &inner,
7150 request,
7151 )
7152 .await
7153 };
7154 Box::pin(fut)
7155 }
7156 }
7157 let accept_compression_encodings = self.accept_compression_encodings;
7158 let send_compression_encodings = self.send_compression_encodings;
7159 let max_decoding_message_size = self.max_decoding_message_size;
7160 let max_encoding_message_size = self.max_encoding_message_size;
7161 let inner = self.inner.clone();
7162 let fut = async move {
7163 let method = SetSessionParamSvc(inner);
7164 let codec = tonic::codec::ProstCodec::default();
7165 let mut grpc = tonic::server::Grpc::new(codec)
7166 .apply_compression_config(
7167 accept_compression_encodings,
7168 send_compression_encodings,
7169 )
7170 .apply_max_message_size_config(
7171 max_decoding_message_size,
7172 max_encoding_message_size,
7173 );
7174 let res = grpc.unary(method, req).await;
7175 Ok(res)
7176 };
7177 Box::pin(fut)
7178 }
7179 _ => {
7180 Box::pin(async move {
7181 let mut response = http::Response::new(empty_body());
7182 let headers = response.headers_mut();
7183 headers
7184 .insert(
7185 tonic::Status::GRPC_STATUS,
7186 (tonic::Code::Unimplemented as i32).into(),
7187 );
7188 headers
7189 .insert(
7190 http::header::CONTENT_TYPE,
7191 tonic::metadata::GRPC_CONTENT_TYPE,
7192 );
7193 Ok(response)
7194 })
7195 }
7196 }
7197 }
7198 }
7199 impl<T> Clone for SessionParamServiceServer<T> {
7200 fn clone(&self) -> Self {
7201 let inner = self.inner.clone();
7202 Self {
7203 inner,
7204 accept_compression_encodings: self.accept_compression_encodings,
7205 send_compression_encodings: self.send_compression_encodings,
7206 max_decoding_message_size: self.max_decoding_message_size,
7207 max_encoding_message_size: self.max_encoding_message_size,
7208 }
7209 }
7210 }
7211 pub const SERVICE_NAME: &str = "meta.SessionParamService";
7213 impl<T> tonic::server::NamedService for SessionParamServiceServer<T> {
7214 const NAME: &'static str = SERVICE_NAME;
7215 }
7216}
7217pub mod serving_service_server {
7219 #![allow(
7220 unused_variables,
7221 dead_code,
7222 missing_docs,
7223 clippy::wildcard_imports,
7224 clippy::let_unit_value,
7225 )]
7226 use tonic::codegen::*;
7227 #[async_trait]
7229 pub trait ServingService: std::marker::Send + std::marker::Sync + 'static {
7230 async fn get_serving_vnode_mappings(
7231 &self,
7232 request: tonic::Request<super::GetServingVnodeMappingsRequest>,
7233 ) -> std::result::Result<
7234 tonic::Response<super::GetServingVnodeMappingsResponse>,
7235 tonic::Status,
7236 >;
7237 }
7238 #[derive(Debug)]
7239 pub struct ServingServiceServer<T> {
7240 inner: Arc<T>,
7241 accept_compression_encodings: EnabledCompressionEncodings,
7242 send_compression_encodings: EnabledCompressionEncodings,
7243 max_decoding_message_size: Option<usize>,
7244 max_encoding_message_size: Option<usize>,
7245 }
7246 impl<T> ServingServiceServer<T> {
7247 pub fn new(inner: T) -> Self {
7248 Self::from_arc(Arc::new(inner))
7249 }
7250 pub fn from_arc(inner: Arc<T>) -> Self {
7251 Self {
7252 inner,
7253 accept_compression_encodings: Default::default(),
7254 send_compression_encodings: Default::default(),
7255 max_decoding_message_size: None,
7256 max_encoding_message_size: None,
7257 }
7258 }
7259 pub fn with_interceptor<F>(
7260 inner: T,
7261 interceptor: F,
7262 ) -> InterceptedService<Self, F>
7263 where
7264 F: tonic::service::Interceptor,
7265 {
7266 InterceptedService::new(Self::new(inner), interceptor)
7267 }
7268 #[must_use]
7270 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
7271 self.accept_compression_encodings.enable(encoding);
7272 self
7273 }
7274 #[must_use]
7276 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
7277 self.send_compression_encodings.enable(encoding);
7278 self
7279 }
7280 #[must_use]
7284 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
7285 self.max_decoding_message_size = Some(limit);
7286 self
7287 }
7288 #[must_use]
7292 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
7293 self.max_encoding_message_size = Some(limit);
7294 self
7295 }
7296 }
7297 impl<T, B> tonic::codegen::Service<http::Request<B>> for ServingServiceServer<T>
7298 where
7299 T: ServingService,
7300 B: Body + std::marker::Send + 'static,
7301 B::Error: Into<StdError> + std::marker::Send + 'static,
7302 {
7303 type Response = http::Response<tonic::body::BoxBody>;
7304 type Error = std::convert::Infallible;
7305 type Future = BoxFuture<Self::Response, Self::Error>;
7306 fn poll_ready(
7307 &mut self,
7308 _cx: &mut Context<'_>,
7309 ) -> Poll<std::result::Result<(), Self::Error>> {
7310 Poll::Ready(Ok(()))
7311 }
7312 fn call(&mut self, req: http::Request<B>) -> Self::Future {
7313 match req.uri().path() {
7314 "/meta.ServingService/GetServingVnodeMappings" => {
7315 #[allow(non_camel_case_types)]
7316 struct GetServingVnodeMappingsSvc<T: ServingService>(pub Arc<T>);
7317 impl<
7318 T: ServingService,
7319 > tonic::server::UnaryService<super::GetServingVnodeMappingsRequest>
7320 for GetServingVnodeMappingsSvc<T> {
7321 type Response = super::GetServingVnodeMappingsResponse;
7322 type Future = BoxFuture<
7323 tonic::Response<Self::Response>,
7324 tonic::Status,
7325 >;
7326 fn call(
7327 &mut self,
7328 request: tonic::Request<
7329 super::GetServingVnodeMappingsRequest,
7330 >,
7331 ) -> Self::Future {
7332 let inner = Arc::clone(&self.0);
7333 let fut = async move {
7334 <T as ServingService>::get_serving_vnode_mappings(
7335 &inner,
7336 request,
7337 )
7338 .await
7339 };
7340 Box::pin(fut)
7341 }
7342 }
7343 let accept_compression_encodings = self.accept_compression_encodings;
7344 let send_compression_encodings = self.send_compression_encodings;
7345 let max_decoding_message_size = self.max_decoding_message_size;
7346 let max_encoding_message_size = self.max_encoding_message_size;
7347 let inner = self.inner.clone();
7348 let fut = async move {
7349 let method = GetServingVnodeMappingsSvc(inner);
7350 let codec = tonic::codec::ProstCodec::default();
7351 let mut grpc = tonic::server::Grpc::new(codec)
7352 .apply_compression_config(
7353 accept_compression_encodings,
7354 send_compression_encodings,
7355 )
7356 .apply_max_message_size_config(
7357 max_decoding_message_size,
7358 max_encoding_message_size,
7359 );
7360 let res = grpc.unary(method, req).await;
7361 Ok(res)
7362 };
7363 Box::pin(fut)
7364 }
7365 _ => {
7366 Box::pin(async move {
7367 let mut response = http::Response::new(empty_body());
7368 let headers = response.headers_mut();
7369 headers
7370 .insert(
7371 tonic::Status::GRPC_STATUS,
7372 (tonic::Code::Unimplemented as i32).into(),
7373 );
7374 headers
7375 .insert(
7376 http::header::CONTENT_TYPE,
7377 tonic::metadata::GRPC_CONTENT_TYPE,
7378 );
7379 Ok(response)
7380 })
7381 }
7382 }
7383 }
7384 }
7385 impl<T> Clone for ServingServiceServer<T> {
7386 fn clone(&self) -> Self {
7387 let inner = self.inner.clone();
7388 Self {
7389 inner,
7390 accept_compression_encodings: self.accept_compression_encodings,
7391 send_compression_encodings: self.send_compression_encodings,
7392 max_decoding_message_size: self.max_decoding_message_size,
7393 max_encoding_message_size: self.max_encoding_message_size,
7394 }
7395 }
7396 }
7397 pub const SERVICE_NAME: &str = "meta.ServingService";
7399 impl<T> tonic::server::NamedService for ServingServiceServer<T> {
7400 const NAME: &'static str = SERVICE_NAME;
7401 }
7402}
7403pub mod event_log_service_server {
7405 #![allow(
7406 unused_variables,
7407 dead_code,
7408 missing_docs,
7409 clippy::wildcard_imports,
7410 clippy::let_unit_value,
7411 )]
7412 use tonic::codegen::*;
7413 #[async_trait]
7415 pub trait EventLogService: std::marker::Send + std::marker::Sync + 'static {
7416 async fn list_event_log(
7417 &self,
7418 request: tonic::Request<super::ListEventLogRequest>,
7419 ) -> std::result::Result<
7420 tonic::Response<super::ListEventLogResponse>,
7421 tonic::Status,
7422 >;
7423 async fn add_event_log(
7424 &self,
7425 request: tonic::Request<super::AddEventLogRequest>,
7426 ) -> std::result::Result<
7427 tonic::Response<super::AddEventLogResponse>,
7428 tonic::Status,
7429 >;
7430 }
7431 #[derive(Debug)]
7432 pub struct EventLogServiceServer<T> {
7433 inner: Arc<T>,
7434 accept_compression_encodings: EnabledCompressionEncodings,
7435 send_compression_encodings: EnabledCompressionEncodings,
7436 max_decoding_message_size: Option<usize>,
7437 max_encoding_message_size: Option<usize>,
7438 }
7439 impl<T> EventLogServiceServer<T> {
7440 pub fn new(inner: T) -> Self {
7441 Self::from_arc(Arc::new(inner))
7442 }
7443 pub fn from_arc(inner: Arc<T>) -> Self {
7444 Self {
7445 inner,
7446 accept_compression_encodings: Default::default(),
7447 send_compression_encodings: Default::default(),
7448 max_decoding_message_size: None,
7449 max_encoding_message_size: None,
7450 }
7451 }
7452 pub fn with_interceptor<F>(
7453 inner: T,
7454 interceptor: F,
7455 ) -> InterceptedService<Self, F>
7456 where
7457 F: tonic::service::Interceptor,
7458 {
7459 InterceptedService::new(Self::new(inner), interceptor)
7460 }
7461 #[must_use]
7463 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
7464 self.accept_compression_encodings.enable(encoding);
7465 self
7466 }
7467 #[must_use]
7469 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
7470 self.send_compression_encodings.enable(encoding);
7471 self
7472 }
7473 #[must_use]
7477 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
7478 self.max_decoding_message_size = Some(limit);
7479 self
7480 }
7481 #[must_use]
7485 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
7486 self.max_encoding_message_size = Some(limit);
7487 self
7488 }
7489 }
7490 impl<T, B> tonic::codegen::Service<http::Request<B>> for EventLogServiceServer<T>
7491 where
7492 T: EventLogService,
7493 B: Body + std::marker::Send + 'static,
7494 B::Error: Into<StdError> + std::marker::Send + 'static,
7495 {
7496 type Response = http::Response<tonic::body::BoxBody>;
7497 type Error = std::convert::Infallible;
7498 type Future = BoxFuture<Self::Response, Self::Error>;
7499 fn poll_ready(
7500 &mut self,
7501 _cx: &mut Context<'_>,
7502 ) -> Poll<std::result::Result<(), Self::Error>> {
7503 Poll::Ready(Ok(()))
7504 }
7505 fn call(&mut self, req: http::Request<B>) -> Self::Future {
7506 match req.uri().path() {
7507 "/meta.EventLogService/ListEventLog" => {
7508 #[allow(non_camel_case_types)]
7509 struct ListEventLogSvc<T: EventLogService>(pub Arc<T>);
7510 impl<
7511 T: EventLogService,
7512 > tonic::server::UnaryService<super::ListEventLogRequest>
7513 for ListEventLogSvc<T> {
7514 type Response = super::ListEventLogResponse;
7515 type Future = BoxFuture<
7516 tonic::Response<Self::Response>,
7517 tonic::Status,
7518 >;
7519 fn call(
7520 &mut self,
7521 request: tonic::Request<super::ListEventLogRequest>,
7522 ) -> Self::Future {
7523 let inner = Arc::clone(&self.0);
7524 let fut = async move {
7525 <T as EventLogService>::list_event_log(&inner, request)
7526 .await
7527 };
7528 Box::pin(fut)
7529 }
7530 }
7531 let accept_compression_encodings = self.accept_compression_encodings;
7532 let send_compression_encodings = self.send_compression_encodings;
7533 let max_decoding_message_size = self.max_decoding_message_size;
7534 let max_encoding_message_size = self.max_encoding_message_size;
7535 let inner = self.inner.clone();
7536 let fut = async move {
7537 let method = ListEventLogSvc(inner);
7538 let codec = tonic::codec::ProstCodec::default();
7539 let mut grpc = tonic::server::Grpc::new(codec)
7540 .apply_compression_config(
7541 accept_compression_encodings,
7542 send_compression_encodings,
7543 )
7544 .apply_max_message_size_config(
7545 max_decoding_message_size,
7546 max_encoding_message_size,
7547 );
7548 let res = grpc.unary(method, req).await;
7549 Ok(res)
7550 };
7551 Box::pin(fut)
7552 }
7553 "/meta.EventLogService/AddEventLog" => {
7554 #[allow(non_camel_case_types)]
7555 struct AddEventLogSvc<T: EventLogService>(pub Arc<T>);
7556 impl<
7557 T: EventLogService,
7558 > tonic::server::UnaryService<super::AddEventLogRequest>
7559 for AddEventLogSvc<T> {
7560 type Response = super::AddEventLogResponse;
7561 type Future = BoxFuture<
7562 tonic::Response<Self::Response>,
7563 tonic::Status,
7564 >;
7565 fn call(
7566 &mut self,
7567 request: tonic::Request<super::AddEventLogRequest>,
7568 ) -> Self::Future {
7569 let inner = Arc::clone(&self.0);
7570 let fut = async move {
7571 <T as EventLogService>::add_event_log(&inner, request).await
7572 };
7573 Box::pin(fut)
7574 }
7575 }
7576 let accept_compression_encodings = self.accept_compression_encodings;
7577 let send_compression_encodings = self.send_compression_encodings;
7578 let max_decoding_message_size = self.max_decoding_message_size;
7579 let max_encoding_message_size = self.max_encoding_message_size;
7580 let inner = self.inner.clone();
7581 let fut = async move {
7582 let method = AddEventLogSvc(inner);
7583 let codec = tonic::codec::ProstCodec::default();
7584 let mut grpc = tonic::server::Grpc::new(codec)
7585 .apply_compression_config(
7586 accept_compression_encodings,
7587 send_compression_encodings,
7588 )
7589 .apply_max_message_size_config(
7590 max_decoding_message_size,
7591 max_encoding_message_size,
7592 );
7593 let res = grpc.unary(method, req).await;
7594 Ok(res)
7595 };
7596 Box::pin(fut)
7597 }
7598 _ => {
7599 Box::pin(async move {
7600 let mut response = http::Response::new(empty_body());
7601 let headers = response.headers_mut();
7602 headers
7603 .insert(
7604 tonic::Status::GRPC_STATUS,
7605 (tonic::Code::Unimplemented as i32).into(),
7606 );
7607 headers
7608 .insert(
7609 http::header::CONTENT_TYPE,
7610 tonic::metadata::GRPC_CONTENT_TYPE,
7611 );
7612 Ok(response)
7613 })
7614 }
7615 }
7616 }
7617 }
7618 impl<T> Clone for EventLogServiceServer<T> {
7619 fn clone(&self) -> Self {
7620 let inner = self.inner.clone();
7621 Self {
7622 inner,
7623 accept_compression_encodings: self.accept_compression_encodings,
7624 send_compression_encodings: self.send_compression_encodings,
7625 max_decoding_message_size: self.max_decoding_message_size,
7626 max_encoding_message_size: self.max_encoding_message_size,
7627 }
7628 }
7629 }
7630 pub const SERVICE_NAME: &str = "meta.EventLogService";
7632 impl<T> tonic::server::NamedService for EventLogServiceServer<T> {
7633 const NAME: &'static str = SERVICE_NAME;
7634 }
7635}
7636pub mod cluster_limit_service_server {
7638 #![allow(
7639 unused_variables,
7640 dead_code,
7641 missing_docs,
7642 clippy::wildcard_imports,
7643 clippy::let_unit_value,
7644 )]
7645 use tonic::codegen::*;
7646 #[async_trait]
7648 pub trait ClusterLimitService: std::marker::Send + std::marker::Sync + 'static {
7649 async fn get_cluster_limits(
7650 &self,
7651 request: tonic::Request<super::GetClusterLimitsRequest>,
7652 ) -> std::result::Result<
7653 tonic::Response<super::GetClusterLimitsResponse>,
7654 tonic::Status,
7655 >;
7656 }
7657 #[derive(Debug)]
7658 pub struct ClusterLimitServiceServer<T> {
7659 inner: Arc<T>,
7660 accept_compression_encodings: EnabledCompressionEncodings,
7661 send_compression_encodings: EnabledCompressionEncodings,
7662 max_decoding_message_size: Option<usize>,
7663 max_encoding_message_size: Option<usize>,
7664 }
7665 impl<T> ClusterLimitServiceServer<T> {
7666 pub fn new(inner: T) -> Self {
7667 Self::from_arc(Arc::new(inner))
7668 }
7669 pub fn from_arc(inner: Arc<T>) -> Self {
7670 Self {
7671 inner,
7672 accept_compression_encodings: Default::default(),
7673 send_compression_encodings: Default::default(),
7674 max_decoding_message_size: None,
7675 max_encoding_message_size: None,
7676 }
7677 }
7678 pub fn with_interceptor<F>(
7679 inner: T,
7680 interceptor: F,
7681 ) -> InterceptedService<Self, F>
7682 where
7683 F: tonic::service::Interceptor,
7684 {
7685 InterceptedService::new(Self::new(inner), interceptor)
7686 }
7687 #[must_use]
7689 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
7690 self.accept_compression_encodings.enable(encoding);
7691 self
7692 }
7693 #[must_use]
7695 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
7696 self.send_compression_encodings.enable(encoding);
7697 self
7698 }
7699 #[must_use]
7703 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
7704 self.max_decoding_message_size = Some(limit);
7705 self
7706 }
7707 #[must_use]
7711 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
7712 self.max_encoding_message_size = Some(limit);
7713 self
7714 }
7715 }
7716 impl<T, B> tonic::codegen::Service<http::Request<B>> for ClusterLimitServiceServer<T>
7717 where
7718 T: ClusterLimitService,
7719 B: Body + std::marker::Send + 'static,
7720 B::Error: Into<StdError> + std::marker::Send + 'static,
7721 {
7722 type Response = http::Response<tonic::body::BoxBody>;
7723 type Error = std::convert::Infallible;
7724 type Future = BoxFuture<Self::Response, Self::Error>;
7725 fn poll_ready(
7726 &mut self,
7727 _cx: &mut Context<'_>,
7728 ) -> Poll<std::result::Result<(), Self::Error>> {
7729 Poll::Ready(Ok(()))
7730 }
7731 fn call(&mut self, req: http::Request<B>) -> Self::Future {
7732 match req.uri().path() {
7733 "/meta.ClusterLimitService/GetClusterLimits" => {
7734 #[allow(non_camel_case_types)]
7735 struct GetClusterLimitsSvc<T: ClusterLimitService>(pub Arc<T>);
7736 impl<
7737 T: ClusterLimitService,
7738 > tonic::server::UnaryService<super::GetClusterLimitsRequest>
7739 for GetClusterLimitsSvc<T> {
7740 type Response = super::GetClusterLimitsResponse;
7741 type Future = BoxFuture<
7742 tonic::Response<Self::Response>,
7743 tonic::Status,
7744 >;
7745 fn call(
7746 &mut self,
7747 request: tonic::Request<super::GetClusterLimitsRequest>,
7748 ) -> Self::Future {
7749 let inner = Arc::clone(&self.0);
7750 let fut = async move {
7751 <T as ClusterLimitService>::get_cluster_limits(
7752 &inner,
7753 request,
7754 )
7755 .await
7756 };
7757 Box::pin(fut)
7758 }
7759 }
7760 let accept_compression_encodings = self.accept_compression_encodings;
7761 let send_compression_encodings = self.send_compression_encodings;
7762 let max_decoding_message_size = self.max_decoding_message_size;
7763 let max_encoding_message_size = self.max_encoding_message_size;
7764 let inner = self.inner.clone();
7765 let fut = async move {
7766 let method = GetClusterLimitsSvc(inner);
7767 let codec = tonic::codec::ProstCodec::default();
7768 let mut grpc = tonic::server::Grpc::new(codec)
7769 .apply_compression_config(
7770 accept_compression_encodings,
7771 send_compression_encodings,
7772 )
7773 .apply_max_message_size_config(
7774 max_decoding_message_size,
7775 max_encoding_message_size,
7776 );
7777 let res = grpc.unary(method, req).await;
7778 Ok(res)
7779 };
7780 Box::pin(fut)
7781 }
7782 _ => {
7783 Box::pin(async move {
7784 let mut response = http::Response::new(empty_body());
7785 let headers = response.headers_mut();
7786 headers
7787 .insert(
7788 tonic::Status::GRPC_STATUS,
7789 (tonic::Code::Unimplemented as i32).into(),
7790 );
7791 headers
7792 .insert(
7793 http::header::CONTENT_TYPE,
7794 tonic::metadata::GRPC_CONTENT_TYPE,
7795 );
7796 Ok(response)
7797 })
7798 }
7799 }
7800 }
7801 }
7802 impl<T> Clone for ClusterLimitServiceServer<T> {
7803 fn clone(&self) -> Self {
7804 let inner = self.inner.clone();
7805 Self {
7806 inner,
7807 accept_compression_encodings: self.accept_compression_encodings,
7808 send_compression_encodings: self.send_compression_encodings,
7809 max_decoding_message_size: self.max_decoding_message_size,
7810 max_encoding_message_size: self.max_encoding_message_size,
7811 }
7812 }
7813 }
7814 pub const SERVICE_NAME: &str = "meta.ClusterLimitService";
7816 impl<T> tonic::server::NamedService for ClusterLimitServiceServer<T> {
7817 const NAME: &'static str = SERVICE_NAME;
7818 }
7819}
7820pub mod hosted_iceberg_catalog_service_server {
7822 #![allow(
7823 unused_variables,
7824 dead_code,
7825 missing_docs,
7826 clippy::wildcard_imports,
7827 clippy::let_unit_value,
7828 )]
7829 use tonic::codegen::*;
7830 #[async_trait]
7832 pub trait HostedIcebergCatalogService: std::marker::Send + std::marker::Sync + 'static {
7833 async fn list_iceberg_tables(
7834 &self,
7835 request: tonic::Request<super::ListIcebergTablesRequest>,
7836 ) -> std::result::Result<
7837 tonic::Response<super::ListIcebergTablesResponse>,
7838 tonic::Status,
7839 >;
7840 }
7841 #[derive(Debug)]
7842 pub struct HostedIcebergCatalogServiceServer<T> {
7843 inner: Arc<T>,
7844 accept_compression_encodings: EnabledCompressionEncodings,
7845 send_compression_encodings: EnabledCompressionEncodings,
7846 max_decoding_message_size: Option<usize>,
7847 max_encoding_message_size: Option<usize>,
7848 }
7849 impl<T> HostedIcebergCatalogServiceServer<T> {
7850 pub fn new(inner: T) -> Self {
7851 Self::from_arc(Arc::new(inner))
7852 }
7853 pub fn from_arc(inner: Arc<T>) -> Self {
7854 Self {
7855 inner,
7856 accept_compression_encodings: Default::default(),
7857 send_compression_encodings: Default::default(),
7858 max_decoding_message_size: None,
7859 max_encoding_message_size: None,
7860 }
7861 }
7862 pub fn with_interceptor<F>(
7863 inner: T,
7864 interceptor: F,
7865 ) -> InterceptedService<Self, F>
7866 where
7867 F: tonic::service::Interceptor,
7868 {
7869 InterceptedService::new(Self::new(inner), interceptor)
7870 }
7871 #[must_use]
7873 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
7874 self.accept_compression_encodings.enable(encoding);
7875 self
7876 }
7877 #[must_use]
7879 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
7880 self.send_compression_encodings.enable(encoding);
7881 self
7882 }
7883 #[must_use]
7887 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
7888 self.max_decoding_message_size = Some(limit);
7889 self
7890 }
7891 #[must_use]
7895 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
7896 self.max_encoding_message_size = Some(limit);
7897 self
7898 }
7899 }
7900 impl<T, B> tonic::codegen::Service<http::Request<B>>
7901 for HostedIcebergCatalogServiceServer<T>
7902 where
7903 T: HostedIcebergCatalogService,
7904 B: Body + std::marker::Send + 'static,
7905 B::Error: Into<StdError> + std::marker::Send + 'static,
7906 {
7907 type Response = http::Response<tonic::body::BoxBody>;
7908 type Error = std::convert::Infallible;
7909 type Future = BoxFuture<Self::Response, Self::Error>;
7910 fn poll_ready(
7911 &mut self,
7912 _cx: &mut Context<'_>,
7913 ) -> Poll<std::result::Result<(), Self::Error>> {
7914 Poll::Ready(Ok(()))
7915 }
7916 fn call(&mut self, req: http::Request<B>) -> Self::Future {
7917 match req.uri().path() {
7918 "/meta.HostedIcebergCatalogService/ListIcebergTables" => {
7919 #[allow(non_camel_case_types)]
7920 struct ListIcebergTablesSvc<T: HostedIcebergCatalogService>(
7921 pub Arc<T>,
7922 );
7923 impl<
7924 T: HostedIcebergCatalogService,
7925 > tonic::server::UnaryService<super::ListIcebergTablesRequest>
7926 for ListIcebergTablesSvc<T> {
7927 type Response = super::ListIcebergTablesResponse;
7928 type Future = BoxFuture<
7929 tonic::Response<Self::Response>,
7930 tonic::Status,
7931 >;
7932 fn call(
7933 &mut self,
7934 request: tonic::Request<super::ListIcebergTablesRequest>,
7935 ) -> Self::Future {
7936 let inner = Arc::clone(&self.0);
7937 let fut = async move {
7938 <T as HostedIcebergCatalogService>::list_iceberg_tables(
7939 &inner,
7940 request,
7941 )
7942 .await
7943 };
7944 Box::pin(fut)
7945 }
7946 }
7947 let accept_compression_encodings = self.accept_compression_encodings;
7948 let send_compression_encodings = self.send_compression_encodings;
7949 let max_decoding_message_size = self.max_decoding_message_size;
7950 let max_encoding_message_size = self.max_encoding_message_size;
7951 let inner = self.inner.clone();
7952 let fut = async move {
7953 let method = ListIcebergTablesSvc(inner);
7954 let codec = tonic::codec::ProstCodec::default();
7955 let mut grpc = tonic::server::Grpc::new(codec)
7956 .apply_compression_config(
7957 accept_compression_encodings,
7958 send_compression_encodings,
7959 )
7960 .apply_max_message_size_config(
7961 max_decoding_message_size,
7962 max_encoding_message_size,
7963 );
7964 let res = grpc.unary(method, req).await;
7965 Ok(res)
7966 };
7967 Box::pin(fut)
7968 }
7969 _ => {
7970 Box::pin(async move {
7971 let mut response = http::Response::new(empty_body());
7972 let headers = response.headers_mut();
7973 headers
7974 .insert(
7975 tonic::Status::GRPC_STATUS,
7976 (tonic::Code::Unimplemented as i32).into(),
7977 );
7978 headers
7979 .insert(
7980 http::header::CONTENT_TYPE,
7981 tonic::metadata::GRPC_CONTENT_TYPE,
7982 );
7983 Ok(response)
7984 })
7985 }
7986 }
7987 }
7988 }
7989 impl<T> Clone for HostedIcebergCatalogServiceServer<T> {
7990 fn clone(&self) -> Self {
7991 let inner = self.inner.clone();
7992 Self {
7993 inner,
7994 accept_compression_encodings: self.accept_compression_encodings,
7995 send_compression_encodings: self.send_compression_encodings,
7996 max_decoding_message_size: self.max_decoding_message_size,
7997 max_encoding_message_size: self.max_encoding_message_size,
7998 }
7999 }
8000 }
8001 pub const SERVICE_NAME: &str = "meta.HostedIcebergCatalogService";
8003 impl<T> tonic::server::NamedService for HostedIcebergCatalogServiceServer<T> {
8004 const NAME: &'static str = SERVICE_NAME;
8005 }
8006}