1#[derive(prost_helpers::AnyPB)]
3#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
4pub struct GetTelemetryInfoRequest {}
5#[derive(prost_helpers::AnyPB)]
6#[derive(Clone, PartialEq, Eq, Hash, ::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, Eq, Hash, ::prost::Message)]
13pub struct HeartbeatRequest {
14 #[prost(uint32, tag = "1", wrapper = "crate::id::WorkerId")]
15 pub node_id: crate::id::WorkerId,
16}
17#[derive(prost_helpers::AnyPB)]
18#[derive(Clone, PartialEq, Eq, Hash, ::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", wrapper = "crate::id::JobId")]
31 pub table_id: crate::id::JobId,
32 #[prost(enumeration = "table_fragments::State", tag = "2")]
33 pub state: i32,
34 #[prost(map = "uint32, message", tag = "3", wrapper = "crate::id::FragmentId")]
35 pub fragments: ::std::collections::HashMap<
36 crate::id::FragmentId,
37 table_fragments::Fragment,
38 >,
39 #[prost(map = "uint32, message", tag = "4", wrapper = "crate::id::ActorId")]
40 pub actor_status: ::std::collections::HashMap<
41 crate::id::ActorId,
42 table_fragments::ActorStatus,
43 >,
44 #[prost(message, optional, tag = "6")]
45 pub ctx: ::core::option::Option<super::stream_plan::StreamContext>,
46 #[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, Eq, Hash, ::prost::Message)]
73 pub struct ActorStatus {
74 #[prost(message, optional, tag = "1")]
76 pub location: ::core::option::Option<super::super::common::ActorLocation>,
77 }
78 #[derive(prost_helpers::AnyPB)]
79 #[derive(Clone, PartialEq, ::prost::Message)]
80 pub struct Fragment {
81 #[prost(uint32, tag = "1", wrapper = "crate::id::FragmentId")]
82 pub fragment_id: crate::id::FragmentId,
83 #[prost(uint32, tag = "2")]
85 pub fragment_type_mask: u32,
86 #[prost(enumeration = "fragment::FragmentDistributionType", tag = "3")]
87 pub distribution_type: i32,
88 #[prost(message, repeated, tag = "4")]
89 pub actors: ::prost::alloc::vec::Vec<super::super::stream_plan::StreamActor>,
90 #[prost(uint32, repeated, tag = "6", wrapper = "crate::id::TableId")]
91 pub state_table_ids: ::prost::alloc::vec::Vec<crate::id::TableId>,
92 #[prost(uint32, repeated, tag = "7", wrapper = "crate::id::FragmentId")]
97 pub upstream_fragment_ids: ::prost::alloc::vec::Vec<crate::id::FragmentId>,
98 #[prost(uint32, optional, tag = "8")]
105 pub maybe_vnode_count: ::core::option::Option<u32>,
106 #[prost(message, optional, tag = "9")]
107 pub nodes: ::core::option::Option<super::super::stream_plan::StreamNode>,
108 }
109 pub mod fragment {
111 #[derive(prost_helpers::AnyPB)]
112 #[derive(
113 Clone,
114 Copy,
115 Debug,
116 PartialEq,
117 Eq,
118 Hash,
119 PartialOrd,
120 Ord,
121 ::prost::Enumeration
122 )]
123 #[repr(i32)]
124 pub enum FragmentDistributionType {
125 Unspecified = 0,
126 Single = 1,
127 Hash = 2,
128 }
129 impl FragmentDistributionType {
130 pub fn as_str_name(&self) -> &'static str {
135 match self {
136 Self::Unspecified => "UNSPECIFIED",
137 Self::Single => "SINGLE",
138 Self::Hash => "HASH",
139 }
140 }
141 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
143 match value {
144 "UNSPECIFIED" => Some(Self::Unspecified),
145 "SINGLE" => Some(Self::Single),
146 "HASH" => Some(Self::Hash),
147 _ => None,
148 }
149 }
150 }
151 }
152 #[derive(prost_helpers::AnyPB)]
154 #[derive(
155 Clone,
156 Copy,
157 Debug,
158 PartialEq,
159 Eq,
160 Hash,
161 PartialOrd,
162 Ord,
163 ::prost::Enumeration
164 )]
165 #[repr(i32)]
166 pub enum State {
167 Unspecified = 0,
168 Initial = 1,
170 Creating = 2,
172 Created = 3,
174 }
175 impl State {
176 pub fn as_str_name(&self) -> &'static str {
181 match self {
182 Self::Unspecified => "UNSPECIFIED",
183 Self::Initial => "INITIAL",
184 Self::Creating => "CREATING",
185 Self::Created => "CREATED",
186 }
187 }
188 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
190 match value {
191 "UNSPECIFIED" => Some(Self::Unspecified),
192 "INITIAL" => Some(Self::Initial),
193 "CREATING" => Some(Self::Creating),
194 "CREATED" => Some(Self::Created),
195 _ => None,
196 }
197 }
198 }
199}
200#[derive(prost_helpers::AnyPB)]
202#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
203pub struct FragmentWorkerSlotMapping {
204 #[prost(uint32, tag = "1", wrapper = "crate::id::FragmentId")]
205 pub fragment_id: crate::id::FragmentId,
206 #[prost(message, optional, tag = "2")]
207 pub mapping: ::core::option::Option<super::common::WorkerSlotMapping>,
208}
209#[derive(prost_helpers::AnyPB)]
210#[derive(Clone, PartialEq, ::prost::Message)]
211pub struct FragmentWorkerSlotMappings {
212 #[prost(message, repeated, tag = "1")]
213 pub mappings: ::prost::alloc::vec::Vec<FragmentWorkerSlotMapping>,
214}
215#[derive(prost_helpers::AnyPB)]
217#[derive(Clone, PartialEq, ::prost::Message)]
218pub struct ActorLocation {
219 #[prost(message, optional, tag = "1")]
220 pub node: ::core::option::Option<super::common::WorkerNode>,
221 #[prost(message, repeated, tag = "2")]
222 pub actors: ::prost::alloc::vec::Vec<super::stream_plan::StreamActor>,
223}
224#[derive(prost_helpers::AnyPB)]
225#[derive(Clone, PartialEq, ::prost::Message)]
226pub struct MigrationPlan {
227 #[prost(map = "uint64, uint64", tag = "2")]
229 pub worker_slot_migration_plan: ::std::collections::HashMap<u64, u64>,
230}
231#[derive(prost_helpers::AnyPB)]
232#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
233pub struct FlushRequest {
234 #[prost(uint32, tag = "1", wrapper = "crate::id::DatabaseId")]
235 pub database_id: crate::id::DatabaseId,
236}
237#[derive(prost_helpers::AnyPB)]
238#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
239pub struct FlushResponse {
240 #[prost(message, optional, tag = "1")]
241 pub status: ::core::option::Option<super::common::Status>,
242 #[prost(uint64, tag = "2", wrapper = "crate::id::HummockVersionId")]
243 pub hummock_version_id: crate::id::HummockVersionId,
244}
245#[derive(prost_helpers::AnyPB)]
246#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
247pub struct PauseRequest {}
248#[derive(prost_helpers::AnyPB)]
249#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
250pub struct PauseResponse {}
251#[derive(prost_helpers::AnyPB)]
252#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
253pub struct ResumeRequest {}
254#[derive(prost_helpers::AnyPB)]
255#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
256pub struct ResumeResponse {}
257#[derive(prost_helpers::AnyPB)]
258#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
259pub struct RefreshRequest {
260 #[prost(uint32, tag = "1", wrapper = "crate::id::TableId")]
261 pub table_id: crate::id::TableId,
262 #[prost(uint32, tag = "2", wrapper = "crate::id::SourceId")]
263 pub associated_source_id: crate::id::SourceId,
264}
265#[derive(prost_helpers::AnyPB)]
266#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
267pub struct RefreshResponse {
268 #[prost(message, optional, tag = "1")]
269 pub status: ::core::option::Option<super::common::Status>,
270}
271#[derive(prost_helpers::AnyPB)]
272#[derive(Clone, PartialEq, ::prost::Message)]
273pub struct CancelCreatingJobsRequest {
274 #[prost(oneof = "cancel_creating_jobs_request::Jobs", tags = "1, 2")]
275 pub jobs: ::core::option::Option<cancel_creating_jobs_request::Jobs>,
276}
277pub mod cancel_creating_jobs_request {
279 #[derive(prost_helpers::AnyPB)]
280 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
281 pub struct CreatingJobInfo {
282 #[prost(uint32, tag = "1", wrapper = "crate::id::DatabaseId")]
283 pub database_id: crate::id::DatabaseId,
284 #[prost(uint32, tag = "2", wrapper = "crate::id::SchemaId")]
285 pub schema_id: crate::id::SchemaId,
286 #[prost(string, tag = "3")]
287 pub name: ::prost::alloc::string::String,
288 }
289 #[derive(prost_helpers::AnyPB)]
290 #[derive(Clone, PartialEq, ::prost::Message)]
291 pub struct CreatingJobInfos {
292 #[prost(message, repeated, tag = "1")]
293 pub infos: ::prost::alloc::vec::Vec<CreatingJobInfo>,
294 }
295 #[derive(prost_helpers::AnyPB)]
296 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
297 pub struct CreatingJobIds {
298 #[prost(uint32, repeated, tag = "1", wrapper = "crate::id::JobId")]
299 pub job_ids: ::prost::alloc::vec::Vec<crate::id::JobId>,
300 }
301 #[derive(prost_helpers::AnyPB)]
302 #[derive(Clone, PartialEq, ::prost::Oneof)]
303 pub enum Jobs {
304 #[prost(message, tag = "1")]
305 Infos(CreatingJobInfos),
306 #[prost(message, tag = "2")]
307 Ids(CreatingJobIds),
308 }
309}
310#[derive(prost_helpers::AnyPB)]
311#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
312pub struct CancelCreatingJobsResponse {
313 #[prost(message, optional, tag = "1")]
314 pub status: ::core::option::Option<super::common::Status>,
315 #[prost(uint32, repeated, tag = "2")]
316 pub canceled_jobs: ::prost::alloc::vec::Vec<u32>,
317}
318#[derive(prost_helpers::AnyPB)]
319#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
320pub struct ListTableFragmentsRequest {
321 #[prost(uint32, repeated, tag = "1", wrapper = "crate::id::JobId")]
322 pub table_ids: ::prost::alloc::vec::Vec<crate::id::JobId>,
323}
324#[derive(prost_helpers::AnyPB)]
325#[derive(Clone, PartialEq, ::prost::Message)]
326pub struct ListTableFragmentsResponse {
327 #[prost(map = "uint32, message", tag = "1", wrapper = "crate::id::JobId")]
328 pub table_fragments: ::std::collections::HashMap<
329 crate::id::JobId,
330 list_table_fragments_response::TableFragmentInfo,
331 >,
332}
333pub mod list_table_fragments_response {
335 #[derive(prost_helpers::AnyPB)]
336 #[derive(Clone, PartialEq, ::prost::Message)]
337 pub struct ActorInfo {
338 #[prost(uint32, tag = "1", wrapper = "crate::id::ActorId")]
339 pub id: crate::id::ActorId,
340 #[prost(message, optional, tag = "2")]
341 pub node: ::core::option::Option<super::super::stream_plan::StreamNode>,
342 #[prost(message, repeated, tag = "3")]
343 pub dispatcher: ::prost::alloc::vec::Vec<super::super::stream_plan::Dispatcher>,
344 }
345 #[derive(prost_helpers::AnyPB)]
346 #[derive(Clone, PartialEq, ::prost::Message)]
347 pub struct FragmentInfo {
348 #[prost(uint32, tag = "1", wrapper = "crate::id::FragmentId")]
349 pub id: crate::id::FragmentId,
350 #[prost(message, repeated, tag = "4")]
351 pub actors: ::prost::alloc::vec::Vec<ActorInfo>,
352 }
353 #[derive(prost_helpers::AnyPB)]
354 #[derive(Clone, PartialEq, ::prost::Message)]
355 pub struct TableFragmentInfo {
356 #[prost(message, repeated, tag = "1")]
357 pub fragments: ::prost::alloc::vec::Vec<FragmentInfo>,
358 #[prost(message, optional, tag = "2")]
359 pub ctx: ::core::option::Option<super::super::stream_plan::StreamContext>,
360 }
361}
362#[derive(prost_helpers::AnyPB)]
363#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
364pub struct GetFragmentByIdRequest {
365 #[prost(uint32, tag = "1", wrapper = "crate::id::FragmentId")]
366 pub fragment_id: crate::id::FragmentId,
367}
368#[derive(prost_helpers::AnyPB)]
369#[derive(Clone, PartialEq, ::prost::Message)]
370pub struct GetFragmentByIdResponse {
371 #[prost(message, optional, tag = "1")]
372 pub distribution: ::core::option::Option<FragmentDistribution>,
373}
374#[derive(prost_helpers::AnyPB)]
375#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
376pub struct GetFragmentVnodesRequest {
377 #[prost(uint32, tag = "1", wrapper = "crate::id::FragmentId")]
378 pub fragment_id: crate::id::FragmentId,
379}
380#[derive(prost_helpers::AnyPB)]
381#[derive(Clone, PartialEq, ::prost::Message)]
382pub struct GetFragmentVnodesResponse {
383 #[prost(message, repeated, tag = "1")]
384 pub actor_vnodes: ::prost::alloc::vec::Vec<
385 get_fragment_vnodes_response::ActorVnodes,
386 >,
387}
388pub mod get_fragment_vnodes_response {
390 #[derive(prost_helpers::AnyPB)]
391 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
392 pub struct ActorVnodes {
393 #[prost(uint32, tag = "1", wrapper = "crate::id::ActorId")]
394 pub actor_id: crate::id::ActorId,
395 #[prost(uint32, repeated, tag = "2")]
396 pub vnode_indices: ::prost::alloc::vec::Vec<u32>,
397 }
398}
399#[derive(prost_helpers::AnyPB)]
400#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
401pub struct GetActorVnodesRequest {
402 #[prost(uint32, tag = "1", wrapper = "crate::id::ActorId")]
403 pub actor_id: crate::id::ActorId,
404}
405#[derive(prost_helpers::AnyPB)]
406#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
407pub struct GetActorVnodesResponse {
408 #[prost(uint32, repeated, tag = "1")]
409 pub vnode_indices: ::prost::alloc::vec::Vec<u32>,
410}
411#[derive(prost_helpers::AnyPB)]
412#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
413pub struct ListStreamingJobStatesRequest {}
414#[derive(prost_helpers::AnyPB)]
415#[derive(Clone, PartialEq, ::prost::Message)]
416pub struct ListStreamingJobStatesResponse {
417 #[prost(message, repeated, tag = "1")]
418 pub states: ::prost::alloc::vec::Vec<
419 list_streaming_job_states_response::StreamingJobState,
420 >,
421}
422pub mod list_streaming_job_states_response {
424 #[derive(prost_helpers::AnyPB)]
425 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
426 pub struct StreamingJobState {
427 #[prost(uint32, tag = "1", wrapper = "crate::id::JobId")]
428 pub table_id: crate::id::JobId,
429 #[prost(enumeration = "super::table_fragments::State", tag = "2")]
430 pub state: i32,
431 #[prost(message, optional, tag = "3")]
432 pub parallelism: ::core::option::Option<super::TableParallelism>,
433 #[prost(uint32, tag = "4")]
434 pub max_parallelism: u32,
435 #[prost(string, tag = "5")]
436 pub name: ::prost::alloc::string::String,
437 #[prost(string, tag = "6")]
438 pub resource_group: ::prost::alloc::string::String,
439 #[prost(string, tag = "9")]
440 pub config_override: ::prost::alloc::string::String,
441 #[prost(uint32, tag = "7", wrapper = "crate::id::DatabaseId")]
442 pub database_id: crate::id::DatabaseId,
443 #[prost(uint32, tag = "8", wrapper = "crate::id::SchemaId")]
444 pub schema_id: crate::id::SchemaId,
445 #[prost(string, optional, tag = "10")]
446 pub adaptive_parallelism_strategy: ::core::option::Option<
447 ::prost::alloc::string::String,
448 >,
449 }
450}
451#[derive(prost_helpers::AnyPB)]
452#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
453pub struct ListFragmentDistributionRequest {
454 #[prost(bool, optional, tag = "1")]
455 pub include_node: ::core::option::Option<bool>,
456}
457#[derive(prost_helpers::AnyPB)]
458#[derive(Clone, PartialEq, ::prost::Message)]
459pub struct FragmentDistribution {
460 #[prost(uint32, tag = "1", wrapper = "crate::id::FragmentId")]
461 pub fragment_id: crate::id::FragmentId,
462 #[prost(uint32, tag = "2", wrapper = "crate::id::JobId")]
463 pub table_id: crate::id::JobId,
464 #[prost(
465 enumeration = "table_fragments::fragment::FragmentDistributionType",
466 tag = "3"
467 )]
468 pub distribution_type: i32,
469 #[prost(uint32, repeated, tag = "4", wrapper = "crate::id::TableId")]
470 pub state_table_ids: ::prost::alloc::vec::Vec<crate::id::TableId>,
471 #[prost(uint32, repeated, tag = "5", wrapper = "crate::id::FragmentId")]
472 pub upstream_fragment_ids: ::prost::alloc::vec::Vec<crate::id::FragmentId>,
473 #[prost(uint32, tag = "6")]
474 pub fragment_type_mask: u32,
475 #[prost(uint32, tag = "7")]
476 pub parallelism: u32,
477 #[prost(uint32, tag = "8")]
478 pub vnode_count: u32,
479 #[prost(message, optional, tag = "9")]
480 pub node: ::core::option::Option<super::stream_plan::StreamNode>,
481 #[prost(string, tag = "10")]
482 pub parallelism_policy: ::prost::alloc::string::String,
483}
484#[derive(prost_helpers::AnyPB)]
485#[derive(Clone, PartialEq, ::prost::Message)]
486pub struct ListFragmentDistributionResponse {
487 #[prost(message, repeated, tag = "1")]
488 pub distributions: ::prost::alloc::vec::Vec<FragmentDistribution>,
489}
490#[derive(prost_helpers::AnyPB)]
493#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
494pub struct ListCreatingFragmentDistributionRequest {
495 #[prost(bool, optional, tag = "1")]
496 pub include_node: ::core::option::Option<bool>,
497}
498#[derive(prost_helpers::AnyPB)]
501#[derive(Clone, PartialEq, ::prost::Message)]
502pub struct ListCreatingFragmentDistributionResponse {
503 #[prost(message, repeated, tag = "1")]
504 pub distributions: ::prost::alloc::vec::Vec<FragmentDistribution>,
505}
506#[derive(prost_helpers::AnyPB)]
507#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
508pub struct ListSinkLogStoreTablesRequest {}
509#[derive(prost_helpers::AnyPB)]
510#[derive(Clone, PartialEq, ::prost::Message)]
511pub struct ListSinkLogStoreTablesResponse {
512 #[prost(message, repeated, tag = "1")]
513 pub tables: ::prost::alloc::vec::Vec<
514 list_sink_log_store_tables_response::SinkLogStoreTable,
515 >,
516}
517pub mod list_sink_log_store_tables_response {
519 #[derive(prost_helpers::AnyPB)]
520 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
521 pub struct SinkLogStoreTable {
522 #[prost(uint32, tag = "1")]
523 pub sink_id: u32,
524 #[prost(uint32, tag = "2")]
525 pub internal_table_id: u32,
526 }
527}
528#[derive(prost_helpers::AnyPB)]
529#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
530pub struct ListActorStatesRequest {}
531#[derive(prost_helpers::AnyPB)]
532#[derive(Clone, PartialEq, ::prost::Message)]
533pub struct ListActorStatesResponse {
534 #[prost(message, repeated, tag = "1")]
535 pub states: ::prost::alloc::vec::Vec<list_actor_states_response::ActorState>,
536}
537pub mod list_actor_states_response {
539 #[derive(prost_helpers::AnyPB)]
540 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
541 pub struct ActorState {
542 #[prost(uint32, tag = "1", wrapper = "crate::id::ActorId")]
543 pub actor_id: crate::id::ActorId,
544 #[prost(uint32, tag = "2", wrapper = "crate::id::FragmentId")]
545 pub fragment_id: crate::id::FragmentId,
546 #[prost(uint32, tag = "5", wrapper = "crate::id::WorkerId")]
547 pub worker_id: crate::id::WorkerId,
548 }
549}
550#[derive(prost_helpers::AnyPB)]
551#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
552pub struct ListActorSplitsRequest {}
553#[derive(prost_helpers::AnyPB)]
554#[derive(Clone, PartialEq, ::prost::Message)]
555pub struct ListActorSplitsResponse {
556 #[prost(message, repeated, tag = "1")]
557 pub actor_splits: ::prost::alloc::vec::Vec<list_actor_splits_response::ActorSplit>,
558}
559pub mod list_actor_splits_response {
561 #[derive(prost_helpers::AnyPB)]
562 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
563 pub struct ActorSplit {
564 #[prost(uint32, tag = "1", wrapper = "crate::id::ActorId")]
565 pub actor_id: crate::id::ActorId,
566 #[prost(uint32, tag = "2", wrapper = "crate::id::FragmentId")]
567 pub fragment_id: crate::id::FragmentId,
568 #[prost(uint32, tag = "3", wrapper = "crate::id::SourceId")]
569 pub source_id: crate::id::SourceId,
570 #[prost(string, tag = "4")]
571 pub split_id: ::prost::alloc::string::String,
572 #[prost(enumeration = "FragmentType", tag = "5")]
573 pub fragment_type: i32,
574 }
575 #[derive(prost_helpers::AnyPB)]
576 #[derive(
577 Clone,
578 Copy,
579 Debug,
580 PartialEq,
581 Eq,
582 Hash,
583 PartialOrd,
584 Ord,
585 ::prost::Enumeration
586 )]
587 #[repr(i32)]
588 pub enum FragmentType {
589 Unspecified = 0,
590 NonSharedSource = 1,
591 SharedSource = 2,
592 SharedSourceBackfill = 3,
593 }
594 impl FragmentType {
595 pub fn as_str_name(&self) -> &'static str {
600 match self {
601 Self::Unspecified => "UNSPECIFIED",
602 Self::NonSharedSource => "NON_SHARED_SOURCE",
603 Self::SharedSource => "SHARED_SOURCE",
604 Self::SharedSourceBackfill => "SHARED_SOURCE_BACKFILL",
605 }
606 }
607 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
609 match value {
610 "UNSPECIFIED" => Some(Self::Unspecified),
611 "NON_SHARED_SOURCE" => Some(Self::NonSharedSource),
612 "SHARED_SOURCE" => Some(Self::SharedSource),
613 "SHARED_SOURCE_BACKFILL" => Some(Self::SharedSourceBackfill),
614 _ => None,
615 }
616 }
617 }
618}
619#[derive(prost_helpers::AnyPB)]
620#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
621pub struct ObjectDependency {
622 #[prost(uint32, tag = "1", wrapper = "crate::id::ObjectId")]
623 pub object_id: crate::id::ObjectId,
624 #[prost(uint32, tag = "2", wrapper = "crate::id::ObjectId")]
625 pub referenced_object_id: crate::id::ObjectId,
626 #[prost(enumeration = "super::common::ObjectType", tag = "3")]
627 pub referenced_object_type: i32,
628}
629#[derive(prost_helpers::AnyPB)]
630#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
631pub struct ApplyThrottleRequest {
632 #[prost(enumeration = "ThrottleTarget", tag = "1")]
633 pub throttle_target: i32,
634 #[prost(enumeration = "super::common::ThrottleType", tag = "2")]
635 pub throttle_type: i32,
636 #[prost(uint32, tag = "3")]
637 pub id: u32,
638 #[prost(uint32, optional, tag = "4")]
639 pub rate: ::core::option::Option<u32>,
640}
641#[derive(prost_helpers::AnyPB)]
642#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
643pub struct ApplyThrottleResponse {
644 #[prost(message, optional, tag = "1")]
645 pub status: ::core::option::Option<super::common::Status>,
646}
647#[derive(prost_helpers::AnyPB)]
648#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
649pub struct RecoverRequest {}
650#[derive(prost_helpers::AnyPB)]
651#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
652pub struct RecoverResponse {}
653#[derive(prost_helpers::AnyPB)]
654#[derive(Clone, PartialEq, ::prost::Message)]
655pub struct AlterConnectorPropsRequest {
656 #[prost(uint32, tag = "1")]
657 pub object_id: u32,
658 #[prost(map = "string, string", tag = "2")]
659 pub changed_props: ::std::collections::HashMap<
660 ::prost::alloc::string::String,
661 ::prost::alloc::string::String,
662 >,
663 #[prost(map = "string, message", tag = "3")]
664 pub changed_secret_refs: ::std::collections::HashMap<
665 ::prost::alloc::string::String,
666 super::secret::SecretRef,
667 >,
668 #[prost(uint32, optional, tag = "4", wrapper = "crate::id::ConnectionId")]
669 pub connector_conn_ref: ::core::option::Option<crate::id::ConnectionId>,
670 #[prost(
671 enumeration = "alter_connector_props_request::AlterConnectorPropsObject",
672 tag = "5"
673 )]
674 pub object_type: i32,
675 #[prost(oneof = "alter_connector_props_request::ExtraOptions", tags = "6")]
676 pub extra_options: ::core::option::Option<
677 alter_connector_props_request::ExtraOptions,
678 >,
679}
680pub mod alter_connector_props_request {
682 #[derive(prost_helpers::AnyPB)]
683 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
684 pub struct AlterIcebergTableIds {
685 #[prost(uint32, tag = "1", wrapper = "crate::id::SourceId")]
686 pub source_id: crate::id::SourceId,
687 #[prost(uint32, tag = "2", wrapper = "crate::id::SinkId")]
688 pub sink_id: crate::id::SinkId,
689 }
690 #[derive(prost_helpers::AnyPB)]
691 #[derive(
692 Clone,
693 Copy,
694 Debug,
695 PartialEq,
696 Eq,
697 Hash,
698 PartialOrd,
699 Ord,
700 ::prost::Enumeration
701 )]
702 #[repr(i32)]
703 pub enum AlterConnectorPropsObject {
704 Unspecified = 0,
705 Source = 1,
706 Sink = 2,
707 Connection = 3,
708 IcebergTable = 4,
709 }
710 impl AlterConnectorPropsObject {
711 pub fn as_str_name(&self) -> &'static str {
716 match self {
717 Self::Unspecified => "UNSPECIFIED",
718 Self::Source => "SOURCE",
719 Self::Sink => "SINK",
720 Self::Connection => "CONNECTION",
721 Self::IcebergTable => "ICEBERG_TABLE",
722 }
723 }
724 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
726 match value {
727 "UNSPECIFIED" => Some(Self::Unspecified),
728 "SOURCE" => Some(Self::Source),
729 "SINK" => Some(Self::Sink),
730 "CONNECTION" => Some(Self::Connection),
731 "ICEBERG_TABLE" => Some(Self::IcebergTable),
732 _ => None,
733 }
734 }
735 }
736 #[derive(prost_helpers::AnyPB)]
737 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Oneof)]
738 pub enum ExtraOptions {
739 #[prost(message, tag = "6")]
740 AlterIcebergTableIds(AlterIcebergTableIds),
741 }
742}
743#[derive(prost_helpers::AnyPB)]
744#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
745pub struct AlterConnectorPropsResponse {}
746#[derive(prost_helpers::AnyPB)]
748#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
749pub struct PropertyUpdateOptions {
750 #[prost(bool, tag = "1")]
753 pub reset_splits: bool,
754}
755#[derive(prost_helpers::AnyPB)]
757#[derive(Clone, PartialEq, ::prost::Message)]
758pub struct AlterSourcePropertiesSafeRequest {
759 #[prost(uint32, tag = "1")]
760 pub source_id: u32,
761 #[prost(map = "string, string", tag = "2")]
762 pub changed_props: ::std::collections::HashMap<
763 ::prost::alloc::string::String,
764 ::prost::alloc::string::String,
765 >,
766 #[prost(map = "string, message", tag = "3")]
767 pub changed_secret_refs: ::std::collections::HashMap<
768 ::prost::alloc::string::String,
769 super::secret::SecretRef,
770 >,
771 #[prost(message, optional, tag = "4")]
772 pub options: ::core::option::Option<PropertyUpdateOptions>,
773}
774#[derive(prost_helpers::AnyPB)]
775#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
776pub struct AlterSourcePropertiesSafeResponse {}
777#[derive(prost_helpers::AnyPB)]
779#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
780pub struct ResetSourceSplitsRequest {
781 #[prost(uint32, tag = "1")]
782 pub source_id: u32,
783}
784#[derive(prost_helpers::AnyPB)]
785#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
786pub struct ResetSourceSplitsResponse {}
787#[derive(prost_helpers::AnyPB)]
789#[derive(Clone, PartialEq, ::prost::Message)]
790pub struct InjectSourceOffsetsRequest {
791 #[prost(uint32, tag = "1")]
792 pub source_id: u32,
793 #[prost(map = "string, string", tag = "2")]
795 pub split_offsets: ::std::collections::HashMap<
796 ::prost::alloc::string::String,
797 ::prost::alloc::string::String,
798 >,
799}
800#[derive(prost_helpers::AnyPB)]
801#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
802pub struct InjectSourceOffsetsResponse {
803 #[prost(string, repeated, tag = "1")]
804 pub applied_split_ids: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
805}
806#[derive(prost_helpers::AnyPB)]
807#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
808pub struct ListCdcProgressRequest {}
809#[derive(prost_helpers::AnyPB)]
810#[derive(Clone, PartialEq, ::prost::Message)]
811pub struct ListCdcProgressResponse {
812 #[prost(map = "uint32, message", tag = "1", wrapper = "crate::id::JobId")]
813 pub cdc_progress: ::std::collections::HashMap<
814 crate::id::JobId,
815 list_cdc_progress_response::CdcProgress,
816 >,
817}
818pub mod list_cdc_progress_response {
820 #[derive(prost_helpers::AnyPB)]
821 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
822 pub struct CdcProgress {
823 #[prost(uint64, tag = "1")]
824 pub split_total_count: u64,
825 #[prost(uint64, tag = "2")]
826 pub split_backfilled_count: u64,
827 #[prost(uint64, tag = "3")]
828 pub split_completed_count: u64,
829 }
830}
831#[derive(prost_helpers::AnyPB)]
832#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
833pub struct ListBoundedJobsRequest {}
834#[derive(prost_helpers::AnyPB)]
835#[derive(Clone, PartialEq, ::prost::Message)]
836pub struct ListBoundedJobsResponse {
837 #[prost(message, repeated, tag = "1")]
838 pub jobs: ::prost::alloc::vec::Vec<list_bounded_jobs_response::BoundedJob>,
839}
840pub mod list_bounded_jobs_response {
842 #[derive(prost_helpers::AnyPB)]
843 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
844 pub struct BoundedJob {
845 #[prost(uint32, tag = "1", wrapper = "crate::id::JobId")]
846 pub job_id: crate::id::JobId,
847 #[prost(uint32, tag = "2", wrapper = "crate::id::SourceId")]
848 pub source_id: crate::id::SourceId,
849 #[prost(message, optional, tag = "3")]
851 pub input: ::core::option::Option<
852 super::super::plan_common::source_ingest_mode::SourceIngestModeBounded,
853 >,
854 #[prost(int64, optional, tag = "4")]
856 pub completed_at_ms: ::core::option::Option<i64>,
857 #[prost(enumeration = "Status", tag = "5")]
858 pub status: i32,
859 }
860 #[derive(prost_helpers::AnyPB)]
861 #[derive(
862 Clone,
863 Copy,
864 Debug,
865 PartialEq,
866 Eq,
867 Hash,
868 PartialOrd,
869 Ord,
870 ::prost::Enumeration
871 )]
872 #[repr(i32)]
873 pub enum Status {
874 Unspecified = 0,
875 Loading = 1,
876 Completed = 2,
877 Failed = 3,
878 }
879 impl Status {
880 pub fn as_str_name(&self) -> &'static str {
885 match self {
886 Self::Unspecified => "STATUS_UNSPECIFIED",
887 Self::Loading => "STATUS_LOADING",
888 Self::Completed => "STATUS_COMPLETED",
889 Self::Failed => "STATUS_FAILED",
890 }
891 }
892 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
894 match value {
895 "STATUS_UNSPECIFIED" => Some(Self::Unspecified),
896 "STATUS_LOADING" => Some(Self::Loading),
897 "STATUS_COMPLETED" => Some(Self::Completed),
898 "STATUS_FAILED" => Some(Self::Failed),
899 _ => None,
900 }
901 }
902 }
903}
904#[derive(prost_helpers::AnyPB)]
905#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
906pub struct ListRefreshTableStatesRequest {}
907#[derive(prost_helpers::AnyPB)]
908#[derive(Clone, PartialEq, ::prost::Message)]
909pub struct ListRefreshTableStatesResponse {
910 #[prost(message, repeated, tag = "1")]
911 pub states: ::prost::alloc::vec::Vec<
912 list_refresh_table_states_response::RefreshTableState,
913 >,
914}
915pub mod list_refresh_table_states_response {
917 #[derive(prost_helpers::AnyPB)]
918 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
919 pub struct RefreshTableState {
920 #[prost(uint32, tag = "1", wrapper = "crate::id::TableId")]
921 pub table_id: crate::id::TableId,
922 #[prost(string, tag = "2")]
923 pub current_status: ::prost::alloc::string::String,
924 #[prost(string, optional, tag = "3")]
925 pub last_trigger_time: ::core::option::Option<::prost::alloc::string::String>,
926 #[prost(int64, optional, tag = "4")]
927 pub trigger_interval_secs: ::core::option::Option<i64>,
928 #[prost(string, optional, tag = "5")]
929 pub last_success_time: ::core::option::Option<::prost::alloc::string::String>,
930 }
931}
932#[derive(prost_helpers::AnyPB)]
933#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
934pub struct ListIcebergCompactionStatusRequest {}
935#[derive(prost_helpers::AnyPB)]
936#[derive(Clone, PartialEq, ::prost::Message)]
937pub struct ListIcebergCompactionStatusResponse {
938 #[prost(message, repeated, tag = "1")]
939 pub statuses: ::prost::alloc::vec::Vec<
940 list_iceberg_compaction_status_response::IcebergCompactionStatus,
941 >,
942}
943pub mod list_iceberg_compaction_status_response {
945 #[derive(prost_helpers::AnyPB)]
946 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
947 pub struct IcebergCompactionStatus {
948 #[prost(uint32, tag = "1")]
949 pub sink_id: u32,
950 #[prost(string, tag = "2")]
951 pub task_type: ::prost::alloc::string::String,
952 #[prost(uint64, tag = "3")]
953 pub trigger_interval_sec: u64,
954 #[prost(uint64, tag = "4")]
955 pub trigger_snapshot_count: u64,
956 #[prost(string, tag = "5")]
957 pub schedule_state: ::prost::alloc::string::String,
958 #[prost(uint64, optional, tag = "6")]
959 pub next_compaction_after_sec: ::core::option::Option<u64>,
960 #[prost(uint64, optional, tag = "7")]
962 pub pending_snapshot_count: ::core::option::Option<u64>,
963 #[prost(bool, tag = "8")]
964 pub is_triggerable: bool,
965 #[prost(int64, optional, tag = "9")]
968 pub last_success_at_ms: ::core::option::Option<i64>,
969 #[prost(int64, optional, tag = "10")]
970 pub last_failure_at_ms: ::core::option::Option<i64>,
971 #[prost(string, optional, tag = "11")]
972 pub last_error: ::core::option::Option<::prost::alloc::string::String>,
973 #[prost(uint32, tag = "12")]
974 pub consecutive_failures: u32,
975 #[prost(uint64, optional, tag = "13")]
978 pub compaction_lag_sec: ::core::option::Option<u64>,
979 }
980}
981#[derive(prost_helpers::AnyPB)]
983#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
984pub struct AddWorkerNodeRequest {
985 #[prost(enumeration = "super::common::WorkerType", tag = "1")]
986 pub worker_type: i32,
987 #[prost(message, optional, tag = "2")]
988 pub host: ::core::option::Option<super::common::HostAddress>,
989 #[prost(message, optional, tag = "5")]
990 pub resource: ::core::option::Option<super::common::worker_node::Resource>,
991 #[prost(message, optional, tag = "6")]
992 pub property: ::core::option::Option<super::common::worker_node::Property>,
993}
994#[derive(prost_helpers::AnyPB)]
995#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
996pub struct AddWorkerNodeResponse {
997 #[prost(uint32, optional, tag = "2", wrapper = "crate::id::WorkerId")]
998 pub node_id: ::core::option::Option<crate::id::WorkerId>,
999 #[prost(string, tag = "4")]
1000 pub cluster_id: ::prost::alloc::string::String,
1001}
1002#[derive(prost_helpers::AnyPB)]
1003#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1004pub struct ActivateWorkerNodeRequest {
1005 #[prost(message, optional, tag = "1")]
1006 pub host: ::core::option::Option<super::common::HostAddress>,
1007 #[prost(uint32, tag = "2", wrapper = "crate::id::WorkerId")]
1008 pub node_id: crate::id::WorkerId,
1009}
1010#[derive(prost_helpers::AnyPB)]
1011#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1012pub struct ActivateWorkerNodeResponse {
1013 #[prost(message, optional, tag = "1")]
1014 pub status: ::core::option::Option<super::common::Status>,
1015}
1016#[derive(prost_helpers::AnyPB)]
1017#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1018pub struct DeleteWorkerNodeRequest {
1019 #[prost(message, optional, tag = "1")]
1020 pub host: ::core::option::Option<super::common::HostAddress>,
1021}
1022#[derive(prost_helpers::AnyPB)]
1023#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1024pub struct DeleteWorkerNodeResponse {
1025 #[prost(message, optional, tag = "1")]
1026 pub status: ::core::option::Option<super::common::Status>,
1027}
1028#[derive(prost_helpers::AnyPB)]
1029#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1030pub struct ListAllNodesRequest {
1031 #[prost(enumeration = "super::common::WorkerType", optional, tag = "1")]
1032 pub worker_type: ::core::option::Option<i32>,
1033 #[prost(bool, tag = "2")]
1035 pub include_starting_nodes: bool,
1036}
1037#[derive(prost_helpers::AnyPB)]
1038#[derive(Clone, PartialEq, ::prost::Message)]
1039pub struct ListAllNodesResponse {
1040 #[prost(message, optional, tag = "1")]
1041 pub status: ::core::option::Option<super::common::Status>,
1042 #[prost(message, repeated, tag = "2")]
1043 pub nodes: ::prost::alloc::vec::Vec<super::common::WorkerNode>,
1044}
1045#[derive(prost_helpers::AnyPB)]
1046#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1047pub struct GetClusterRecoveryStatusRequest {}
1048#[derive(prost_helpers::AnyPB)]
1049#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1050pub struct GetClusterRecoveryStatusResponse {
1051 #[prost(enumeration = "RecoveryStatus", tag = "1")]
1052 pub status: i32,
1053}
1054#[derive(prost_helpers::AnyPB)]
1055#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1056pub struct GetMetaStoreInfoRequest {}
1057#[derive(prost_helpers::AnyPB)]
1058#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1059pub struct GetMetaStoreInfoResponse {
1060 #[prost(string, tag = "1")]
1061 pub meta_store_endpoint: ::prost::alloc::string::String,
1062}
1063#[derive(prost_helpers::AnyPB)]
1065#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1066pub struct SubscribeRequest {
1067 #[prost(enumeration = "SubscribeType", tag = "1")]
1068 pub subscribe_type: i32,
1069 #[prost(message, optional, tag = "2")]
1070 pub host: ::core::option::Option<super::common::HostAddress>,
1071 #[prost(uint32, tag = "3", wrapper = "crate::id::WorkerId")]
1072 pub worker_id: crate::id::WorkerId,
1073}
1074#[derive(prost_helpers::AnyPB)]
1075#[derive(Clone, PartialEq, ::prost::Message)]
1076pub struct MetaSnapshot {
1077 #[prost(message, repeated, tag = "1")]
1078 pub databases: ::prost::alloc::vec::Vec<super::catalog::Database>,
1079 #[prost(message, repeated, tag = "2")]
1080 pub schemas: ::prost::alloc::vec::Vec<super::catalog::Schema>,
1081 #[prost(message, repeated, tag = "3")]
1082 pub sources: ::prost::alloc::vec::Vec<super::catalog::Source>,
1083 #[prost(message, repeated, tag = "4")]
1084 pub sinks: ::prost::alloc::vec::Vec<super::catalog::Sink>,
1085 #[prost(message, repeated, tag = "5")]
1086 pub tables: ::prost::alloc::vec::Vec<super::catalog::Table>,
1087 #[prost(message, repeated, tag = "6")]
1088 pub indexes: ::prost::alloc::vec::Vec<super::catalog::Index>,
1089 #[prost(message, repeated, tag = "7")]
1090 pub views: ::prost::alloc::vec::Vec<super::catalog::View>,
1091 #[prost(message, repeated, tag = "15")]
1092 pub functions: ::prost::alloc::vec::Vec<super::catalog::Function>,
1093 #[prost(message, repeated, tag = "17")]
1094 pub connections: ::prost::alloc::vec::Vec<super::catalog::Connection>,
1095 #[prost(message, repeated, tag = "19")]
1096 pub subscriptions: ::prost::alloc::vec::Vec<super::catalog::Subscription>,
1097 #[prost(message, repeated, tag = "8")]
1098 pub users: ::prost::alloc::vec::Vec<super::user::UserInfo>,
1099 #[prost(message, optional, tag = "20")]
1100 pub session_params: ::core::option::Option<GetSessionParamsResponse>,
1101 #[prost(message, repeated, tag = "23")]
1102 pub secrets: ::prost::alloc::vec::Vec<super::catalog::Secret>,
1103 #[prost(message, optional, tag = "25")]
1104 pub cluster_resource: ::core::option::Option<super::common::ClusterResource>,
1105 #[prost(message, repeated, tag = "10")]
1106 pub nodes: ::prost::alloc::vec::Vec<super::common::WorkerNode>,
1107 #[prost(message, optional, tag = "12")]
1108 pub hummock_version: ::core::option::Option<super::hummock::HummockVersion>,
1109 #[prost(message, optional, tag = "14")]
1110 pub meta_backup_manifest_id: ::core::option::Option<
1111 super::backup_service::MetaBackupManifestId,
1112 >,
1113 #[prost(message, optional, tag = "16")]
1114 pub hummock_write_limits: ::core::option::Option<super::hummock::WriteLimits>,
1115 #[prost(message, repeated, tag = "21")]
1117 pub streaming_worker_slot_mappings: ::prost::alloc::vec::Vec<
1118 FragmentWorkerSlotMapping,
1119 >,
1120 #[prost(message, repeated, tag = "22")]
1121 pub serving_worker_slot_mappings: ::prost::alloc::vec::Vec<
1122 FragmentWorkerSlotMapping,
1123 >,
1124 #[prost(message, repeated, tag = "26")]
1125 pub object_dependencies: ::prost::alloc::vec::Vec<ObjectDependency>,
1126 #[prost(message, optional, tag = "27")]
1127 pub table_refill_runtime_config: ::core::option::Option<TableRefillRuntimeConfig>,
1128 #[prost(message, optional, tag = "13")]
1129 pub version: ::core::option::Option<meta_snapshot::SnapshotVersion>,
1130}
1131pub mod meta_snapshot {
1133 #[derive(prost_helpers::AnyPB)]
1134 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1135 pub struct SnapshotVersion {
1136 #[prost(uint64, tag = "1")]
1137 pub catalog_version: u64,
1138 #[prost(uint64, tag = "3")]
1139 pub worker_node_version: u64,
1140 #[prost(uint64, tag = "4")]
1141 pub streaming_worker_slot_mapping_version: u64,
1142 }
1143}
1144#[derive(prost_helpers::AnyPB)]
1145#[derive(Clone, PartialEq, ::prost::Message)]
1146pub struct Object {
1147 #[prost(oneof = "object::ObjectInfo", tags = "1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11")]
1148 pub object_info: ::core::option::Option<object::ObjectInfo>,
1149}
1150pub mod object {
1152 #[derive(prost_helpers::AnyPB)]
1153 #[derive(strum::Display)]
1154 #[derive(Clone, PartialEq, ::prost::Oneof)]
1155 pub enum ObjectInfo {
1156 #[prost(message, tag = "1")]
1157 Database(super::super::catalog::Database),
1158 #[prost(message, tag = "2")]
1159 Schema(super::super::catalog::Schema),
1160 #[prost(message, tag = "3")]
1161 Table(super::super::catalog::Table),
1162 #[prost(message, tag = "4")]
1163 Index(super::super::catalog::Index),
1164 #[prost(message, tag = "5")]
1165 Source(super::super::catalog::Source),
1166 #[prost(message, tag = "6")]
1167 Sink(super::super::catalog::Sink),
1168 #[prost(message, tag = "7")]
1169 View(super::super::catalog::View),
1170 #[prost(message, tag = "8")]
1171 Function(super::super::catalog::Function),
1172 #[prost(message, tag = "9")]
1173 Connection(super::super::catalog::Connection),
1174 #[prost(message, tag = "10")]
1175 Subscription(super::super::catalog::Subscription),
1176 #[prost(message, tag = "11")]
1177 Secret(super::super::catalog::Secret),
1178 }
1179}
1180#[derive(prost_helpers::AnyPB)]
1181#[derive(Clone, PartialEq, ::prost::Message)]
1182pub struct ObjectGroup {
1183 #[prost(message, repeated, tag = "1")]
1184 pub objects: ::prost::alloc::vec::Vec<Object>,
1185 #[prost(message, repeated, tag = "2")]
1186 pub dependencies: ::prost::alloc::vec::Vec<ObjectDependency>,
1187}
1188#[derive(prost_helpers::AnyPB)]
1189#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1190pub struct Recovery {}
1191#[derive(prost_helpers::AnyPB)]
1192#[derive(Clone, PartialEq, ::prost::Message)]
1193pub struct SubscribeResponse {
1194 #[prost(message, optional, tag = "1")]
1195 pub status: ::core::option::Option<super::common::Status>,
1196 #[prost(enumeration = "subscribe_response::Operation", tag = "2")]
1197 pub operation: i32,
1198 #[prost(uint64, tag = "3")]
1200 pub version: u64,
1201 #[prost(
1202 oneof = "subscribe_response::Info",
1203 tags = "4, 5, 6, 11, 26, 13, 15, 16, 17, 19, 20, 21, 22, 24, 25, 27, 28, 29, 31, 32"
1204 )]
1205 pub info: ::core::option::Option<subscribe_response::Info>,
1206}
1207pub mod subscribe_response {
1209 #[derive(prost_helpers::AnyPB)]
1210 #[derive(
1211 Clone,
1212 Copy,
1213 Debug,
1214 PartialEq,
1215 Eq,
1216 Hash,
1217 PartialOrd,
1218 Ord,
1219 ::prost::Enumeration
1220 )]
1221 #[repr(i32)]
1222 pub enum Operation {
1223 Unspecified = 0,
1224 Add = 1,
1225 Delete = 2,
1226 Update = 3,
1227 Snapshot = 4,
1228 }
1229 impl Operation {
1230 pub fn as_str_name(&self) -> &'static str {
1235 match self {
1236 Self::Unspecified => "UNSPECIFIED",
1237 Self::Add => "ADD",
1238 Self::Delete => "DELETE",
1239 Self::Update => "UPDATE",
1240 Self::Snapshot => "SNAPSHOT",
1241 }
1242 }
1243 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1245 match value {
1246 "UNSPECIFIED" => Some(Self::Unspecified),
1247 "ADD" => Some(Self::Add),
1248 "DELETE" => Some(Self::Delete),
1249 "UPDATE" => Some(Self::Update),
1250 "SNAPSHOT" => Some(Self::Snapshot),
1251 _ => None,
1252 }
1253 }
1254 }
1255 #[derive(prost_helpers::AnyPB)]
1256 #[derive(strum::Display)]
1257 #[derive(Clone, PartialEq, ::prost::Oneof)]
1258 pub enum Info {
1259 #[prost(message, tag = "4")]
1260 Database(super::super::catalog::Database),
1261 #[prost(message, tag = "5")]
1262 Schema(super::super::catalog::Schema),
1263 #[prost(message, tag = "6")]
1264 Function(super::super::catalog::Function),
1265 #[prost(message, tag = "11")]
1266 User(super::super::user::UserInfo),
1267 #[prost(message, tag = "26")]
1268 SessionParam(super::SetSessionParamRequest),
1269 #[prost(message, tag = "13")]
1270 Node(super::super::common::WorkerNode),
1271 #[prost(message, tag = "15")]
1272 HummockVersionDeltas(super::super::hummock::HummockVersionDeltas),
1273 #[prost(message, tag = "16")]
1274 Snapshot(super::MetaSnapshot),
1275 #[prost(message, tag = "17")]
1276 MetaBackupManifestId(super::super::backup_service::MetaBackupManifestId),
1277 #[prost(message, tag = "19")]
1278 SystemParams(super::SystemParams),
1279 #[prost(message, tag = "20")]
1280 HummockWriteLimits(super::super::hummock::WriteLimits),
1281 #[prost(message, tag = "21")]
1282 ObjectGroup(super::ObjectGroup),
1283 #[prost(message, tag = "22")]
1284 Connection(super::super::catalog::Connection),
1285 #[prost(message, tag = "24")]
1286 HummockStats(super::super::hummock::HummockVersionStats),
1287 #[prost(message, tag = "25")]
1288 Recovery(super::Recovery),
1289 #[prost(message, tag = "27")]
1290 StreamingWorkerSlotMapping(super::FragmentWorkerSlotMapping),
1291 #[prost(message, tag = "28")]
1292 ServingWorkerSlotMappings(super::FragmentWorkerSlotMappings),
1293 #[prost(message, tag = "29")]
1294 Secret(super::super::catalog::Secret),
1295 #[prost(message, tag = "31")]
1296 ClusterResource(super::super::common::ClusterResource),
1297 #[prost(message, tag = "32")]
1298 TableRefillRuntimeConfig(super::TableRefillRuntimeConfig),
1299 }
1300}
1301#[derive(prost_helpers::AnyPB)]
1302#[derive(Clone, PartialEq, ::prost::Message)]
1303pub struct TableRefillRuntimeConfig {
1304 #[prost(message, optional, tag = "1")]
1305 pub table_cache_refill_policies: ::core::option::Option<TableCacheRefillPolicies>,
1306 #[prost(message, optional, tag = "2")]
1307 pub serving_table_vnode_mappings: ::core::option::Option<ServingTableVnodeMappings>,
1308 #[prost(uint64, tag = "3")]
1309 pub version: u64,
1310}
1311#[derive(prost_helpers::AnyPB)]
1312#[derive(Clone, PartialEq, ::prost::Message)]
1313pub struct ServingTableVnodeMappings {
1314 #[prost(message, repeated, tag = "1")]
1315 pub mappings: ::prost::alloc::vec::Vec<
1316 serving_table_vnode_mappings::ServingTableVnodeMapping,
1317 >,
1318}
1319pub mod serving_table_vnode_mappings {
1321 #[derive(prost_helpers::AnyPB)]
1322 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1323 pub struct ServingTableVnodeMapping {
1324 #[prost(uint32, tag = "1")]
1325 pub table_id: u32,
1326 #[prost(message, optional, tag = "2")]
1327 pub bitmap: ::core::option::Option<super::super::common::Buffer>,
1328 }
1329}
1330#[derive(prost_helpers::AnyPB)]
1331#[derive(Clone, PartialEq, ::prost::Message)]
1332pub struct TableCacheRefillPolicies {
1333 #[prost(message, repeated, tag = "1")]
1335 pub table_policies: ::prost::alloc::vec::Vec<
1336 table_cache_refill_policies::TableCacheRefillPolicy,
1337 >,
1338 #[prost(message, repeated, tag = "2")]
1340 pub internal_table_policies: ::prost::alloc::vec::Vec<
1341 table_cache_refill_policies::TableCacheRefillPolicy,
1342 >,
1343}
1344pub mod table_cache_refill_policies {
1346 #[derive(prost_helpers::AnyPB)]
1347 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1348 pub struct TableCacheRefillPolicy {
1349 #[prost(uint32, tag = "1")]
1350 pub table_id: u32,
1351 #[prost(enumeration = "table_cache_refill_policy::CacheRefillPolicy", tag = "2")]
1352 pub policy: i32,
1353 }
1354 pub mod table_cache_refill_policy {
1356 #[derive(prost_helpers::AnyPB)]
1357 #[derive(
1358 Clone,
1359 Copy,
1360 Debug,
1361 PartialEq,
1362 Eq,
1363 Hash,
1364 PartialOrd,
1365 Ord,
1366 ::prost::Enumeration
1367 )]
1368 #[repr(i32)]
1369 pub enum CacheRefillPolicy {
1370 Unspecified = 0,
1372 Enabled = 1,
1374 Disabled = 2,
1376 Streaming = 3,
1378 Serving = 4,
1380 Both = 5,
1382 }
1383 impl CacheRefillPolicy {
1384 pub fn as_str_name(&self) -> &'static str {
1389 match self {
1390 Self::Unspecified => "UNSPECIFIED",
1391 Self::Enabled => "ENABLED",
1392 Self::Disabled => "DISABLED",
1393 Self::Streaming => "STREAMING",
1394 Self::Serving => "SERVING",
1395 Self::Both => "BOTH",
1396 }
1397 }
1398 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1400 match value {
1401 "UNSPECIFIED" => Some(Self::Unspecified),
1402 "ENABLED" => Some(Self::Enabled),
1403 "DISABLED" => Some(Self::Disabled),
1404 "STREAMING" => Some(Self::Streaming),
1405 "SERVING" => Some(Self::Serving),
1406 "BOTH" => Some(Self::Both),
1407 _ => None,
1408 }
1409 }
1410 }
1411 }
1412}
1413#[derive(prost_helpers::AnyPB)]
1414#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1415pub struct GetClusterInfoRequest {}
1416#[derive(prost_helpers::AnyPB)]
1417#[derive(Clone, PartialEq, ::prost::Message)]
1418pub struct GetClusterInfoResponse {
1419 #[prost(message, repeated, tag = "1")]
1420 pub worker_nodes: ::prost::alloc::vec::Vec<super::common::WorkerNode>,
1421 #[prost(message, repeated, tag = "2")]
1422 pub table_fragments: ::prost::alloc::vec::Vec<TableFragments>,
1423 #[prost(map = "uint32, message", tag = "3", wrapper = "crate::id::ActorId")]
1425 pub actor_splits: ::std::collections::HashMap<
1426 crate::id::ActorId,
1427 super::source::ConnectorSplits,
1428 >,
1429 #[prost(map = "uint32, message", tag = "4", wrapper = "crate::id::SourceId")]
1430 pub source_infos: ::std::collections::HashMap<
1431 crate::id::SourceId,
1432 super::catalog::Source,
1433 >,
1434 #[prost(uint64, tag = "5")]
1435 pub revision: u64,
1436}
1437#[derive(prost_helpers::AnyPB)]
1440#[derive(Clone, PartialEq, ::prost::Message)]
1441pub struct WorkerReschedule {
1442 #[prost(map = "uint32, int32", tag = "1", wrapper = "crate::id::WorkerId")]
1444 pub worker_actor_diff: ::std::collections::HashMap<crate::id::WorkerId, i32>,
1445}
1446#[derive(prost_helpers::AnyPB)]
1447#[derive(Clone, PartialEq, ::prost::Message)]
1448pub struct RescheduleRequest {
1449 #[prost(uint64, tag = "2")]
1450 pub revision: u64,
1451 #[prost(bool, tag = "3")]
1452 pub resolve_no_shuffle_upstream: bool,
1453 #[prost(map = "uint32, message", tag = "4")]
1454 pub worker_reschedules: ::std::collections::HashMap<u32, WorkerReschedule>,
1455}
1456#[derive(prost_helpers::AnyPB)]
1457#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1458pub struct RescheduleResponse {
1459 #[prost(bool, tag = "1")]
1460 pub success: bool,
1461 #[prost(uint64, tag = "2")]
1462 pub revision: u64,
1463}
1464#[derive(prost_helpers::AnyPB)]
1465#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1466pub struct TableParallelism {
1467 #[prost(oneof = "table_parallelism::Parallelism", tags = "1, 2, 3, 4")]
1468 pub parallelism: ::core::option::Option<table_parallelism::Parallelism>,
1469}
1470pub mod table_parallelism {
1472 #[derive(prost_helpers::AnyPB)]
1473 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1474 pub struct FixedParallelism {
1475 #[prost(uint32, tag = "1")]
1476 pub parallelism: u32,
1477 }
1478 #[derive(prost_helpers::AnyPB)]
1480 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1481 pub struct AutoParallelism {}
1482 #[derive(prost_helpers::AnyPB)]
1483 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1484 pub struct AdaptiveParallelism {}
1485 #[derive(prost_helpers::AnyPB)]
1486 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1487 pub struct CustomParallelism {}
1488 #[derive(prost_helpers::AnyPB)]
1489 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Oneof)]
1490 pub enum Parallelism {
1491 #[prost(message, tag = "1")]
1492 Fixed(FixedParallelism),
1493 #[prost(message, tag = "2")]
1494 Auto(AutoParallelism),
1495 #[prost(message, tag = "3")]
1496 Custom(CustomParallelism),
1497 #[prost(message, tag = "4")]
1498 Adaptive(AdaptiveParallelism),
1499 }
1500}
1501#[derive(prost_helpers::AnyPB)]
1504#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1505pub struct UpdateStreamingJobNodeLabelsRequest {
1506 #[prost(uint32, tag = "1")]
1508 pub id: u32,
1509 #[prost(string, tag = "2")]
1511 pub node_label: ::prost::alloc::string::String,
1512}
1513#[derive(prost_helpers::AnyPB)]
1515#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1516pub struct UpdateStreamingJobNodeLabelsResponse {}
1517#[derive(prost_helpers::AnyPB)]
1518#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1519pub struct GetServerlessStreamingJobsStatusRequest {}
1520#[derive(prost_helpers::AnyPB)]
1522#[derive(Clone, PartialEq, ::prost::Message)]
1523pub struct GetServerlessStreamingJobsStatusResponse {
1524 #[prost(message, repeated, tag = "1")]
1525 pub streaming_job_statuses: ::prost::alloc::vec::Vec<
1526 get_serverless_streaming_jobs_status_response::Status,
1527 >,
1528}
1529pub mod get_serverless_streaming_jobs_status_response {
1531 #[derive(prost_helpers::AnyPB)]
1532 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1533 pub struct Status {
1534 #[prost(uint32, tag = "1", wrapper = "crate::id::TableId")]
1535 pub table_id: crate::id::TableId,
1536 #[prost(string, tag = "2")]
1537 pub node_label: ::prost::alloc::string::String,
1538 #[prost(bool, tag = "3")]
1539 pub backfill_done: bool,
1540 }
1541}
1542#[derive(prost_helpers::AnyPB)]
1543#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1544pub struct MembersRequest {}
1545#[derive(prost_helpers::AnyPB)]
1546#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1547pub struct MetaMember {
1548 #[prost(message, optional, tag = "1")]
1549 pub address: ::core::option::Option<super::common::HostAddress>,
1550 #[prost(bool, tag = "2")]
1551 pub is_leader: bool,
1552}
1553#[derive(prost_helpers::AnyPB)]
1554#[derive(Clone, PartialEq, ::prost::Message)]
1555pub struct MembersResponse {
1556 #[prost(message, repeated, tag = "1")]
1557 pub members: ::prost::alloc::vec::Vec<MetaMember>,
1558}
1559#[derive(prost_helpers::AnyPB)]
1566#[derive(Clone, PartialEq, ::prost::Message)]
1567#[prost(skip_debug)]
1568pub struct SystemParams {
1569 #[prost(uint32, optional, tag = "1")]
1570 pub barrier_interval_ms: ::core::option::Option<u32>,
1571 #[prost(uint64, optional, tag = "2")]
1572 pub checkpoint_frequency: ::core::option::Option<u64>,
1573 #[prost(uint32, optional, tag = "3")]
1574 pub sstable_size_mb: ::core::option::Option<u32>,
1575 #[prost(uint32, optional, tag = "4")]
1576 pub block_size_kb: ::core::option::Option<u32>,
1577 #[deprecated]
1580 #[prost(double, optional, tag = "5")]
1581 pub bloom_false_positive: ::core::option::Option<f64>,
1582 #[prost(string, optional, tag = "6")]
1583 pub state_store: ::core::option::Option<::prost::alloc::string::String>,
1584 #[prost(string, optional, tag = "7")]
1585 pub data_directory: ::core::option::Option<::prost::alloc::string::String>,
1586 #[prost(string, optional, tag = "8")]
1587 pub backup_storage_url: ::core::option::Option<::prost::alloc::string::String>,
1588 #[prost(string, optional, tag = "9")]
1589 pub backup_storage_directory: ::core::option::Option<::prost::alloc::string::String>,
1590 #[deprecated]
1592 #[prost(bool, optional, tag = "10")]
1593 pub telemetry_enabled: ::core::option::Option<bool>,
1594 #[prost(uint32, optional, tag = "11")]
1595 pub parallel_compact_size_mb: ::core::option::Option<u32>,
1596 #[prost(uint32, optional, tag = "12")]
1597 pub max_concurrent_creating_streaming_jobs: ::core::option::Option<u32>,
1598 #[prost(bool, optional, tag = "13")]
1599 pub pause_on_next_bootstrap: ::core::option::Option<bool>,
1600 #[deprecated]
1601 #[prost(string, optional, tag = "14")]
1602 pub wasm_storage_url: ::core::option::Option<::prost::alloc::string::String>,
1603 #[prost(bool, optional, tag = "15")]
1604 pub enable_tracing: ::core::option::Option<bool>,
1605 #[prost(bool, optional, tag = "16")]
1606 pub use_new_object_prefix_strategy: ::core::option::Option<bool>,
1607 #[prost(string, optional, tag = "17")]
1608 pub license_key: ::core::option::Option<::prost::alloc::string::String>,
1609 #[prost(uint64, optional, tag = "18")]
1610 pub time_travel_retention_ms: ::core::option::Option<u64>,
1611 #[prost(string, optional, tag = "19")]
1612 pub adaptive_parallelism_strategy: ::core::option::Option<
1613 ::prost::alloc::string::String,
1614 >,
1615 #[prost(bool, optional, tag = "20")]
1616 pub per_database_isolation: ::core::option::Option<bool>,
1617 #[prost(bool, optional, tag = "21")]
1618 pub enforce_secret: ::core::option::Option<bool>,
1619}
1620#[derive(prost_helpers::AnyPB)]
1621#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1622pub struct GetSystemParamsRequest {}
1623#[derive(prost_helpers::AnyPB)]
1624#[derive(Clone, PartialEq, ::prost::Message)]
1625pub struct GetSystemParamsResponse {
1626 #[prost(message, optional, tag = "1")]
1627 pub params: ::core::option::Option<SystemParams>,
1628}
1629#[derive(prost_helpers::AnyPB)]
1630#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1631pub struct SetSystemParamRequest {
1632 #[prost(string, tag = "1")]
1633 pub param: ::prost::alloc::string::String,
1634 #[prost(string, optional, tag = "2")]
1636 pub value: ::core::option::Option<::prost::alloc::string::String>,
1637}
1638#[derive(prost_helpers::AnyPB)]
1639#[derive(Clone, PartialEq, ::prost::Message)]
1640pub struct SetSystemParamResponse {
1641 #[prost(message, optional, tag = "1")]
1642 pub params: ::core::option::Option<SystemParams>,
1643}
1644#[derive(prost_helpers::AnyPB)]
1645#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1646pub struct ClearFileCacheRequest {
1647 #[prost(bool, tag = "1")]
1648 pub clear_meta_cache: bool,
1649 #[prost(bool, tag = "2")]
1650 pub clear_data_cache: bool,
1651}
1652#[derive(prost_helpers::AnyPB)]
1653#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1654pub struct ClearFileCacheResponse {}
1655#[derive(prost_helpers::AnyPB)]
1656#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1657pub struct GetSessionParamsRequest {}
1658#[derive(prost_helpers::AnyPB)]
1659#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1660pub struct GetSessionParamsResponse {
1661 #[prost(string, tag = "1")]
1662 pub params: ::prost::alloc::string::String,
1663}
1664#[derive(prost_helpers::AnyPB)]
1665#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1666pub struct SetSessionParamRequest {
1667 #[prost(string, tag = "1")]
1668 pub param: ::prost::alloc::string::String,
1669 #[prost(string, optional, tag = "2")]
1671 pub value: ::core::option::Option<::prost::alloc::string::String>,
1672}
1673#[derive(prost_helpers::AnyPB)]
1674#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1675pub struct SetSessionParamResponse {
1676 #[prost(string, tag = "1")]
1677 pub param: ::prost::alloc::string::String,
1678}
1679#[derive(prost_helpers::AnyPB)]
1680#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1681pub struct GetServingVnodeMappingsRequest {}
1682#[derive(prost_helpers::AnyPB)]
1683#[derive(Clone, PartialEq, ::prost::Message)]
1684pub struct GetServingVnodeMappingsResponse {
1685 #[prost(
1686 map = "uint32, uint32",
1687 tag = "2",
1688 wrapper = "crate::id::FragmentId ->crate::id:: JobId"
1689 )]
1690 pub fragment_to_table: ::std::collections::HashMap<
1691 crate::id::FragmentId,
1692 crate::id::JobId,
1693 >,
1694 #[prost(message, repeated, tag = "3")]
1695 pub worker_slot_mappings: ::prost::alloc::vec::Vec<FragmentWorkerSlotMapping>,
1696}
1697#[derive(prost_helpers::AnyPB)]
1698#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1699pub struct WarmUpTableCacheRequest {
1700 #[prost(uint32, tag = "1", wrapper = "crate::id::TableId")]
1701 pub table_id: crate::id::TableId,
1702 #[prost(uint32, tag = "2")]
1704 pub concurrency: u32,
1705}
1706#[derive(prost_helpers::AnyPB)]
1707#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1708pub struct WarmUpTableCacheResponse {
1709 #[prost(uint64, tag = "1")]
1710 pub key_count: u64,
1711 #[prost(uint32, tag = "2")]
1712 pub worker_count: u32,
1713}
1714#[derive(prost_helpers::AnyPB)]
1715#[derive(Clone, PartialEq, ::prost::Message)]
1716pub struct EventLog {
1717 #[prost(string, optional, tag = "1")]
1719 pub unique_id: ::core::option::Option<::prost::alloc::string::String>,
1720 #[prost(uint64, optional, tag = "2")]
1722 pub timestamp: ::core::option::Option<u64>,
1723 #[prost(oneof = "event_log::Event", tags = "3, 4, 5, 6, 7, 8, 9, 10, 11, 12")]
1724 pub event: ::core::option::Option<event_log::Event>,
1725}
1726pub mod event_log {
1728 #[derive(prost_helpers::AnyPB)]
1729 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1730 pub struct EventMetaNodeStart {
1731 #[prost(string, tag = "1")]
1732 pub advertise_addr: ::prost::alloc::string::String,
1733 #[prost(string, tag = "2")]
1734 pub listen_addr: ::prost::alloc::string::String,
1735 #[prost(string, tag = "3")]
1736 pub opts: ::prost::alloc::string::String,
1737 }
1738 #[derive(prost_helpers::AnyPB)]
1739 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1740 pub struct EventCreateStreamJobFail {
1741 #[prost(uint32, tag = "1", wrapper = "crate::id::JobId")]
1742 pub id: crate::id::JobId,
1743 #[prost(string, tag = "2")]
1744 pub name: ::prost::alloc::string::String,
1745 #[prost(string, tag = "3")]
1746 pub definition: ::prost::alloc::string::String,
1747 #[prost(string, tag = "4")]
1748 pub error: ::prost::alloc::string::String,
1749 }
1750 #[derive(prost_helpers::AnyPB)]
1751 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1752 pub struct EventDirtyStreamJobClear {
1753 #[prost(uint32, tag = "1", wrapper = "crate::id::JobId")]
1754 pub id: crate::id::JobId,
1755 #[prost(string, tag = "2")]
1756 pub name: ::prost::alloc::string::String,
1757 #[prost(string, tag = "3")]
1758 pub definition: ::prost::alloc::string::String,
1759 #[prost(string, tag = "4")]
1760 pub error: ::prost::alloc::string::String,
1761 }
1762 #[derive(prost_helpers::AnyPB)]
1763 #[derive(Clone, PartialEq, ::prost::Message)]
1764 pub struct EventBarrierComplete {
1765 #[prost(uint64, tag = "1")]
1766 pub prev_epoch: u64,
1767 #[prost(uint64, tag = "2")]
1768 pub cur_epoch: u64,
1769 #[prost(double, tag = "3")]
1770 pub duration_sec: f64,
1771 #[prost(string, tag = "4")]
1772 pub command: ::prost::alloc::string::String,
1773 #[prost(string, tag = "5")]
1774 pub barrier_kind: ::prost::alloc::string::String,
1775 #[prost(uint32, tag = "6")]
1776 pub database_id: u32,
1777 }
1778 #[derive(prost_helpers::AnyPB)]
1779 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1780 pub struct EventInjectBarrierFail {
1781 #[prost(uint64, tag = "1")]
1782 pub prev_epoch: u64,
1783 #[prost(uint64, tag = "2")]
1784 pub cur_epoch: u64,
1785 #[prost(string, tag = "3")]
1786 pub error: ::prost::alloc::string::String,
1787 }
1788 #[derive(prost_helpers::AnyPB)]
1789 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1790 pub struct EventCollectBarrierFail {
1791 #[prost(string, tag = "3")]
1792 pub error: ::prost::alloc::string::String,
1793 }
1794 #[derive(prost_helpers::AnyPB)]
1795 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1796 pub struct EventWorkerNodePanic {
1797 #[prost(uint32, tag = "1", wrapper = "crate::id::WorkerId")]
1798 pub worker_id: crate::id::WorkerId,
1799 #[prost(enumeration = "super::super::common::WorkerType", tag = "2")]
1800 pub worker_type: i32,
1801 #[prost(message, optional, tag = "3")]
1802 pub host_addr: ::core::option::Option<super::super::common::HostAddress>,
1803 #[prost(string, tag = "4")]
1804 pub panic_info: ::prost::alloc::string::String,
1805 }
1806 #[derive(prost_helpers::AnyPB)]
1807 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1808 pub struct EventAutoSchemaChangeFail {
1809 #[prost(uint32, tag = "1", wrapper = "crate::id::TableId")]
1810 pub table_id: crate::id::TableId,
1811 #[prost(string, tag = "2")]
1812 pub table_name: ::prost::alloc::string::String,
1813 #[prost(string, tag = "3")]
1814 pub cdc_table_id: ::prost::alloc::string::String,
1815 #[prost(string, tag = "4")]
1816 pub upstream_ddl: ::prost::alloc::string::String,
1817 #[prost(string, tag = "5")]
1818 pub fail_info: ::prost::alloc::string::String,
1819 }
1820 #[derive(prost_helpers::AnyPB)]
1821 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1822 pub struct EventSinkFail {
1823 #[prost(uint32, tag = "1", wrapper = "crate::id::SinkId")]
1824 pub sink_id: crate::id::SinkId,
1825 #[prost(string, tag = "2")]
1826 pub sink_name: ::prost::alloc::string::String,
1827 #[prost(string, tag = "3")]
1828 pub connector: ::prost::alloc::string::String,
1829 #[prost(string, tag = "4")]
1830 pub error: ::prost::alloc::string::String,
1831 }
1832 #[derive(prost_helpers::AnyPB)]
1833 #[derive(Clone, PartialEq, ::prost::Message)]
1834 pub struct EventRecovery {
1835 #[prost(oneof = "event_recovery::RecoveryEvent", tags = "1, 2, 3, 4, 5, 6")]
1836 pub recovery_event: ::core::option::Option<event_recovery::RecoveryEvent>,
1837 }
1838 pub mod event_recovery {
1840 #[derive(prost_helpers::AnyPB)]
1841 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1842 pub struct GlobalRecoveryStart {
1843 #[prost(string, tag = "1")]
1844 pub reason: ::prost::alloc::string::String,
1845 }
1846 #[derive(prost_helpers::AnyPB)]
1847 #[derive(Clone, PartialEq, ::prost::Message)]
1848 pub struct GlobalRecoverySuccess {
1849 #[prost(string, tag = "1")]
1850 pub reason: ::prost::alloc::string::String,
1851 #[prost(float, tag = "2")]
1852 pub duration_secs: f32,
1853 #[prost(uint32, repeated, tag = "3")]
1854 pub running_database_ids: ::prost::alloc::vec::Vec<u32>,
1855 #[prost(uint32, repeated, tag = "4")]
1856 pub recovering_database_ids: ::prost::alloc::vec::Vec<u32>,
1857 }
1858 #[derive(prost_helpers::AnyPB)]
1859 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1860 pub struct GlobalRecoveryFailure {
1861 #[prost(string, tag = "1")]
1862 pub reason: ::prost::alloc::string::String,
1863 #[prost(string, tag = "2")]
1864 pub error: ::prost::alloc::string::String,
1865 }
1866 #[derive(prost_helpers::AnyPB)]
1867 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1868 pub struct DatabaseRecoveryStart {
1869 #[prost(uint32, tag = "1")]
1870 pub database_id: u32,
1871 }
1872 #[derive(prost_helpers::AnyPB)]
1873 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1874 pub struct DatabaseRecoveryFailure {
1875 #[prost(uint32, tag = "1")]
1876 pub database_id: u32,
1877 }
1878 #[derive(prost_helpers::AnyPB)]
1879 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1880 pub struct DatabaseRecoverySuccess {
1881 #[prost(uint32, tag = "1")]
1882 pub database_id: u32,
1883 }
1884 #[derive(prost_helpers::AnyPB)]
1885 #[derive(Clone, PartialEq, ::prost::Oneof)]
1886 pub enum RecoveryEvent {
1887 #[prost(message, tag = "1")]
1888 GlobalStart(GlobalRecoveryStart),
1889 #[prost(message, tag = "2")]
1890 GlobalSuccess(GlobalRecoverySuccess),
1891 #[prost(message, tag = "3")]
1892 GlobalFailure(GlobalRecoveryFailure),
1893 #[prost(message, tag = "4")]
1894 DatabaseStart(DatabaseRecoveryStart),
1895 #[prost(message, tag = "5")]
1896 DatabaseFailure(DatabaseRecoveryFailure),
1897 #[prost(message, tag = "6")]
1898 DatabaseSuccess(DatabaseRecoverySuccess),
1899 }
1900 }
1901 #[derive(prost_helpers::AnyPB)]
1902 #[derive(Clone, PartialEq, ::prost::Oneof)]
1903 pub enum Event {
1904 #[prost(message, tag = "3")]
1905 CreateStreamJobFail(EventCreateStreamJobFail),
1906 #[prost(message, tag = "4")]
1907 DirtyStreamJobClear(EventDirtyStreamJobClear),
1908 #[prost(message, tag = "5")]
1909 MetaNodeStart(EventMetaNodeStart),
1910 #[prost(message, tag = "6")]
1911 BarrierComplete(EventBarrierComplete),
1912 #[prost(message, tag = "7")]
1913 InjectBarrierFail(EventInjectBarrierFail),
1914 #[prost(message, tag = "8")]
1915 CollectBarrierFail(EventCollectBarrierFail),
1916 #[prost(message, tag = "9")]
1917 WorkerNodePanic(EventWorkerNodePanic),
1918 #[prost(message, tag = "10")]
1919 AutoSchemaChangeFail(EventAutoSchemaChangeFail),
1920 #[prost(message, tag = "11")]
1921 SinkFail(EventSinkFail),
1922 #[prost(message, tag = "12")]
1923 Recovery(EventRecovery),
1924 }
1925}
1926#[derive(prost_helpers::AnyPB)]
1927#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1928pub struct ListEventLogRequest {}
1929#[derive(prost_helpers::AnyPB)]
1930#[derive(Clone, PartialEq, ::prost::Message)]
1931pub struct ListEventLogResponse {
1932 #[prost(message, repeated, tag = "1")]
1933 pub event_logs: ::prost::alloc::vec::Vec<EventLog>,
1934}
1935#[derive(prost_helpers::AnyPB)]
1936#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1937pub struct AddEventLogRequest {
1938 #[prost(oneof = "add_event_log_request::Event", tags = "1, 2, 3")]
1940 pub event: ::core::option::Option<add_event_log_request::Event>,
1941}
1942pub mod add_event_log_request {
1944 #[derive(prost_helpers::AnyPB)]
1946 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
1947 pub enum Event {
1948 #[prost(message, tag = "1")]
1949 WorkerNodePanic(super::event_log::EventWorkerNodePanic),
1950 #[prost(message, tag = "2")]
1951 SinkFail(super::event_log::EventSinkFail),
1952 #[prost(message, tag = "3")]
1953 AutoSchemaChangeFail(super::event_log::EventAutoSchemaChangeFail),
1954 }
1955}
1956#[derive(prost_helpers::AnyPB)]
1957#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1958pub struct AddEventLogResponse {}
1959#[derive(prost_helpers::AnyPB)]
1960#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1961pub struct ActorIds {
1962 #[prost(uint32, repeated, tag = "1", wrapper = "crate::id::ActorId")]
1963 pub ids: ::prost::alloc::vec::Vec<crate::id::ActorId>,
1964}
1965#[derive(prost_helpers::AnyPB)]
1966#[derive(Clone, PartialEq, ::prost::Message)]
1967pub struct FragmentIdToActorIdMap {
1968 #[prost(map = "uint32, message", tag = "1", wrapper = "crate::id::FragmentId")]
1969 pub map: ::std::collections::HashMap<crate::id::FragmentId, ActorIds>,
1970}
1971#[derive(prost_helpers::AnyPB)]
1976#[derive(Clone, PartialEq, ::prost::Message)]
1977pub struct RelationIdInfos {
1978 #[prost(map = "uint32, message", tag = "1")]
1980 pub map: ::std::collections::HashMap<u32, FragmentIdToActorIdMap>,
1981}
1982#[derive(prost_helpers::AnyPB)]
1983#[derive(Clone, PartialEq, ::prost::Message)]
1984pub struct FragmentToRelationMap {
1985 #[prost(
1987 map = "uint32, uint32",
1988 tag = "1",
1989 wrapper = "crate::id::FragmentId ->crate::id:: JobId"
1990 )]
1991 pub fragment_to_relation_map: ::std::collections::HashMap<
1992 crate::id::FragmentId,
1993 crate::id::JobId,
1994 >,
1995}
1996#[derive(prost_helpers::AnyPB)]
1997#[derive(Clone, PartialEq, ::prost::Message)]
1998pub struct ActorCountPerParallelism {
1999 #[prost(map = "uint32, message", tag = "1", wrapper = "crate::id::WorkerId")]
2000 pub worker_id_to_actor_count: ::std::collections::HashMap<
2001 crate::id::WorkerId,
2002 actor_count_per_parallelism::WorkerActorCount,
2003 >,
2004 #[prost(uint64, tag = "2")]
2005 pub hard_limit: u64,
2006 #[prost(uint64, tag = "3")]
2007 pub soft_limit: u64,
2008}
2009pub mod actor_count_per_parallelism {
2011 #[derive(prost_helpers::AnyPB)]
2012 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
2013 pub struct WorkerActorCount {
2014 #[prost(uint64, tag = "1")]
2015 pub actor_count: u64,
2016 #[prost(uint64, tag = "2")]
2017 pub parallelism: u64,
2018 }
2019}
2020#[derive(prost_helpers::AnyPB)]
2021#[derive(Clone, PartialEq, ::prost::Message)]
2022pub struct ClusterLimit {
2023 #[prost(oneof = "cluster_limit::Limit", tags = "1")]
2024 pub limit: ::core::option::Option<cluster_limit::Limit>,
2025}
2026pub mod cluster_limit {
2028 #[derive(prost_helpers::AnyPB)]
2029 #[derive(Clone, PartialEq, ::prost::Oneof)]
2030 pub enum Limit {
2031 #[prost(message, tag = "1")]
2033 ActorCount(super::ActorCountPerParallelism),
2034 }
2035}
2036#[derive(prost_helpers::AnyPB)]
2037#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
2038pub struct GetClusterLimitsRequest {}
2039#[derive(prost_helpers::AnyPB)]
2040#[derive(Clone, PartialEq, ::prost::Message)]
2041pub struct GetClusterLimitsResponse {
2042 #[prost(message, repeated, tag = "1")]
2043 pub active_limits: ::prost::alloc::vec::Vec<ClusterLimit>,
2044}
2045#[derive(prost_helpers::AnyPB)]
2046#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
2047pub struct ListRateLimitsRequest {}
2048#[derive(prost_helpers::AnyPB)]
2049#[derive(Clone, PartialEq, ::prost::Message)]
2050pub struct ListRateLimitsResponse {
2051 #[prost(message, repeated, tag = "1")]
2052 pub rate_limits: ::prost::alloc::vec::Vec<list_rate_limits_response::RateLimitInfo>,
2053}
2054pub mod list_rate_limits_response {
2056 #[derive(prost_helpers::AnyPB)]
2057 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
2058 pub struct RateLimitInfo {
2059 #[prost(uint32, tag = "1", wrapper = "crate::id::FragmentId")]
2060 pub fragment_id: crate::id::FragmentId,
2061 #[prost(uint32, tag = "2", wrapper = "crate::id::JobId")]
2062 pub job_id: crate::id::JobId,
2063 #[prost(uint32, tag = "3")]
2064 pub fragment_type_mask: u32,
2065 #[prost(uint32, tag = "4")]
2066 pub rate_limit: u32,
2067 #[prost(string, tag = "5")]
2068 pub node_name: ::prost::alloc::string::String,
2069 }
2070}
2071#[derive(prost_helpers::AnyPB)]
2072#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
2073pub struct ListIcebergTablesRequest {}
2074#[derive(prost_helpers::AnyPB)]
2075#[derive(Clone, PartialEq, ::prost::Message)]
2076pub struct ListIcebergTablesResponse {
2077 #[prost(message, repeated, tag = "1")]
2078 pub iceberg_tables: ::prost::alloc::vec::Vec<
2079 list_iceberg_tables_response::IcebergTable,
2080 >,
2081}
2082pub mod list_iceberg_tables_response {
2084 #[derive(prost_helpers::AnyPB)]
2085 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
2086 pub struct IcebergTable {
2087 #[prost(string, tag = "1")]
2088 pub catalog_name: ::prost::alloc::string::String,
2089 #[prost(string, tag = "2")]
2090 pub table_namespace: ::prost::alloc::string::String,
2091 #[prost(string, tag = "3")]
2092 pub table_name: ::prost::alloc::string::String,
2093 #[prost(string, optional, tag = "4")]
2094 pub metadata_location: ::core::option::Option<::prost::alloc::string::String>,
2095 #[prost(string, optional, tag = "5")]
2096 pub previous_metadata_location: ::core::option::Option<
2097 ::prost::alloc::string::String,
2098 >,
2099 #[prost(string, optional, tag = "6")]
2100 pub iceberg_type: ::core::option::Option<::prost::alloc::string::String>,
2101 }
2102}
2103#[derive(prost_helpers::AnyPB)]
2104#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
2105pub struct SetSyncLogStoreAlignedRequest {
2106 #[prost(uint32, tag = "1", wrapper = "crate::id::JobId")]
2107 pub job_id: crate::id::JobId,
2108 #[prost(bool, tag = "2")]
2109 pub aligned: bool,
2110}
2111#[derive(prost_helpers::AnyPB)]
2112#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
2113pub struct SetSyncLogStoreAlignedResponse {}
2114#[derive(prost_helpers::AnyPB)]
2115#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
2116pub struct ListUnmigratedTablesRequest {}
2117#[derive(prost_helpers::AnyPB)]
2118#[derive(Clone, PartialEq, ::prost::Message)]
2119pub struct ListUnmigratedTablesResponse {
2120 #[prost(message, repeated, tag = "1")]
2121 pub tables: ::prost::alloc::vec::Vec<
2122 list_unmigrated_tables_response::UnmigratedTable,
2123 >,
2124}
2125pub mod list_unmigrated_tables_response {
2127 #[derive(prost_helpers::AnyPB)]
2128 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
2129 pub struct UnmigratedTable {
2130 #[prost(uint32, tag = "1", wrapper = "crate::id::TableId")]
2131 pub table_id: crate::id::TableId,
2132 #[prost(string, tag = "2")]
2133 pub table_name: ::prost::alloc::string::String,
2134 }
2135}
2136#[derive(prost_helpers::AnyPB)]
2137#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2138#[repr(i32)]
2139pub enum ThrottleTarget {
2140 Unspecified = 0,
2141 Source = 1,
2142 Mv = 2,
2143 Table = 3,
2144 Sink = 4,
2145 Fragment = 5,
2146}
2147impl ThrottleTarget {
2148 pub fn as_str_name(&self) -> &'static str {
2153 match self {
2154 Self::Unspecified => "THROTTLE_TARGET_UNSPECIFIED",
2155 Self::Source => "SOURCE",
2156 Self::Mv => "MV",
2157 Self::Table => "TABLE",
2158 Self::Sink => "SINK",
2159 Self::Fragment => "FRAGMENT",
2160 }
2161 }
2162 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2164 match value {
2165 "THROTTLE_TARGET_UNSPECIFIED" => Some(Self::Unspecified),
2166 "SOURCE" => Some(Self::Source),
2167 "MV" => Some(Self::Mv),
2168 "TABLE" => Some(Self::Table),
2169 "SINK" => Some(Self::Sink),
2170 "FRAGMENT" => Some(Self::Fragment),
2171 _ => None,
2172 }
2173 }
2174}
2175#[derive(prost_helpers::AnyPB)]
2176#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2177#[repr(i32)]
2178pub enum RecoveryStatus {
2179 StatusUnspecified = 0,
2180 StatusStarting = 1,
2181 StatusRecovering = 2,
2182 StatusRunning = 3,
2183}
2184impl RecoveryStatus {
2185 pub fn as_str_name(&self) -> &'static str {
2190 match self {
2191 Self::StatusUnspecified => "STATUS_UNSPECIFIED",
2192 Self::StatusStarting => "STATUS_STARTING",
2193 Self::StatusRecovering => "STATUS_RECOVERING",
2194 Self::StatusRunning => "STATUS_RUNNING",
2195 }
2196 }
2197 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2199 match value {
2200 "STATUS_UNSPECIFIED" => Some(Self::StatusUnspecified),
2201 "STATUS_STARTING" => Some(Self::StatusStarting),
2202 "STATUS_RECOVERING" => Some(Self::StatusRecovering),
2203 "STATUS_RUNNING" => Some(Self::StatusRunning),
2204 _ => None,
2205 }
2206 }
2207}
2208#[derive(prost_helpers::AnyPB)]
2209#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2210#[repr(i32)]
2211pub enum SubscribeType {
2212 Unspecified = 0,
2213 Frontend = 1,
2214 Hummock = 2,
2215 Compactor = 3,
2216 Compute = 4,
2217}
2218impl SubscribeType {
2219 pub fn as_str_name(&self) -> &'static str {
2224 match self {
2225 Self::Unspecified => "UNSPECIFIED",
2226 Self::Frontend => "FRONTEND",
2227 Self::Hummock => "HUMMOCK",
2228 Self::Compactor => "COMPACTOR",
2229 Self::Compute => "COMPUTE",
2230 }
2231 }
2232 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2234 match value {
2235 "UNSPECIFIED" => Some(Self::Unspecified),
2236 "FRONTEND" => Some(Self::Frontend),
2237 "HUMMOCK" => Some(Self::Hummock),
2238 "COMPACTOR" => Some(Self::Compactor),
2239 "COMPUTE" => Some(Self::Compute),
2240 _ => None,
2241 }
2242 }
2243}
2244pub mod telemetry_info_service_client {
2246 #![allow(
2247 unused_variables,
2248 dead_code,
2249 missing_docs,
2250 clippy::wildcard_imports,
2251 clippy::let_unit_value,
2252 )]
2253 use tonic::codegen::*;
2254 use tonic::codegen::http::Uri;
2255 #[derive(Debug, Clone)]
2256 pub struct TelemetryInfoServiceClient<T> {
2257 inner: tonic::client::Grpc<T>,
2258 }
2259 impl TelemetryInfoServiceClient<tonic::transport::Channel> {
2260 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
2262 where
2263 D: TryInto<tonic::transport::Endpoint>,
2264 D::Error: Into<StdError>,
2265 {
2266 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
2267 Ok(Self::new(conn))
2268 }
2269 }
2270 impl<T> TelemetryInfoServiceClient<T>
2271 where
2272 T: tonic::client::GrpcService<tonic::body::Body>,
2273 T::Error: Into<StdError>,
2274 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
2275 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
2276 {
2277 pub fn new(inner: T) -> Self {
2278 let inner = tonic::client::Grpc::new(inner);
2279 Self { inner }
2280 }
2281 pub fn with_origin(inner: T, origin: Uri) -> Self {
2282 let inner = tonic::client::Grpc::with_origin(inner, origin);
2283 Self { inner }
2284 }
2285 pub fn with_interceptor<F>(
2286 inner: T,
2287 interceptor: F,
2288 ) -> TelemetryInfoServiceClient<InterceptedService<T, F>>
2289 where
2290 F: tonic::service::Interceptor,
2291 T::ResponseBody: Default,
2292 T: tonic::codegen::Service<
2293 http::Request<tonic::body::Body>,
2294 Response = http::Response<
2295 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
2296 >,
2297 >,
2298 <T as tonic::codegen::Service<
2299 http::Request<tonic::body::Body>,
2300 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
2301 {
2302 TelemetryInfoServiceClient::new(InterceptedService::new(inner, interceptor))
2303 }
2304 #[must_use]
2309 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
2310 self.inner = self.inner.send_compressed(encoding);
2311 self
2312 }
2313 #[must_use]
2315 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
2316 self.inner = self.inner.accept_compressed(encoding);
2317 self
2318 }
2319 #[must_use]
2323 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
2324 self.inner = self.inner.max_decoding_message_size(limit);
2325 self
2326 }
2327 #[must_use]
2331 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
2332 self.inner = self.inner.max_encoding_message_size(limit);
2333 self
2334 }
2335 pub async fn get_telemetry_info(
2337 &mut self,
2338 request: impl tonic::IntoRequest<super::GetTelemetryInfoRequest>,
2339 ) -> std::result::Result<
2340 tonic::Response<super::TelemetryInfoResponse>,
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_prost::ProstCodec::default();
2352 let path = http::uri::PathAndQuery::from_static(
2353 "/meta.TelemetryInfoService/GetTelemetryInfo",
2354 );
2355 let mut req = request.into_request();
2356 req.extensions_mut()
2357 .insert(
2358 GrpcMethod::new("meta.TelemetryInfoService", "GetTelemetryInfo"),
2359 );
2360 self.inner.unary(req, path, codec).await
2361 }
2362 }
2363}
2364pub mod telemetry_info_service_server {
2366 #![allow(
2367 unused_variables,
2368 dead_code,
2369 missing_docs,
2370 clippy::wildcard_imports,
2371 clippy::let_unit_value,
2372 )]
2373 use tonic::codegen::*;
2374 #[async_trait]
2376 pub trait TelemetryInfoService: std::marker::Send + std::marker::Sync + 'static {
2377 async fn get_telemetry_info(
2379 &self,
2380 request: tonic::Request<super::GetTelemetryInfoRequest>,
2381 ) -> std::result::Result<
2382 tonic::Response<super::TelemetryInfoResponse>,
2383 tonic::Status,
2384 >;
2385 }
2386 #[derive(Debug)]
2387 pub struct TelemetryInfoServiceServer<T> {
2388 inner: Arc<T>,
2389 accept_compression_encodings: EnabledCompressionEncodings,
2390 send_compression_encodings: EnabledCompressionEncodings,
2391 max_decoding_message_size: Option<usize>,
2392 max_encoding_message_size: Option<usize>,
2393 }
2394 impl<T> TelemetryInfoServiceServer<T> {
2395 pub fn new(inner: T) -> Self {
2396 Self::from_arc(Arc::new(inner))
2397 }
2398 pub fn from_arc(inner: Arc<T>) -> Self {
2399 Self {
2400 inner,
2401 accept_compression_encodings: Default::default(),
2402 send_compression_encodings: Default::default(),
2403 max_decoding_message_size: None,
2404 max_encoding_message_size: None,
2405 }
2406 }
2407 pub fn with_interceptor<F>(
2408 inner: T,
2409 interceptor: F,
2410 ) -> InterceptedService<Self, F>
2411 where
2412 F: tonic::service::Interceptor,
2413 {
2414 InterceptedService::new(Self::new(inner), interceptor)
2415 }
2416 #[must_use]
2418 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
2419 self.accept_compression_encodings.enable(encoding);
2420 self
2421 }
2422 #[must_use]
2424 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
2425 self.send_compression_encodings.enable(encoding);
2426 self
2427 }
2428 #[must_use]
2432 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
2433 self.max_decoding_message_size = Some(limit);
2434 self
2435 }
2436 #[must_use]
2440 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
2441 self.max_encoding_message_size = Some(limit);
2442 self
2443 }
2444 }
2445 impl<T, B> tonic::codegen::Service<http::Request<B>>
2446 for TelemetryInfoServiceServer<T>
2447 where
2448 T: TelemetryInfoService,
2449 B: Body + std::marker::Send + 'static,
2450 B::Error: Into<StdError> + std::marker::Send + 'static,
2451 {
2452 type Response = http::Response<tonic::body::Body>;
2453 type Error = std::convert::Infallible;
2454 type Future = BoxFuture<Self::Response, Self::Error>;
2455 fn poll_ready(
2456 &mut self,
2457 _cx: &mut Context<'_>,
2458 ) -> Poll<std::result::Result<(), Self::Error>> {
2459 Poll::Ready(Ok(()))
2460 }
2461 fn call(&mut self, req: http::Request<B>) -> Self::Future {
2462 match req.uri().path() {
2463 "/meta.TelemetryInfoService/GetTelemetryInfo" => {
2464 #[allow(non_camel_case_types)]
2465 struct GetTelemetryInfoSvc<T: TelemetryInfoService>(pub Arc<T>);
2466 impl<
2467 T: TelemetryInfoService,
2468 > tonic::server::UnaryService<super::GetTelemetryInfoRequest>
2469 for GetTelemetryInfoSvc<T> {
2470 type Response = super::TelemetryInfoResponse;
2471 type Future = BoxFuture<
2472 tonic::Response<Self::Response>,
2473 tonic::Status,
2474 >;
2475 fn call(
2476 &mut self,
2477 request: tonic::Request<super::GetTelemetryInfoRequest>,
2478 ) -> Self::Future {
2479 let inner = Arc::clone(&self.0);
2480 let fut = async move {
2481 <T as TelemetryInfoService>::get_telemetry_info(
2482 &inner,
2483 request,
2484 )
2485 .await
2486 };
2487 Box::pin(fut)
2488 }
2489 }
2490 let accept_compression_encodings = self.accept_compression_encodings;
2491 let send_compression_encodings = self.send_compression_encodings;
2492 let max_decoding_message_size = self.max_decoding_message_size;
2493 let max_encoding_message_size = self.max_encoding_message_size;
2494 let inner = self.inner.clone();
2495 let fut = async move {
2496 let method = GetTelemetryInfoSvc(inner);
2497 let codec = tonic_prost::ProstCodec::default();
2498 let mut grpc = tonic::server::Grpc::new(codec)
2499 .apply_compression_config(
2500 accept_compression_encodings,
2501 send_compression_encodings,
2502 )
2503 .apply_max_message_size_config(
2504 max_decoding_message_size,
2505 max_encoding_message_size,
2506 );
2507 let res = grpc.unary(method, req).await;
2508 Ok(res)
2509 };
2510 Box::pin(fut)
2511 }
2512 _ => {
2513 Box::pin(async move {
2514 let mut response = http::Response::new(
2515 tonic::body::Body::default(),
2516 );
2517 let headers = response.headers_mut();
2518 headers
2519 .insert(
2520 tonic::Status::GRPC_STATUS,
2521 (tonic::Code::Unimplemented as i32).into(),
2522 );
2523 headers
2524 .insert(
2525 http::header::CONTENT_TYPE,
2526 tonic::metadata::GRPC_CONTENT_TYPE,
2527 );
2528 Ok(response)
2529 })
2530 }
2531 }
2532 }
2533 }
2534 impl<T> Clone for TelemetryInfoServiceServer<T> {
2535 fn clone(&self) -> Self {
2536 let inner = self.inner.clone();
2537 Self {
2538 inner,
2539 accept_compression_encodings: self.accept_compression_encodings,
2540 send_compression_encodings: self.send_compression_encodings,
2541 max_decoding_message_size: self.max_decoding_message_size,
2542 max_encoding_message_size: self.max_encoding_message_size,
2543 }
2544 }
2545 }
2546 pub const SERVICE_NAME: &str = "meta.TelemetryInfoService";
2548 impl<T> tonic::server::NamedService for TelemetryInfoServiceServer<T> {
2549 const NAME: &'static str = SERVICE_NAME;
2550 }
2551}
2552pub mod heartbeat_service_client {
2554 #![allow(
2555 unused_variables,
2556 dead_code,
2557 missing_docs,
2558 clippy::wildcard_imports,
2559 clippy::let_unit_value,
2560 )]
2561 use tonic::codegen::*;
2562 use tonic::codegen::http::Uri;
2563 #[derive(Debug, Clone)]
2564 pub struct HeartbeatServiceClient<T> {
2565 inner: tonic::client::Grpc<T>,
2566 }
2567 impl HeartbeatServiceClient<tonic::transport::Channel> {
2568 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
2570 where
2571 D: TryInto<tonic::transport::Endpoint>,
2572 D::Error: Into<StdError>,
2573 {
2574 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
2575 Ok(Self::new(conn))
2576 }
2577 }
2578 impl<T> HeartbeatServiceClient<T>
2579 where
2580 T: tonic::client::GrpcService<tonic::body::Body>,
2581 T::Error: Into<StdError>,
2582 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
2583 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
2584 {
2585 pub fn new(inner: T) -> Self {
2586 let inner = tonic::client::Grpc::new(inner);
2587 Self { inner }
2588 }
2589 pub fn with_origin(inner: T, origin: Uri) -> Self {
2590 let inner = tonic::client::Grpc::with_origin(inner, origin);
2591 Self { inner }
2592 }
2593 pub fn with_interceptor<F>(
2594 inner: T,
2595 interceptor: F,
2596 ) -> HeartbeatServiceClient<InterceptedService<T, F>>
2597 where
2598 F: tonic::service::Interceptor,
2599 T::ResponseBody: Default,
2600 T: tonic::codegen::Service<
2601 http::Request<tonic::body::Body>,
2602 Response = http::Response<
2603 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
2604 >,
2605 >,
2606 <T as tonic::codegen::Service<
2607 http::Request<tonic::body::Body>,
2608 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
2609 {
2610 HeartbeatServiceClient::new(InterceptedService::new(inner, interceptor))
2611 }
2612 #[must_use]
2617 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
2618 self.inner = self.inner.send_compressed(encoding);
2619 self
2620 }
2621 #[must_use]
2623 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
2624 self.inner = self.inner.accept_compressed(encoding);
2625 self
2626 }
2627 #[must_use]
2631 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
2632 self.inner = self.inner.max_decoding_message_size(limit);
2633 self
2634 }
2635 #[must_use]
2639 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
2640 self.inner = self.inner.max_encoding_message_size(limit);
2641 self
2642 }
2643 pub async fn heartbeat(
2644 &mut self,
2645 request: impl tonic::IntoRequest<super::HeartbeatRequest>,
2646 ) -> std::result::Result<
2647 tonic::Response<super::HeartbeatResponse>,
2648 tonic::Status,
2649 > {
2650 self.inner
2651 .ready()
2652 .await
2653 .map_err(|e| {
2654 tonic::Status::unknown(
2655 format!("Service was not ready: {}", e.into()),
2656 )
2657 })?;
2658 let codec = tonic_prost::ProstCodec::default();
2659 let path = http::uri::PathAndQuery::from_static(
2660 "/meta.HeartbeatService/Heartbeat",
2661 );
2662 let mut req = request.into_request();
2663 req.extensions_mut()
2664 .insert(GrpcMethod::new("meta.HeartbeatService", "Heartbeat"));
2665 self.inner.unary(req, path, codec).await
2666 }
2667 }
2668}
2669pub mod heartbeat_service_server {
2671 #![allow(
2672 unused_variables,
2673 dead_code,
2674 missing_docs,
2675 clippy::wildcard_imports,
2676 clippy::let_unit_value,
2677 )]
2678 use tonic::codegen::*;
2679 #[async_trait]
2681 pub trait HeartbeatService: std::marker::Send + std::marker::Sync + 'static {
2682 async fn heartbeat(
2683 &self,
2684 request: tonic::Request<super::HeartbeatRequest>,
2685 ) -> std::result::Result<
2686 tonic::Response<super::HeartbeatResponse>,
2687 tonic::Status,
2688 >;
2689 }
2690 #[derive(Debug)]
2691 pub struct HeartbeatServiceServer<T> {
2692 inner: Arc<T>,
2693 accept_compression_encodings: EnabledCompressionEncodings,
2694 send_compression_encodings: EnabledCompressionEncodings,
2695 max_decoding_message_size: Option<usize>,
2696 max_encoding_message_size: Option<usize>,
2697 }
2698 impl<T> HeartbeatServiceServer<T> {
2699 pub fn new(inner: T) -> Self {
2700 Self::from_arc(Arc::new(inner))
2701 }
2702 pub fn from_arc(inner: Arc<T>) -> Self {
2703 Self {
2704 inner,
2705 accept_compression_encodings: Default::default(),
2706 send_compression_encodings: Default::default(),
2707 max_decoding_message_size: None,
2708 max_encoding_message_size: None,
2709 }
2710 }
2711 pub fn with_interceptor<F>(
2712 inner: T,
2713 interceptor: F,
2714 ) -> InterceptedService<Self, F>
2715 where
2716 F: tonic::service::Interceptor,
2717 {
2718 InterceptedService::new(Self::new(inner), interceptor)
2719 }
2720 #[must_use]
2722 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
2723 self.accept_compression_encodings.enable(encoding);
2724 self
2725 }
2726 #[must_use]
2728 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
2729 self.send_compression_encodings.enable(encoding);
2730 self
2731 }
2732 #[must_use]
2736 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
2737 self.max_decoding_message_size = Some(limit);
2738 self
2739 }
2740 #[must_use]
2744 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
2745 self.max_encoding_message_size = Some(limit);
2746 self
2747 }
2748 }
2749 impl<T, B> tonic::codegen::Service<http::Request<B>> for HeartbeatServiceServer<T>
2750 where
2751 T: HeartbeatService,
2752 B: Body + std::marker::Send + 'static,
2753 B::Error: Into<StdError> + std::marker::Send + 'static,
2754 {
2755 type Response = http::Response<tonic::body::Body>;
2756 type Error = std::convert::Infallible;
2757 type Future = BoxFuture<Self::Response, Self::Error>;
2758 fn poll_ready(
2759 &mut self,
2760 _cx: &mut Context<'_>,
2761 ) -> Poll<std::result::Result<(), Self::Error>> {
2762 Poll::Ready(Ok(()))
2763 }
2764 fn call(&mut self, req: http::Request<B>) -> Self::Future {
2765 match req.uri().path() {
2766 "/meta.HeartbeatService/Heartbeat" => {
2767 #[allow(non_camel_case_types)]
2768 struct HeartbeatSvc<T: HeartbeatService>(pub Arc<T>);
2769 impl<
2770 T: HeartbeatService,
2771 > tonic::server::UnaryService<super::HeartbeatRequest>
2772 for HeartbeatSvc<T> {
2773 type Response = super::HeartbeatResponse;
2774 type Future = BoxFuture<
2775 tonic::Response<Self::Response>,
2776 tonic::Status,
2777 >;
2778 fn call(
2779 &mut self,
2780 request: tonic::Request<super::HeartbeatRequest>,
2781 ) -> Self::Future {
2782 let inner = Arc::clone(&self.0);
2783 let fut = async move {
2784 <T as HeartbeatService>::heartbeat(&inner, request).await
2785 };
2786 Box::pin(fut)
2787 }
2788 }
2789 let accept_compression_encodings = self.accept_compression_encodings;
2790 let send_compression_encodings = self.send_compression_encodings;
2791 let max_decoding_message_size = self.max_decoding_message_size;
2792 let max_encoding_message_size = self.max_encoding_message_size;
2793 let inner = self.inner.clone();
2794 let fut = async move {
2795 let method = HeartbeatSvc(inner);
2796 let codec = tonic_prost::ProstCodec::default();
2797 let mut grpc = tonic::server::Grpc::new(codec)
2798 .apply_compression_config(
2799 accept_compression_encodings,
2800 send_compression_encodings,
2801 )
2802 .apply_max_message_size_config(
2803 max_decoding_message_size,
2804 max_encoding_message_size,
2805 );
2806 let res = grpc.unary(method, req).await;
2807 Ok(res)
2808 };
2809 Box::pin(fut)
2810 }
2811 _ => {
2812 Box::pin(async move {
2813 let mut response = http::Response::new(
2814 tonic::body::Body::default(),
2815 );
2816 let headers = response.headers_mut();
2817 headers
2818 .insert(
2819 tonic::Status::GRPC_STATUS,
2820 (tonic::Code::Unimplemented as i32).into(),
2821 );
2822 headers
2823 .insert(
2824 http::header::CONTENT_TYPE,
2825 tonic::metadata::GRPC_CONTENT_TYPE,
2826 );
2827 Ok(response)
2828 })
2829 }
2830 }
2831 }
2832 }
2833 impl<T> Clone for HeartbeatServiceServer<T> {
2834 fn clone(&self) -> Self {
2835 let inner = self.inner.clone();
2836 Self {
2837 inner,
2838 accept_compression_encodings: self.accept_compression_encodings,
2839 send_compression_encodings: self.send_compression_encodings,
2840 max_decoding_message_size: self.max_decoding_message_size,
2841 max_encoding_message_size: self.max_encoding_message_size,
2842 }
2843 }
2844 }
2845 pub const SERVICE_NAME: &str = "meta.HeartbeatService";
2847 impl<T> tonic::server::NamedService for HeartbeatServiceServer<T> {
2848 const NAME: &'static str = SERVICE_NAME;
2849 }
2850}
2851pub mod stream_manager_service_client {
2853 #![allow(
2854 unused_variables,
2855 dead_code,
2856 missing_docs,
2857 clippy::wildcard_imports,
2858 clippy::let_unit_value,
2859 )]
2860 use tonic::codegen::*;
2861 use tonic::codegen::http::Uri;
2862 #[derive(Debug, Clone)]
2863 pub struct StreamManagerServiceClient<T> {
2864 inner: tonic::client::Grpc<T>,
2865 }
2866 impl StreamManagerServiceClient<tonic::transport::Channel> {
2867 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
2869 where
2870 D: TryInto<tonic::transport::Endpoint>,
2871 D::Error: Into<StdError>,
2872 {
2873 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
2874 Ok(Self::new(conn))
2875 }
2876 }
2877 impl<T> StreamManagerServiceClient<T>
2878 where
2879 T: tonic::client::GrpcService<tonic::body::Body>,
2880 T::Error: Into<StdError>,
2881 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
2882 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
2883 {
2884 pub fn new(inner: T) -> Self {
2885 let inner = tonic::client::Grpc::new(inner);
2886 Self { inner }
2887 }
2888 pub fn with_origin(inner: T, origin: Uri) -> Self {
2889 let inner = tonic::client::Grpc::with_origin(inner, origin);
2890 Self { inner }
2891 }
2892 pub fn with_interceptor<F>(
2893 inner: T,
2894 interceptor: F,
2895 ) -> StreamManagerServiceClient<InterceptedService<T, F>>
2896 where
2897 F: tonic::service::Interceptor,
2898 T::ResponseBody: Default,
2899 T: tonic::codegen::Service<
2900 http::Request<tonic::body::Body>,
2901 Response = http::Response<
2902 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
2903 >,
2904 >,
2905 <T as tonic::codegen::Service<
2906 http::Request<tonic::body::Body>,
2907 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
2908 {
2909 StreamManagerServiceClient::new(InterceptedService::new(inner, interceptor))
2910 }
2911 #[must_use]
2916 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
2917 self.inner = self.inner.send_compressed(encoding);
2918 self
2919 }
2920 #[must_use]
2922 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
2923 self.inner = self.inner.accept_compressed(encoding);
2924 self
2925 }
2926 #[must_use]
2930 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
2931 self.inner = self.inner.max_decoding_message_size(limit);
2932 self
2933 }
2934 #[must_use]
2938 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
2939 self.inner = self.inner.max_encoding_message_size(limit);
2940 self
2941 }
2942 pub async fn flush(
2943 &mut self,
2944 request: impl tonic::IntoRequest<super::FlushRequest>,
2945 ) -> std::result::Result<tonic::Response<super::FlushResponse>, tonic::Status> {
2946 self.inner
2947 .ready()
2948 .await
2949 .map_err(|e| {
2950 tonic::Status::unknown(
2951 format!("Service was not ready: {}", e.into()),
2952 )
2953 })?;
2954 let codec = tonic_prost::ProstCodec::default();
2955 let path = http::uri::PathAndQuery::from_static(
2956 "/meta.StreamManagerService/Flush",
2957 );
2958 let mut req = request.into_request();
2959 req.extensions_mut()
2960 .insert(GrpcMethod::new("meta.StreamManagerService", "Flush"));
2961 self.inner.unary(req, path, codec).await
2962 }
2963 pub async fn pause(
2964 &mut self,
2965 request: impl tonic::IntoRequest<super::PauseRequest>,
2966 ) -> std::result::Result<tonic::Response<super::PauseResponse>, tonic::Status> {
2967 self.inner
2968 .ready()
2969 .await
2970 .map_err(|e| {
2971 tonic::Status::unknown(
2972 format!("Service was not ready: {}", e.into()),
2973 )
2974 })?;
2975 let codec = tonic_prost::ProstCodec::default();
2976 let path = http::uri::PathAndQuery::from_static(
2977 "/meta.StreamManagerService/Pause",
2978 );
2979 let mut req = request.into_request();
2980 req.extensions_mut()
2981 .insert(GrpcMethod::new("meta.StreamManagerService", "Pause"));
2982 self.inner.unary(req, path, codec).await
2983 }
2984 pub async fn resume(
2985 &mut self,
2986 request: impl tonic::IntoRequest<super::ResumeRequest>,
2987 ) -> std::result::Result<tonic::Response<super::ResumeResponse>, tonic::Status> {
2988 self.inner
2989 .ready()
2990 .await
2991 .map_err(|e| {
2992 tonic::Status::unknown(
2993 format!("Service was not ready: {}", e.into()),
2994 )
2995 })?;
2996 let codec = tonic_prost::ProstCodec::default();
2997 let path = http::uri::PathAndQuery::from_static(
2998 "/meta.StreamManagerService/Resume",
2999 );
3000 let mut req = request.into_request();
3001 req.extensions_mut()
3002 .insert(GrpcMethod::new("meta.StreamManagerService", "Resume"));
3003 self.inner.unary(req, path, codec).await
3004 }
3005 pub async fn refresh(
3006 &mut self,
3007 request: impl tonic::IntoRequest<super::RefreshRequest>,
3008 ) -> std::result::Result<
3009 tonic::Response<super::RefreshResponse>,
3010 tonic::Status,
3011 > {
3012 self.inner
3013 .ready()
3014 .await
3015 .map_err(|e| {
3016 tonic::Status::unknown(
3017 format!("Service was not ready: {}", e.into()),
3018 )
3019 })?;
3020 let codec = tonic_prost::ProstCodec::default();
3021 let path = http::uri::PathAndQuery::from_static(
3022 "/meta.StreamManagerService/Refresh",
3023 );
3024 let mut req = request.into_request();
3025 req.extensions_mut()
3026 .insert(GrpcMethod::new("meta.StreamManagerService", "Refresh"));
3027 self.inner.unary(req, path, codec).await
3028 }
3029 pub async fn cancel_creating_jobs(
3030 &mut self,
3031 request: impl tonic::IntoRequest<super::CancelCreatingJobsRequest>,
3032 ) -> std::result::Result<
3033 tonic::Response<super::CancelCreatingJobsResponse>,
3034 tonic::Status,
3035 > {
3036 self.inner
3037 .ready()
3038 .await
3039 .map_err(|e| {
3040 tonic::Status::unknown(
3041 format!("Service was not ready: {}", e.into()),
3042 )
3043 })?;
3044 let codec = tonic_prost::ProstCodec::default();
3045 let path = http::uri::PathAndQuery::from_static(
3046 "/meta.StreamManagerService/CancelCreatingJobs",
3047 );
3048 let mut req = request.into_request();
3049 req.extensions_mut()
3050 .insert(
3051 GrpcMethod::new("meta.StreamManagerService", "CancelCreatingJobs"),
3052 );
3053 self.inner.unary(req, path, codec).await
3054 }
3055 pub async fn list_table_fragments(
3056 &mut self,
3057 request: impl tonic::IntoRequest<super::ListTableFragmentsRequest>,
3058 ) -> std::result::Result<
3059 tonic::Response<super::ListTableFragmentsResponse>,
3060 tonic::Status,
3061 > {
3062 self.inner
3063 .ready()
3064 .await
3065 .map_err(|e| {
3066 tonic::Status::unknown(
3067 format!("Service was not ready: {}", e.into()),
3068 )
3069 })?;
3070 let codec = tonic_prost::ProstCodec::default();
3071 let path = http::uri::PathAndQuery::from_static(
3072 "/meta.StreamManagerService/ListTableFragments",
3073 );
3074 let mut req = request.into_request();
3075 req.extensions_mut()
3076 .insert(
3077 GrpcMethod::new("meta.StreamManagerService", "ListTableFragments"),
3078 );
3079 self.inner.unary(req, path, codec).await
3080 }
3081 pub async fn list_streaming_job_states(
3082 &mut self,
3083 request: impl tonic::IntoRequest<super::ListStreamingJobStatesRequest>,
3084 ) -> std::result::Result<
3085 tonic::Response<super::ListStreamingJobStatesResponse>,
3086 tonic::Status,
3087 > {
3088 self.inner
3089 .ready()
3090 .await
3091 .map_err(|e| {
3092 tonic::Status::unknown(
3093 format!("Service was not ready: {}", e.into()),
3094 )
3095 })?;
3096 let codec = tonic_prost::ProstCodec::default();
3097 let path = http::uri::PathAndQuery::from_static(
3098 "/meta.StreamManagerService/ListStreamingJobStates",
3099 );
3100 let mut req = request.into_request();
3101 req.extensions_mut()
3102 .insert(
3103 GrpcMethod::new(
3104 "meta.StreamManagerService",
3105 "ListStreamingJobStates",
3106 ),
3107 );
3108 self.inner.unary(req, path, codec).await
3109 }
3110 pub async fn list_fragment_distribution(
3111 &mut self,
3112 request: impl tonic::IntoRequest<super::ListFragmentDistributionRequest>,
3113 ) -> std::result::Result<
3114 tonic::Response<super::ListFragmentDistributionResponse>,
3115 tonic::Status,
3116 > {
3117 self.inner
3118 .ready()
3119 .await
3120 .map_err(|e| {
3121 tonic::Status::unknown(
3122 format!("Service was not ready: {}", e.into()),
3123 )
3124 })?;
3125 let codec = tonic_prost::ProstCodec::default();
3126 let path = http::uri::PathAndQuery::from_static(
3127 "/meta.StreamManagerService/ListFragmentDistribution",
3128 );
3129 let mut req = request.into_request();
3130 req.extensions_mut()
3131 .insert(
3132 GrpcMethod::new(
3133 "meta.StreamManagerService",
3134 "ListFragmentDistribution",
3135 ),
3136 );
3137 self.inner.unary(req, path, codec).await
3138 }
3139 pub async fn list_creating_fragment_distribution(
3140 &mut self,
3141 request: impl tonic::IntoRequest<
3142 super::ListCreatingFragmentDistributionRequest,
3143 >,
3144 ) -> std::result::Result<
3145 tonic::Response<super::ListCreatingFragmentDistributionResponse>,
3146 tonic::Status,
3147 > {
3148 self.inner
3149 .ready()
3150 .await
3151 .map_err(|e| {
3152 tonic::Status::unknown(
3153 format!("Service was not ready: {}", e.into()),
3154 )
3155 })?;
3156 let codec = tonic_prost::ProstCodec::default();
3157 let path = http::uri::PathAndQuery::from_static(
3158 "/meta.StreamManagerService/ListCreatingFragmentDistribution",
3159 );
3160 let mut req = request.into_request();
3161 req.extensions_mut()
3162 .insert(
3163 GrpcMethod::new(
3164 "meta.StreamManagerService",
3165 "ListCreatingFragmentDistribution",
3166 ),
3167 );
3168 self.inner.unary(req, path, codec).await
3169 }
3170 pub async fn list_sink_log_store_tables(
3171 &mut self,
3172 request: impl tonic::IntoRequest<super::ListSinkLogStoreTablesRequest>,
3173 ) -> std::result::Result<
3174 tonic::Response<super::ListSinkLogStoreTablesResponse>,
3175 tonic::Status,
3176 > {
3177 self.inner
3178 .ready()
3179 .await
3180 .map_err(|e| {
3181 tonic::Status::unknown(
3182 format!("Service was not ready: {}", e.into()),
3183 )
3184 })?;
3185 let codec = tonic_prost::ProstCodec::default();
3186 let path = http::uri::PathAndQuery::from_static(
3187 "/meta.StreamManagerService/ListSinkLogStoreTables",
3188 );
3189 let mut req = request.into_request();
3190 req.extensions_mut()
3191 .insert(
3192 GrpcMethod::new(
3193 "meta.StreamManagerService",
3194 "ListSinkLogStoreTables",
3195 ),
3196 );
3197 self.inner.unary(req, path, codec).await
3198 }
3199 pub async fn list_actor_states(
3200 &mut self,
3201 request: impl tonic::IntoRequest<super::ListActorStatesRequest>,
3202 ) -> std::result::Result<
3203 tonic::Response<super::ListActorStatesResponse>,
3204 tonic::Status,
3205 > {
3206 self.inner
3207 .ready()
3208 .await
3209 .map_err(|e| {
3210 tonic::Status::unknown(
3211 format!("Service was not ready: {}", e.into()),
3212 )
3213 })?;
3214 let codec = tonic_prost::ProstCodec::default();
3215 let path = http::uri::PathAndQuery::from_static(
3216 "/meta.StreamManagerService/ListActorStates",
3217 );
3218 let mut req = request.into_request();
3219 req.extensions_mut()
3220 .insert(GrpcMethod::new("meta.StreamManagerService", "ListActorStates"));
3221 self.inner.unary(req, path, codec).await
3222 }
3223 pub async fn list_actor_splits(
3224 &mut self,
3225 request: impl tonic::IntoRequest<super::ListActorSplitsRequest>,
3226 ) -> std::result::Result<
3227 tonic::Response<super::ListActorSplitsResponse>,
3228 tonic::Status,
3229 > {
3230 self.inner
3231 .ready()
3232 .await
3233 .map_err(|e| {
3234 tonic::Status::unknown(
3235 format!("Service was not ready: {}", e.into()),
3236 )
3237 })?;
3238 let codec = tonic_prost::ProstCodec::default();
3239 let path = http::uri::PathAndQuery::from_static(
3240 "/meta.StreamManagerService/ListActorSplits",
3241 );
3242 let mut req = request.into_request();
3243 req.extensions_mut()
3244 .insert(GrpcMethod::new("meta.StreamManagerService", "ListActorSplits"));
3245 self.inner.unary(req, path, codec).await
3246 }
3247 pub async fn apply_throttle(
3248 &mut self,
3249 request: impl tonic::IntoRequest<super::ApplyThrottleRequest>,
3250 ) -> std::result::Result<
3251 tonic::Response<super::ApplyThrottleResponse>,
3252 tonic::Status,
3253 > {
3254 self.inner
3255 .ready()
3256 .await
3257 .map_err(|e| {
3258 tonic::Status::unknown(
3259 format!("Service was not ready: {}", e.into()),
3260 )
3261 })?;
3262 let codec = tonic_prost::ProstCodec::default();
3263 let path = http::uri::PathAndQuery::from_static(
3264 "/meta.StreamManagerService/ApplyThrottle",
3265 );
3266 let mut req = request.into_request();
3267 req.extensions_mut()
3268 .insert(GrpcMethod::new("meta.StreamManagerService", "ApplyThrottle"));
3269 self.inner.unary(req, path, codec).await
3270 }
3271 pub async fn recover(
3272 &mut self,
3273 request: impl tonic::IntoRequest<super::RecoverRequest>,
3274 ) -> std::result::Result<
3275 tonic::Response<super::RecoverResponse>,
3276 tonic::Status,
3277 > {
3278 self.inner
3279 .ready()
3280 .await
3281 .map_err(|e| {
3282 tonic::Status::unknown(
3283 format!("Service was not ready: {}", e.into()),
3284 )
3285 })?;
3286 let codec = tonic_prost::ProstCodec::default();
3287 let path = http::uri::PathAndQuery::from_static(
3288 "/meta.StreamManagerService/Recover",
3289 );
3290 let mut req = request.into_request();
3291 req.extensions_mut()
3292 .insert(GrpcMethod::new("meta.StreamManagerService", "Recover"));
3293 self.inner.unary(req, path, codec).await
3294 }
3295 pub async fn list_rate_limits(
3296 &mut self,
3297 request: impl tonic::IntoRequest<super::ListRateLimitsRequest>,
3298 ) -> std::result::Result<
3299 tonic::Response<super::ListRateLimitsResponse>,
3300 tonic::Status,
3301 > {
3302 self.inner
3303 .ready()
3304 .await
3305 .map_err(|e| {
3306 tonic::Status::unknown(
3307 format!("Service was not ready: {}", e.into()),
3308 )
3309 })?;
3310 let codec = tonic_prost::ProstCodec::default();
3311 let path = http::uri::PathAndQuery::from_static(
3312 "/meta.StreamManagerService/ListRateLimits",
3313 );
3314 let mut req = request.into_request();
3315 req.extensions_mut()
3316 .insert(GrpcMethod::new("meta.StreamManagerService", "ListRateLimits"));
3317 self.inner.unary(req, path, codec).await
3318 }
3319 pub async fn alter_connector_props(
3320 &mut self,
3321 request: impl tonic::IntoRequest<super::AlterConnectorPropsRequest>,
3322 ) -> std::result::Result<
3323 tonic::Response<super::AlterConnectorPropsResponse>,
3324 tonic::Status,
3325 > {
3326 self.inner
3327 .ready()
3328 .await
3329 .map_err(|e| {
3330 tonic::Status::unknown(
3331 format!("Service was not ready: {}", e.into()),
3332 )
3333 })?;
3334 let codec = tonic_prost::ProstCodec::default();
3335 let path = http::uri::PathAndQuery::from_static(
3336 "/meta.StreamManagerService/AlterConnectorProps",
3337 );
3338 let mut req = request.into_request();
3339 req.extensions_mut()
3340 .insert(
3341 GrpcMethod::new("meta.StreamManagerService", "AlterConnectorProps"),
3342 );
3343 self.inner.unary(req, path, codec).await
3344 }
3345 pub async fn alter_source_properties_safe(
3346 &mut self,
3347 request: impl tonic::IntoRequest<super::AlterSourcePropertiesSafeRequest>,
3348 ) -> std::result::Result<
3349 tonic::Response<super::AlterSourcePropertiesSafeResponse>,
3350 tonic::Status,
3351 > {
3352 self.inner
3353 .ready()
3354 .await
3355 .map_err(|e| {
3356 tonic::Status::unknown(
3357 format!("Service was not ready: {}", e.into()),
3358 )
3359 })?;
3360 let codec = tonic_prost::ProstCodec::default();
3361 let path = http::uri::PathAndQuery::from_static(
3362 "/meta.StreamManagerService/AlterSourcePropertiesSafe",
3363 );
3364 let mut req = request.into_request();
3365 req.extensions_mut()
3366 .insert(
3367 GrpcMethod::new(
3368 "meta.StreamManagerService",
3369 "AlterSourcePropertiesSafe",
3370 ),
3371 );
3372 self.inner.unary(req, path, codec).await
3373 }
3374 pub async fn reset_source_splits(
3375 &mut self,
3376 request: impl tonic::IntoRequest<super::ResetSourceSplitsRequest>,
3377 ) -> std::result::Result<
3378 tonic::Response<super::ResetSourceSplitsResponse>,
3379 tonic::Status,
3380 > {
3381 self.inner
3382 .ready()
3383 .await
3384 .map_err(|e| {
3385 tonic::Status::unknown(
3386 format!("Service was not ready: {}", e.into()),
3387 )
3388 })?;
3389 let codec = tonic_prost::ProstCodec::default();
3390 let path = http::uri::PathAndQuery::from_static(
3391 "/meta.StreamManagerService/ResetSourceSplits",
3392 );
3393 let mut req = request.into_request();
3394 req.extensions_mut()
3395 .insert(
3396 GrpcMethod::new("meta.StreamManagerService", "ResetSourceSplits"),
3397 );
3398 self.inner.unary(req, path, codec).await
3399 }
3400 pub async fn inject_source_offsets(
3401 &mut self,
3402 request: impl tonic::IntoRequest<super::InjectSourceOffsetsRequest>,
3403 ) -> std::result::Result<
3404 tonic::Response<super::InjectSourceOffsetsResponse>,
3405 tonic::Status,
3406 > {
3407 self.inner
3408 .ready()
3409 .await
3410 .map_err(|e| {
3411 tonic::Status::unknown(
3412 format!("Service was not ready: {}", e.into()),
3413 )
3414 })?;
3415 let codec = tonic_prost::ProstCodec::default();
3416 let path = http::uri::PathAndQuery::from_static(
3417 "/meta.StreamManagerService/InjectSourceOffsets",
3418 );
3419 let mut req = request.into_request();
3420 req.extensions_mut()
3421 .insert(
3422 GrpcMethod::new("meta.StreamManagerService", "InjectSourceOffsets"),
3423 );
3424 self.inner.unary(req, path, codec).await
3425 }
3426 pub async fn get_fragment_by_id(
3427 &mut self,
3428 request: impl tonic::IntoRequest<super::GetFragmentByIdRequest>,
3429 ) -> std::result::Result<
3430 tonic::Response<super::GetFragmentByIdResponse>,
3431 tonic::Status,
3432 > {
3433 self.inner
3434 .ready()
3435 .await
3436 .map_err(|e| {
3437 tonic::Status::unknown(
3438 format!("Service was not ready: {}", e.into()),
3439 )
3440 })?;
3441 let codec = tonic_prost::ProstCodec::default();
3442 let path = http::uri::PathAndQuery::from_static(
3443 "/meta.StreamManagerService/GetFragmentById",
3444 );
3445 let mut req = request.into_request();
3446 req.extensions_mut()
3447 .insert(GrpcMethod::new("meta.StreamManagerService", "GetFragmentById"));
3448 self.inner.unary(req, path, codec).await
3449 }
3450 pub async fn get_fragment_vnodes(
3451 &mut self,
3452 request: impl tonic::IntoRequest<super::GetFragmentVnodesRequest>,
3453 ) -> std::result::Result<
3454 tonic::Response<super::GetFragmentVnodesResponse>,
3455 tonic::Status,
3456 > {
3457 self.inner
3458 .ready()
3459 .await
3460 .map_err(|e| {
3461 tonic::Status::unknown(
3462 format!("Service was not ready: {}", e.into()),
3463 )
3464 })?;
3465 let codec = tonic_prost::ProstCodec::default();
3466 let path = http::uri::PathAndQuery::from_static(
3467 "/meta.StreamManagerService/GetFragmentVnodes",
3468 );
3469 let mut req = request.into_request();
3470 req.extensions_mut()
3471 .insert(
3472 GrpcMethod::new("meta.StreamManagerService", "GetFragmentVnodes"),
3473 );
3474 self.inner.unary(req, path, codec).await
3475 }
3476 pub async fn get_actor_vnodes(
3477 &mut self,
3478 request: impl tonic::IntoRequest<super::GetActorVnodesRequest>,
3479 ) -> std::result::Result<
3480 tonic::Response<super::GetActorVnodesResponse>,
3481 tonic::Status,
3482 > {
3483 self.inner
3484 .ready()
3485 .await
3486 .map_err(|e| {
3487 tonic::Status::unknown(
3488 format!("Service was not ready: {}", e.into()),
3489 )
3490 })?;
3491 let codec = tonic_prost::ProstCodec::default();
3492 let path = http::uri::PathAndQuery::from_static(
3493 "/meta.StreamManagerService/GetActorVnodes",
3494 );
3495 let mut req = request.into_request();
3496 req.extensions_mut()
3497 .insert(GrpcMethod::new("meta.StreamManagerService", "GetActorVnodes"));
3498 self.inner.unary(req, path, codec).await
3499 }
3500 pub async fn set_sync_log_store_aligned(
3501 &mut self,
3502 request: impl tonic::IntoRequest<super::SetSyncLogStoreAlignedRequest>,
3503 ) -> std::result::Result<
3504 tonic::Response<super::SetSyncLogStoreAlignedResponse>,
3505 tonic::Status,
3506 > {
3507 self.inner
3508 .ready()
3509 .await
3510 .map_err(|e| {
3511 tonic::Status::unknown(
3512 format!("Service was not ready: {}", e.into()),
3513 )
3514 })?;
3515 let codec = tonic_prost::ProstCodec::default();
3516 let path = http::uri::PathAndQuery::from_static(
3517 "/meta.StreamManagerService/SetSyncLogStoreAligned",
3518 );
3519 let mut req = request.into_request();
3520 req.extensions_mut()
3521 .insert(
3522 GrpcMethod::new(
3523 "meta.StreamManagerService",
3524 "SetSyncLogStoreAligned",
3525 ),
3526 );
3527 self.inner.unary(req, path, codec).await
3528 }
3529 pub async fn list_cdc_progress(
3530 &mut self,
3531 request: impl tonic::IntoRequest<super::ListCdcProgressRequest>,
3532 ) -> std::result::Result<
3533 tonic::Response<super::ListCdcProgressResponse>,
3534 tonic::Status,
3535 > {
3536 self.inner
3537 .ready()
3538 .await
3539 .map_err(|e| {
3540 tonic::Status::unknown(
3541 format!("Service was not ready: {}", e.into()),
3542 )
3543 })?;
3544 let codec = tonic_prost::ProstCodec::default();
3545 let path = http::uri::PathAndQuery::from_static(
3546 "/meta.StreamManagerService/ListCdcProgress",
3547 );
3548 let mut req = request.into_request();
3549 req.extensions_mut()
3550 .insert(GrpcMethod::new("meta.StreamManagerService", "ListCdcProgress"));
3551 self.inner.unary(req, path, codec).await
3552 }
3553 pub async fn list_unmigrated_tables(
3554 &mut self,
3555 request: impl tonic::IntoRequest<super::ListUnmigratedTablesRequest>,
3556 ) -> std::result::Result<
3557 tonic::Response<super::ListUnmigratedTablesResponse>,
3558 tonic::Status,
3559 > {
3560 self.inner
3561 .ready()
3562 .await
3563 .map_err(|e| {
3564 tonic::Status::unknown(
3565 format!("Service was not ready: {}", e.into()),
3566 )
3567 })?;
3568 let codec = tonic_prost::ProstCodec::default();
3569 let path = http::uri::PathAndQuery::from_static(
3570 "/meta.StreamManagerService/ListUnmigratedTables",
3571 );
3572 let mut req = request.into_request();
3573 req.extensions_mut()
3574 .insert(
3575 GrpcMethod::new("meta.StreamManagerService", "ListUnmigratedTables"),
3576 );
3577 self.inner.unary(req, path, codec).await
3578 }
3579 pub async fn list_refresh_table_states(
3580 &mut self,
3581 request: impl tonic::IntoRequest<super::ListRefreshTableStatesRequest>,
3582 ) -> std::result::Result<
3583 tonic::Response<super::ListRefreshTableStatesResponse>,
3584 tonic::Status,
3585 > {
3586 self.inner
3587 .ready()
3588 .await
3589 .map_err(|e| {
3590 tonic::Status::unknown(
3591 format!("Service was not ready: {}", e.into()),
3592 )
3593 })?;
3594 let codec = tonic_prost::ProstCodec::default();
3595 let path = http::uri::PathAndQuery::from_static(
3596 "/meta.StreamManagerService/ListRefreshTableStates",
3597 );
3598 let mut req = request.into_request();
3599 req.extensions_mut()
3600 .insert(
3601 GrpcMethod::new(
3602 "meta.StreamManagerService",
3603 "ListRefreshTableStates",
3604 ),
3605 );
3606 self.inner.unary(req, path, codec).await
3607 }
3608 pub async fn list_bounded_jobs(
3609 &mut self,
3610 request: impl tonic::IntoRequest<super::ListBoundedJobsRequest>,
3611 ) -> std::result::Result<
3612 tonic::Response<super::ListBoundedJobsResponse>,
3613 tonic::Status,
3614 > {
3615 self.inner
3616 .ready()
3617 .await
3618 .map_err(|e| {
3619 tonic::Status::unknown(
3620 format!("Service was not ready: {}", e.into()),
3621 )
3622 })?;
3623 let codec = tonic_prost::ProstCodec::default();
3624 let path = http::uri::PathAndQuery::from_static(
3625 "/meta.StreamManagerService/ListBoundedJobs",
3626 );
3627 let mut req = request.into_request();
3628 req.extensions_mut()
3629 .insert(GrpcMethod::new("meta.StreamManagerService", "ListBoundedJobs"));
3630 self.inner.unary(req, path, codec).await
3631 }
3632 pub async fn list_iceberg_compaction_status(
3633 &mut self,
3634 request: impl tonic::IntoRequest<super::ListIcebergCompactionStatusRequest>,
3635 ) -> std::result::Result<
3636 tonic::Response<super::ListIcebergCompactionStatusResponse>,
3637 tonic::Status,
3638 > {
3639 self.inner
3640 .ready()
3641 .await
3642 .map_err(|e| {
3643 tonic::Status::unknown(
3644 format!("Service was not ready: {}", e.into()),
3645 )
3646 })?;
3647 let codec = tonic_prost::ProstCodec::default();
3648 let path = http::uri::PathAndQuery::from_static(
3649 "/meta.StreamManagerService/ListIcebergCompactionStatus",
3650 );
3651 let mut req = request.into_request();
3652 req.extensions_mut()
3653 .insert(
3654 GrpcMethod::new(
3655 "meta.StreamManagerService",
3656 "ListIcebergCompactionStatus",
3657 ),
3658 );
3659 self.inner.unary(req, path, codec).await
3660 }
3661 }
3662}
3663pub mod stream_manager_service_server {
3665 #![allow(
3666 unused_variables,
3667 dead_code,
3668 missing_docs,
3669 clippy::wildcard_imports,
3670 clippy::let_unit_value,
3671 )]
3672 use tonic::codegen::*;
3673 #[async_trait]
3675 pub trait StreamManagerService: std::marker::Send + std::marker::Sync + 'static {
3676 async fn flush(
3677 &self,
3678 request: tonic::Request<super::FlushRequest>,
3679 ) -> std::result::Result<tonic::Response<super::FlushResponse>, tonic::Status>;
3680 async fn pause(
3681 &self,
3682 request: tonic::Request<super::PauseRequest>,
3683 ) -> std::result::Result<tonic::Response<super::PauseResponse>, tonic::Status>;
3684 async fn resume(
3685 &self,
3686 request: tonic::Request<super::ResumeRequest>,
3687 ) -> std::result::Result<tonic::Response<super::ResumeResponse>, tonic::Status>;
3688 async fn refresh(
3689 &self,
3690 request: tonic::Request<super::RefreshRequest>,
3691 ) -> std::result::Result<tonic::Response<super::RefreshResponse>, tonic::Status>;
3692 async fn cancel_creating_jobs(
3693 &self,
3694 request: tonic::Request<super::CancelCreatingJobsRequest>,
3695 ) -> std::result::Result<
3696 tonic::Response<super::CancelCreatingJobsResponse>,
3697 tonic::Status,
3698 >;
3699 async fn list_table_fragments(
3700 &self,
3701 request: tonic::Request<super::ListTableFragmentsRequest>,
3702 ) -> std::result::Result<
3703 tonic::Response<super::ListTableFragmentsResponse>,
3704 tonic::Status,
3705 >;
3706 async fn list_streaming_job_states(
3707 &self,
3708 request: tonic::Request<super::ListStreamingJobStatesRequest>,
3709 ) -> std::result::Result<
3710 tonic::Response<super::ListStreamingJobStatesResponse>,
3711 tonic::Status,
3712 >;
3713 async fn list_fragment_distribution(
3714 &self,
3715 request: tonic::Request<super::ListFragmentDistributionRequest>,
3716 ) -> std::result::Result<
3717 tonic::Response<super::ListFragmentDistributionResponse>,
3718 tonic::Status,
3719 >;
3720 async fn list_creating_fragment_distribution(
3721 &self,
3722 request: tonic::Request<super::ListCreatingFragmentDistributionRequest>,
3723 ) -> std::result::Result<
3724 tonic::Response<super::ListCreatingFragmentDistributionResponse>,
3725 tonic::Status,
3726 >;
3727 async fn list_sink_log_store_tables(
3728 &self,
3729 request: tonic::Request<super::ListSinkLogStoreTablesRequest>,
3730 ) -> std::result::Result<
3731 tonic::Response<super::ListSinkLogStoreTablesResponse>,
3732 tonic::Status,
3733 >;
3734 async fn list_actor_states(
3735 &self,
3736 request: tonic::Request<super::ListActorStatesRequest>,
3737 ) -> std::result::Result<
3738 tonic::Response<super::ListActorStatesResponse>,
3739 tonic::Status,
3740 >;
3741 async fn list_actor_splits(
3742 &self,
3743 request: tonic::Request<super::ListActorSplitsRequest>,
3744 ) -> std::result::Result<
3745 tonic::Response<super::ListActorSplitsResponse>,
3746 tonic::Status,
3747 >;
3748 async fn apply_throttle(
3749 &self,
3750 request: tonic::Request<super::ApplyThrottleRequest>,
3751 ) -> std::result::Result<
3752 tonic::Response<super::ApplyThrottleResponse>,
3753 tonic::Status,
3754 >;
3755 async fn recover(
3756 &self,
3757 request: tonic::Request<super::RecoverRequest>,
3758 ) -> std::result::Result<tonic::Response<super::RecoverResponse>, tonic::Status>;
3759 async fn list_rate_limits(
3760 &self,
3761 request: tonic::Request<super::ListRateLimitsRequest>,
3762 ) -> std::result::Result<
3763 tonic::Response<super::ListRateLimitsResponse>,
3764 tonic::Status,
3765 >;
3766 async fn alter_connector_props(
3767 &self,
3768 request: tonic::Request<super::AlterConnectorPropsRequest>,
3769 ) -> std::result::Result<
3770 tonic::Response<super::AlterConnectorPropsResponse>,
3771 tonic::Status,
3772 >;
3773 async fn alter_source_properties_safe(
3774 &self,
3775 request: tonic::Request<super::AlterSourcePropertiesSafeRequest>,
3776 ) -> std::result::Result<
3777 tonic::Response<super::AlterSourcePropertiesSafeResponse>,
3778 tonic::Status,
3779 >;
3780 async fn reset_source_splits(
3781 &self,
3782 request: tonic::Request<super::ResetSourceSplitsRequest>,
3783 ) -> std::result::Result<
3784 tonic::Response<super::ResetSourceSplitsResponse>,
3785 tonic::Status,
3786 >;
3787 async fn inject_source_offsets(
3788 &self,
3789 request: tonic::Request<super::InjectSourceOffsetsRequest>,
3790 ) -> std::result::Result<
3791 tonic::Response<super::InjectSourceOffsetsResponse>,
3792 tonic::Status,
3793 >;
3794 async fn get_fragment_by_id(
3795 &self,
3796 request: tonic::Request<super::GetFragmentByIdRequest>,
3797 ) -> std::result::Result<
3798 tonic::Response<super::GetFragmentByIdResponse>,
3799 tonic::Status,
3800 >;
3801 async fn get_fragment_vnodes(
3802 &self,
3803 request: tonic::Request<super::GetFragmentVnodesRequest>,
3804 ) -> std::result::Result<
3805 tonic::Response<super::GetFragmentVnodesResponse>,
3806 tonic::Status,
3807 >;
3808 async fn get_actor_vnodes(
3809 &self,
3810 request: tonic::Request<super::GetActorVnodesRequest>,
3811 ) -> std::result::Result<
3812 tonic::Response<super::GetActorVnodesResponse>,
3813 tonic::Status,
3814 >;
3815 async fn set_sync_log_store_aligned(
3816 &self,
3817 request: tonic::Request<super::SetSyncLogStoreAlignedRequest>,
3818 ) -> std::result::Result<
3819 tonic::Response<super::SetSyncLogStoreAlignedResponse>,
3820 tonic::Status,
3821 >;
3822 async fn list_cdc_progress(
3823 &self,
3824 request: tonic::Request<super::ListCdcProgressRequest>,
3825 ) -> std::result::Result<
3826 tonic::Response<super::ListCdcProgressResponse>,
3827 tonic::Status,
3828 >;
3829 async fn list_unmigrated_tables(
3830 &self,
3831 request: tonic::Request<super::ListUnmigratedTablesRequest>,
3832 ) -> std::result::Result<
3833 tonic::Response<super::ListUnmigratedTablesResponse>,
3834 tonic::Status,
3835 >;
3836 async fn list_refresh_table_states(
3837 &self,
3838 request: tonic::Request<super::ListRefreshTableStatesRequest>,
3839 ) -> std::result::Result<
3840 tonic::Response<super::ListRefreshTableStatesResponse>,
3841 tonic::Status,
3842 >;
3843 async fn list_bounded_jobs(
3844 &self,
3845 request: tonic::Request<super::ListBoundedJobsRequest>,
3846 ) -> std::result::Result<
3847 tonic::Response<super::ListBoundedJobsResponse>,
3848 tonic::Status,
3849 >;
3850 async fn list_iceberg_compaction_status(
3851 &self,
3852 request: tonic::Request<super::ListIcebergCompactionStatusRequest>,
3853 ) -> std::result::Result<
3854 tonic::Response<super::ListIcebergCompactionStatusResponse>,
3855 tonic::Status,
3856 >;
3857 }
3858 #[derive(Debug)]
3859 pub struct StreamManagerServiceServer<T> {
3860 inner: Arc<T>,
3861 accept_compression_encodings: EnabledCompressionEncodings,
3862 send_compression_encodings: EnabledCompressionEncodings,
3863 max_decoding_message_size: Option<usize>,
3864 max_encoding_message_size: Option<usize>,
3865 }
3866 impl<T> StreamManagerServiceServer<T> {
3867 pub fn new(inner: T) -> Self {
3868 Self::from_arc(Arc::new(inner))
3869 }
3870 pub fn from_arc(inner: Arc<T>) -> Self {
3871 Self {
3872 inner,
3873 accept_compression_encodings: Default::default(),
3874 send_compression_encodings: Default::default(),
3875 max_decoding_message_size: None,
3876 max_encoding_message_size: None,
3877 }
3878 }
3879 pub fn with_interceptor<F>(
3880 inner: T,
3881 interceptor: F,
3882 ) -> InterceptedService<Self, F>
3883 where
3884 F: tonic::service::Interceptor,
3885 {
3886 InterceptedService::new(Self::new(inner), interceptor)
3887 }
3888 #[must_use]
3890 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
3891 self.accept_compression_encodings.enable(encoding);
3892 self
3893 }
3894 #[must_use]
3896 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
3897 self.send_compression_encodings.enable(encoding);
3898 self
3899 }
3900 #[must_use]
3904 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
3905 self.max_decoding_message_size = Some(limit);
3906 self
3907 }
3908 #[must_use]
3912 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
3913 self.max_encoding_message_size = Some(limit);
3914 self
3915 }
3916 }
3917 impl<T, B> tonic::codegen::Service<http::Request<B>>
3918 for StreamManagerServiceServer<T>
3919 where
3920 T: StreamManagerService,
3921 B: Body + std::marker::Send + 'static,
3922 B::Error: Into<StdError> + std::marker::Send + 'static,
3923 {
3924 type Response = http::Response<tonic::body::Body>;
3925 type Error = std::convert::Infallible;
3926 type Future = BoxFuture<Self::Response, Self::Error>;
3927 fn poll_ready(
3928 &mut self,
3929 _cx: &mut Context<'_>,
3930 ) -> Poll<std::result::Result<(), Self::Error>> {
3931 Poll::Ready(Ok(()))
3932 }
3933 fn call(&mut self, req: http::Request<B>) -> Self::Future {
3934 match req.uri().path() {
3935 "/meta.StreamManagerService/Flush" => {
3936 #[allow(non_camel_case_types)]
3937 struct FlushSvc<T: StreamManagerService>(pub Arc<T>);
3938 impl<
3939 T: StreamManagerService,
3940 > tonic::server::UnaryService<super::FlushRequest> for FlushSvc<T> {
3941 type Response = super::FlushResponse;
3942 type Future = BoxFuture<
3943 tonic::Response<Self::Response>,
3944 tonic::Status,
3945 >;
3946 fn call(
3947 &mut self,
3948 request: tonic::Request<super::FlushRequest>,
3949 ) -> Self::Future {
3950 let inner = Arc::clone(&self.0);
3951 let fut = async move {
3952 <T as StreamManagerService>::flush(&inner, request).await
3953 };
3954 Box::pin(fut)
3955 }
3956 }
3957 let accept_compression_encodings = self.accept_compression_encodings;
3958 let send_compression_encodings = self.send_compression_encodings;
3959 let max_decoding_message_size = self.max_decoding_message_size;
3960 let max_encoding_message_size = self.max_encoding_message_size;
3961 let inner = self.inner.clone();
3962 let fut = async move {
3963 let method = FlushSvc(inner);
3964 let codec = tonic_prost::ProstCodec::default();
3965 let mut grpc = tonic::server::Grpc::new(codec)
3966 .apply_compression_config(
3967 accept_compression_encodings,
3968 send_compression_encodings,
3969 )
3970 .apply_max_message_size_config(
3971 max_decoding_message_size,
3972 max_encoding_message_size,
3973 );
3974 let res = grpc.unary(method, req).await;
3975 Ok(res)
3976 };
3977 Box::pin(fut)
3978 }
3979 "/meta.StreamManagerService/Pause" => {
3980 #[allow(non_camel_case_types)]
3981 struct PauseSvc<T: StreamManagerService>(pub Arc<T>);
3982 impl<
3983 T: StreamManagerService,
3984 > tonic::server::UnaryService<super::PauseRequest> for PauseSvc<T> {
3985 type Response = super::PauseResponse;
3986 type Future = BoxFuture<
3987 tonic::Response<Self::Response>,
3988 tonic::Status,
3989 >;
3990 fn call(
3991 &mut self,
3992 request: tonic::Request<super::PauseRequest>,
3993 ) -> Self::Future {
3994 let inner = Arc::clone(&self.0);
3995 let fut = async move {
3996 <T as StreamManagerService>::pause(&inner, request).await
3997 };
3998 Box::pin(fut)
3999 }
4000 }
4001 let accept_compression_encodings = self.accept_compression_encodings;
4002 let send_compression_encodings = self.send_compression_encodings;
4003 let max_decoding_message_size = self.max_decoding_message_size;
4004 let max_encoding_message_size = self.max_encoding_message_size;
4005 let inner = self.inner.clone();
4006 let fut = async move {
4007 let method = PauseSvc(inner);
4008 let codec = tonic_prost::ProstCodec::default();
4009 let mut grpc = tonic::server::Grpc::new(codec)
4010 .apply_compression_config(
4011 accept_compression_encodings,
4012 send_compression_encodings,
4013 )
4014 .apply_max_message_size_config(
4015 max_decoding_message_size,
4016 max_encoding_message_size,
4017 );
4018 let res = grpc.unary(method, req).await;
4019 Ok(res)
4020 };
4021 Box::pin(fut)
4022 }
4023 "/meta.StreamManagerService/Resume" => {
4024 #[allow(non_camel_case_types)]
4025 struct ResumeSvc<T: StreamManagerService>(pub Arc<T>);
4026 impl<
4027 T: StreamManagerService,
4028 > tonic::server::UnaryService<super::ResumeRequest>
4029 for ResumeSvc<T> {
4030 type Response = super::ResumeResponse;
4031 type Future = BoxFuture<
4032 tonic::Response<Self::Response>,
4033 tonic::Status,
4034 >;
4035 fn call(
4036 &mut self,
4037 request: tonic::Request<super::ResumeRequest>,
4038 ) -> Self::Future {
4039 let inner = Arc::clone(&self.0);
4040 let fut = async move {
4041 <T as StreamManagerService>::resume(&inner, request).await
4042 };
4043 Box::pin(fut)
4044 }
4045 }
4046 let accept_compression_encodings = self.accept_compression_encodings;
4047 let send_compression_encodings = self.send_compression_encodings;
4048 let max_decoding_message_size = self.max_decoding_message_size;
4049 let max_encoding_message_size = self.max_encoding_message_size;
4050 let inner = self.inner.clone();
4051 let fut = async move {
4052 let method = ResumeSvc(inner);
4053 let codec = tonic_prost::ProstCodec::default();
4054 let mut grpc = tonic::server::Grpc::new(codec)
4055 .apply_compression_config(
4056 accept_compression_encodings,
4057 send_compression_encodings,
4058 )
4059 .apply_max_message_size_config(
4060 max_decoding_message_size,
4061 max_encoding_message_size,
4062 );
4063 let res = grpc.unary(method, req).await;
4064 Ok(res)
4065 };
4066 Box::pin(fut)
4067 }
4068 "/meta.StreamManagerService/Refresh" => {
4069 #[allow(non_camel_case_types)]
4070 struct RefreshSvc<T: StreamManagerService>(pub Arc<T>);
4071 impl<
4072 T: StreamManagerService,
4073 > tonic::server::UnaryService<super::RefreshRequest>
4074 for RefreshSvc<T> {
4075 type Response = super::RefreshResponse;
4076 type Future = BoxFuture<
4077 tonic::Response<Self::Response>,
4078 tonic::Status,
4079 >;
4080 fn call(
4081 &mut self,
4082 request: tonic::Request<super::RefreshRequest>,
4083 ) -> Self::Future {
4084 let inner = Arc::clone(&self.0);
4085 let fut = async move {
4086 <T as StreamManagerService>::refresh(&inner, request).await
4087 };
4088 Box::pin(fut)
4089 }
4090 }
4091 let accept_compression_encodings = self.accept_compression_encodings;
4092 let send_compression_encodings = self.send_compression_encodings;
4093 let max_decoding_message_size = self.max_decoding_message_size;
4094 let max_encoding_message_size = self.max_encoding_message_size;
4095 let inner = self.inner.clone();
4096 let fut = async move {
4097 let method = RefreshSvc(inner);
4098 let codec = tonic_prost::ProstCodec::default();
4099 let mut grpc = tonic::server::Grpc::new(codec)
4100 .apply_compression_config(
4101 accept_compression_encodings,
4102 send_compression_encodings,
4103 )
4104 .apply_max_message_size_config(
4105 max_decoding_message_size,
4106 max_encoding_message_size,
4107 );
4108 let res = grpc.unary(method, req).await;
4109 Ok(res)
4110 };
4111 Box::pin(fut)
4112 }
4113 "/meta.StreamManagerService/CancelCreatingJobs" => {
4114 #[allow(non_camel_case_types)]
4115 struct CancelCreatingJobsSvc<T: StreamManagerService>(pub Arc<T>);
4116 impl<
4117 T: StreamManagerService,
4118 > tonic::server::UnaryService<super::CancelCreatingJobsRequest>
4119 for CancelCreatingJobsSvc<T> {
4120 type Response = super::CancelCreatingJobsResponse;
4121 type Future = BoxFuture<
4122 tonic::Response<Self::Response>,
4123 tonic::Status,
4124 >;
4125 fn call(
4126 &mut self,
4127 request: tonic::Request<super::CancelCreatingJobsRequest>,
4128 ) -> Self::Future {
4129 let inner = Arc::clone(&self.0);
4130 let fut = async move {
4131 <T as StreamManagerService>::cancel_creating_jobs(
4132 &inner,
4133 request,
4134 )
4135 .await
4136 };
4137 Box::pin(fut)
4138 }
4139 }
4140 let accept_compression_encodings = self.accept_compression_encodings;
4141 let send_compression_encodings = self.send_compression_encodings;
4142 let max_decoding_message_size = self.max_decoding_message_size;
4143 let max_encoding_message_size = self.max_encoding_message_size;
4144 let inner = self.inner.clone();
4145 let fut = async move {
4146 let method = CancelCreatingJobsSvc(inner);
4147 let codec = tonic_prost::ProstCodec::default();
4148 let mut grpc = tonic::server::Grpc::new(codec)
4149 .apply_compression_config(
4150 accept_compression_encodings,
4151 send_compression_encodings,
4152 )
4153 .apply_max_message_size_config(
4154 max_decoding_message_size,
4155 max_encoding_message_size,
4156 );
4157 let res = grpc.unary(method, req).await;
4158 Ok(res)
4159 };
4160 Box::pin(fut)
4161 }
4162 "/meta.StreamManagerService/ListTableFragments" => {
4163 #[allow(non_camel_case_types)]
4164 struct ListTableFragmentsSvc<T: StreamManagerService>(pub Arc<T>);
4165 impl<
4166 T: StreamManagerService,
4167 > tonic::server::UnaryService<super::ListTableFragmentsRequest>
4168 for ListTableFragmentsSvc<T> {
4169 type Response = super::ListTableFragmentsResponse;
4170 type Future = BoxFuture<
4171 tonic::Response<Self::Response>,
4172 tonic::Status,
4173 >;
4174 fn call(
4175 &mut self,
4176 request: tonic::Request<super::ListTableFragmentsRequest>,
4177 ) -> Self::Future {
4178 let inner = Arc::clone(&self.0);
4179 let fut = async move {
4180 <T as StreamManagerService>::list_table_fragments(
4181 &inner,
4182 request,
4183 )
4184 .await
4185 };
4186 Box::pin(fut)
4187 }
4188 }
4189 let accept_compression_encodings = self.accept_compression_encodings;
4190 let send_compression_encodings = self.send_compression_encodings;
4191 let max_decoding_message_size = self.max_decoding_message_size;
4192 let max_encoding_message_size = self.max_encoding_message_size;
4193 let inner = self.inner.clone();
4194 let fut = async move {
4195 let method = ListTableFragmentsSvc(inner);
4196 let codec = tonic_prost::ProstCodec::default();
4197 let mut grpc = tonic::server::Grpc::new(codec)
4198 .apply_compression_config(
4199 accept_compression_encodings,
4200 send_compression_encodings,
4201 )
4202 .apply_max_message_size_config(
4203 max_decoding_message_size,
4204 max_encoding_message_size,
4205 );
4206 let res = grpc.unary(method, req).await;
4207 Ok(res)
4208 };
4209 Box::pin(fut)
4210 }
4211 "/meta.StreamManagerService/ListStreamingJobStates" => {
4212 #[allow(non_camel_case_types)]
4213 struct ListStreamingJobStatesSvc<T: StreamManagerService>(
4214 pub Arc<T>,
4215 );
4216 impl<
4217 T: StreamManagerService,
4218 > tonic::server::UnaryService<super::ListStreamingJobStatesRequest>
4219 for ListStreamingJobStatesSvc<T> {
4220 type Response = super::ListStreamingJobStatesResponse;
4221 type Future = BoxFuture<
4222 tonic::Response<Self::Response>,
4223 tonic::Status,
4224 >;
4225 fn call(
4226 &mut self,
4227 request: tonic::Request<super::ListStreamingJobStatesRequest>,
4228 ) -> Self::Future {
4229 let inner = Arc::clone(&self.0);
4230 let fut = async move {
4231 <T as StreamManagerService>::list_streaming_job_states(
4232 &inner,
4233 request,
4234 )
4235 .await
4236 };
4237 Box::pin(fut)
4238 }
4239 }
4240 let accept_compression_encodings = self.accept_compression_encodings;
4241 let send_compression_encodings = self.send_compression_encodings;
4242 let max_decoding_message_size = self.max_decoding_message_size;
4243 let max_encoding_message_size = self.max_encoding_message_size;
4244 let inner = self.inner.clone();
4245 let fut = async move {
4246 let method = ListStreamingJobStatesSvc(inner);
4247 let codec = tonic_prost::ProstCodec::default();
4248 let mut grpc = tonic::server::Grpc::new(codec)
4249 .apply_compression_config(
4250 accept_compression_encodings,
4251 send_compression_encodings,
4252 )
4253 .apply_max_message_size_config(
4254 max_decoding_message_size,
4255 max_encoding_message_size,
4256 );
4257 let res = grpc.unary(method, req).await;
4258 Ok(res)
4259 };
4260 Box::pin(fut)
4261 }
4262 "/meta.StreamManagerService/ListFragmentDistribution" => {
4263 #[allow(non_camel_case_types)]
4264 struct ListFragmentDistributionSvc<T: StreamManagerService>(
4265 pub Arc<T>,
4266 );
4267 impl<
4268 T: StreamManagerService,
4269 > tonic::server::UnaryService<super::ListFragmentDistributionRequest>
4270 for ListFragmentDistributionSvc<T> {
4271 type Response = super::ListFragmentDistributionResponse;
4272 type Future = BoxFuture<
4273 tonic::Response<Self::Response>,
4274 tonic::Status,
4275 >;
4276 fn call(
4277 &mut self,
4278 request: tonic::Request<
4279 super::ListFragmentDistributionRequest,
4280 >,
4281 ) -> Self::Future {
4282 let inner = Arc::clone(&self.0);
4283 let fut = async move {
4284 <T as StreamManagerService>::list_fragment_distribution(
4285 &inner,
4286 request,
4287 )
4288 .await
4289 };
4290 Box::pin(fut)
4291 }
4292 }
4293 let accept_compression_encodings = self.accept_compression_encodings;
4294 let send_compression_encodings = self.send_compression_encodings;
4295 let max_decoding_message_size = self.max_decoding_message_size;
4296 let max_encoding_message_size = self.max_encoding_message_size;
4297 let inner = self.inner.clone();
4298 let fut = async move {
4299 let method = ListFragmentDistributionSvc(inner);
4300 let codec = tonic_prost::ProstCodec::default();
4301 let mut grpc = tonic::server::Grpc::new(codec)
4302 .apply_compression_config(
4303 accept_compression_encodings,
4304 send_compression_encodings,
4305 )
4306 .apply_max_message_size_config(
4307 max_decoding_message_size,
4308 max_encoding_message_size,
4309 );
4310 let res = grpc.unary(method, req).await;
4311 Ok(res)
4312 };
4313 Box::pin(fut)
4314 }
4315 "/meta.StreamManagerService/ListCreatingFragmentDistribution" => {
4316 #[allow(non_camel_case_types)]
4317 struct ListCreatingFragmentDistributionSvc<T: StreamManagerService>(
4318 pub Arc<T>,
4319 );
4320 impl<
4321 T: StreamManagerService,
4322 > tonic::server::UnaryService<
4323 super::ListCreatingFragmentDistributionRequest,
4324 > for ListCreatingFragmentDistributionSvc<T> {
4325 type Response = super::ListCreatingFragmentDistributionResponse;
4326 type Future = BoxFuture<
4327 tonic::Response<Self::Response>,
4328 tonic::Status,
4329 >;
4330 fn call(
4331 &mut self,
4332 request: tonic::Request<
4333 super::ListCreatingFragmentDistributionRequest,
4334 >,
4335 ) -> Self::Future {
4336 let inner = Arc::clone(&self.0);
4337 let fut = async move {
4338 <T as StreamManagerService>::list_creating_fragment_distribution(
4339 &inner,
4340 request,
4341 )
4342 .await
4343 };
4344 Box::pin(fut)
4345 }
4346 }
4347 let accept_compression_encodings = self.accept_compression_encodings;
4348 let send_compression_encodings = self.send_compression_encodings;
4349 let max_decoding_message_size = self.max_decoding_message_size;
4350 let max_encoding_message_size = self.max_encoding_message_size;
4351 let inner = self.inner.clone();
4352 let fut = async move {
4353 let method = ListCreatingFragmentDistributionSvc(inner);
4354 let codec = tonic_prost::ProstCodec::default();
4355 let mut grpc = tonic::server::Grpc::new(codec)
4356 .apply_compression_config(
4357 accept_compression_encodings,
4358 send_compression_encodings,
4359 )
4360 .apply_max_message_size_config(
4361 max_decoding_message_size,
4362 max_encoding_message_size,
4363 );
4364 let res = grpc.unary(method, req).await;
4365 Ok(res)
4366 };
4367 Box::pin(fut)
4368 }
4369 "/meta.StreamManagerService/ListSinkLogStoreTables" => {
4370 #[allow(non_camel_case_types)]
4371 struct ListSinkLogStoreTablesSvc<T: StreamManagerService>(
4372 pub Arc<T>,
4373 );
4374 impl<
4375 T: StreamManagerService,
4376 > tonic::server::UnaryService<super::ListSinkLogStoreTablesRequest>
4377 for ListSinkLogStoreTablesSvc<T> {
4378 type Response = super::ListSinkLogStoreTablesResponse;
4379 type Future = BoxFuture<
4380 tonic::Response<Self::Response>,
4381 tonic::Status,
4382 >;
4383 fn call(
4384 &mut self,
4385 request: tonic::Request<super::ListSinkLogStoreTablesRequest>,
4386 ) -> Self::Future {
4387 let inner = Arc::clone(&self.0);
4388 let fut = async move {
4389 <T as StreamManagerService>::list_sink_log_store_tables(
4390 &inner,
4391 request,
4392 )
4393 .await
4394 };
4395 Box::pin(fut)
4396 }
4397 }
4398 let accept_compression_encodings = self.accept_compression_encodings;
4399 let send_compression_encodings = self.send_compression_encodings;
4400 let max_decoding_message_size = self.max_decoding_message_size;
4401 let max_encoding_message_size = self.max_encoding_message_size;
4402 let inner = self.inner.clone();
4403 let fut = async move {
4404 let method = ListSinkLogStoreTablesSvc(inner);
4405 let codec = tonic_prost::ProstCodec::default();
4406 let mut grpc = tonic::server::Grpc::new(codec)
4407 .apply_compression_config(
4408 accept_compression_encodings,
4409 send_compression_encodings,
4410 )
4411 .apply_max_message_size_config(
4412 max_decoding_message_size,
4413 max_encoding_message_size,
4414 );
4415 let res = grpc.unary(method, req).await;
4416 Ok(res)
4417 };
4418 Box::pin(fut)
4419 }
4420 "/meta.StreamManagerService/ListActorStates" => {
4421 #[allow(non_camel_case_types)]
4422 struct ListActorStatesSvc<T: StreamManagerService>(pub Arc<T>);
4423 impl<
4424 T: StreamManagerService,
4425 > tonic::server::UnaryService<super::ListActorStatesRequest>
4426 for ListActorStatesSvc<T> {
4427 type Response = super::ListActorStatesResponse;
4428 type Future = BoxFuture<
4429 tonic::Response<Self::Response>,
4430 tonic::Status,
4431 >;
4432 fn call(
4433 &mut self,
4434 request: tonic::Request<super::ListActorStatesRequest>,
4435 ) -> Self::Future {
4436 let inner = Arc::clone(&self.0);
4437 let fut = async move {
4438 <T as StreamManagerService>::list_actor_states(
4439 &inner,
4440 request,
4441 )
4442 .await
4443 };
4444 Box::pin(fut)
4445 }
4446 }
4447 let accept_compression_encodings = self.accept_compression_encodings;
4448 let send_compression_encodings = self.send_compression_encodings;
4449 let max_decoding_message_size = self.max_decoding_message_size;
4450 let max_encoding_message_size = self.max_encoding_message_size;
4451 let inner = self.inner.clone();
4452 let fut = async move {
4453 let method = ListActorStatesSvc(inner);
4454 let codec = tonic_prost::ProstCodec::default();
4455 let mut grpc = tonic::server::Grpc::new(codec)
4456 .apply_compression_config(
4457 accept_compression_encodings,
4458 send_compression_encodings,
4459 )
4460 .apply_max_message_size_config(
4461 max_decoding_message_size,
4462 max_encoding_message_size,
4463 );
4464 let res = grpc.unary(method, req).await;
4465 Ok(res)
4466 };
4467 Box::pin(fut)
4468 }
4469 "/meta.StreamManagerService/ListActorSplits" => {
4470 #[allow(non_camel_case_types)]
4471 struct ListActorSplitsSvc<T: StreamManagerService>(pub Arc<T>);
4472 impl<
4473 T: StreamManagerService,
4474 > tonic::server::UnaryService<super::ListActorSplitsRequest>
4475 for ListActorSplitsSvc<T> {
4476 type Response = super::ListActorSplitsResponse;
4477 type Future = BoxFuture<
4478 tonic::Response<Self::Response>,
4479 tonic::Status,
4480 >;
4481 fn call(
4482 &mut self,
4483 request: tonic::Request<super::ListActorSplitsRequest>,
4484 ) -> Self::Future {
4485 let inner = Arc::clone(&self.0);
4486 let fut = async move {
4487 <T as StreamManagerService>::list_actor_splits(
4488 &inner,
4489 request,
4490 )
4491 .await
4492 };
4493 Box::pin(fut)
4494 }
4495 }
4496 let accept_compression_encodings = self.accept_compression_encodings;
4497 let send_compression_encodings = self.send_compression_encodings;
4498 let max_decoding_message_size = self.max_decoding_message_size;
4499 let max_encoding_message_size = self.max_encoding_message_size;
4500 let inner = self.inner.clone();
4501 let fut = async move {
4502 let method = ListActorSplitsSvc(inner);
4503 let codec = tonic_prost::ProstCodec::default();
4504 let mut grpc = tonic::server::Grpc::new(codec)
4505 .apply_compression_config(
4506 accept_compression_encodings,
4507 send_compression_encodings,
4508 )
4509 .apply_max_message_size_config(
4510 max_decoding_message_size,
4511 max_encoding_message_size,
4512 );
4513 let res = grpc.unary(method, req).await;
4514 Ok(res)
4515 };
4516 Box::pin(fut)
4517 }
4518 "/meta.StreamManagerService/ApplyThrottle" => {
4519 #[allow(non_camel_case_types)]
4520 struct ApplyThrottleSvc<T: StreamManagerService>(pub Arc<T>);
4521 impl<
4522 T: StreamManagerService,
4523 > tonic::server::UnaryService<super::ApplyThrottleRequest>
4524 for ApplyThrottleSvc<T> {
4525 type Response = super::ApplyThrottleResponse;
4526 type Future = BoxFuture<
4527 tonic::Response<Self::Response>,
4528 tonic::Status,
4529 >;
4530 fn call(
4531 &mut self,
4532 request: tonic::Request<super::ApplyThrottleRequest>,
4533 ) -> Self::Future {
4534 let inner = Arc::clone(&self.0);
4535 let fut = async move {
4536 <T as StreamManagerService>::apply_throttle(&inner, request)
4537 .await
4538 };
4539 Box::pin(fut)
4540 }
4541 }
4542 let accept_compression_encodings = self.accept_compression_encodings;
4543 let send_compression_encodings = self.send_compression_encodings;
4544 let max_decoding_message_size = self.max_decoding_message_size;
4545 let max_encoding_message_size = self.max_encoding_message_size;
4546 let inner = self.inner.clone();
4547 let fut = async move {
4548 let method = ApplyThrottleSvc(inner);
4549 let codec = tonic_prost::ProstCodec::default();
4550 let mut grpc = tonic::server::Grpc::new(codec)
4551 .apply_compression_config(
4552 accept_compression_encodings,
4553 send_compression_encodings,
4554 )
4555 .apply_max_message_size_config(
4556 max_decoding_message_size,
4557 max_encoding_message_size,
4558 );
4559 let res = grpc.unary(method, req).await;
4560 Ok(res)
4561 };
4562 Box::pin(fut)
4563 }
4564 "/meta.StreamManagerService/Recover" => {
4565 #[allow(non_camel_case_types)]
4566 struct RecoverSvc<T: StreamManagerService>(pub Arc<T>);
4567 impl<
4568 T: StreamManagerService,
4569 > tonic::server::UnaryService<super::RecoverRequest>
4570 for RecoverSvc<T> {
4571 type Response = super::RecoverResponse;
4572 type Future = BoxFuture<
4573 tonic::Response<Self::Response>,
4574 tonic::Status,
4575 >;
4576 fn call(
4577 &mut self,
4578 request: tonic::Request<super::RecoverRequest>,
4579 ) -> Self::Future {
4580 let inner = Arc::clone(&self.0);
4581 let fut = async move {
4582 <T as StreamManagerService>::recover(&inner, request).await
4583 };
4584 Box::pin(fut)
4585 }
4586 }
4587 let accept_compression_encodings = self.accept_compression_encodings;
4588 let send_compression_encodings = self.send_compression_encodings;
4589 let max_decoding_message_size = self.max_decoding_message_size;
4590 let max_encoding_message_size = self.max_encoding_message_size;
4591 let inner = self.inner.clone();
4592 let fut = async move {
4593 let method = RecoverSvc(inner);
4594 let codec = tonic_prost::ProstCodec::default();
4595 let mut grpc = tonic::server::Grpc::new(codec)
4596 .apply_compression_config(
4597 accept_compression_encodings,
4598 send_compression_encodings,
4599 )
4600 .apply_max_message_size_config(
4601 max_decoding_message_size,
4602 max_encoding_message_size,
4603 );
4604 let res = grpc.unary(method, req).await;
4605 Ok(res)
4606 };
4607 Box::pin(fut)
4608 }
4609 "/meta.StreamManagerService/ListRateLimits" => {
4610 #[allow(non_camel_case_types)]
4611 struct ListRateLimitsSvc<T: StreamManagerService>(pub Arc<T>);
4612 impl<
4613 T: StreamManagerService,
4614 > tonic::server::UnaryService<super::ListRateLimitsRequest>
4615 for ListRateLimitsSvc<T> {
4616 type Response = super::ListRateLimitsResponse;
4617 type Future = BoxFuture<
4618 tonic::Response<Self::Response>,
4619 tonic::Status,
4620 >;
4621 fn call(
4622 &mut self,
4623 request: tonic::Request<super::ListRateLimitsRequest>,
4624 ) -> Self::Future {
4625 let inner = Arc::clone(&self.0);
4626 let fut = async move {
4627 <T as StreamManagerService>::list_rate_limits(
4628 &inner,
4629 request,
4630 )
4631 .await
4632 };
4633 Box::pin(fut)
4634 }
4635 }
4636 let accept_compression_encodings = self.accept_compression_encodings;
4637 let send_compression_encodings = self.send_compression_encodings;
4638 let max_decoding_message_size = self.max_decoding_message_size;
4639 let max_encoding_message_size = self.max_encoding_message_size;
4640 let inner = self.inner.clone();
4641 let fut = async move {
4642 let method = ListRateLimitsSvc(inner);
4643 let codec = tonic_prost::ProstCodec::default();
4644 let mut grpc = tonic::server::Grpc::new(codec)
4645 .apply_compression_config(
4646 accept_compression_encodings,
4647 send_compression_encodings,
4648 )
4649 .apply_max_message_size_config(
4650 max_decoding_message_size,
4651 max_encoding_message_size,
4652 );
4653 let res = grpc.unary(method, req).await;
4654 Ok(res)
4655 };
4656 Box::pin(fut)
4657 }
4658 "/meta.StreamManagerService/AlterConnectorProps" => {
4659 #[allow(non_camel_case_types)]
4660 struct AlterConnectorPropsSvc<T: StreamManagerService>(pub Arc<T>);
4661 impl<
4662 T: StreamManagerService,
4663 > tonic::server::UnaryService<super::AlterConnectorPropsRequest>
4664 for AlterConnectorPropsSvc<T> {
4665 type Response = super::AlterConnectorPropsResponse;
4666 type Future = BoxFuture<
4667 tonic::Response<Self::Response>,
4668 tonic::Status,
4669 >;
4670 fn call(
4671 &mut self,
4672 request: tonic::Request<super::AlterConnectorPropsRequest>,
4673 ) -> Self::Future {
4674 let inner = Arc::clone(&self.0);
4675 let fut = async move {
4676 <T as StreamManagerService>::alter_connector_props(
4677 &inner,
4678 request,
4679 )
4680 .await
4681 };
4682 Box::pin(fut)
4683 }
4684 }
4685 let accept_compression_encodings = self.accept_compression_encodings;
4686 let send_compression_encodings = self.send_compression_encodings;
4687 let max_decoding_message_size = self.max_decoding_message_size;
4688 let max_encoding_message_size = self.max_encoding_message_size;
4689 let inner = self.inner.clone();
4690 let fut = async move {
4691 let method = AlterConnectorPropsSvc(inner);
4692 let codec = tonic_prost::ProstCodec::default();
4693 let mut grpc = tonic::server::Grpc::new(codec)
4694 .apply_compression_config(
4695 accept_compression_encodings,
4696 send_compression_encodings,
4697 )
4698 .apply_max_message_size_config(
4699 max_decoding_message_size,
4700 max_encoding_message_size,
4701 );
4702 let res = grpc.unary(method, req).await;
4703 Ok(res)
4704 };
4705 Box::pin(fut)
4706 }
4707 "/meta.StreamManagerService/AlterSourcePropertiesSafe" => {
4708 #[allow(non_camel_case_types)]
4709 struct AlterSourcePropertiesSafeSvc<T: StreamManagerService>(
4710 pub Arc<T>,
4711 );
4712 impl<
4713 T: StreamManagerService,
4714 > tonic::server::UnaryService<
4715 super::AlterSourcePropertiesSafeRequest,
4716 > for AlterSourcePropertiesSafeSvc<T> {
4717 type Response = super::AlterSourcePropertiesSafeResponse;
4718 type Future = BoxFuture<
4719 tonic::Response<Self::Response>,
4720 tonic::Status,
4721 >;
4722 fn call(
4723 &mut self,
4724 request: tonic::Request<
4725 super::AlterSourcePropertiesSafeRequest,
4726 >,
4727 ) -> Self::Future {
4728 let inner = Arc::clone(&self.0);
4729 let fut = async move {
4730 <T as StreamManagerService>::alter_source_properties_safe(
4731 &inner,
4732 request,
4733 )
4734 .await
4735 };
4736 Box::pin(fut)
4737 }
4738 }
4739 let accept_compression_encodings = self.accept_compression_encodings;
4740 let send_compression_encodings = self.send_compression_encodings;
4741 let max_decoding_message_size = self.max_decoding_message_size;
4742 let max_encoding_message_size = self.max_encoding_message_size;
4743 let inner = self.inner.clone();
4744 let fut = async move {
4745 let method = AlterSourcePropertiesSafeSvc(inner);
4746 let codec = tonic_prost::ProstCodec::default();
4747 let mut grpc = tonic::server::Grpc::new(codec)
4748 .apply_compression_config(
4749 accept_compression_encodings,
4750 send_compression_encodings,
4751 )
4752 .apply_max_message_size_config(
4753 max_decoding_message_size,
4754 max_encoding_message_size,
4755 );
4756 let res = grpc.unary(method, req).await;
4757 Ok(res)
4758 };
4759 Box::pin(fut)
4760 }
4761 "/meta.StreamManagerService/ResetSourceSplits" => {
4762 #[allow(non_camel_case_types)]
4763 struct ResetSourceSplitsSvc<T: StreamManagerService>(pub Arc<T>);
4764 impl<
4765 T: StreamManagerService,
4766 > tonic::server::UnaryService<super::ResetSourceSplitsRequest>
4767 for ResetSourceSplitsSvc<T> {
4768 type Response = super::ResetSourceSplitsResponse;
4769 type Future = BoxFuture<
4770 tonic::Response<Self::Response>,
4771 tonic::Status,
4772 >;
4773 fn call(
4774 &mut self,
4775 request: tonic::Request<super::ResetSourceSplitsRequest>,
4776 ) -> Self::Future {
4777 let inner = Arc::clone(&self.0);
4778 let fut = async move {
4779 <T as StreamManagerService>::reset_source_splits(
4780 &inner,
4781 request,
4782 )
4783 .await
4784 };
4785 Box::pin(fut)
4786 }
4787 }
4788 let accept_compression_encodings = self.accept_compression_encodings;
4789 let send_compression_encodings = self.send_compression_encodings;
4790 let max_decoding_message_size = self.max_decoding_message_size;
4791 let max_encoding_message_size = self.max_encoding_message_size;
4792 let inner = self.inner.clone();
4793 let fut = async move {
4794 let method = ResetSourceSplitsSvc(inner);
4795 let codec = tonic_prost::ProstCodec::default();
4796 let mut grpc = tonic::server::Grpc::new(codec)
4797 .apply_compression_config(
4798 accept_compression_encodings,
4799 send_compression_encodings,
4800 )
4801 .apply_max_message_size_config(
4802 max_decoding_message_size,
4803 max_encoding_message_size,
4804 );
4805 let res = grpc.unary(method, req).await;
4806 Ok(res)
4807 };
4808 Box::pin(fut)
4809 }
4810 "/meta.StreamManagerService/InjectSourceOffsets" => {
4811 #[allow(non_camel_case_types)]
4812 struct InjectSourceOffsetsSvc<T: StreamManagerService>(pub Arc<T>);
4813 impl<
4814 T: StreamManagerService,
4815 > tonic::server::UnaryService<super::InjectSourceOffsetsRequest>
4816 for InjectSourceOffsetsSvc<T> {
4817 type Response = super::InjectSourceOffsetsResponse;
4818 type Future = BoxFuture<
4819 tonic::Response<Self::Response>,
4820 tonic::Status,
4821 >;
4822 fn call(
4823 &mut self,
4824 request: tonic::Request<super::InjectSourceOffsetsRequest>,
4825 ) -> Self::Future {
4826 let inner = Arc::clone(&self.0);
4827 let fut = async move {
4828 <T as StreamManagerService>::inject_source_offsets(
4829 &inner,
4830 request,
4831 )
4832 .await
4833 };
4834 Box::pin(fut)
4835 }
4836 }
4837 let accept_compression_encodings = self.accept_compression_encodings;
4838 let send_compression_encodings = self.send_compression_encodings;
4839 let max_decoding_message_size = self.max_decoding_message_size;
4840 let max_encoding_message_size = self.max_encoding_message_size;
4841 let inner = self.inner.clone();
4842 let fut = async move {
4843 let method = InjectSourceOffsetsSvc(inner);
4844 let codec = tonic_prost::ProstCodec::default();
4845 let mut grpc = tonic::server::Grpc::new(codec)
4846 .apply_compression_config(
4847 accept_compression_encodings,
4848 send_compression_encodings,
4849 )
4850 .apply_max_message_size_config(
4851 max_decoding_message_size,
4852 max_encoding_message_size,
4853 );
4854 let res = grpc.unary(method, req).await;
4855 Ok(res)
4856 };
4857 Box::pin(fut)
4858 }
4859 "/meta.StreamManagerService/GetFragmentById" => {
4860 #[allow(non_camel_case_types)]
4861 struct GetFragmentByIdSvc<T: StreamManagerService>(pub Arc<T>);
4862 impl<
4863 T: StreamManagerService,
4864 > tonic::server::UnaryService<super::GetFragmentByIdRequest>
4865 for GetFragmentByIdSvc<T> {
4866 type Response = super::GetFragmentByIdResponse;
4867 type Future = BoxFuture<
4868 tonic::Response<Self::Response>,
4869 tonic::Status,
4870 >;
4871 fn call(
4872 &mut self,
4873 request: tonic::Request<super::GetFragmentByIdRequest>,
4874 ) -> Self::Future {
4875 let inner = Arc::clone(&self.0);
4876 let fut = async move {
4877 <T as StreamManagerService>::get_fragment_by_id(
4878 &inner,
4879 request,
4880 )
4881 .await
4882 };
4883 Box::pin(fut)
4884 }
4885 }
4886 let accept_compression_encodings = self.accept_compression_encodings;
4887 let send_compression_encodings = self.send_compression_encodings;
4888 let max_decoding_message_size = self.max_decoding_message_size;
4889 let max_encoding_message_size = self.max_encoding_message_size;
4890 let inner = self.inner.clone();
4891 let fut = async move {
4892 let method = GetFragmentByIdSvc(inner);
4893 let codec = tonic_prost::ProstCodec::default();
4894 let mut grpc = tonic::server::Grpc::new(codec)
4895 .apply_compression_config(
4896 accept_compression_encodings,
4897 send_compression_encodings,
4898 )
4899 .apply_max_message_size_config(
4900 max_decoding_message_size,
4901 max_encoding_message_size,
4902 );
4903 let res = grpc.unary(method, req).await;
4904 Ok(res)
4905 };
4906 Box::pin(fut)
4907 }
4908 "/meta.StreamManagerService/GetFragmentVnodes" => {
4909 #[allow(non_camel_case_types)]
4910 struct GetFragmentVnodesSvc<T: StreamManagerService>(pub Arc<T>);
4911 impl<
4912 T: StreamManagerService,
4913 > tonic::server::UnaryService<super::GetFragmentVnodesRequest>
4914 for GetFragmentVnodesSvc<T> {
4915 type Response = super::GetFragmentVnodesResponse;
4916 type Future = BoxFuture<
4917 tonic::Response<Self::Response>,
4918 tonic::Status,
4919 >;
4920 fn call(
4921 &mut self,
4922 request: tonic::Request<super::GetFragmentVnodesRequest>,
4923 ) -> Self::Future {
4924 let inner = Arc::clone(&self.0);
4925 let fut = async move {
4926 <T as StreamManagerService>::get_fragment_vnodes(
4927 &inner,
4928 request,
4929 )
4930 .await
4931 };
4932 Box::pin(fut)
4933 }
4934 }
4935 let accept_compression_encodings = self.accept_compression_encodings;
4936 let send_compression_encodings = self.send_compression_encodings;
4937 let max_decoding_message_size = self.max_decoding_message_size;
4938 let max_encoding_message_size = self.max_encoding_message_size;
4939 let inner = self.inner.clone();
4940 let fut = async move {
4941 let method = GetFragmentVnodesSvc(inner);
4942 let codec = tonic_prost::ProstCodec::default();
4943 let mut grpc = tonic::server::Grpc::new(codec)
4944 .apply_compression_config(
4945 accept_compression_encodings,
4946 send_compression_encodings,
4947 )
4948 .apply_max_message_size_config(
4949 max_decoding_message_size,
4950 max_encoding_message_size,
4951 );
4952 let res = grpc.unary(method, req).await;
4953 Ok(res)
4954 };
4955 Box::pin(fut)
4956 }
4957 "/meta.StreamManagerService/GetActorVnodes" => {
4958 #[allow(non_camel_case_types)]
4959 struct GetActorVnodesSvc<T: StreamManagerService>(pub Arc<T>);
4960 impl<
4961 T: StreamManagerService,
4962 > tonic::server::UnaryService<super::GetActorVnodesRequest>
4963 for GetActorVnodesSvc<T> {
4964 type Response = super::GetActorVnodesResponse;
4965 type Future = BoxFuture<
4966 tonic::Response<Self::Response>,
4967 tonic::Status,
4968 >;
4969 fn call(
4970 &mut self,
4971 request: tonic::Request<super::GetActorVnodesRequest>,
4972 ) -> Self::Future {
4973 let inner = Arc::clone(&self.0);
4974 let fut = async move {
4975 <T as StreamManagerService>::get_actor_vnodes(
4976 &inner,
4977 request,
4978 )
4979 .await
4980 };
4981 Box::pin(fut)
4982 }
4983 }
4984 let accept_compression_encodings = self.accept_compression_encodings;
4985 let send_compression_encodings = self.send_compression_encodings;
4986 let max_decoding_message_size = self.max_decoding_message_size;
4987 let max_encoding_message_size = self.max_encoding_message_size;
4988 let inner = self.inner.clone();
4989 let fut = async move {
4990 let method = GetActorVnodesSvc(inner);
4991 let codec = tonic_prost::ProstCodec::default();
4992 let mut grpc = tonic::server::Grpc::new(codec)
4993 .apply_compression_config(
4994 accept_compression_encodings,
4995 send_compression_encodings,
4996 )
4997 .apply_max_message_size_config(
4998 max_decoding_message_size,
4999 max_encoding_message_size,
5000 );
5001 let res = grpc.unary(method, req).await;
5002 Ok(res)
5003 };
5004 Box::pin(fut)
5005 }
5006 "/meta.StreamManagerService/SetSyncLogStoreAligned" => {
5007 #[allow(non_camel_case_types)]
5008 struct SetSyncLogStoreAlignedSvc<T: StreamManagerService>(
5009 pub Arc<T>,
5010 );
5011 impl<
5012 T: StreamManagerService,
5013 > tonic::server::UnaryService<super::SetSyncLogStoreAlignedRequest>
5014 for SetSyncLogStoreAlignedSvc<T> {
5015 type Response = super::SetSyncLogStoreAlignedResponse;
5016 type Future = BoxFuture<
5017 tonic::Response<Self::Response>,
5018 tonic::Status,
5019 >;
5020 fn call(
5021 &mut self,
5022 request: tonic::Request<super::SetSyncLogStoreAlignedRequest>,
5023 ) -> Self::Future {
5024 let inner = Arc::clone(&self.0);
5025 let fut = async move {
5026 <T as StreamManagerService>::set_sync_log_store_aligned(
5027 &inner,
5028 request,
5029 )
5030 .await
5031 };
5032 Box::pin(fut)
5033 }
5034 }
5035 let accept_compression_encodings = self.accept_compression_encodings;
5036 let send_compression_encodings = self.send_compression_encodings;
5037 let max_decoding_message_size = self.max_decoding_message_size;
5038 let max_encoding_message_size = self.max_encoding_message_size;
5039 let inner = self.inner.clone();
5040 let fut = async move {
5041 let method = SetSyncLogStoreAlignedSvc(inner);
5042 let codec = tonic_prost::ProstCodec::default();
5043 let mut grpc = tonic::server::Grpc::new(codec)
5044 .apply_compression_config(
5045 accept_compression_encodings,
5046 send_compression_encodings,
5047 )
5048 .apply_max_message_size_config(
5049 max_decoding_message_size,
5050 max_encoding_message_size,
5051 );
5052 let res = grpc.unary(method, req).await;
5053 Ok(res)
5054 };
5055 Box::pin(fut)
5056 }
5057 "/meta.StreamManagerService/ListCdcProgress" => {
5058 #[allow(non_camel_case_types)]
5059 struct ListCdcProgressSvc<T: StreamManagerService>(pub Arc<T>);
5060 impl<
5061 T: StreamManagerService,
5062 > tonic::server::UnaryService<super::ListCdcProgressRequest>
5063 for ListCdcProgressSvc<T> {
5064 type Response = super::ListCdcProgressResponse;
5065 type Future = BoxFuture<
5066 tonic::Response<Self::Response>,
5067 tonic::Status,
5068 >;
5069 fn call(
5070 &mut self,
5071 request: tonic::Request<super::ListCdcProgressRequest>,
5072 ) -> Self::Future {
5073 let inner = Arc::clone(&self.0);
5074 let fut = async move {
5075 <T as StreamManagerService>::list_cdc_progress(
5076 &inner,
5077 request,
5078 )
5079 .await
5080 };
5081 Box::pin(fut)
5082 }
5083 }
5084 let accept_compression_encodings = self.accept_compression_encodings;
5085 let send_compression_encodings = self.send_compression_encodings;
5086 let max_decoding_message_size = self.max_decoding_message_size;
5087 let max_encoding_message_size = self.max_encoding_message_size;
5088 let inner = self.inner.clone();
5089 let fut = async move {
5090 let method = ListCdcProgressSvc(inner);
5091 let codec = tonic_prost::ProstCodec::default();
5092 let mut grpc = tonic::server::Grpc::new(codec)
5093 .apply_compression_config(
5094 accept_compression_encodings,
5095 send_compression_encodings,
5096 )
5097 .apply_max_message_size_config(
5098 max_decoding_message_size,
5099 max_encoding_message_size,
5100 );
5101 let res = grpc.unary(method, req).await;
5102 Ok(res)
5103 };
5104 Box::pin(fut)
5105 }
5106 "/meta.StreamManagerService/ListUnmigratedTables" => {
5107 #[allow(non_camel_case_types)]
5108 struct ListUnmigratedTablesSvc<T: StreamManagerService>(pub Arc<T>);
5109 impl<
5110 T: StreamManagerService,
5111 > tonic::server::UnaryService<super::ListUnmigratedTablesRequest>
5112 for ListUnmigratedTablesSvc<T> {
5113 type Response = super::ListUnmigratedTablesResponse;
5114 type Future = BoxFuture<
5115 tonic::Response<Self::Response>,
5116 tonic::Status,
5117 >;
5118 fn call(
5119 &mut self,
5120 request: tonic::Request<super::ListUnmigratedTablesRequest>,
5121 ) -> Self::Future {
5122 let inner = Arc::clone(&self.0);
5123 let fut = async move {
5124 <T as StreamManagerService>::list_unmigrated_tables(
5125 &inner,
5126 request,
5127 )
5128 .await
5129 };
5130 Box::pin(fut)
5131 }
5132 }
5133 let accept_compression_encodings = self.accept_compression_encodings;
5134 let send_compression_encodings = self.send_compression_encodings;
5135 let max_decoding_message_size = self.max_decoding_message_size;
5136 let max_encoding_message_size = self.max_encoding_message_size;
5137 let inner = self.inner.clone();
5138 let fut = async move {
5139 let method = ListUnmigratedTablesSvc(inner);
5140 let codec = tonic_prost::ProstCodec::default();
5141 let mut grpc = tonic::server::Grpc::new(codec)
5142 .apply_compression_config(
5143 accept_compression_encodings,
5144 send_compression_encodings,
5145 )
5146 .apply_max_message_size_config(
5147 max_decoding_message_size,
5148 max_encoding_message_size,
5149 );
5150 let res = grpc.unary(method, req).await;
5151 Ok(res)
5152 };
5153 Box::pin(fut)
5154 }
5155 "/meta.StreamManagerService/ListRefreshTableStates" => {
5156 #[allow(non_camel_case_types)]
5157 struct ListRefreshTableStatesSvc<T: StreamManagerService>(
5158 pub Arc<T>,
5159 );
5160 impl<
5161 T: StreamManagerService,
5162 > tonic::server::UnaryService<super::ListRefreshTableStatesRequest>
5163 for ListRefreshTableStatesSvc<T> {
5164 type Response = super::ListRefreshTableStatesResponse;
5165 type Future = BoxFuture<
5166 tonic::Response<Self::Response>,
5167 tonic::Status,
5168 >;
5169 fn call(
5170 &mut self,
5171 request: tonic::Request<super::ListRefreshTableStatesRequest>,
5172 ) -> Self::Future {
5173 let inner = Arc::clone(&self.0);
5174 let fut = async move {
5175 <T as StreamManagerService>::list_refresh_table_states(
5176 &inner,
5177 request,
5178 )
5179 .await
5180 };
5181 Box::pin(fut)
5182 }
5183 }
5184 let accept_compression_encodings = self.accept_compression_encodings;
5185 let send_compression_encodings = self.send_compression_encodings;
5186 let max_decoding_message_size = self.max_decoding_message_size;
5187 let max_encoding_message_size = self.max_encoding_message_size;
5188 let inner = self.inner.clone();
5189 let fut = async move {
5190 let method = ListRefreshTableStatesSvc(inner);
5191 let codec = tonic_prost::ProstCodec::default();
5192 let mut grpc = tonic::server::Grpc::new(codec)
5193 .apply_compression_config(
5194 accept_compression_encodings,
5195 send_compression_encodings,
5196 )
5197 .apply_max_message_size_config(
5198 max_decoding_message_size,
5199 max_encoding_message_size,
5200 );
5201 let res = grpc.unary(method, req).await;
5202 Ok(res)
5203 };
5204 Box::pin(fut)
5205 }
5206 "/meta.StreamManagerService/ListBoundedJobs" => {
5207 #[allow(non_camel_case_types)]
5208 struct ListBoundedJobsSvc<T: StreamManagerService>(pub Arc<T>);
5209 impl<
5210 T: StreamManagerService,
5211 > tonic::server::UnaryService<super::ListBoundedJobsRequest>
5212 for ListBoundedJobsSvc<T> {
5213 type Response = super::ListBoundedJobsResponse;
5214 type Future = BoxFuture<
5215 tonic::Response<Self::Response>,
5216 tonic::Status,
5217 >;
5218 fn call(
5219 &mut self,
5220 request: tonic::Request<super::ListBoundedJobsRequest>,
5221 ) -> Self::Future {
5222 let inner = Arc::clone(&self.0);
5223 let fut = async move {
5224 <T as StreamManagerService>::list_bounded_jobs(
5225 &inner,
5226 request,
5227 )
5228 .await
5229 };
5230 Box::pin(fut)
5231 }
5232 }
5233 let accept_compression_encodings = self.accept_compression_encodings;
5234 let send_compression_encodings = self.send_compression_encodings;
5235 let max_decoding_message_size = self.max_decoding_message_size;
5236 let max_encoding_message_size = self.max_encoding_message_size;
5237 let inner = self.inner.clone();
5238 let fut = async move {
5239 let method = ListBoundedJobsSvc(inner);
5240 let codec = tonic_prost::ProstCodec::default();
5241 let mut grpc = tonic::server::Grpc::new(codec)
5242 .apply_compression_config(
5243 accept_compression_encodings,
5244 send_compression_encodings,
5245 )
5246 .apply_max_message_size_config(
5247 max_decoding_message_size,
5248 max_encoding_message_size,
5249 );
5250 let res = grpc.unary(method, req).await;
5251 Ok(res)
5252 };
5253 Box::pin(fut)
5254 }
5255 "/meta.StreamManagerService/ListIcebergCompactionStatus" => {
5256 #[allow(non_camel_case_types)]
5257 struct ListIcebergCompactionStatusSvc<T: StreamManagerService>(
5258 pub Arc<T>,
5259 );
5260 impl<
5261 T: StreamManagerService,
5262 > tonic::server::UnaryService<
5263 super::ListIcebergCompactionStatusRequest,
5264 > for ListIcebergCompactionStatusSvc<T> {
5265 type Response = super::ListIcebergCompactionStatusResponse;
5266 type Future = BoxFuture<
5267 tonic::Response<Self::Response>,
5268 tonic::Status,
5269 >;
5270 fn call(
5271 &mut self,
5272 request: tonic::Request<
5273 super::ListIcebergCompactionStatusRequest,
5274 >,
5275 ) -> Self::Future {
5276 let inner = Arc::clone(&self.0);
5277 let fut = async move {
5278 <T as StreamManagerService>::list_iceberg_compaction_status(
5279 &inner,
5280 request,
5281 )
5282 .await
5283 };
5284 Box::pin(fut)
5285 }
5286 }
5287 let accept_compression_encodings = self.accept_compression_encodings;
5288 let send_compression_encodings = self.send_compression_encodings;
5289 let max_decoding_message_size = self.max_decoding_message_size;
5290 let max_encoding_message_size = self.max_encoding_message_size;
5291 let inner = self.inner.clone();
5292 let fut = async move {
5293 let method = ListIcebergCompactionStatusSvc(inner);
5294 let codec = tonic_prost::ProstCodec::default();
5295 let mut grpc = tonic::server::Grpc::new(codec)
5296 .apply_compression_config(
5297 accept_compression_encodings,
5298 send_compression_encodings,
5299 )
5300 .apply_max_message_size_config(
5301 max_decoding_message_size,
5302 max_encoding_message_size,
5303 );
5304 let res = grpc.unary(method, req).await;
5305 Ok(res)
5306 };
5307 Box::pin(fut)
5308 }
5309 _ => {
5310 Box::pin(async move {
5311 let mut response = http::Response::new(
5312 tonic::body::Body::default(),
5313 );
5314 let headers = response.headers_mut();
5315 headers
5316 .insert(
5317 tonic::Status::GRPC_STATUS,
5318 (tonic::Code::Unimplemented as i32).into(),
5319 );
5320 headers
5321 .insert(
5322 http::header::CONTENT_TYPE,
5323 tonic::metadata::GRPC_CONTENT_TYPE,
5324 );
5325 Ok(response)
5326 })
5327 }
5328 }
5329 }
5330 }
5331 impl<T> Clone for StreamManagerServiceServer<T> {
5332 fn clone(&self) -> Self {
5333 let inner = self.inner.clone();
5334 Self {
5335 inner,
5336 accept_compression_encodings: self.accept_compression_encodings,
5337 send_compression_encodings: self.send_compression_encodings,
5338 max_decoding_message_size: self.max_decoding_message_size,
5339 max_encoding_message_size: self.max_encoding_message_size,
5340 }
5341 }
5342 }
5343 pub const SERVICE_NAME: &str = "meta.StreamManagerService";
5345 impl<T> tonic::server::NamedService for StreamManagerServiceServer<T> {
5346 const NAME: &'static str = SERVICE_NAME;
5347 }
5348}
5349pub mod cluster_service_client {
5351 #![allow(
5352 unused_variables,
5353 dead_code,
5354 missing_docs,
5355 clippy::wildcard_imports,
5356 clippy::let_unit_value,
5357 )]
5358 use tonic::codegen::*;
5359 use tonic::codegen::http::Uri;
5360 #[derive(Debug, Clone)]
5361 pub struct ClusterServiceClient<T> {
5362 inner: tonic::client::Grpc<T>,
5363 }
5364 impl ClusterServiceClient<tonic::transport::Channel> {
5365 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
5367 where
5368 D: TryInto<tonic::transport::Endpoint>,
5369 D::Error: Into<StdError>,
5370 {
5371 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
5372 Ok(Self::new(conn))
5373 }
5374 }
5375 impl<T> ClusterServiceClient<T>
5376 where
5377 T: tonic::client::GrpcService<tonic::body::Body>,
5378 T::Error: Into<StdError>,
5379 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
5380 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
5381 {
5382 pub fn new(inner: T) -> Self {
5383 let inner = tonic::client::Grpc::new(inner);
5384 Self { inner }
5385 }
5386 pub fn with_origin(inner: T, origin: Uri) -> Self {
5387 let inner = tonic::client::Grpc::with_origin(inner, origin);
5388 Self { inner }
5389 }
5390 pub fn with_interceptor<F>(
5391 inner: T,
5392 interceptor: F,
5393 ) -> ClusterServiceClient<InterceptedService<T, F>>
5394 where
5395 F: tonic::service::Interceptor,
5396 T::ResponseBody: Default,
5397 T: tonic::codegen::Service<
5398 http::Request<tonic::body::Body>,
5399 Response = http::Response<
5400 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
5401 >,
5402 >,
5403 <T as tonic::codegen::Service<
5404 http::Request<tonic::body::Body>,
5405 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
5406 {
5407 ClusterServiceClient::new(InterceptedService::new(inner, interceptor))
5408 }
5409 #[must_use]
5414 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
5415 self.inner = self.inner.send_compressed(encoding);
5416 self
5417 }
5418 #[must_use]
5420 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
5421 self.inner = self.inner.accept_compressed(encoding);
5422 self
5423 }
5424 #[must_use]
5428 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
5429 self.inner = self.inner.max_decoding_message_size(limit);
5430 self
5431 }
5432 #[must_use]
5436 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
5437 self.inner = self.inner.max_encoding_message_size(limit);
5438 self
5439 }
5440 pub async fn add_worker_node(
5441 &mut self,
5442 request: impl tonic::IntoRequest<super::AddWorkerNodeRequest>,
5443 ) -> std::result::Result<
5444 tonic::Response<super::AddWorkerNodeResponse>,
5445 tonic::Status,
5446 > {
5447 self.inner
5448 .ready()
5449 .await
5450 .map_err(|e| {
5451 tonic::Status::unknown(
5452 format!("Service was not ready: {}", e.into()),
5453 )
5454 })?;
5455 let codec = tonic_prost::ProstCodec::default();
5456 let path = http::uri::PathAndQuery::from_static(
5457 "/meta.ClusterService/AddWorkerNode",
5458 );
5459 let mut req = request.into_request();
5460 req.extensions_mut()
5461 .insert(GrpcMethod::new("meta.ClusterService", "AddWorkerNode"));
5462 self.inner.unary(req, path, codec).await
5463 }
5464 pub async fn activate_worker_node(
5465 &mut self,
5466 request: impl tonic::IntoRequest<super::ActivateWorkerNodeRequest>,
5467 ) -> std::result::Result<
5468 tonic::Response<super::ActivateWorkerNodeResponse>,
5469 tonic::Status,
5470 > {
5471 self.inner
5472 .ready()
5473 .await
5474 .map_err(|e| {
5475 tonic::Status::unknown(
5476 format!("Service was not ready: {}", e.into()),
5477 )
5478 })?;
5479 let codec = tonic_prost::ProstCodec::default();
5480 let path = http::uri::PathAndQuery::from_static(
5481 "/meta.ClusterService/ActivateWorkerNode",
5482 );
5483 let mut req = request.into_request();
5484 req.extensions_mut()
5485 .insert(GrpcMethod::new("meta.ClusterService", "ActivateWorkerNode"));
5486 self.inner.unary(req, path, codec).await
5487 }
5488 pub async fn delete_worker_node(
5489 &mut self,
5490 request: impl tonic::IntoRequest<super::DeleteWorkerNodeRequest>,
5491 ) -> std::result::Result<
5492 tonic::Response<super::DeleteWorkerNodeResponse>,
5493 tonic::Status,
5494 > {
5495 self.inner
5496 .ready()
5497 .await
5498 .map_err(|e| {
5499 tonic::Status::unknown(
5500 format!("Service was not ready: {}", e.into()),
5501 )
5502 })?;
5503 let codec = tonic_prost::ProstCodec::default();
5504 let path = http::uri::PathAndQuery::from_static(
5505 "/meta.ClusterService/DeleteWorkerNode",
5506 );
5507 let mut req = request.into_request();
5508 req.extensions_mut()
5509 .insert(GrpcMethod::new("meta.ClusterService", "DeleteWorkerNode"));
5510 self.inner.unary(req, path, codec).await
5511 }
5512 pub async fn list_all_nodes(
5513 &mut self,
5514 request: impl tonic::IntoRequest<super::ListAllNodesRequest>,
5515 ) -> std::result::Result<
5516 tonic::Response<super::ListAllNodesResponse>,
5517 tonic::Status,
5518 > {
5519 self.inner
5520 .ready()
5521 .await
5522 .map_err(|e| {
5523 tonic::Status::unknown(
5524 format!("Service was not ready: {}", e.into()),
5525 )
5526 })?;
5527 let codec = tonic_prost::ProstCodec::default();
5528 let path = http::uri::PathAndQuery::from_static(
5529 "/meta.ClusterService/ListAllNodes",
5530 );
5531 let mut req = request.into_request();
5532 req.extensions_mut()
5533 .insert(GrpcMethod::new("meta.ClusterService", "ListAllNodes"));
5534 self.inner.unary(req, path, codec).await
5535 }
5536 pub async fn get_cluster_recovery_status(
5537 &mut self,
5538 request: impl tonic::IntoRequest<super::GetClusterRecoveryStatusRequest>,
5539 ) -> std::result::Result<
5540 tonic::Response<super::GetClusterRecoveryStatusResponse>,
5541 tonic::Status,
5542 > {
5543 self.inner
5544 .ready()
5545 .await
5546 .map_err(|e| {
5547 tonic::Status::unknown(
5548 format!("Service was not ready: {}", e.into()),
5549 )
5550 })?;
5551 let codec = tonic_prost::ProstCodec::default();
5552 let path = http::uri::PathAndQuery::from_static(
5553 "/meta.ClusterService/GetClusterRecoveryStatus",
5554 );
5555 let mut req = request.into_request();
5556 req.extensions_mut()
5557 .insert(
5558 GrpcMethod::new("meta.ClusterService", "GetClusterRecoveryStatus"),
5559 );
5560 self.inner.unary(req, path, codec).await
5561 }
5562 pub async fn get_meta_store_info(
5563 &mut self,
5564 request: impl tonic::IntoRequest<super::GetMetaStoreInfoRequest>,
5565 ) -> std::result::Result<
5566 tonic::Response<super::GetMetaStoreInfoResponse>,
5567 tonic::Status,
5568 > {
5569 self.inner
5570 .ready()
5571 .await
5572 .map_err(|e| {
5573 tonic::Status::unknown(
5574 format!("Service was not ready: {}", e.into()),
5575 )
5576 })?;
5577 let codec = tonic_prost::ProstCodec::default();
5578 let path = http::uri::PathAndQuery::from_static(
5579 "/meta.ClusterService/GetMetaStoreInfo",
5580 );
5581 let mut req = request.into_request();
5582 req.extensions_mut()
5583 .insert(GrpcMethod::new("meta.ClusterService", "GetMetaStoreInfo"));
5584 self.inner.unary(req, path, codec).await
5585 }
5586 }
5587}
5588pub mod cluster_service_server {
5590 #![allow(
5591 unused_variables,
5592 dead_code,
5593 missing_docs,
5594 clippy::wildcard_imports,
5595 clippy::let_unit_value,
5596 )]
5597 use tonic::codegen::*;
5598 #[async_trait]
5600 pub trait ClusterService: std::marker::Send + std::marker::Sync + 'static {
5601 async fn add_worker_node(
5602 &self,
5603 request: tonic::Request<super::AddWorkerNodeRequest>,
5604 ) -> std::result::Result<
5605 tonic::Response<super::AddWorkerNodeResponse>,
5606 tonic::Status,
5607 >;
5608 async fn activate_worker_node(
5609 &self,
5610 request: tonic::Request<super::ActivateWorkerNodeRequest>,
5611 ) -> std::result::Result<
5612 tonic::Response<super::ActivateWorkerNodeResponse>,
5613 tonic::Status,
5614 >;
5615 async fn delete_worker_node(
5616 &self,
5617 request: tonic::Request<super::DeleteWorkerNodeRequest>,
5618 ) -> std::result::Result<
5619 tonic::Response<super::DeleteWorkerNodeResponse>,
5620 tonic::Status,
5621 >;
5622 async fn list_all_nodes(
5623 &self,
5624 request: tonic::Request<super::ListAllNodesRequest>,
5625 ) -> std::result::Result<
5626 tonic::Response<super::ListAllNodesResponse>,
5627 tonic::Status,
5628 >;
5629 async fn get_cluster_recovery_status(
5630 &self,
5631 request: tonic::Request<super::GetClusterRecoveryStatusRequest>,
5632 ) -> std::result::Result<
5633 tonic::Response<super::GetClusterRecoveryStatusResponse>,
5634 tonic::Status,
5635 >;
5636 async fn get_meta_store_info(
5637 &self,
5638 request: tonic::Request<super::GetMetaStoreInfoRequest>,
5639 ) -> std::result::Result<
5640 tonic::Response<super::GetMetaStoreInfoResponse>,
5641 tonic::Status,
5642 >;
5643 }
5644 #[derive(Debug)]
5645 pub struct ClusterServiceServer<T> {
5646 inner: Arc<T>,
5647 accept_compression_encodings: EnabledCompressionEncodings,
5648 send_compression_encodings: EnabledCompressionEncodings,
5649 max_decoding_message_size: Option<usize>,
5650 max_encoding_message_size: Option<usize>,
5651 }
5652 impl<T> ClusterServiceServer<T> {
5653 pub fn new(inner: T) -> Self {
5654 Self::from_arc(Arc::new(inner))
5655 }
5656 pub fn from_arc(inner: Arc<T>) -> Self {
5657 Self {
5658 inner,
5659 accept_compression_encodings: Default::default(),
5660 send_compression_encodings: Default::default(),
5661 max_decoding_message_size: None,
5662 max_encoding_message_size: None,
5663 }
5664 }
5665 pub fn with_interceptor<F>(
5666 inner: T,
5667 interceptor: F,
5668 ) -> InterceptedService<Self, F>
5669 where
5670 F: tonic::service::Interceptor,
5671 {
5672 InterceptedService::new(Self::new(inner), interceptor)
5673 }
5674 #[must_use]
5676 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
5677 self.accept_compression_encodings.enable(encoding);
5678 self
5679 }
5680 #[must_use]
5682 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
5683 self.send_compression_encodings.enable(encoding);
5684 self
5685 }
5686 #[must_use]
5690 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
5691 self.max_decoding_message_size = Some(limit);
5692 self
5693 }
5694 #[must_use]
5698 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
5699 self.max_encoding_message_size = Some(limit);
5700 self
5701 }
5702 }
5703 impl<T, B> tonic::codegen::Service<http::Request<B>> for ClusterServiceServer<T>
5704 where
5705 T: ClusterService,
5706 B: Body + std::marker::Send + 'static,
5707 B::Error: Into<StdError> + std::marker::Send + 'static,
5708 {
5709 type Response = http::Response<tonic::body::Body>;
5710 type Error = std::convert::Infallible;
5711 type Future = BoxFuture<Self::Response, Self::Error>;
5712 fn poll_ready(
5713 &mut self,
5714 _cx: &mut Context<'_>,
5715 ) -> Poll<std::result::Result<(), Self::Error>> {
5716 Poll::Ready(Ok(()))
5717 }
5718 fn call(&mut self, req: http::Request<B>) -> Self::Future {
5719 match req.uri().path() {
5720 "/meta.ClusterService/AddWorkerNode" => {
5721 #[allow(non_camel_case_types)]
5722 struct AddWorkerNodeSvc<T: ClusterService>(pub Arc<T>);
5723 impl<
5724 T: ClusterService,
5725 > tonic::server::UnaryService<super::AddWorkerNodeRequest>
5726 for AddWorkerNodeSvc<T> {
5727 type Response = super::AddWorkerNodeResponse;
5728 type Future = BoxFuture<
5729 tonic::Response<Self::Response>,
5730 tonic::Status,
5731 >;
5732 fn call(
5733 &mut self,
5734 request: tonic::Request<super::AddWorkerNodeRequest>,
5735 ) -> Self::Future {
5736 let inner = Arc::clone(&self.0);
5737 let fut = async move {
5738 <T as ClusterService>::add_worker_node(&inner, request)
5739 .await
5740 };
5741 Box::pin(fut)
5742 }
5743 }
5744 let accept_compression_encodings = self.accept_compression_encodings;
5745 let send_compression_encodings = self.send_compression_encodings;
5746 let max_decoding_message_size = self.max_decoding_message_size;
5747 let max_encoding_message_size = self.max_encoding_message_size;
5748 let inner = self.inner.clone();
5749 let fut = async move {
5750 let method = AddWorkerNodeSvc(inner);
5751 let codec = tonic_prost::ProstCodec::default();
5752 let mut grpc = tonic::server::Grpc::new(codec)
5753 .apply_compression_config(
5754 accept_compression_encodings,
5755 send_compression_encodings,
5756 )
5757 .apply_max_message_size_config(
5758 max_decoding_message_size,
5759 max_encoding_message_size,
5760 );
5761 let res = grpc.unary(method, req).await;
5762 Ok(res)
5763 };
5764 Box::pin(fut)
5765 }
5766 "/meta.ClusterService/ActivateWorkerNode" => {
5767 #[allow(non_camel_case_types)]
5768 struct ActivateWorkerNodeSvc<T: ClusterService>(pub Arc<T>);
5769 impl<
5770 T: ClusterService,
5771 > tonic::server::UnaryService<super::ActivateWorkerNodeRequest>
5772 for ActivateWorkerNodeSvc<T> {
5773 type Response = super::ActivateWorkerNodeResponse;
5774 type Future = BoxFuture<
5775 tonic::Response<Self::Response>,
5776 tonic::Status,
5777 >;
5778 fn call(
5779 &mut self,
5780 request: tonic::Request<super::ActivateWorkerNodeRequest>,
5781 ) -> Self::Future {
5782 let inner = Arc::clone(&self.0);
5783 let fut = async move {
5784 <T as ClusterService>::activate_worker_node(&inner, request)
5785 .await
5786 };
5787 Box::pin(fut)
5788 }
5789 }
5790 let accept_compression_encodings = self.accept_compression_encodings;
5791 let send_compression_encodings = self.send_compression_encodings;
5792 let max_decoding_message_size = self.max_decoding_message_size;
5793 let max_encoding_message_size = self.max_encoding_message_size;
5794 let inner = self.inner.clone();
5795 let fut = async move {
5796 let method = ActivateWorkerNodeSvc(inner);
5797 let codec = tonic_prost::ProstCodec::default();
5798 let mut grpc = tonic::server::Grpc::new(codec)
5799 .apply_compression_config(
5800 accept_compression_encodings,
5801 send_compression_encodings,
5802 )
5803 .apply_max_message_size_config(
5804 max_decoding_message_size,
5805 max_encoding_message_size,
5806 );
5807 let res = grpc.unary(method, req).await;
5808 Ok(res)
5809 };
5810 Box::pin(fut)
5811 }
5812 "/meta.ClusterService/DeleteWorkerNode" => {
5813 #[allow(non_camel_case_types)]
5814 struct DeleteWorkerNodeSvc<T: ClusterService>(pub Arc<T>);
5815 impl<
5816 T: ClusterService,
5817 > tonic::server::UnaryService<super::DeleteWorkerNodeRequest>
5818 for DeleteWorkerNodeSvc<T> {
5819 type Response = super::DeleteWorkerNodeResponse;
5820 type Future = BoxFuture<
5821 tonic::Response<Self::Response>,
5822 tonic::Status,
5823 >;
5824 fn call(
5825 &mut self,
5826 request: tonic::Request<super::DeleteWorkerNodeRequest>,
5827 ) -> Self::Future {
5828 let inner = Arc::clone(&self.0);
5829 let fut = async move {
5830 <T as ClusterService>::delete_worker_node(&inner, request)
5831 .await
5832 };
5833 Box::pin(fut)
5834 }
5835 }
5836 let accept_compression_encodings = self.accept_compression_encodings;
5837 let send_compression_encodings = self.send_compression_encodings;
5838 let max_decoding_message_size = self.max_decoding_message_size;
5839 let max_encoding_message_size = self.max_encoding_message_size;
5840 let inner = self.inner.clone();
5841 let fut = async move {
5842 let method = DeleteWorkerNodeSvc(inner);
5843 let codec = tonic_prost::ProstCodec::default();
5844 let mut grpc = tonic::server::Grpc::new(codec)
5845 .apply_compression_config(
5846 accept_compression_encodings,
5847 send_compression_encodings,
5848 )
5849 .apply_max_message_size_config(
5850 max_decoding_message_size,
5851 max_encoding_message_size,
5852 );
5853 let res = grpc.unary(method, req).await;
5854 Ok(res)
5855 };
5856 Box::pin(fut)
5857 }
5858 "/meta.ClusterService/ListAllNodes" => {
5859 #[allow(non_camel_case_types)]
5860 struct ListAllNodesSvc<T: ClusterService>(pub Arc<T>);
5861 impl<
5862 T: ClusterService,
5863 > tonic::server::UnaryService<super::ListAllNodesRequest>
5864 for ListAllNodesSvc<T> {
5865 type Response = super::ListAllNodesResponse;
5866 type Future = BoxFuture<
5867 tonic::Response<Self::Response>,
5868 tonic::Status,
5869 >;
5870 fn call(
5871 &mut self,
5872 request: tonic::Request<super::ListAllNodesRequest>,
5873 ) -> Self::Future {
5874 let inner = Arc::clone(&self.0);
5875 let fut = async move {
5876 <T as ClusterService>::list_all_nodes(&inner, request).await
5877 };
5878 Box::pin(fut)
5879 }
5880 }
5881 let accept_compression_encodings = self.accept_compression_encodings;
5882 let send_compression_encodings = self.send_compression_encodings;
5883 let max_decoding_message_size = self.max_decoding_message_size;
5884 let max_encoding_message_size = self.max_encoding_message_size;
5885 let inner = self.inner.clone();
5886 let fut = async move {
5887 let method = ListAllNodesSvc(inner);
5888 let codec = tonic_prost::ProstCodec::default();
5889 let mut grpc = tonic::server::Grpc::new(codec)
5890 .apply_compression_config(
5891 accept_compression_encodings,
5892 send_compression_encodings,
5893 )
5894 .apply_max_message_size_config(
5895 max_decoding_message_size,
5896 max_encoding_message_size,
5897 );
5898 let res = grpc.unary(method, req).await;
5899 Ok(res)
5900 };
5901 Box::pin(fut)
5902 }
5903 "/meta.ClusterService/GetClusterRecoveryStatus" => {
5904 #[allow(non_camel_case_types)]
5905 struct GetClusterRecoveryStatusSvc<T: ClusterService>(pub Arc<T>);
5906 impl<
5907 T: ClusterService,
5908 > tonic::server::UnaryService<super::GetClusterRecoveryStatusRequest>
5909 for GetClusterRecoveryStatusSvc<T> {
5910 type Response = super::GetClusterRecoveryStatusResponse;
5911 type Future = BoxFuture<
5912 tonic::Response<Self::Response>,
5913 tonic::Status,
5914 >;
5915 fn call(
5916 &mut self,
5917 request: tonic::Request<
5918 super::GetClusterRecoveryStatusRequest,
5919 >,
5920 ) -> Self::Future {
5921 let inner = Arc::clone(&self.0);
5922 let fut = async move {
5923 <T as ClusterService>::get_cluster_recovery_status(
5924 &inner,
5925 request,
5926 )
5927 .await
5928 };
5929 Box::pin(fut)
5930 }
5931 }
5932 let accept_compression_encodings = self.accept_compression_encodings;
5933 let send_compression_encodings = self.send_compression_encodings;
5934 let max_decoding_message_size = self.max_decoding_message_size;
5935 let max_encoding_message_size = self.max_encoding_message_size;
5936 let inner = self.inner.clone();
5937 let fut = async move {
5938 let method = GetClusterRecoveryStatusSvc(inner);
5939 let codec = tonic_prost::ProstCodec::default();
5940 let mut grpc = tonic::server::Grpc::new(codec)
5941 .apply_compression_config(
5942 accept_compression_encodings,
5943 send_compression_encodings,
5944 )
5945 .apply_max_message_size_config(
5946 max_decoding_message_size,
5947 max_encoding_message_size,
5948 );
5949 let res = grpc.unary(method, req).await;
5950 Ok(res)
5951 };
5952 Box::pin(fut)
5953 }
5954 "/meta.ClusterService/GetMetaStoreInfo" => {
5955 #[allow(non_camel_case_types)]
5956 struct GetMetaStoreInfoSvc<T: ClusterService>(pub Arc<T>);
5957 impl<
5958 T: ClusterService,
5959 > tonic::server::UnaryService<super::GetMetaStoreInfoRequest>
5960 for GetMetaStoreInfoSvc<T> {
5961 type Response = super::GetMetaStoreInfoResponse;
5962 type Future = BoxFuture<
5963 tonic::Response<Self::Response>,
5964 tonic::Status,
5965 >;
5966 fn call(
5967 &mut self,
5968 request: tonic::Request<super::GetMetaStoreInfoRequest>,
5969 ) -> Self::Future {
5970 let inner = Arc::clone(&self.0);
5971 let fut = async move {
5972 <T as ClusterService>::get_meta_store_info(&inner, request)
5973 .await
5974 };
5975 Box::pin(fut)
5976 }
5977 }
5978 let accept_compression_encodings = self.accept_compression_encodings;
5979 let send_compression_encodings = self.send_compression_encodings;
5980 let max_decoding_message_size = self.max_decoding_message_size;
5981 let max_encoding_message_size = self.max_encoding_message_size;
5982 let inner = self.inner.clone();
5983 let fut = async move {
5984 let method = GetMetaStoreInfoSvc(inner);
5985 let codec = tonic_prost::ProstCodec::default();
5986 let mut grpc = tonic::server::Grpc::new(codec)
5987 .apply_compression_config(
5988 accept_compression_encodings,
5989 send_compression_encodings,
5990 )
5991 .apply_max_message_size_config(
5992 max_decoding_message_size,
5993 max_encoding_message_size,
5994 );
5995 let res = grpc.unary(method, req).await;
5996 Ok(res)
5997 };
5998 Box::pin(fut)
5999 }
6000 _ => {
6001 Box::pin(async move {
6002 let mut response = http::Response::new(
6003 tonic::body::Body::default(),
6004 );
6005 let headers = response.headers_mut();
6006 headers
6007 .insert(
6008 tonic::Status::GRPC_STATUS,
6009 (tonic::Code::Unimplemented as i32).into(),
6010 );
6011 headers
6012 .insert(
6013 http::header::CONTENT_TYPE,
6014 tonic::metadata::GRPC_CONTENT_TYPE,
6015 );
6016 Ok(response)
6017 })
6018 }
6019 }
6020 }
6021 }
6022 impl<T> Clone for ClusterServiceServer<T> {
6023 fn clone(&self) -> Self {
6024 let inner = self.inner.clone();
6025 Self {
6026 inner,
6027 accept_compression_encodings: self.accept_compression_encodings,
6028 send_compression_encodings: self.send_compression_encodings,
6029 max_decoding_message_size: self.max_decoding_message_size,
6030 max_encoding_message_size: self.max_encoding_message_size,
6031 }
6032 }
6033 }
6034 pub const SERVICE_NAME: &str = "meta.ClusterService";
6036 impl<T> tonic::server::NamedService for ClusterServiceServer<T> {
6037 const NAME: &'static str = SERVICE_NAME;
6038 }
6039}
6040pub mod notification_service_client {
6042 #![allow(
6043 unused_variables,
6044 dead_code,
6045 missing_docs,
6046 clippy::wildcard_imports,
6047 clippy::let_unit_value,
6048 )]
6049 use tonic::codegen::*;
6050 use tonic::codegen::http::Uri;
6051 #[derive(Debug, Clone)]
6052 pub struct NotificationServiceClient<T> {
6053 inner: tonic::client::Grpc<T>,
6054 }
6055 impl NotificationServiceClient<tonic::transport::Channel> {
6056 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
6058 where
6059 D: TryInto<tonic::transport::Endpoint>,
6060 D::Error: Into<StdError>,
6061 {
6062 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
6063 Ok(Self::new(conn))
6064 }
6065 }
6066 impl<T> NotificationServiceClient<T>
6067 where
6068 T: tonic::client::GrpcService<tonic::body::Body>,
6069 T::Error: Into<StdError>,
6070 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
6071 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
6072 {
6073 pub fn new(inner: T) -> Self {
6074 let inner = tonic::client::Grpc::new(inner);
6075 Self { inner }
6076 }
6077 pub fn with_origin(inner: T, origin: Uri) -> Self {
6078 let inner = tonic::client::Grpc::with_origin(inner, origin);
6079 Self { inner }
6080 }
6081 pub fn with_interceptor<F>(
6082 inner: T,
6083 interceptor: F,
6084 ) -> NotificationServiceClient<InterceptedService<T, F>>
6085 where
6086 F: tonic::service::Interceptor,
6087 T::ResponseBody: Default,
6088 T: tonic::codegen::Service<
6089 http::Request<tonic::body::Body>,
6090 Response = http::Response<
6091 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
6092 >,
6093 >,
6094 <T as tonic::codegen::Service<
6095 http::Request<tonic::body::Body>,
6096 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
6097 {
6098 NotificationServiceClient::new(InterceptedService::new(inner, interceptor))
6099 }
6100 #[must_use]
6105 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
6106 self.inner = self.inner.send_compressed(encoding);
6107 self
6108 }
6109 #[must_use]
6111 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
6112 self.inner = self.inner.accept_compressed(encoding);
6113 self
6114 }
6115 #[must_use]
6119 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
6120 self.inner = self.inner.max_decoding_message_size(limit);
6121 self
6122 }
6123 #[must_use]
6127 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
6128 self.inner = self.inner.max_encoding_message_size(limit);
6129 self
6130 }
6131 pub async fn subscribe(
6132 &mut self,
6133 request: impl tonic::IntoRequest<super::SubscribeRequest>,
6134 ) -> std::result::Result<
6135 tonic::Response<tonic::codec::Streaming<super::SubscribeResponse>>,
6136 tonic::Status,
6137 > {
6138 self.inner
6139 .ready()
6140 .await
6141 .map_err(|e| {
6142 tonic::Status::unknown(
6143 format!("Service was not ready: {}", e.into()),
6144 )
6145 })?;
6146 let codec = tonic_prost::ProstCodec::default();
6147 let path = http::uri::PathAndQuery::from_static(
6148 "/meta.NotificationService/Subscribe",
6149 );
6150 let mut req = request.into_request();
6151 req.extensions_mut()
6152 .insert(GrpcMethod::new("meta.NotificationService", "Subscribe"));
6153 self.inner.server_streaming(req, path, codec).await
6154 }
6155 }
6156}
6157pub mod notification_service_server {
6159 #![allow(
6160 unused_variables,
6161 dead_code,
6162 missing_docs,
6163 clippy::wildcard_imports,
6164 clippy::let_unit_value,
6165 )]
6166 use tonic::codegen::*;
6167 #[async_trait]
6169 pub trait NotificationService: std::marker::Send + std::marker::Sync + 'static {
6170 type SubscribeStream: tonic::codegen::tokio_stream::Stream<
6172 Item = std::result::Result<super::SubscribeResponse, tonic::Status>,
6173 >
6174 + std::marker::Send
6175 + 'static;
6176 async fn subscribe(
6177 &self,
6178 request: tonic::Request<super::SubscribeRequest>,
6179 ) -> std::result::Result<tonic::Response<Self::SubscribeStream>, tonic::Status>;
6180 }
6181 #[derive(Debug)]
6182 pub struct NotificationServiceServer<T> {
6183 inner: Arc<T>,
6184 accept_compression_encodings: EnabledCompressionEncodings,
6185 send_compression_encodings: EnabledCompressionEncodings,
6186 max_decoding_message_size: Option<usize>,
6187 max_encoding_message_size: Option<usize>,
6188 }
6189 impl<T> NotificationServiceServer<T> {
6190 pub fn new(inner: T) -> Self {
6191 Self::from_arc(Arc::new(inner))
6192 }
6193 pub fn from_arc(inner: Arc<T>) -> Self {
6194 Self {
6195 inner,
6196 accept_compression_encodings: Default::default(),
6197 send_compression_encodings: Default::default(),
6198 max_decoding_message_size: None,
6199 max_encoding_message_size: None,
6200 }
6201 }
6202 pub fn with_interceptor<F>(
6203 inner: T,
6204 interceptor: F,
6205 ) -> InterceptedService<Self, F>
6206 where
6207 F: tonic::service::Interceptor,
6208 {
6209 InterceptedService::new(Self::new(inner), interceptor)
6210 }
6211 #[must_use]
6213 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
6214 self.accept_compression_encodings.enable(encoding);
6215 self
6216 }
6217 #[must_use]
6219 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
6220 self.send_compression_encodings.enable(encoding);
6221 self
6222 }
6223 #[must_use]
6227 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
6228 self.max_decoding_message_size = Some(limit);
6229 self
6230 }
6231 #[must_use]
6235 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
6236 self.max_encoding_message_size = Some(limit);
6237 self
6238 }
6239 }
6240 impl<T, B> tonic::codegen::Service<http::Request<B>> for NotificationServiceServer<T>
6241 where
6242 T: NotificationService,
6243 B: Body + std::marker::Send + 'static,
6244 B::Error: Into<StdError> + std::marker::Send + 'static,
6245 {
6246 type Response = http::Response<tonic::body::Body>;
6247 type Error = std::convert::Infallible;
6248 type Future = BoxFuture<Self::Response, Self::Error>;
6249 fn poll_ready(
6250 &mut self,
6251 _cx: &mut Context<'_>,
6252 ) -> Poll<std::result::Result<(), Self::Error>> {
6253 Poll::Ready(Ok(()))
6254 }
6255 fn call(&mut self, req: http::Request<B>) -> Self::Future {
6256 match req.uri().path() {
6257 "/meta.NotificationService/Subscribe" => {
6258 #[allow(non_camel_case_types)]
6259 struct SubscribeSvc<T: NotificationService>(pub Arc<T>);
6260 impl<
6261 T: NotificationService,
6262 > tonic::server::ServerStreamingService<super::SubscribeRequest>
6263 for SubscribeSvc<T> {
6264 type Response = super::SubscribeResponse;
6265 type ResponseStream = T::SubscribeStream;
6266 type Future = BoxFuture<
6267 tonic::Response<Self::ResponseStream>,
6268 tonic::Status,
6269 >;
6270 fn call(
6271 &mut self,
6272 request: tonic::Request<super::SubscribeRequest>,
6273 ) -> Self::Future {
6274 let inner = Arc::clone(&self.0);
6275 let fut = async move {
6276 <T as NotificationService>::subscribe(&inner, request).await
6277 };
6278 Box::pin(fut)
6279 }
6280 }
6281 let accept_compression_encodings = self.accept_compression_encodings;
6282 let send_compression_encodings = self.send_compression_encodings;
6283 let max_decoding_message_size = self.max_decoding_message_size;
6284 let max_encoding_message_size = self.max_encoding_message_size;
6285 let inner = self.inner.clone();
6286 let fut = async move {
6287 let method = SubscribeSvc(inner);
6288 let codec = tonic_prost::ProstCodec::default();
6289 let mut grpc = tonic::server::Grpc::new(codec)
6290 .apply_compression_config(
6291 accept_compression_encodings,
6292 send_compression_encodings,
6293 )
6294 .apply_max_message_size_config(
6295 max_decoding_message_size,
6296 max_encoding_message_size,
6297 );
6298 let res = grpc.server_streaming(method, req).await;
6299 Ok(res)
6300 };
6301 Box::pin(fut)
6302 }
6303 _ => {
6304 Box::pin(async move {
6305 let mut response = http::Response::new(
6306 tonic::body::Body::default(),
6307 );
6308 let headers = response.headers_mut();
6309 headers
6310 .insert(
6311 tonic::Status::GRPC_STATUS,
6312 (tonic::Code::Unimplemented as i32).into(),
6313 );
6314 headers
6315 .insert(
6316 http::header::CONTENT_TYPE,
6317 tonic::metadata::GRPC_CONTENT_TYPE,
6318 );
6319 Ok(response)
6320 })
6321 }
6322 }
6323 }
6324 }
6325 impl<T> Clone for NotificationServiceServer<T> {
6326 fn clone(&self) -> Self {
6327 let inner = self.inner.clone();
6328 Self {
6329 inner,
6330 accept_compression_encodings: self.accept_compression_encodings,
6331 send_compression_encodings: self.send_compression_encodings,
6332 max_decoding_message_size: self.max_decoding_message_size,
6333 max_encoding_message_size: self.max_encoding_message_size,
6334 }
6335 }
6336 }
6337 pub const SERVICE_NAME: &str = "meta.NotificationService";
6339 impl<T> tonic::server::NamedService for NotificationServiceServer<T> {
6340 const NAME: &'static str = SERVICE_NAME;
6341 }
6342}
6343pub mod scale_service_client {
6345 #![allow(
6346 unused_variables,
6347 dead_code,
6348 missing_docs,
6349 clippy::wildcard_imports,
6350 clippy::let_unit_value,
6351 )]
6352 use tonic::codegen::*;
6353 use tonic::codegen::http::Uri;
6354 #[derive(Debug, Clone)]
6356 pub struct ScaleServiceClient<T> {
6357 inner: tonic::client::Grpc<T>,
6358 }
6359 impl ScaleServiceClient<tonic::transport::Channel> {
6360 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
6362 where
6363 D: TryInto<tonic::transport::Endpoint>,
6364 D::Error: Into<StdError>,
6365 {
6366 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
6367 Ok(Self::new(conn))
6368 }
6369 }
6370 impl<T> ScaleServiceClient<T>
6371 where
6372 T: tonic::client::GrpcService<tonic::body::Body>,
6373 T::Error: Into<StdError>,
6374 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
6375 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
6376 {
6377 pub fn new(inner: T) -> Self {
6378 let inner = tonic::client::Grpc::new(inner);
6379 Self { inner }
6380 }
6381 pub fn with_origin(inner: T, origin: Uri) -> Self {
6382 let inner = tonic::client::Grpc::with_origin(inner, origin);
6383 Self { inner }
6384 }
6385 pub fn with_interceptor<F>(
6386 inner: T,
6387 interceptor: F,
6388 ) -> ScaleServiceClient<InterceptedService<T, F>>
6389 where
6390 F: tonic::service::Interceptor,
6391 T::ResponseBody: Default,
6392 T: tonic::codegen::Service<
6393 http::Request<tonic::body::Body>,
6394 Response = http::Response<
6395 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
6396 >,
6397 >,
6398 <T as tonic::codegen::Service<
6399 http::Request<tonic::body::Body>,
6400 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
6401 {
6402 ScaleServiceClient::new(InterceptedService::new(inner, interceptor))
6403 }
6404 #[must_use]
6409 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
6410 self.inner = self.inner.send_compressed(encoding);
6411 self
6412 }
6413 #[must_use]
6415 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
6416 self.inner = self.inner.accept_compressed(encoding);
6417 self
6418 }
6419 #[must_use]
6423 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
6424 self.inner = self.inner.max_decoding_message_size(limit);
6425 self
6426 }
6427 #[must_use]
6431 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
6432 self.inner = self.inner.max_encoding_message_size(limit);
6433 self
6434 }
6435 pub async fn get_cluster_info(
6436 &mut self,
6437 request: impl tonic::IntoRequest<super::GetClusterInfoRequest>,
6438 ) -> std::result::Result<
6439 tonic::Response<super::GetClusterInfoResponse>,
6440 tonic::Status,
6441 > {
6442 self.inner
6443 .ready()
6444 .await
6445 .map_err(|e| {
6446 tonic::Status::unknown(
6447 format!("Service was not ready: {}", e.into()),
6448 )
6449 })?;
6450 let codec = tonic_prost::ProstCodec::default();
6451 let path = http::uri::PathAndQuery::from_static(
6452 "/meta.ScaleService/GetClusterInfo",
6453 );
6454 let mut req = request.into_request();
6455 req.extensions_mut()
6456 .insert(GrpcMethod::new("meta.ScaleService", "GetClusterInfo"));
6457 self.inner.unary(req, path, codec).await
6458 }
6459 pub async fn reschedule(
6460 &mut self,
6461 request: impl tonic::IntoRequest<super::RescheduleRequest>,
6462 ) -> std::result::Result<
6463 tonic::Response<super::RescheduleResponse>,
6464 tonic::Status,
6465 > {
6466 self.inner
6467 .ready()
6468 .await
6469 .map_err(|e| {
6470 tonic::Status::unknown(
6471 format!("Service was not ready: {}", e.into()),
6472 )
6473 })?;
6474 let codec = tonic_prost::ProstCodec::default();
6475 let path = http::uri::PathAndQuery::from_static(
6476 "/meta.ScaleService/Reschedule",
6477 );
6478 let mut req = request.into_request();
6479 req.extensions_mut()
6480 .insert(GrpcMethod::new("meta.ScaleService", "Reschedule"));
6481 self.inner.unary(req, path, codec).await
6482 }
6483 pub async fn update_streaming_job_node_labels(
6484 &mut self,
6485 request: impl tonic::IntoRequest<super::UpdateStreamingJobNodeLabelsRequest>,
6486 ) -> std::result::Result<
6487 tonic::Response<super::UpdateStreamingJobNodeLabelsResponse>,
6488 tonic::Status,
6489 > {
6490 self.inner
6491 .ready()
6492 .await
6493 .map_err(|e| {
6494 tonic::Status::unknown(
6495 format!("Service was not ready: {}", e.into()),
6496 )
6497 })?;
6498 let codec = tonic_prost::ProstCodec::default();
6499 let path = http::uri::PathAndQuery::from_static(
6500 "/meta.ScaleService/UpdateStreamingJobNodeLabels",
6501 );
6502 let mut req = request.into_request();
6503 req.extensions_mut()
6504 .insert(
6505 GrpcMethod::new("meta.ScaleService", "UpdateStreamingJobNodeLabels"),
6506 );
6507 self.inner.unary(req, path, codec).await
6508 }
6509 pub async fn get_serverless_streaming_jobs_status(
6510 &mut self,
6511 request: impl tonic::IntoRequest<
6512 super::GetServerlessStreamingJobsStatusRequest,
6513 >,
6514 ) -> std::result::Result<
6515 tonic::Response<super::GetServerlessStreamingJobsStatusResponse>,
6516 tonic::Status,
6517 > {
6518 self.inner
6519 .ready()
6520 .await
6521 .map_err(|e| {
6522 tonic::Status::unknown(
6523 format!("Service was not ready: {}", e.into()),
6524 )
6525 })?;
6526 let codec = tonic_prost::ProstCodec::default();
6527 let path = http::uri::PathAndQuery::from_static(
6528 "/meta.ScaleService/GetServerlessStreamingJobsStatus",
6529 );
6530 let mut req = request.into_request();
6531 req.extensions_mut()
6532 .insert(
6533 GrpcMethod::new(
6534 "meta.ScaleService",
6535 "GetServerlessStreamingJobsStatus",
6536 ),
6537 );
6538 self.inner.unary(req, path, codec).await
6539 }
6540 }
6541}
6542pub mod scale_service_server {
6544 #![allow(
6545 unused_variables,
6546 dead_code,
6547 missing_docs,
6548 clippy::wildcard_imports,
6549 clippy::let_unit_value,
6550 )]
6551 use tonic::codegen::*;
6552 #[async_trait]
6554 pub trait ScaleService: std::marker::Send + std::marker::Sync + 'static {
6555 async fn get_cluster_info(
6556 &self,
6557 request: tonic::Request<super::GetClusterInfoRequest>,
6558 ) -> std::result::Result<
6559 tonic::Response<super::GetClusterInfoResponse>,
6560 tonic::Status,
6561 >;
6562 async fn reschedule(
6563 &self,
6564 request: tonic::Request<super::RescheduleRequest>,
6565 ) -> std::result::Result<
6566 tonic::Response<super::RescheduleResponse>,
6567 tonic::Status,
6568 >;
6569 async fn update_streaming_job_node_labels(
6570 &self,
6571 request: tonic::Request<super::UpdateStreamingJobNodeLabelsRequest>,
6572 ) -> std::result::Result<
6573 tonic::Response<super::UpdateStreamingJobNodeLabelsResponse>,
6574 tonic::Status,
6575 >;
6576 async fn get_serverless_streaming_jobs_status(
6577 &self,
6578 request: tonic::Request<super::GetServerlessStreamingJobsStatusRequest>,
6579 ) -> std::result::Result<
6580 tonic::Response<super::GetServerlessStreamingJobsStatusResponse>,
6581 tonic::Status,
6582 >;
6583 }
6584 #[derive(Debug)]
6586 pub struct ScaleServiceServer<T> {
6587 inner: Arc<T>,
6588 accept_compression_encodings: EnabledCompressionEncodings,
6589 send_compression_encodings: EnabledCompressionEncodings,
6590 max_decoding_message_size: Option<usize>,
6591 max_encoding_message_size: Option<usize>,
6592 }
6593 impl<T> ScaleServiceServer<T> {
6594 pub fn new(inner: T) -> Self {
6595 Self::from_arc(Arc::new(inner))
6596 }
6597 pub fn from_arc(inner: Arc<T>) -> Self {
6598 Self {
6599 inner,
6600 accept_compression_encodings: Default::default(),
6601 send_compression_encodings: Default::default(),
6602 max_decoding_message_size: None,
6603 max_encoding_message_size: None,
6604 }
6605 }
6606 pub fn with_interceptor<F>(
6607 inner: T,
6608 interceptor: F,
6609 ) -> InterceptedService<Self, F>
6610 where
6611 F: tonic::service::Interceptor,
6612 {
6613 InterceptedService::new(Self::new(inner), interceptor)
6614 }
6615 #[must_use]
6617 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
6618 self.accept_compression_encodings.enable(encoding);
6619 self
6620 }
6621 #[must_use]
6623 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
6624 self.send_compression_encodings.enable(encoding);
6625 self
6626 }
6627 #[must_use]
6631 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
6632 self.max_decoding_message_size = Some(limit);
6633 self
6634 }
6635 #[must_use]
6639 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
6640 self.max_encoding_message_size = Some(limit);
6641 self
6642 }
6643 }
6644 impl<T, B> tonic::codegen::Service<http::Request<B>> for ScaleServiceServer<T>
6645 where
6646 T: ScaleService,
6647 B: Body + std::marker::Send + 'static,
6648 B::Error: Into<StdError> + std::marker::Send + 'static,
6649 {
6650 type Response = http::Response<tonic::body::Body>;
6651 type Error = std::convert::Infallible;
6652 type Future = BoxFuture<Self::Response, Self::Error>;
6653 fn poll_ready(
6654 &mut self,
6655 _cx: &mut Context<'_>,
6656 ) -> Poll<std::result::Result<(), Self::Error>> {
6657 Poll::Ready(Ok(()))
6658 }
6659 fn call(&mut self, req: http::Request<B>) -> Self::Future {
6660 match req.uri().path() {
6661 "/meta.ScaleService/GetClusterInfo" => {
6662 #[allow(non_camel_case_types)]
6663 struct GetClusterInfoSvc<T: ScaleService>(pub Arc<T>);
6664 impl<
6665 T: ScaleService,
6666 > tonic::server::UnaryService<super::GetClusterInfoRequest>
6667 for GetClusterInfoSvc<T> {
6668 type Response = super::GetClusterInfoResponse;
6669 type Future = BoxFuture<
6670 tonic::Response<Self::Response>,
6671 tonic::Status,
6672 >;
6673 fn call(
6674 &mut self,
6675 request: tonic::Request<super::GetClusterInfoRequest>,
6676 ) -> Self::Future {
6677 let inner = Arc::clone(&self.0);
6678 let fut = async move {
6679 <T as ScaleService>::get_cluster_info(&inner, request).await
6680 };
6681 Box::pin(fut)
6682 }
6683 }
6684 let accept_compression_encodings = self.accept_compression_encodings;
6685 let send_compression_encodings = self.send_compression_encodings;
6686 let max_decoding_message_size = self.max_decoding_message_size;
6687 let max_encoding_message_size = self.max_encoding_message_size;
6688 let inner = self.inner.clone();
6689 let fut = async move {
6690 let method = GetClusterInfoSvc(inner);
6691 let codec = tonic_prost::ProstCodec::default();
6692 let mut grpc = tonic::server::Grpc::new(codec)
6693 .apply_compression_config(
6694 accept_compression_encodings,
6695 send_compression_encodings,
6696 )
6697 .apply_max_message_size_config(
6698 max_decoding_message_size,
6699 max_encoding_message_size,
6700 );
6701 let res = grpc.unary(method, req).await;
6702 Ok(res)
6703 };
6704 Box::pin(fut)
6705 }
6706 "/meta.ScaleService/Reschedule" => {
6707 #[allow(non_camel_case_types)]
6708 struct RescheduleSvc<T: ScaleService>(pub Arc<T>);
6709 impl<
6710 T: ScaleService,
6711 > tonic::server::UnaryService<super::RescheduleRequest>
6712 for RescheduleSvc<T> {
6713 type Response = super::RescheduleResponse;
6714 type Future = BoxFuture<
6715 tonic::Response<Self::Response>,
6716 tonic::Status,
6717 >;
6718 fn call(
6719 &mut self,
6720 request: tonic::Request<super::RescheduleRequest>,
6721 ) -> Self::Future {
6722 let inner = Arc::clone(&self.0);
6723 let fut = async move {
6724 <T as ScaleService>::reschedule(&inner, request).await
6725 };
6726 Box::pin(fut)
6727 }
6728 }
6729 let accept_compression_encodings = self.accept_compression_encodings;
6730 let send_compression_encodings = self.send_compression_encodings;
6731 let max_decoding_message_size = self.max_decoding_message_size;
6732 let max_encoding_message_size = self.max_encoding_message_size;
6733 let inner = self.inner.clone();
6734 let fut = async move {
6735 let method = RescheduleSvc(inner);
6736 let codec = tonic_prost::ProstCodec::default();
6737 let mut grpc = tonic::server::Grpc::new(codec)
6738 .apply_compression_config(
6739 accept_compression_encodings,
6740 send_compression_encodings,
6741 )
6742 .apply_max_message_size_config(
6743 max_decoding_message_size,
6744 max_encoding_message_size,
6745 );
6746 let res = grpc.unary(method, req).await;
6747 Ok(res)
6748 };
6749 Box::pin(fut)
6750 }
6751 "/meta.ScaleService/UpdateStreamingJobNodeLabels" => {
6752 #[allow(non_camel_case_types)]
6753 struct UpdateStreamingJobNodeLabelsSvc<T: ScaleService>(pub Arc<T>);
6754 impl<
6755 T: ScaleService,
6756 > tonic::server::UnaryService<
6757 super::UpdateStreamingJobNodeLabelsRequest,
6758 > for UpdateStreamingJobNodeLabelsSvc<T> {
6759 type Response = super::UpdateStreamingJobNodeLabelsResponse;
6760 type Future = BoxFuture<
6761 tonic::Response<Self::Response>,
6762 tonic::Status,
6763 >;
6764 fn call(
6765 &mut self,
6766 request: tonic::Request<
6767 super::UpdateStreamingJobNodeLabelsRequest,
6768 >,
6769 ) -> Self::Future {
6770 let inner = Arc::clone(&self.0);
6771 let fut = async move {
6772 <T as ScaleService>::update_streaming_job_node_labels(
6773 &inner,
6774 request,
6775 )
6776 .await
6777 };
6778 Box::pin(fut)
6779 }
6780 }
6781 let accept_compression_encodings = self.accept_compression_encodings;
6782 let send_compression_encodings = self.send_compression_encodings;
6783 let max_decoding_message_size = self.max_decoding_message_size;
6784 let max_encoding_message_size = self.max_encoding_message_size;
6785 let inner = self.inner.clone();
6786 let fut = async move {
6787 let method = UpdateStreamingJobNodeLabelsSvc(inner);
6788 let codec = tonic_prost::ProstCodec::default();
6789 let mut grpc = tonic::server::Grpc::new(codec)
6790 .apply_compression_config(
6791 accept_compression_encodings,
6792 send_compression_encodings,
6793 )
6794 .apply_max_message_size_config(
6795 max_decoding_message_size,
6796 max_encoding_message_size,
6797 );
6798 let res = grpc.unary(method, req).await;
6799 Ok(res)
6800 };
6801 Box::pin(fut)
6802 }
6803 "/meta.ScaleService/GetServerlessStreamingJobsStatus" => {
6804 #[allow(non_camel_case_types)]
6805 struct GetServerlessStreamingJobsStatusSvc<T: ScaleService>(
6806 pub Arc<T>,
6807 );
6808 impl<
6809 T: ScaleService,
6810 > tonic::server::UnaryService<
6811 super::GetServerlessStreamingJobsStatusRequest,
6812 > for GetServerlessStreamingJobsStatusSvc<T> {
6813 type Response = super::GetServerlessStreamingJobsStatusResponse;
6814 type Future = BoxFuture<
6815 tonic::Response<Self::Response>,
6816 tonic::Status,
6817 >;
6818 fn call(
6819 &mut self,
6820 request: tonic::Request<
6821 super::GetServerlessStreamingJobsStatusRequest,
6822 >,
6823 ) -> Self::Future {
6824 let inner = Arc::clone(&self.0);
6825 let fut = async move {
6826 <T as ScaleService>::get_serverless_streaming_jobs_status(
6827 &inner,
6828 request,
6829 )
6830 .await
6831 };
6832 Box::pin(fut)
6833 }
6834 }
6835 let accept_compression_encodings = self.accept_compression_encodings;
6836 let send_compression_encodings = self.send_compression_encodings;
6837 let max_decoding_message_size = self.max_decoding_message_size;
6838 let max_encoding_message_size = self.max_encoding_message_size;
6839 let inner = self.inner.clone();
6840 let fut = async move {
6841 let method = GetServerlessStreamingJobsStatusSvc(inner);
6842 let codec = tonic_prost::ProstCodec::default();
6843 let mut grpc = tonic::server::Grpc::new(codec)
6844 .apply_compression_config(
6845 accept_compression_encodings,
6846 send_compression_encodings,
6847 )
6848 .apply_max_message_size_config(
6849 max_decoding_message_size,
6850 max_encoding_message_size,
6851 );
6852 let res = grpc.unary(method, req).await;
6853 Ok(res)
6854 };
6855 Box::pin(fut)
6856 }
6857 _ => {
6858 Box::pin(async move {
6859 let mut response = http::Response::new(
6860 tonic::body::Body::default(),
6861 );
6862 let headers = response.headers_mut();
6863 headers
6864 .insert(
6865 tonic::Status::GRPC_STATUS,
6866 (tonic::Code::Unimplemented as i32).into(),
6867 );
6868 headers
6869 .insert(
6870 http::header::CONTENT_TYPE,
6871 tonic::metadata::GRPC_CONTENT_TYPE,
6872 );
6873 Ok(response)
6874 })
6875 }
6876 }
6877 }
6878 }
6879 impl<T> Clone for ScaleServiceServer<T> {
6880 fn clone(&self) -> Self {
6881 let inner = self.inner.clone();
6882 Self {
6883 inner,
6884 accept_compression_encodings: self.accept_compression_encodings,
6885 send_compression_encodings: self.send_compression_encodings,
6886 max_decoding_message_size: self.max_decoding_message_size,
6887 max_encoding_message_size: self.max_encoding_message_size,
6888 }
6889 }
6890 }
6891 pub const SERVICE_NAME: &str = "meta.ScaleService";
6893 impl<T> tonic::server::NamedService for ScaleServiceServer<T> {
6894 const NAME: &'static str = SERVICE_NAME;
6895 }
6896}
6897pub mod meta_member_service_client {
6899 #![allow(
6900 unused_variables,
6901 dead_code,
6902 missing_docs,
6903 clippy::wildcard_imports,
6904 clippy::let_unit_value,
6905 )]
6906 use tonic::codegen::*;
6907 use tonic::codegen::http::Uri;
6908 #[derive(Debug, Clone)]
6909 pub struct MetaMemberServiceClient<T> {
6910 inner: tonic::client::Grpc<T>,
6911 }
6912 impl MetaMemberServiceClient<tonic::transport::Channel> {
6913 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
6915 where
6916 D: TryInto<tonic::transport::Endpoint>,
6917 D::Error: Into<StdError>,
6918 {
6919 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
6920 Ok(Self::new(conn))
6921 }
6922 }
6923 impl<T> MetaMemberServiceClient<T>
6924 where
6925 T: tonic::client::GrpcService<tonic::body::Body>,
6926 T::Error: Into<StdError>,
6927 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
6928 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
6929 {
6930 pub fn new(inner: T) -> Self {
6931 let inner = tonic::client::Grpc::new(inner);
6932 Self { inner }
6933 }
6934 pub fn with_origin(inner: T, origin: Uri) -> Self {
6935 let inner = tonic::client::Grpc::with_origin(inner, origin);
6936 Self { inner }
6937 }
6938 pub fn with_interceptor<F>(
6939 inner: T,
6940 interceptor: F,
6941 ) -> MetaMemberServiceClient<InterceptedService<T, F>>
6942 where
6943 F: tonic::service::Interceptor,
6944 T::ResponseBody: Default,
6945 T: tonic::codegen::Service<
6946 http::Request<tonic::body::Body>,
6947 Response = http::Response<
6948 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
6949 >,
6950 >,
6951 <T as tonic::codegen::Service<
6952 http::Request<tonic::body::Body>,
6953 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
6954 {
6955 MetaMemberServiceClient::new(InterceptedService::new(inner, interceptor))
6956 }
6957 #[must_use]
6962 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
6963 self.inner = self.inner.send_compressed(encoding);
6964 self
6965 }
6966 #[must_use]
6968 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
6969 self.inner = self.inner.accept_compressed(encoding);
6970 self
6971 }
6972 #[must_use]
6976 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
6977 self.inner = self.inner.max_decoding_message_size(limit);
6978 self
6979 }
6980 #[must_use]
6984 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
6985 self.inner = self.inner.max_encoding_message_size(limit);
6986 self
6987 }
6988 pub async fn members(
6989 &mut self,
6990 request: impl tonic::IntoRequest<super::MembersRequest>,
6991 ) -> std::result::Result<
6992 tonic::Response<super::MembersResponse>,
6993 tonic::Status,
6994 > {
6995 self.inner
6996 .ready()
6997 .await
6998 .map_err(|e| {
6999 tonic::Status::unknown(
7000 format!("Service was not ready: {}", e.into()),
7001 )
7002 })?;
7003 let codec = tonic_prost::ProstCodec::default();
7004 let path = http::uri::PathAndQuery::from_static(
7005 "/meta.MetaMemberService/Members",
7006 );
7007 let mut req = request.into_request();
7008 req.extensions_mut()
7009 .insert(GrpcMethod::new("meta.MetaMemberService", "Members"));
7010 self.inner.unary(req, path, codec).await
7011 }
7012 }
7013}
7014pub mod meta_member_service_server {
7016 #![allow(
7017 unused_variables,
7018 dead_code,
7019 missing_docs,
7020 clippy::wildcard_imports,
7021 clippy::let_unit_value,
7022 )]
7023 use tonic::codegen::*;
7024 #[async_trait]
7026 pub trait MetaMemberService: std::marker::Send + std::marker::Sync + 'static {
7027 async fn members(
7028 &self,
7029 request: tonic::Request<super::MembersRequest>,
7030 ) -> std::result::Result<tonic::Response<super::MembersResponse>, tonic::Status>;
7031 }
7032 #[derive(Debug)]
7033 pub struct MetaMemberServiceServer<T> {
7034 inner: Arc<T>,
7035 accept_compression_encodings: EnabledCompressionEncodings,
7036 send_compression_encodings: EnabledCompressionEncodings,
7037 max_decoding_message_size: Option<usize>,
7038 max_encoding_message_size: Option<usize>,
7039 }
7040 impl<T> MetaMemberServiceServer<T> {
7041 pub fn new(inner: T) -> Self {
7042 Self::from_arc(Arc::new(inner))
7043 }
7044 pub fn from_arc(inner: Arc<T>) -> Self {
7045 Self {
7046 inner,
7047 accept_compression_encodings: Default::default(),
7048 send_compression_encodings: Default::default(),
7049 max_decoding_message_size: None,
7050 max_encoding_message_size: None,
7051 }
7052 }
7053 pub fn with_interceptor<F>(
7054 inner: T,
7055 interceptor: F,
7056 ) -> InterceptedService<Self, F>
7057 where
7058 F: tonic::service::Interceptor,
7059 {
7060 InterceptedService::new(Self::new(inner), interceptor)
7061 }
7062 #[must_use]
7064 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
7065 self.accept_compression_encodings.enable(encoding);
7066 self
7067 }
7068 #[must_use]
7070 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
7071 self.send_compression_encodings.enable(encoding);
7072 self
7073 }
7074 #[must_use]
7078 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
7079 self.max_decoding_message_size = Some(limit);
7080 self
7081 }
7082 #[must_use]
7086 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
7087 self.max_encoding_message_size = Some(limit);
7088 self
7089 }
7090 }
7091 impl<T, B> tonic::codegen::Service<http::Request<B>> for MetaMemberServiceServer<T>
7092 where
7093 T: MetaMemberService,
7094 B: Body + std::marker::Send + 'static,
7095 B::Error: Into<StdError> + std::marker::Send + 'static,
7096 {
7097 type Response = http::Response<tonic::body::Body>;
7098 type Error = std::convert::Infallible;
7099 type Future = BoxFuture<Self::Response, Self::Error>;
7100 fn poll_ready(
7101 &mut self,
7102 _cx: &mut Context<'_>,
7103 ) -> Poll<std::result::Result<(), Self::Error>> {
7104 Poll::Ready(Ok(()))
7105 }
7106 fn call(&mut self, req: http::Request<B>) -> Self::Future {
7107 match req.uri().path() {
7108 "/meta.MetaMemberService/Members" => {
7109 #[allow(non_camel_case_types)]
7110 struct MembersSvc<T: MetaMemberService>(pub Arc<T>);
7111 impl<
7112 T: MetaMemberService,
7113 > tonic::server::UnaryService<super::MembersRequest>
7114 for MembersSvc<T> {
7115 type Response = super::MembersResponse;
7116 type Future = BoxFuture<
7117 tonic::Response<Self::Response>,
7118 tonic::Status,
7119 >;
7120 fn call(
7121 &mut self,
7122 request: tonic::Request<super::MembersRequest>,
7123 ) -> Self::Future {
7124 let inner = Arc::clone(&self.0);
7125 let fut = async move {
7126 <T as MetaMemberService>::members(&inner, request).await
7127 };
7128 Box::pin(fut)
7129 }
7130 }
7131 let accept_compression_encodings = self.accept_compression_encodings;
7132 let send_compression_encodings = self.send_compression_encodings;
7133 let max_decoding_message_size = self.max_decoding_message_size;
7134 let max_encoding_message_size = self.max_encoding_message_size;
7135 let inner = self.inner.clone();
7136 let fut = async move {
7137 let method = MembersSvc(inner);
7138 let codec = tonic_prost::ProstCodec::default();
7139 let mut grpc = tonic::server::Grpc::new(codec)
7140 .apply_compression_config(
7141 accept_compression_encodings,
7142 send_compression_encodings,
7143 )
7144 .apply_max_message_size_config(
7145 max_decoding_message_size,
7146 max_encoding_message_size,
7147 );
7148 let res = grpc.unary(method, req).await;
7149 Ok(res)
7150 };
7151 Box::pin(fut)
7152 }
7153 _ => {
7154 Box::pin(async move {
7155 let mut response = http::Response::new(
7156 tonic::body::Body::default(),
7157 );
7158 let headers = response.headers_mut();
7159 headers
7160 .insert(
7161 tonic::Status::GRPC_STATUS,
7162 (tonic::Code::Unimplemented as i32).into(),
7163 );
7164 headers
7165 .insert(
7166 http::header::CONTENT_TYPE,
7167 tonic::metadata::GRPC_CONTENT_TYPE,
7168 );
7169 Ok(response)
7170 })
7171 }
7172 }
7173 }
7174 }
7175 impl<T> Clone for MetaMemberServiceServer<T> {
7176 fn clone(&self) -> Self {
7177 let inner = self.inner.clone();
7178 Self {
7179 inner,
7180 accept_compression_encodings: self.accept_compression_encodings,
7181 send_compression_encodings: self.send_compression_encodings,
7182 max_decoding_message_size: self.max_decoding_message_size,
7183 max_encoding_message_size: self.max_encoding_message_size,
7184 }
7185 }
7186 }
7187 pub const SERVICE_NAME: &str = "meta.MetaMemberService";
7189 impl<T> tonic::server::NamedService for MetaMemberServiceServer<T> {
7190 const NAME: &'static str = SERVICE_NAME;
7191 }
7192}
7193pub mod system_params_service_client {
7195 #![allow(
7196 unused_variables,
7197 dead_code,
7198 missing_docs,
7199 clippy::wildcard_imports,
7200 clippy::let_unit_value,
7201 )]
7202 use tonic::codegen::*;
7203 use tonic::codegen::http::Uri;
7204 #[derive(Debug, Clone)]
7205 pub struct SystemParamsServiceClient<T> {
7206 inner: tonic::client::Grpc<T>,
7207 }
7208 impl SystemParamsServiceClient<tonic::transport::Channel> {
7209 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
7211 where
7212 D: TryInto<tonic::transport::Endpoint>,
7213 D::Error: Into<StdError>,
7214 {
7215 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
7216 Ok(Self::new(conn))
7217 }
7218 }
7219 impl<T> SystemParamsServiceClient<T>
7220 where
7221 T: tonic::client::GrpcService<tonic::body::Body>,
7222 T::Error: Into<StdError>,
7223 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
7224 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
7225 {
7226 pub fn new(inner: T) -> Self {
7227 let inner = tonic::client::Grpc::new(inner);
7228 Self { inner }
7229 }
7230 pub fn with_origin(inner: T, origin: Uri) -> Self {
7231 let inner = tonic::client::Grpc::with_origin(inner, origin);
7232 Self { inner }
7233 }
7234 pub fn with_interceptor<F>(
7235 inner: T,
7236 interceptor: F,
7237 ) -> SystemParamsServiceClient<InterceptedService<T, F>>
7238 where
7239 F: tonic::service::Interceptor,
7240 T::ResponseBody: Default,
7241 T: tonic::codegen::Service<
7242 http::Request<tonic::body::Body>,
7243 Response = http::Response<
7244 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
7245 >,
7246 >,
7247 <T as tonic::codegen::Service<
7248 http::Request<tonic::body::Body>,
7249 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
7250 {
7251 SystemParamsServiceClient::new(InterceptedService::new(inner, interceptor))
7252 }
7253 #[must_use]
7258 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
7259 self.inner = self.inner.send_compressed(encoding);
7260 self
7261 }
7262 #[must_use]
7264 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
7265 self.inner = self.inner.accept_compressed(encoding);
7266 self
7267 }
7268 #[must_use]
7272 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
7273 self.inner = self.inner.max_decoding_message_size(limit);
7274 self
7275 }
7276 #[must_use]
7280 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
7281 self.inner = self.inner.max_encoding_message_size(limit);
7282 self
7283 }
7284 pub async fn get_system_params(
7285 &mut self,
7286 request: impl tonic::IntoRequest<super::GetSystemParamsRequest>,
7287 ) -> std::result::Result<
7288 tonic::Response<super::GetSystemParamsResponse>,
7289 tonic::Status,
7290 > {
7291 self.inner
7292 .ready()
7293 .await
7294 .map_err(|e| {
7295 tonic::Status::unknown(
7296 format!("Service was not ready: {}", e.into()),
7297 )
7298 })?;
7299 let codec = tonic_prost::ProstCodec::default();
7300 let path = http::uri::PathAndQuery::from_static(
7301 "/meta.SystemParamsService/GetSystemParams",
7302 );
7303 let mut req = request.into_request();
7304 req.extensions_mut()
7305 .insert(GrpcMethod::new("meta.SystemParamsService", "GetSystemParams"));
7306 self.inner.unary(req, path, codec).await
7307 }
7308 pub async fn set_system_param(
7309 &mut self,
7310 request: impl tonic::IntoRequest<super::SetSystemParamRequest>,
7311 ) -> std::result::Result<
7312 tonic::Response<super::SetSystemParamResponse>,
7313 tonic::Status,
7314 > {
7315 self.inner
7316 .ready()
7317 .await
7318 .map_err(|e| {
7319 tonic::Status::unknown(
7320 format!("Service was not ready: {}", e.into()),
7321 )
7322 })?;
7323 let codec = tonic_prost::ProstCodec::default();
7324 let path = http::uri::PathAndQuery::from_static(
7325 "/meta.SystemParamsService/SetSystemParam",
7326 );
7327 let mut req = request.into_request();
7328 req.extensions_mut()
7329 .insert(GrpcMethod::new("meta.SystemParamsService", "SetSystemParam"));
7330 self.inner.unary(req, path, codec).await
7331 }
7332 pub async fn clear_file_cache(
7333 &mut self,
7334 request: impl tonic::IntoRequest<super::ClearFileCacheRequest>,
7335 ) -> std::result::Result<
7336 tonic::Response<super::ClearFileCacheResponse>,
7337 tonic::Status,
7338 > {
7339 self.inner
7340 .ready()
7341 .await
7342 .map_err(|e| {
7343 tonic::Status::unknown(
7344 format!("Service was not ready: {}", e.into()),
7345 )
7346 })?;
7347 let codec = tonic_prost::ProstCodec::default();
7348 let path = http::uri::PathAndQuery::from_static(
7349 "/meta.SystemParamsService/ClearFileCache",
7350 );
7351 let mut req = request.into_request();
7352 req.extensions_mut()
7353 .insert(GrpcMethod::new("meta.SystemParamsService", "ClearFileCache"));
7354 self.inner.unary(req, path, codec).await
7355 }
7356 }
7357}
7358pub mod system_params_service_server {
7360 #![allow(
7361 unused_variables,
7362 dead_code,
7363 missing_docs,
7364 clippy::wildcard_imports,
7365 clippy::let_unit_value,
7366 )]
7367 use tonic::codegen::*;
7368 #[async_trait]
7370 pub trait SystemParamsService: std::marker::Send + std::marker::Sync + 'static {
7371 async fn get_system_params(
7372 &self,
7373 request: tonic::Request<super::GetSystemParamsRequest>,
7374 ) -> std::result::Result<
7375 tonic::Response<super::GetSystemParamsResponse>,
7376 tonic::Status,
7377 >;
7378 async fn set_system_param(
7379 &self,
7380 request: tonic::Request<super::SetSystemParamRequest>,
7381 ) -> std::result::Result<
7382 tonic::Response<super::SetSystemParamResponse>,
7383 tonic::Status,
7384 >;
7385 async fn clear_file_cache(
7386 &self,
7387 request: tonic::Request<super::ClearFileCacheRequest>,
7388 ) -> std::result::Result<
7389 tonic::Response<super::ClearFileCacheResponse>,
7390 tonic::Status,
7391 >;
7392 }
7393 #[derive(Debug)]
7394 pub struct SystemParamsServiceServer<T> {
7395 inner: Arc<T>,
7396 accept_compression_encodings: EnabledCompressionEncodings,
7397 send_compression_encodings: EnabledCompressionEncodings,
7398 max_decoding_message_size: Option<usize>,
7399 max_encoding_message_size: Option<usize>,
7400 }
7401 impl<T> SystemParamsServiceServer<T> {
7402 pub fn new(inner: T) -> Self {
7403 Self::from_arc(Arc::new(inner))
7404 }
7405 pub fn from_arc(inner: Arc<T>) -> Self {
7406 Self {
7407 inner,
7408 accept_compression_encodings: Default::default(),
7409 send_compression_encodings: Default::default(),
7410 max_decoding_message_size: None,
7411 max_encoding_message_size: None,
7412 }
7413 }
7414 pub fn with_interceptor<F>(
7415 inner: T,
7416 interceptor: F,
7417 ) -> InterceptedService<Self, F>
7418 where
7419 F: tonic::service::Interceptor,
7420 {
7421 InterceptedService::new(Self::new(inner), interceptor)
7422 }
7423 #[must_use]
7425 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
7426 self.accept_compression_encodings.enable(encoding);
7427 self
7428 }
7429 #[must_use]
7431 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
7432 self.send_compression_encodings.enable(encoding);
7433 self
7434 }
7435 #[must_use]
7439 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
7440 self.max_decoding_message_size = Some(limit);
7441 self
7442 }
7443 #[must_use]
7447 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
7448 self.max_encoding_message_size = Some(limit);
7449 self
7450 }
7451 }
7452 impl<T, B> tonic::codegen::Service<http::Request<B>> for SystemParamsServiceServer<T>
7453 where
7454 T: SystemParamsService,
7455 B: Body + std::marker::Send + 'static,
7456 B::Error: Into<StdError> + std::marker::Send + 'static,
7457 {
7458 type Response = http::Response<tonic::body::Body>;
7459 type Error = std::convert::Infallible;
7460 type Future = BoxFuture<Self::Response, Self::Error>;
7461 fn poll_ready(
7462 &mut self,
7463 _cx: &mut Context<'_>,
7464 ) -> Poll<std::result::Result<(), Self::Error>> {
7465 Poll::Ready(Ok(()))
7466 }
7467 fn call(&mut self, req: http::Request<B>) -> Self::Future {
7468 match req.uri().path() {
7469 "/meta.SystemParamsService/GetSystemParams" => {
7470 #[allow(non_camel_case_types)]
7471 struct GetSystemParamsSvc<T: SystemParamsService>(pub Arc<T>);
7472 impl<
7473 T: SystemParamsService,
7474 > tonic::server::UnaryService<super::GetSystemParamsRequest>
7475 for GetSystemParamsSvc<T> {
7476 type Response = super::GetSystemParamsResponse;
7477 type Future = BoxFuture<
7478 tonic::Response<Self::Response>,
7479 tonic::Status,
7480 >;
7481 fn call(
7482 &mut self,
7483 request: tonic::Request<super::GetSystemParamsRequest>,
7484 ) -> Self::Future {
7485 let inner = Arc::clone(&self.0);
7486 let fut = async move {
7487 <T as SystemParamsService>::get_system_params(
7488 &inner,
7489 request,
7490 )
7491 .await
7492 };
7493 Box::pin(fut)
7494 }
7495 }
7496 let accept_compression_encodings = self.accept_compression_encodings;
7497 let send_compression_encodings = self.send_compression_encodings;
7498 let max_decoding_message_size = self.max_decoding_message_size;
7499 let max_encoding_message_size = self.max_encoding_message_size;
7500 let inner = self.inner.clone();
7501 let fut = async move {
7502 let method = GetSystemParamsSvc(inner);
7503 let codec = tonic_prost::ProstCodec::default();
7504 let mut grpc = tonic::server::Grpc::new(codec)
7505 .apply_compression_config(
7506 accept_compression_encodings,
7507 send_compression_encodings,
7508 )
7509 .apply_max_message_size_config(
7510 max_decoding_message_size,
7511 max_encoding_message_size,
7512 );
7513 let res = grpc.unary(method, req).await;
7514 Ok(res)
7515 };
7516 Box::pin(fut)
7517 }
7518 "/meta.SystemParamsService/SetSystemParam" => {
7519 #[allow(non_camel_case_types)]
7520 struct SetSystemParamSvc<T: SystemParamsService>(pub Arc<T>);
7521 impl<
7522 T: SystemParamsService,
7523 > tonic::server::UnaryService<super::SetSystemParamRequest>
7524 for SetSystemParamSvc<T> {
7525 type Response = super::SetSystemParamResponse;
7526 type Future = BoxFuture<
7527 tonic::Response<Self::Response>,
7528 tonic::Status,
7529 >;
7530 fn call(
7531 &mut self,
7532 request: tonic::Request<super::SetSystemParamRequest>,
7533 ) -> Self::Future {
7534 let inner = Arc::clone(&self.0);
7535 let fut = async move {
7536 <T as SystemParamsService>::set_system_param(
7537 &inner,
7538 request,
7539 )
7540 .await
7541 };
7542 Box::pin(fut)
7543 }
7544 }
7545 let accept_compression_encodings = self.accept_compression_encodings;
7546 let send_compression_encodings = self.send_compression_encodings;
7547 let max_decoding_message_size = self.max_decoding_message_size;
7548 let max_encoding_message_size = self.max_encoding_message_size;
7549 let inner = self.inner.clone();
7550 let fut = async move {
7551 let method = SetSystemParamSvc(inner);
7552 let codec = tonic_prost::ProstCodec::default();
7553 let mut grpc = tonic::server::Grpc::new(codec)
7554 .apply_compression_config(
7555 accept_compression_encodings,
7556 send_compression_encodings,
7557 )
7558 .apply_max_message_size_config(
7559 max_decoding_message_size,
7560 max_encoding_message_size,
7561 );
7562 let res = grpc.unary(method, req).await;
7563 Ok(res)
7564 };
7565 Box::pin(fut)
7566 }
7567 "/meta.SystemParamsService/ClearFileCache" => {
7568 #[allow(non_camel_case_types)]
7569 struct ClearFileCacheSvc<T: SystemParamsService>(pub Arc<T>);
7570 impl<
7571 T: SystemParamsService,
7572 > tonic::server::UnaryService<super::ClearFileCacheRequest>
7573 for ClearFileCacheSvc<T> {
7574 type Response = super::ClearFileCacheResponse;
7575 type Future = BoxFuture<
7576 tonic::Response<Self::Response>,
7577 tonic::Status,
7578 >;
7579 fn call(
7580 &mut self,
7581 request: tonic::Request<super::ClearFileCacheRequest>,
7582 ) -> Self::Future {
7583 let inner = Arc::clone(&self.0);
7584 let fut = async move {
7585 <T as SystemParamsService>::clear_file_cache(
7586 &inner,
7587 request,
7588 )
7589 .await
7590 };
7591 Box::pin(fut)
7592 }
7593 }
7594 let accept_compression_encodings = self.accept_compression_encodings;
7595 let send_compression_encodings = self.send_compression_encodings;
7596 let max_decoding_message_size = self.max_decoding_message_size;
7597 let max_encoding_message_size = self.max_encoding_message_size;
7598 let inner = self.inner.clone();
7599 let fut = async move {
7600 let method = ClearFileCacheSvc(inner);
7601 let codec = tonic_prost::ProstCodec::default();
7602 let mut grpc = tonic::server::Grpc::new(codec)
7603 .apply_compression_config(
7604 accept_compression_encodings,
7605 send_compression_encodings,
7606 )
7607 .apply_max_message_size_config(
7608 max_decoding_message_size,
7609 max_encoding_message_size,
7610 );
7611 let res = grpc.unary(method, req).await;
7612 Ok(res)
7613 };
7614 Box::pin(fut)
7615 }
7616 _ => {
7617 Box::pin(async move {
7618 let mut response = http::Response::new(
7619 tonic::body::Body::default(),
7620 );
7621 let headers = response.headers_mut();
7622 headers
7623 .insert(
7624 tonic::Status::GRPC_STATUS,
7625 (tonic::Code::Unimplemented as i32).into(),
7626 );
7627 headers
7628 .insert(
7629 http::header::CONTENT_TYPE,
7630 tonic::metadata::GRPC_CONTENT_TYPE,
7631 );
7632 Ok(response)
7633 })
7634 }
7635 }
7636 }
7637 }
7638 impl<T> Clone for SystemParamsServiceServer<T> {
7639 fn clone(&self) -> Self {
7640 let inner = self.inner.clone();
7641 Self {
7642 inner,
7643 accept_compression_encodings: self.accept_compression_encodings,
7644 send_compression_encodings: self.send_compression_encodings,
7645 max_decoding_message_size: self.max_decoding_message_size,
7646 max_encoding_message_size: self.max_encoding_message_size,
7647 }
7648 }
7649 }
7650 pub const SERVICE_NAME: &str = "meta.SystemParamsService";
7652 impl<T> tonic::server::NamedService for SystemParamsServiceServer<T> {
7653 const NAME: &'static str = SERVICE_NAME;
7654 }
7655}
7656pub mod session_param_service_client {
7658 #![allow(
7659 unused_variables,
7660 dead_code,
7661 missing_docs,
7662 clippy::wildcard_imports,
7663 clippy::let_unit_value,
7664 )]
7665 use tonic::codegen::*;
7666 use tonic::codegen::http::Uri;
7667 #[derive(Debug, Clone)]
7669 pub struct SessionParamServiceClient<T> {
7670 inner: tonic::client::Grpc<T>,
7671 }
7672 impl SessionParamServiceClient<tonic::transport::Channel> {
7673 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
7675 where
7676 D: TryInto<tonic::transport::Endpoint>,
7677 D::Error: Into<StdError>,
7678 {
7679 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
7680 Ok(Self::new(conn))
7681 }
7682 }
7683 impl<T> SessionParamServiceClient<T>
7684 where
7685 T: tonic::client::GrpcService<tonic::body::Body>,
7686 T::Error: Into<StdError>,
7687 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
7688 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
7689 {
7690 pub fn new(inner: T) -> Self {
7691 let inner = tonic::client::Grpc::new(inner);
7692 Self { inner }
7693 }
7694 pub fn with_origin(inner: T, origin: Uri) -> Self {
7695 let inner = tonic::client::Grpc::with_origin(inner, origin);
7696 Self { inner }
7697 }
7698 pub fn with_interceptor<F>(
7699 inner: T,
7700 interceptor: F,
7701 ) -> SessionParamServiceClient<InterceptedService<T, F>>
7702 where
7703 F: tonic::service::Interceptor,
7704 T::ResponseBody: Default,
7705 T: tonic::codegen::Service<
7706 http::Request<tonic::body::Body>,
7707 Response = http::Response<
7708 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
7709 >,
7710 >,
7711 <T as tonic::codegen::Service<
7712 http::Request<tonic::body::Body>,
7713 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
7714 {
7715 SessionParamServiceClient::new(InterceptedService::new(inner, interceptor))
7716 }
7717 #[must_use]
7722 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
7723 self.inner = self.inner.send_compressed(encoding);
7724 self
7725 }
7726 #[must_use]
7728 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
7729 self.inner = self.inner.accept_compressed(encoding);
7730 self
7731 }
7732 #[must_use]
7736 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
7737 self.inner = self.inner.max_decoding_message_size(limit);
7738 self
7739 }
7740 #[must_use]
7744 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
7745 self.inner = self.inner.max_encoding_message_size(limit);
7746 self
7747 }
7748 pub async fn get_session_params(
7749 &mut self,
7750 request: impl tonic::IntoRequest<super::GetSessionParamsRequest>,
7751 ) -> std::result::Result<
7752 tonic::Response<super::GetSessionParamsResponse>,
7753 tonic::Status,
7754 > {
7755 self.inner
7756 .ready()
7757 .await
7758 .map_err(|e| {
7759 tonic::Status::unknown(
7760 format!("Service was not ready: {}", e.into()),
7761 )
7762 })?;
7763 let codec = tonic_prost::ProstCodec::default();
7764 let path = http::uri::PathAndQuery::from_static(
7765 "/meta.SessionParamService/GetSessionParams",
7766 );
7767 let mut req = request.into_request();
7768 req.extensions_mut()
7769 .insert(GrpcMethod::new("meta.SessionParamService", "GetSessionParams"));
7770 self.inner.unary(req, path, codec).await
7771 }
7772 pub async fn set_session_param(
7773 &mut self,
7774 request: impl tonic::IntoRequest<super::SetSessionParamRequest>,
7775 ) -> std::result::Result<
7776 tonic::Response<super::SetSessionParamResponse>,
7777 tonic::Status,
7778 > {
7779 self.inner
7780 .ready()
7781 .await
7782 .map_err(|e| {
7783 tonic::Status::unknown(
7784 format!("Service was not ready: {}", e.into()),
7785 )
7786 })?;
7787 let codec = tonic_prost::ProstCodec::default();
7788 let path = http::uri::PathAndQuery::from_static(
7789 "/meta.SessionParamService/SetSessionParam",
7790 );
7791 let mut req = request.into_request();
7792 req.extensions_mut()
7793 .insert(GrpcMethod::new("meta.SessionParamService", "SetSessionParam"));
7794 self.inner.unary(req, path, codec).await
7795 }
7796 }
7797}
7798pub mod session_param_service_server {
7800 #![allow(
7801 unused_variables,
7802 dead_code,
7803 missing_docs,
7804 clippy::wildcard_imports,
7805 clippy::let_unit_value,
7806 )]
7807 use tonic::codegen::*;
7808 #[async_trait]
7810 pub trait SessionParamService: std::marker::Send + std::marker::Sync + 'static {
7811 async fn get_session_params(
7812 &self,
7813 request: tonic::Request<super::GetSessionParamsRequest>,
7814 ) -> std::result::Result<
7815 tonic::Response<super::GetSessionParamsResponse>,
7816 tonic::Status,
7817 >;
7818 async fn set_session_param(
7819 &self,
7820 request: tonic::Request<super::SetSessionParamRequest>,
7821 ) -> std::result::Result<
7822 tonic::Response<super::SetSessionParamResponse>,
7823 tonic::Status,
7824 >;
7825 }
7826 #[derive(Debug)]
7828 pub struct SessionParamServiceServer<T> {
7829 inner: Arc<T>,
7830 accept_compression_encodings: EnabledCompressionEncodings,
7831 send_compression_encodings: EnabledCompressionEncodings,
7832 max_decoding_message_size: Option<usize>,
7833 max_encoding_message_size: Option<usize>,
7834 }
7835 impl<T> SessionParamServiceServer<T> {
7836 pub fn new(inner: T) -> Self {
7837 Self::from_arc(Arc::new(inner))
7838 }
7839 pub fn from_arc(inner: Arc<T>) -> Self {
7840 Self {
7841 inner,
7842 accept_compression_encodings: Default::default(),
7843 send_compression_encodings: Default::default(),
7844 max_decoding_message_size: None,
7845 max_encoding_message_size: None,
7846 }
7847 }
7848 pub fn with_interceptor<F>(
7849 inner: T,
7850 interceptor: F,
7851 ) -> InterceptedService<Self, F>
7852 where
7853 F: tonic::service::Interceptor,
7854 {
7855 InterceptedService::new(Self::new(inner), interceptor)
7856 }
7857 #[must_use]
7859 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
7860 self.accept_compression_encodings.enable(encoding);
7861 self
7862 }
7863 #[must_use]
7865 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
7866 self.send_compression_encodings.enable(encoding);
7867 self
7868 }
7869 #[must_use]
7873 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
7874 self.max_decoding_message_size = Some(limit);
7875 self
7876 }
7877 #[must_use]
7881 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
7882 self.max_encoding_message_size = Some(limit);
7883 self
7884 }
7885 }
7886 impl<T, B> tonic::codegen::Service<http::Request<B>> for SessionParamServiceServer<T>
7887 where
7888 T: SessionParamService,
7889 B: Body + std::marker::Send + 'static,
7890 B::Error: Into<StdError> + std::marker::Send + 'static,
7891 {
7892 type Response = http::Response<tonic::body::Body>;
7893 type Error = std::convert::Infallible;
7894 type Future = BoxFuture<Self::Response, Self::Error>;
7895 fn poll_ready(
7896 &mut self,
7897 _cx: &mut Context<'_>,
7898 ) -> Poll<std::result::Result<(), Self::Error>> {
7899 Poll::Ready(Ok(()))
7900 }
7901 fn call(&mut self, req: http::Request<B>) -> Self::Future {
7902 match req.uri().path() {
7903 "/meta.SessionParamService/GetSessionParams" => {
7904 #[allow(non_camel_case_types)]
7905 struct GetSessionParamsSvc<T: SessionParamService>(pub Arc<T>);
7906 impl<
7907 T: SessionParamService,
7908 > tonic::server::UnaryService<super::GetSessionParamsRequest>
7909 for GetSessionParamsSvc<T> {
7910 type Response = super::GetSessionParamsResponse;
7911 type Future = BoxFuture<
7912 tonic::Response<Self::Response>,
7913 tonic::Status,
7914 >;
7915 fn call(
7916 &mut self,
7917 request: tonic::Request<super::GetSessionParamsRequest>,
7918 ) -> Self::Future {
7919 let inner = Arc::clone(&self.0);
7920 let fut = async move {
7921 <T as SessionParamService>::get_session_params(
7922 &inner,
7923 request,
7924 )
7925 .await
7926 };
7927 Box::pin(fut)
7928 }
7929 }
7930 let accept_compression_encodings = self.accept_compression_encodings;
7931 let send_compression_encodings = self.send_compression_encodings;
7932 let max_decoding_message_size = self.max_decoding_message_size;
7933 let max_encoding_message_size = self.max_encoding_message_size;
7934 let inner = self.inner.clone();
7935 let fut = async move {
7936 let method = GetSessionParamsSvc(inner);
7937 let codec = tonic_prost::ProstCodec::default();
7938 let mut grpc = tonic::server::Grpc::new(codec)
7939 .apply_compression_config(
7940 accept_compression_encodings,
7941 send_compression_encodings,
7942 )
7943 .apply_max_message_size_config(
7944 max_decoding_message_size,
7945 max_encoding_message_size,
7946 );
7947 let res = grpc.unary(method, req).await;
7948 Ok(res)
7949 };
7950 Box::pin(fut)
7951 }
7952 "/meta.SessionParamService/SetSessionParam" => {
7953 #[allow(non_camel_case_types)]
7954 struct SetSessionParamSvc<T: SessionParamService>(pub Arc<T>);
7955 impl<
7956 T: SessionParamService,
7957 > tonic::server::UnaryService<super::SetSessionParamRequest>
7958 for SetSessionParamSvc<T> {
7959 type Response = super::SetSessionParamResponse;
7960 type Future = BoxFuture<
7961 tonic::Response<Self::Response>,
7962 tonic::Status,
7963 >;
7964 fn call(
7965 &mut self,
7966 request: tonic::Request<super::SetSessionParamRequest>,
7967 ) -> Self::Future {
7968 let inner = Arc::clone(&self.0);
7969 let fut = async move {
7970 <T as SessionParamService>::set_session_param(
7971 &inner,
7972 request,
7973 )
7974 .await
7975 };
7976 Box::pin(fut)
7977 }
7978 }
7979 let accept_compression_encodings = self.accept_compression_encodings;
7980 let send_compression_encodings = self.send_compression_encodings;
7981 let max_decoding_message_size = self.max_decoding_message_size;
7982 let max_encoding_message_size = self.max_encoding_message_size;
7983 let inner = self.inner.clone();
7984 let fut = async move {
7985 let method = SetSessionParamSvc(inner);
7986 let codec = tonic_prost::ProstCodec::default();
7987 let mut grpc = tonic::server::Grpc::new(codec)
7988 .apply_compression_config(
7989 accept_compression_encodings,
7990 send_compression_encodings,
7991 )
7992 .apply_max_message_size_config(
7993 max_decoding_message_size,
7994 max_encoding_message_size,
7995 );
7996 let res = grpc.unary(method, req).await;
7997 Ok(res)
7998 };
7999 Box::pin(fut)
8000 }
8001 _ => {
8002 Box::pin(async move {
8003 let mut response = http::Response::new(
8004 tonic::body::Body::default(),
8005 );
8006 let headers = response.headers_mut();
8007 headers
8008 .insert(
8009 tonic::Status::GRPC_STATUS,
8010 (tonic::Code::Unimplemented as i32).into(),
8011 );
8012 headers
8013 .insert(
8014 http::header::CONTENT_TYPE,
8015 tonic::metadata::GRPC_CONTENT_TYPE,
8016 );
8017 Ok(response)
8018 })
8019 }
8020 }
8021 }
8022 }
8023 impl<T> Clone for SessionParamServiceServer<T> {
8024 fn clone(&self) -> Self {
8025 let inner = self.inner.clone();
8026 Self {
8027 inner,
8028 accept_compression_encodings: self.accept_compression_encodings,
8029 send_compression_encodings: self.send_compression_encodings,
8030 max_decoding_message_size: self.max_decoding_message_size,
8031 max_encoding_message_size: self.max_encoding_message_size,
8032 }
8033 }
8034 }
8035 pub const SERVICE_NAME: &str = "meta.SessionParamService";
8037 impl<T> tonic::server::NamedService for SessionParamServiceServer<T> {
8038 const NAME: &'static str = SERVICE_NAME;
8039 }
8040}
8041pub mod serving_service_client {
8043 #![allow(
8044 unused_variables,
8045 dead_code,
8046 missing_docs,
8047 clippy::wildcard_imports,
8048 clippy::let_unit_value,
8049 )]
8050 use tonic::codegen::*;
8051 use tonic::codegen::http::Uri;
8052 #[derive(Debug, Clone)]
8053 pub struct ServingServiceClient<T> {
8054 inner: tonic::client::Grpc<T>,
8055 }
8056 impl ServingServiceClient<tonic::transport::Channel> {
8057 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
8059 where
8060 D: TryInto<tonic::transport::Endpoint>,
8061 D::Error: Into<StdError>,
8062 {
8063 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
8064 Ok(Self::new(conn))
8065 }
8066 }
8067 impl<T> ServingServiceClient<T>
8068 where
8069 T: tonic::client::GrpcService<tonic::body::Body>,
8070 T::Error: Into<StdError>,
8071 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
8072 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
8073 {
8074 pub fn new(inner: T) -> Self {
8075 let inner = tonic::client::Grpc::new(inner);
8076 Self { inner }
8077 }
8078 pub fn with_origin(inner: T, origin: Uri) -> Self {
8079 let inner = tonic::client::Grpc::with_origin(inner, origin);
8080 Self { inner }
8081 }
8082 pub fn with_interceptor<F>(
8083 inner: T,
8084 interceptor: F,
8085 ) -> ServingServiceClient<InterceptedService<T, F>>
8086 where
8087 F: tonic::service::Interceptor,
8088 T::ResponseBody: Default,
8089 T: tonic::codegen::Service<
8090 http::Request<tonic::body::Body>,
8091 Response = http::Response<
8092 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
8093 >,
8094 >,
8095 <T as tonic::codegen::Service<
8096 http::Request<tonic::body::Body>,
8097 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
8098 {
8099 ServingServiceClient::new(InterceptedService::new(inner, interceptor))
8100 }
8101 #[must_use]
8106 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
8107 self.inner = self.inner.send_compressed(encoding);
8108 self
8109 }
8110 #[must_use]
8112 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
8113 self.inner = self.inner.accept_compressed(encoding);
8114 self
8115 }
8116 #[must_use]
8120 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
8121 self.inner = self.inner.max_decoding_message_size(limit);
8122 self
8123 }
8124 #[must_use]
8128 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
8129 self.inner = self.inner.max_encoding_message_size(limit);
8130 self
8131 }
8132 pub async fn get_serving_vnode_mappings(
8133 &mut self,
8134 request: impl tonic::IntoRequest<super::GetServingVnodeMappingsRequest>,
8135 ) -> std::result::Result<
8136 tonic::Response<super::GetServingVnodeMappingsResponse>,
8137 tonic::Status,
8138 > {
8139 self.inner
8140 .ready()
8141 .await
8142 .map_err(|e| {
8143 tonic::Status::unknown(
8144 format!("Service was not ready: {}", e.into()),
8145 )
8146 })?;
8147 let codec = tonic_prost::ProstCodec::default();
8148 let path = http::uri::PathAndQuery::from_static(
8149 "/meta.ServingService/GetServingVnodeMappings",
8150 );
8151 let mut req = request.into_request();
8152 req.extensions_mut()
8153 .insert(
8154 GrpcMethod::new("meta.ServingService", "GetServingVnodeMappings"),
8155 );
8156 self.inner.unary(req, path, codec).await
8157 }
8158 pub async fn warm_up_table_cache(
8159 &mut self,
8160 request: impl tonic::IntoRequest<super::WarmUpTableCacheRequest>,
8161 ) -> std::result::Result<
8162 tonic::Response<super::WarmUpTableCacheResponse>,
8163 tonic::Status,
8164 > {
8165 self.inner
8166 .ready()
8167 .await
8168 .map_err(|e| {
8169 tonic::Status::unknown(
8170 format!("Service was not ready: {}", e.into()),
8171 )
8172 })?;
8173 let codec = tonic_prost::ProstCodec::default();
8174 let path = http::uri::PathAndQuery::from_static(
8175 "/meta.ServingService/WarmUpTableCache",
8176 );
8177 let mut req = request.into_request();
8178 req.extensions_mut()
8179 .insert(GrpcMethod::new("meta.ServingService", "WarmUpTableCache"));
8180 self.inner.unary(req, path, codec).await
8181 }
8182 }
8183}
8184pub mod serving_service_server {
8186 #![allow(
8187 unused_variables,
8188 dead_code,
8189 missing_docs,
8190 clippy::wildcard_imports,
8191 clippy::let_unit_value,
8192 )]
8193 use tonic::codegen::*;
8194 #[async_trait]
8196 pub trait ServingService: std::marker::Send + std::marker::Sync + 'static {
8197 async fn get_serving_vnode_mappings(
8198 &self,
8199 request: tonic::Request<super::GetServingVnodeMappingsRequest>,
8200 ) -> std::result::Result<
8201 tonic::Response<super::GetServingVnodeMappingsResponse>,
8202 tonic::Status,
8203 >;
8204 async fn warm_up_table_cache(
8205 &self,
8206 request: tonic::Request<super::WarmUpTableCacheRequest>,
8207 ) -> std::result::Result<
8208 tonic::Response<super::WarmUpTableCacheResponse>,
8209 tonic::Status,
8210 >;
8211 }
8212 #[derive(Debug)]
8213 pub struct ServingServiceServer<T> {
8214 inner: Arc<T>,
8215 accept_compression_encodings: EnabledCompressionEncodings,
8216 send_compression_encodings: EnabledCompressionEncodings,
8217 max_decoding_message_size: Option<usize>,
8218 max_encoding_message_size: Option<usize>,
8219 }
8220 impl<T> ServingServiceServer<T> {
8221 pub fn new(inner: T) -> Self {
8222 Self::from_arc(Arc::new(inner))
8223 }
8224 pub fn from_arc(inner: Arc<T>) -> Self {
8225 Self {
8226 inner,
8227 accept_compression_encodings: Default::default(),
8228 send_compression_encodings: Default::default(),
8229 max_decoding_message_size: None,
8230 max_encoding_message_size: None,
8231 }
8232 }
8233 pub fn with_interceptor<F>(
8234 inner: T,
8235 interceptor: F,
8236 ) -> InterceptedService<Self, F>
8237 where
8238 F: tonic::service::Interceptor,
8239 {
8240 InterceptedService::new(Self::new(inner), interceptor)
8241 }
8242 #[must_use]
8244 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
8245 self.accept_compression_encodings.enable(encoding);
8246 self
8247 }
8248 #[must_use]
8250 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
8251 self.send_compression_encodings.enable(encoding);
8252 self
8253 }
8254 #[must_use]
8258 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
8259 self.max_decoding_message_size = Some(limit);
8260 self
8261 }
8262 #[must_use]
8266 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
8267 self.max_encoding_message_size = Some(limit);
8268 self
8269 }
8270 }
8271 impl<T, B> tonic::codegen::Service<http::Request<B>> for ServingServiceServer<T>
8272 where
8273 T: ServingService,
8274 B: Body + std::marker::Send + 'static,
8275 B::Error: Into<StdError> + std::marker::Send + 'static,
8276 {
8277 type Response = http::Response<tonic::body::Body>;
8278 type Error = std::convert::Infallible;
8279 type Future = BoxFuture<Self::Response, Self::Error>;
8280 fn poll_ready(
8281 &mut self,
8282 _cx: &mut Context<'_>,
8283 ) -> Poll<std::result::Result<(), Self::Error>> {
8284 Poll::Ready(Ok(()))
8285 }
8286 fn call(&mut self, req: http::Request<B>) -> Self::Future {
8287 match req.uri().path() {
8288 "/meta.ServingService/GetServingVnodeMappings" => {
8289 #[allow(non_camel_case_types)]
8290 struct GetServingVnodeMappingsSvc<T: ServingService>(pub Arc<T>);
8291 impl<
8292 T: ServingService,
8293 > tonic::server::UnaryService<super::GetServingVnodeMappingsRequest>
8294 for GetServingVnodeMappingsSvc<T> {
8295 type Response = super::GetServingVnodeMappingsResponse;
8296 type Future = BoxFuture<
8297 tonic::Response<Self::Response>,
8298 tonic::Status,
8299 >;
8300 fn call(
8301 &mut self,
8302 request: tonic::Request<
8303 super::GetServingVnodeMappingsRequest,
8304 >,
8305 ) -> Self::Future {
8306 let inner = Arc::clone(&self.0);
8307 let fut = async move {
8308 <T as ServingService>::get_serving_vnode_mappings(
8309 &inner,
8310 request,
8311 )
8312 .await
8313 };
8314 Box::pin(fut)
8315 }
8316 }
8317 let accept_compression_encodings = self.accept_compression_encodings;
8318 let send_compression_encodings = self.send_compression_encodings;
8319 let max_decoding_message_size = self.max_decoding_message_size;
8320 let max_encoding_message_size = self.max_encoding_message_size;
8321 let inner = self.inner.clone();
8322 let fut = async move {
8323 let method = GetServingVnodeMappingsSvc(inner);
8324 let codec = tonic_prost::ProstCodec::default();
8325 let mut grpc = tonic::server::Grpc::new(codec)
8326 .apply_compression_config(
8327 accept_compression_encodings,
8328 send_compression_encodings,
8329 )
8330 .apply_max_message_size_config(
8331 max_decoding_message_size,
8332 max_encoding_message_size,
8333 );
8334 let res = grpc.unary(method, req).await;
8335 Ok(res)
8336 };
8337 Box::pin(fut)
8338 }
8339 "/meta.ServingService/WarmUpTableCache" => {
8340 #[allow(non_camel_case_types)]
8341 struct WarmUpTableCacheSvc<T: ServingService>(pub Arc<T>);
8342 impl<
8343 T: ServingService,
8344 > tonic::server::UnaryService<super::WarmUpTableCacheRequest>
8345 for WarmUpTableCacheSvc<T> {
8346 type Response = super::WarmUpTableCacheResponse;
8347 type Future = BoxFuture<
8348 tonic::Response<Self::Response>,
8349 tonic::Status,
8350 >;
8351 fn call(
8352 &mut self,
8353 request: tonic::Request<super::WarmUpTableCacheRequest>,
8354 ) -> Self::Future {
8355 let inner = Arc::clone(&self.0);
8356 let fut = async move {
8357 <T as ServingService>::warm_up_table_cache(&inner, request)
8358 .await
8359 };
8360 Box::pin(fut)
8361 }
8362 }
8363 let accept_compression_encodings = self.accept_compression_encodings;
8364 let send_compression_encodings = self.send_compression_encodings;
8365 let max_decoding_message_size = self.max_decoding_message_size;
8366 let max_encoding_message_size = self.max_encoding_message_size;
8367 let inner = self.inner.clone();
8368 let fut = async move {
8369 let method = WarmUpTableCacheSvc(inner);
8370 let codec = tonic_prost::ProstCodec::default();
8371 let mut grpc = tonic::server::Grpc::new(codec)
8372 .apply_compression_config(
8373 accept_compression_encodings,
8374 send_compression_encodings,
8375 )
8376 .apply_max_message_size_config(
8377 max_decoding_message_size,
8378 max_encoding_message_size,
8379 );
8380 let res = grpc.unary(method, req).await;
8381 Ok(res)
8382 };
8383 Box::pin(fut)
8384 }
8385 _ => {
8386 Box::pin(async move {
8387 let mut response = http::Response::new(
8388 tonic::body::Body::default(),
8389 );
8390 let headers = response.headers_mut();
8391 headers
8392 .insert(
8393 tonic::Status::GRPC_STATUS,
8394 (tonic::Code::Unimplemented as i32).into(),
8395 );
8396 headers
8397 .insert(
8398 http::header::CONTENT_TYPE,
8399 tonic::metadata::GRPC_CONTENT_TYPE,
8400 );
8401 Ok(response)
8402 })
8403 }
8404 }
8405 }
8406 }
8407 impl<T> Clone for ServingServiceServer<T> {
8408 fn clone(&self) -> Self {
8409 let inner = self.inner.clone();
8410 Self {
8411 inner,
8412 accept_compression_encodings: self.accept_compression_encodings,
8413 send_compression_encodings: self.send_compression_encodings,
8414 max_decoding_message_size: self.max_decoding_message_size,
8415 max_encoding_message_size: self.max_encoding_message_size,
8416 }
8417 }
8418 }
8419 pub const SERVICE_NAME: &str = "meta.ServingService";
8421 impl<T> tonic::server::NamedService for ServingServiceServer<T> {
8422 const NAME: &'static str = SERVICE_NAME;
8423 }
8424}
8425pub mod event_log_service_client {
8427 #![allow(
8428 unused_variables,
8429 dead_code,
8430 missing_docs,
8431 clippy::wildcard_imports,
8432 clippy::let_unit_value,
8433 )]
8434 use tonic::codegen::*;
8435 use tonic::codegen::http::Uri;
8436 #[derive(Debug, Clone)]
8437 pub struct EventLogServiceClient<T> {
8438 inner: tonic::client::Grpc<T>,
8439 }
8440 impl EventLogServiceClient<tonic::transport::Channel> {
8441 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
8443 where
8444 D: TryInto<tonic::transport::Endpoint>,
8445 D::Error: Into<StdError>,
8446 {
8447 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
8448 Ok(Self::new(conn))
8449 }
8450 }
8451 impl<T> EventLogServiceClient<T>
8452 where
8453 T: tonic::client::GrpcService<tonic::body::Body>,
8454 T::Error: Into<StdError>,
8455 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
8456 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
8457 {
8458 pub fn new(inner: T) -> Self {
8459 let inner = tonic::client::Grpc::new(inner);
8460 Self { inner }
8461 }
8462 pub fn with_origin(inner: T, origin: Uri) -> Self {
8463 let inner = tonic::client::Grpc::with_origin(inner, origin);
8464 Self { inner }
8465 }
8466 pub fn with_interceptor<F>(
8467 inner: T,
8468 interceptor: F,
8469 ) -> EventLogServiceClient<InterceptedService<T, F>>
8470 where
8471 F: tonic::service::Interceptor,
8472 T::ResponseBody: Default,
8473 T: tonic::codegen::Service<
8474 http::Request<tonic::body::Body>,
8475 Response = http::Response<
8476 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
8477 >,
8478 >,
8479 <T as tonic::codegen::Service<
8480 http::Request<tonic::body::Body>,
8481 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
8482 {
8483 EventLogServiceClient::new(InterceptedService::new(inner, interceptor))
8484 }
8485 #[must_use]
8490 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
8491 self.inner = self.inner.send_compressed(encoding);
8492 self
8493 }
8494 #[must_use]
8496 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
8497 self.inner = self.inner.accept_compressed(encoding);
8498 self
8499 }
8500 #[must_use]
8504 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
8505 self.inner = self.inner.max_decoding_message_size(limit);
8506 self
8507 }
8508 #[must_use]
8512 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
8513 self.inner = self.inner.max_encoding_message_size(limit);
8514 self
8515 }
8516 pub async fn list_event_log(
8517 &mut self,
8518 request: impl tonic::IntoRequest<super::ListEventLogRequest>,
8519 ) -> std::result::Result<
8520 tonic::Response<super::ListEventLogResponse>,
8521 tonic::Status,
8522 > {
8523 self.inner
8524 .ready()
8525 .await
8526 .map_err(|e| {
8527 tonic::Status::unknown(
8528 format!("Service was not ready: {}", e.into()),
8529 )
8530 })?;
8531 let codec = tonic_prost::ProstCodec::default();
8532 let path = http::uri::PathAndQuery::from_static(
8533 "/meta.EventLogService/ListEventLog",
8534 );
8535 let mut req = request.into_request();
8536 req.extensions_mut()
8537 .insert(GrpcMethod::new("meta.EventLogService", "ListEventLog"));
8538 self.inner.unary(req, path, codec).await
8539 }
8540 pub async fn add_event_log(
8541 &mut self,
8542 request: impl tonic::IntoRequest<super::AddEventLogRequest>,
8543 ) -> std::result::Result<
8544 tonic::Response<super::AddEventLogResponse>,
8545 tonic::Status,
8546 > {
8547 self.inner
8548 .ready()
8549 .await
8550 .map_err(|e| {
8551 tonic::Status::unknown(
8552 format!("Service was not ready: {}", e.into()),
8553 )
8554 })?;
8555 let codec = tonic_prost::ProstCodec::default();
8556 let path = http::uri::PathAndQuery::from_static(
8557 "/meta.EventLogService/AddEventLog",
8558 );
8559 let mut req = request.into_request();
8560 req.extensions_mut()
8561 .insert(GrpcMethod::new("meta.EventLogService", "AddEventLog"));
8562 self.inner.unary(req, path, codec).await
8563 }
8564 }
8565}
8566pub mod event_log_service_server {
8568 #![allow(
8569 unused_variables,
8570 dead_code,
8571 missing_docs,
8572 clippy::wildcard_imports,
8573 clippy::let_unit_value,
8574 )]
8575 use tonic::codegen::*;
8576 #[async_trait]
8578 pub trait EventLogService: std::marker::Send + std::marker::Sync + 'static {
8579 async fn list_event_log(
8580 &self,
8581 request: tonic::Request<super::ListEventLogRequest>,
8582 ) -> std::result::Result<
8583 tonic::Response<super::ListEventLogResponse>,
8584 tonic::Status,
8585 >;
8586 async fn add_event_log(
8587 &self,
8588 request: tonic::Request<super::AddEventLogRequest>,
8589 ) -> std::result::Result<
8590 tonic::Response<super::AddEventLogResponse>,
8591 tonic::Status,
8592 >;
8593 }
8594 #[derive(Debug)]
8595 pub struct EventLogServiceServer<T> {
8596 inner: Arc<T>,
8597 accept_compression_encodings: EnabledCompressionEncodings,
8598 send_compression_encodings: EnabledCompressionEncodings,
8599 max_decoding_message_size: Option<usize>,
8600 max_encoding_message_size: Option<usize>,
8601 }
8602 impl<T> EventLogServiceServer<T> {
8603 pub fn new(inner: T) -> Self {
8604 Self::from_arc(Arc::new(inner))
8605 }
8606 pub fn from_arc(inner: Arc<T>) -> Self {
8607 Self {
8608 inner,
8609 accept_compression_encodings: Default::default(),
8610 send_compression_encodings: Default::default(),
8611 max_decoding_message_size: None,
8612 max_encoding_message_size: None,
8613 }
8614 }
8615 pub fn with_interceptor<F>(
8616 inner: T,
8617 interceptor: F,
8618 ) -> InterceptedService<Self, F>
8619 where
8620 F: tonic::service::Interceptor,
8621 {
8622 InterceptedService::new(Self::new(inner), interceptor)
8623 }
8624 #[must_use]
8626 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
8627 self.accept_compression_encodings.enable(encoding);
8628 self
8629 }
8630 #[must_use]
8632 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
8633 self.send_compression_encodings.enable(encoding);
8634 self
8635 }
8636 #[must_use]
8640 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
8641 self.max_decoding_message_size = Some(limit);
8642 self
8643 }
8644 #[must_use]
8648 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
8649 self.max_encoding_message_size = Some(limit);
8650 self
8651 }
8652 }
8653 impl<T, B> tonic::codegen::Service<http::Request<B>> for EventLogServiceServer<T>
8654 where
8655 T: EventLogService,
8656 B: Body + std::marker::Send + 'static,
8657 B::Error: Into<StdError> + std::marker::Send + 'static,
8658 {
8659 type Response = http::Response<tonic::body::Body>;
8660 type Error = std::convert::Infallible;
8661 type Future = BoxFuture<Self::Response, Self::Error>;
8662 fn poll_ready(
8663 &mut self,
8664 _cx: &mut Context<'_>,
8665 ) -> Poll<std::result::Result<(), Self::Error>> {
8666 Poll::Ready(Ok(()))
8667 }
8668 fn call(&mut self, req: http::Request<B>) -> Self::Future {
8669 match req.uri().path() {
8670 "/meta.EventLogService/ListEventLog" => {
8671 #[allow(non_camel_case_types)]
8672 struct ListEventLogSvc<T: EventLogService>(pub Arc<T>);
8673 impl<
8674 T: EventLogService,
8675 > tonic::server::UnaryService<super::ListEventLogRequest>
8676 for ListEventLogSvc<T> {
8677 type Response = super::ListEventLogResponse;
8678 type Future = BoxFuture<
8679 tonic::Response<Self::Response>,
8680 tonic::Status,
8681 >;
8682 fn call(
8683 &mut self,
8684 request: tonic::Request<super::ListEventLogRequest>,
8685 ) -> Self::Future {
8686 let inner = Arc::clone(&self.0);
8687 let fut = async move {
8688 <T as EventLogService>::list_event_log(&inner, request)
8689 .await
8690 };
8691 Box::pin(fut)
8692 }
8693 }
8694 let accept_compression_encodings = self.accept_compression_encodings;
8695 let send_compression_encodings = self.send_compression_encodings;
8696 let max_decoding_message_size = self.max_decoding_message_size;
8697 let max_encoding_message_size = self.max_encoding_message_size;
8698 let inner = self.inner.clone();
8699 let fut = async move {
8700 let method = ListEventLogSvc(inner);
8701 let codec = tonic_prost::ProstCodec::default();
8702 let mut grpc = tonic::server::Grpc::new(codec)
8703 .apply_compression_config(
8704 accept_compression_encodings,
8705 send_compression_encodings,
8706 )
8707 .apply_max_message_size_config(
8708 max_decoding_message_size,
8709 max_encoding_message_size,
8710 );
8711 let res = grpc.unary(method, req).await;
8712 Ok(res)
8713 };
8714 Box::pin(fut)
8715 }
8716 "/meta.EventLogService/AddEventLog" => {
8717 #[allow(non_camel_case_types)]
8718 struct AddEventLogSvc<T: EventLogService>(pub Arc<T>);
8719 impl<
8720 T: EventLogService,
8721 > tonic::server::UnaryService<super::AddEventLogRequest>
8722 for AddEventLogSvc<T> {
8723 type Response = super::AddEventLogResponse;
8724 type Future = BoxFuture<
8725 tonic::Response<Self::Response>,
8726 tonic::Status,
8727 >;
8728 fn call(
8729 &mut self,
8730 request: tonic::Request<super::AddEventLogRequest>,
8731 ) -> Self::Future {
8732 let inner = Arc::clone(&self.0);
8733 let fut = async move {
8734 <T as EventLogService>::add_event_log(&inner, request).await
8735 };
8736 Box::pin(fut)
8737 }
8738 }
8739 let accept_compression_encodings = self.accept_compression_encodings;
8740 let send_compression_encodings = self.send_compression_encodings;
8741 let max_decoding_message_size = self.max_decoding_message_size;
8742 let max_encoding_message_size = self.max_encoding_message_size;
8743 let inner = self.inner.clone();
8744 let fut = async move {
8745 let method = AddEventLogSvc(inner);
8746 let codec = tonic_prost::ProstCodec::default();
8747 let mut grpc = tonic::server::Grpc::new(codec)
8748 .apply_compression_config(
8749 accept_compression_encodings,
8750 send_compression_encodings,
8751 )
8752 .apply_max_message_size_config(
8753 max_decoding_message_size,
8754 max_encoding_message_size,
8755 );
8756 let res = grpc.unary(method, req).await;
8757 Ok(res)
8758 };
8759 Box::pin(fut)
8760 }
8761 _ => {
8762 Box::pin(async move {
8763 let mut response = http::Response::new(
8764 tonic::body::Body::default(),
8765 );
8766 let headers = response.headers_mut();
8767 headers
8768 .insert(
8769 tonic::Status::GRPC_STATUS,
8770 (tonic::Code::Unimplemented as i32).into(),
8771 );
8772 headers
8773 .insert(
8774 http::header::CONTENT_TYPE,
8775 tonic::metadata::GRPC_CONTENT_TYPE,
8776 );
8777 Ok(response)
8778 })
8779 }
8780 }
8781 }
8782 }
8783 impl<T> Clone for EventLogServiceServer<T> {
8784 fn clone(&self) -> Self {
8785 let inner = self.inner.clone();
8786 Self {
8787 inner,
8788 accept_compression_encodings: self.accept_compression_encodings,
8789 send_compression_encodings: self.send_compression_encodings,
8790 max_decoding_message_size: self.max_decoding_message_size,
8791 max_encoding_message_size: self.max_encoding_message_size,
8792 }
8793 }
8794 }
8795 pub const SERVICE_NAME: &str = "meta.EventLogService";
8797 impl<T> tonic::server::NamedService for EventLogServiceServer<T> {
8798 const NAME: &'static str = SERVICE_NAME;
8799 }
8800}
8801pub mod cluster_limit_service_client {
8803 #![allow(
8804 unused_variables,
8805 dead_code,
8806 missing_docs,
8807 clippy::wildcard_imports,
8808 clippy::let_unit_value,
8809 )]
8810 use tonic::codegen::*;
8811 use tonic::codegen::http::Uri;
8812 #[derive(Debug, Clone)]
8813 pub struct ClusterLimitServiceClient<T> {
8814 inner: tonic::client::Grpc<T>,
8815 }
8816 impl ClusterLimitServiceClient<tonic::transport::Channel> {
8817 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
8819 where
8820 D: TryInto<tonic::transport::Endpoint>,
8821 D::Error: Into<StdError>,
8822 {
8823 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
8824 Ok(Self::new(conn))
8825 }
8826 }
8827 impl<T> ClusterLimitServiceClient<T>
8828 where
8829 T: tonic::client::GrpcService<tonic::body::Body>,
8830 T::Error: Into<StdError>,
8831 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
8832 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
8833 {
8834 pub fn new(inner: T) -> Self {
8835 let inner = tonic::client::Grpc::new(inner);
8836 Self { inner }
8837 }
8838 pub fn with_origin(inner: T, origin: Uri) -> Self {
8839 let inner = tonic::client::Grpc::with_origin(inner, origin);
8840 Self { inner }
8841 }
8842 pub fn with_interceptor<F>(
8843 inner: T,
8844 interceptor: F,
8845 ) -> ClusterLimitServiceClient<InterceptedService<T, F>>
8846 where
8847 F: tonic::service::Interceptor,
8848 T::ResponseBody: Default,
8849 T: tonic::codegen::Service<
8850 http::Request<tonic::body::Body>,
8851 Response = http::Response<
8852 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
8853 >,
8854 >,
8855 <T as tonic::codegen::Service<
8856 http::Request<tonic::body::Body>,
8857 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
8858 {
8859 ClusterLimitServiceClient::new(InterceptedService::new(inner, interceptor))
8860 }
8861 #[must_use]
8866 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
8867 self.inner = self.inner.send_compressed(encoding);
8868 self
8869 }
8870 #[must_use]
8872 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
8873 self.inner = self.inner.accept_compressed(encoding);
8874 self
8875 }
8876 #[must_use]
8880 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
8881 self.inner = self.inner.max_decoding_message_size(limit);
8882 self
8883 }
8884 #[must_use]
8888 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
8889 self.inner = self.inner.max_encoding_message_size(limit);
8890 self
8891 }
8892 pub async fn get_cluster_limits(
8893 &mut self,
8894 request: impl tonic::IntoRequest<super::GetClusterLimitsRequest>,
8895 ) -> std::result::Result<
8896 tonic::Response<super::GetClusterLimitsResponse>,
8897 tonic::Status,
8898 > {
8899 self.inner
8900 .ready()
8901 .await
8902 .map_err(|e| {
8903 tonic::Status::unknown(
8904 format!("Service was not ready: {}", e.into()),
8905 )
8906 })?;
8907 let codec = tonic_prost::ProstCodec::default();
8908 let path = http::uri::PathAndQuery::from_static(
8909 "/meta.ClusterLimitService/GetClusterLimits",
8910 );
8911 let mut req = request.into_request();
8912 req.extensions_mut()
8913 .insert(GrpcMethod::new("meta.ClusterLimitService", "GetClusterLimits"));
8914 self.inner.unary(req, path, codec).await
8915 }
8916 }
8917}
8918pub mod cluster_limit_service_server {
8920 #![allow(
8921 unused_variables,
8922 dead_code,
8923 missing_docs,
8924 clippy::wildcard_imports,
8925 clippy::let_unit_value,
8926 )]
8927 use tonic::codegen::*;
8928 #[async_trait]
8930 pub trait ClusterLimitService: std::marker::Send + std::marker::Sync + 'static {
8931 async fn get_cluster_limits(
8932 &self,
8933 request: tonic::Request<super::GetClusterLimitsRequest>,
8934 ) -> std::result::Result<
8935 tonic::Response<super::GetClusterLimitsResponse>,
8936 tonic::Status,
8937 >;
8938 }
8939 #[derive(Debug)]
8940 pub struct ClusterLimitServiceServer<T> {
8941 inner: Arc<T>,
8942 accept_compression_encodings: EnabledCompressionEncodings,
8943 send_compression_encodings: EnabledCompressionEncodings,
8944 max_decoding_message_size: Option<usize>,
8945 max_encoding_message_size: Option<usize>,
8946 }
8947 impl<T> ClusterLimitServiceServer<T> {
8948 pub fn new(inner: T) -> Self {
8949 Self::from_arc(Arc::new(inner))
8950 }
8951 pub fn from_arc(inner: Arc<T>) -> Self {
8952 Self {
8953 inner,
8954 accept_compression_encodings: Default::default(),
8955 send_compression_encodings: Default::default(),
8956 max_decoding_message_size: None,
8957 max_encoding_message_size: None,
8958 }
8959 }
8960 pub fn with_interceptor<F>(
8961 inner: T,
8962 interceptor: F,
8963 ) -> InterceptedService<Self, F>
8964 where
8965 F: tonic::service::Interceptor,
8966 {
8967 InterceptedService::new(Self::new(inner), interceptor)
8968 }
8969 #[must_use]
8971 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
8972 self.accept_compression_encodings.enable(encoding);
8973 self
8974 }
8975 #[must_use]
8977 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
8978 self.send_compression_encodings.enable(encoding);
8979 self
8980 }
8981 #[must_use]
8985 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
8986 self.max_decoding_message_size = Some(limit);
8987 self
8988 }
8989 #[must_use]
8993 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
8994 self.max_encoding_message_size = Some(limit);
8995 self
8996 }
8997 }
8998 impl<T, B> tonic::codegen::Service<http::Request<B>> for ClusterLimitServiceServer<T>
8999 where
9000 T: ClusterLimitService,
9001 B: Body + std::marker::Send + 'static,
9002 B::Error: Into<StdError> + std::marker::Send + 'static,
9003 {
9004 type Response = http::Response<tonic::body::Body>;
9005 type Error = std::convert::Infallible;
9006 type Future = BoxFuture<Self::Response, Self::Error>;
9007 fn poll_ready(
9008 &mut self,
9009 _cx: &mut Context<'_>,
9010 ) -> Poll<std::result::Result<(), Self::Error>> {
9011 Poll::Ready(Ok(()))
9012 }
9013 fn call(&mut self, req: http::Request<B>) -> Self::Future {
9014 match req.uri().path() {
9015 "/meta.ClusterLimitService/GetClusterLimits" => {
9016 #[allow(non_camel_case_types)]
9017 struct GetClusterLimitsSvc<T: ClusterLimitService>(pub Arc<T>);
9018 impl<
9019 T: ClusterLimitService,
9020 > tonic::server::UnaryService<super::GetClusterLimitsRequest>
9021 for GetClusterLimitsSvc<T> {
9022 type Response = super::GetClusterLimitsResponse;
9023 type Future = BoxFuture<
9024 tonic::Response<Self::Response>,
9025 tonic::Status,
9026 >;
9027 fn call(
9028 &mut self,
9029 request: tonic::Request<super::GetClusterLimitsRequest>,
9030 ) -> Self::Future {
9031 let inner = Arc::clone(&self.0);
9032 let fut = async move {
9033 <T as ClusterLimitService>::get_cluster_limits(
9034 &inner,
9035 request,
9036 )
9037 .await
9038 };
9039 Box::pin(fut)
9040 }
9041 }
9042 let accept_compression_encodings = self.accept_compression_encodings;
9043 let send_compression_encodings = self.send_compression_encodings;
9044 let max_decoding_message_size = self.max_decoding_message_size;
9045 let max_encoding_message_size = self.max_encoding_message_size;
9046 let inner = self.inner.clone();
9047 let fut = async move {
9048 let method = GetClusterLimitsSvc(inner);
9049 let codec = tonic_prost::ProstCodec::default();
9050 let mut grpc = tonic::server::Grpc::new(codec)
9051 .apply_compression_config(
9052 accept_compression_encodings,
9053 send_compression_encodings,
9054 )
9055 .apply_max_message_size_config(
9056 max_decoding_message_size,
9057 max_encoding_message_size,
9058 );
9059 let res = grpc.unary(method, req).await;
9060 Ok(res)
9061 };
9062 Box::pin(fut)
9063 }
9064 _ => {
9065 Box::pin(async move {
9066 let mut response = http::Response::new(
9067 tonic::body::Body::default(),
9068 );
9069 let headers = response.headers_mut();
9070 headers
9071 .insert(
9072 tonic::Status::GRPC_STATUS,
9073 (tonic::Code::Unimplemented as i32).into(),
9074 );
9075 headers
9076 .insert(
9077 http::header::CONTENT_TYPE,
9078 tonic::metadata::GRPC_CONTENT_TYPE,
9079 );
9080 Ok(response)
9081 })
9082 }
9083 }
9084 }
9085 }
9086 impl<T> Clone for ClusterLimitServiceServer<T> {
9087 fn clone(&self) -> Self {
9088 let inner = self.inner.clone();
9089 Self {
9090 inner,
9091 accept_compression_encodings: self.accept_compression_encodings,
9092 send_compression_encodings: self.send_compression_encodings,
9093 max_decoding_message_size: self.max_decoding_message_size,
9094 max_encoding_message_size: self.max_encoding_message_size,
9095 }
9096 }
9097 }
9098 pub const SERVICE_NAME: &str = "meta.ClusterLimitService";
9100 impl<T> tonic::server::NamedService for ClusterLimitServiceServer<T> {
9101 const NAME: &'static str = SERVICE_NAME;
9102 }
9103}
9104pub mod hosted_iceberg_catalog_service_client {
9106 #![allow(
9107 unused_variables,
9108 dead_code,
9109 missing_docs,
9110 clippy::wildcard_imports,
9111 clippy::let_unit_value,
9112 )]
9113 use tonic::codegen::*;
9114 use tonic::codegen::http::Uri;
9115 #[derive(Debug, Clone)]
9116 pub struct HostedIcebergCatalogServiceClient<T> {
9117 inner: tonic::client::Grpc<T>,
9118 }
9119 impl HostedIcebergCatalogServiceClient<tonic::transport::Channel> {
9120 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
9122 where
9123 D: TryInto<tonic::transport::Endpoint>,
9124 D::Error: Into<StdError>,
9125 {
9126 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
9127 Ok(Self::new(conn))
9128 }
9129 }
9130 impl<T> HostedIcebergCatalogServiceClient<T>
9131 where
9132 T: tonic::client::GrpcService<tonic::body::Body>,
9133 T::Error: Into<StdError>,
9134 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
9135 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
9136 {
9137 pub fn new(inner: T) -> Self {
9138 let inner = tonic::client::Grpc::new(inner);
9139 Self { inner }
9140 }
9141 pub fn with_origin(inner: T, origin: Uri) -> Self {
9142 let inner = tonic::client::Grpc::with_origin(inner, origin);
9143 Self { inner }
9144 }
9145 pub fn with_interceptor<F>(
9146 inner: T,
9147 interceptor: F,
9148 ) -> HostedIcebergCatalogServiceClient<InterceptedService<T, F>>
9149 where
9150 F: tonic::service::Interceptor,
9151 T::ResponseBody: Default,
9152 T: tonic::codegen::Service<
9153 http::Request<tonic::body::Body>,
9154 Response = http::Response<
9155 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
9156 >,
9157 >,
9158 <T as tonic::codegen::Service<
9159 http::Request<tonic::body::Body>,
9160 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
9161 {
9162 HostedIcebergCatalogServiceClient::new(
9163 InterceptedService::new(inner, interceptor),
9164 )
9165 }
9166 #[must_use]
9171 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
9172 self.inner = self.inner.send_compressed(encoding);
9173 self
9174 }
9175 #[must_use]
9177 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
9178 self.inner = self.inner.accept_compressed(encoding);
9179 self
9180 }
9181 #[must_use]
9185 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
9186 self.inner = self.inner.max_decoding_message_size(limit);
9187 self
9188 }
9189 #[must_use]
9193 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
9194 self.inner = self.inner.max_encoding_message_size(limit);
9195 self
9196 }
9197 pub async fn list_iceberg_tables(
9198 &mut self,
9199 request: impl tonic::IntoRequest<super::ListIcebergTablesRequest>,
9200 ) -> std::result::Result<
9201 tonic::Response<super::ListIcebergTablesResponse>,
9202 tonic::Status,
9203 > {
9204 self.inner
9205 .ready()
9206 .await
9207 .map_err(|e| {
9208 tonic::Status::unknown(
9209 format!("Service was not ready: {}", e.into()),
9210 )
9211 })?;
9212 let codec = tonic_prost::ProstCodec::default();
9213 let path = http::uri::PathAndQuery::from_static(
9214 "/meta.HostedIcebergCatalogService/ListIcebergTables",
9215 );
9216 let mut req = request.into_request();
9217 req.extensions_mut()
9218 .insert(
9219 GrpcMethod::new(
9220 "meta.HostedIcebergCatalogService",
9221 "ListIcebergTables",
9222 ),
9223 );
9224 self.inner.unary(req, path, codec).await
9225 }
9226 }
9227}
9228pub mod hosted_iceberg_catalog_service_server {
9230 #![allow(
9231 unused_variables,
9232 dead_code,
9233 missing_docs,
9234 clippy::wildcard_imports,
9235 clippy::let_unit_value,
9236 )]
9237 use tonic::codegen::*;
9238 #[async_trait]
9240 pub trait HostedIcebergCatalogService: std::marker::Send + std::marker::Sync + 'static {
9241 async fn list_iceberg_tables(
9242 &self,
9243 request: tonic::Request<super::ListIcebergTablesRequest>,
9244 ) -> std::result::Result<
9245 tonic::Response<super::ListIcebergTablesResponse>,
9246 tonic::Status,
9247 >;
9248 }
9249 #[derive(Debug)]
9250 pub struct HostedIcebergCatalogServiceServer<T> {
9251 inner: Arc<T>,
9252 accept_compression_encodings: EnabledCompressionEncodings,
9253 send_compression_encodings: EnabledCompressionEncodings,
9254 max_decoding_message_size: Option<usize>,
9255 max_encoding_message_size: Option<usize>,
9256 }
9257 impl<T> HostedIcebergCatalogServiceServer<T> {
9258 pub fn new(inner: T) -> Self {
9259 Self::from_arc(Arc::new(inner))
9260 }
9261 pub fn from_arc(inner: Arc<T>) -> Self {
9262 Self {
9263 inner,
9264 accept_compression_encodings: Default::default(),
9265 send_compression_encodings: Default::default(),
9266 max_decoding_message_size: None,
9267 max_encoding_message_size: None,
9268 }
9269 }
9270 pub fn with_interceptor<F>(
9271 inner: T,
9272 interceptor: F,
9273 ) -> InterceptedService<Self, F>
9274 where
9275 F: tonic::service::Interceptor,
9276 {
9277 InterceptedService::new(Self::new(inner), interceptor)
9278 }
9279 #[must_use]
9281 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
9282 self.accept_compression_encodings.enable(encoding);
9283 self
9284 }
9285 #[must_use]
9287 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
9288 self.send_compression_encodings.enable(encoding);
9289 self
9290 }
9291 #[must_use]
9295 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
9296 self.max_decoding_message_size = Some(limit);
9297 self
9298 }
9299 #[must_use]
9303 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
9304 self.max_encoding_message_size = Some(limit);
9305 self
9306 }
9307 }
9308 impl<T, B> tonic::codegen::Service<http::Request<B>>
9309 for HostedIcebergCatalogServiceServer<T>
9310 where
9311 T: HostedIcebergCatalogService,
9312 B: Body + std::marker::Send + 'static,
9313 B::Error: Into<StdError> + std::marker::Send + 'static,
9314 {
9315 type Response = http::Response<tonic::body::Body>;
9316 type Error = std::convert::Infallible;
9317 type Future = BoxFuture<Self::Response, Self::Error>;
9318 fn poll_ready(
9319 &mut self,
9320 _cx: &mut Context<'_>,
9321 ) -> Poll<std::result::Result<(), Self::Error>> {
9322 Poll::Ready(Ok(()))
9323 }
9324 fn call(&mut self, req: http::Request<B>) -> Self::Future {
9325 match req.uri().path() {
9326 "/meta.HostedIcebergCatalogService/ListIcebergTables" => {
9327 #[allow(non_camel_case_types)]
9328 struct ListIcebergTablesSvc<T: HostedIcebergCatalogService>(
9329 pub Arc<T>,
9330 );
9331 impl<
9332 T: HostedIcebergCatalogService,
9333 > tonic::server::UnaryService<super::ListIcebergTablesRequest>
9334 for ListIcebergTablesSvc<T> {
9335 type Response = super::ListIcebergTablesResponse;
9336 type Future = BoxFuture<
9337 tonic::Response<Self::Response>,
9338 tonic::Status,
9339 >;
9340 fn call(
9341 &mut self,
9342 request: tonic::Request<super::ListIcebergTablesRequest>,
9343 ) -> Self::Future {
9344 let inner = Arc::clone(&self.0);
9345 let fut = async move {
9346 <T as HostedIcebergCatalogService>::list_iceberg_tables(
9347 &inner,
9348 request,
9349 )
9350 .await
9351 };
9352 Box::pin(fut)
9353 }
9354 }
9355 let accept_compression_encodings = self.accept_compression_encodings;
9356 let send_compression_encodings = self.send_compression_encodings;
9357 let max_decoding_message_size = self.max_decoding_message_size;
9358 let max_encoding_message_size = self.max_encoding_message_size;
9359 let inner = self.inner.clone();
9360 let fut = async move {
9361 let method = ListIcebergTablesSvc(inner);
9362 let codec = tonic_prost::ProstCodec::default();
9363 let mut grpc = tonic::server::Grpc::new(codec)
9364 .apply_compression_config(
9365 accept_compression_encodings,
9366 send_compression_encodings,
9367 )
9368 .apply_max_message_size_config(
9369 max_decoding_message_size,
9370 max_encoding_message_size,
9371 );
9372 let res = grpc.unary(method, req).await;
9373 Ok(res)
9374 };
9375 Box::pin(fut)
9376 }
9377 _ => {
9378 Box::pin(async move {
9379 let mut response = http::Response::new(
9380 tonic::body::Body::default(),
9381 );
9382 let headers = response.headers_mut();
9383 headers
9384 .insert(
9385 tonic::Status::GRPC_STATUS,
9386 (tonic::Code::Unimplemented as i32).into(),
9387 );
9388 headers
9389 .insert(
9390 http::header::CONTENT_TYPE,
9391 tonic::metadata::GRPC_CONTENT_TYPE,
9392 );
9393 Ok(response)
9394 })
9395 }
9396 }
9397 }
9398 }
9399 impl<T> Clone for HostedIcebergCatalogServiceServer<T> {
9400 fn clone(&self) -> Self {
9401 let inner = self.inner.clone();
9402 Self {
9403 inner,
9404 accept_compression_encodings: self.accept_compression_encodings,
9405 send_compression_encodings: self.send_compression_encodings,
9406 max_decoding_message_size: self.max_decoding_message_size,
9407 max_encoding_message_size: self.max_encoding_message_size,
9408 }
9409 }
9410 }
9411 pub const SERVICE_NAME: &str = "meta.HostedIcebergCatalogService";
9413 impl<T> tonic::server::NamedService for HostedIcebergCatalogServiceServer<T> {
9414 const NAME: &'static str = SERVICE_NAME;
9415 }
9416}