1#[derive(prost_helpers::AnyPB)]
3#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4pub struct Status {
5 #[prost(enumeration = "status::Code", tag = "1")]
6 pub code: i32,
7 #[prost(string, tag = "2")]
8 pub message: ::prost::alloc::string::String,
9}
10pub mod status {
12 #[derive(prost_helpers::AnyPB)]
13 #[derive(
14 Clone,
15 Copy,
16 Debug,
17 PartialEq,
18 Eq,
19 Hash,
20 PartialOrd,
21 Ord,
22 ::prost::Enumeration
23 )]
24 #[repr(i32)]
25 pub enum Code {
26 Unspecified = 0,
27 Ok = 1,
28 UnknownWorker = 2,
29 }
30 impl Code {
31 pub fn as_str_name(&self) -> &'static str {
36 match self {
37 Self::Unspecified => "UNSPECIFIED",
38 Self::Ok => "OK",
39 Self::UnknownWorker => "UNKNOWN_WORKER",
40 }
41 }
42 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
44 match value {
45 "UNSPECIFIED" => Some(Self::Unspecified),
46 "OK" => Some(Self::Ok),
47 "UNKNOWN_WORKER" => Some(Self::UnknownWorker),
48 _ => None,
49 }
50 }
51 }
52}
53#[derive(prost_helpers::AnyPB)]
54#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
55pub struct HostAddress {
56 #[prost(string, tag = "1")]
57 pub host: ::prost::alloc::string::String,
58 #[prost(int32, tag = "2")]
59 pub port: i32,
60}
61#[derive(prost_helpers::AnyPB)]
63#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
64pub struct ActorInfo {
65 #[prost(uint32, tag = "1", wrapper = "crate::id::ActorId")]
66 pub actor_id: crate::id::ActorId,
67 #[prost(message, optional, tag = "2")]
68 pub host: ::core::option::Option<HostAddress>,
69 #[prost(uint64, tag = "3", wrapper = "crate::id::PartialGraphId")]
70 pub partial_graph_id: crate::id::PartialGraphId,
71}
72#[derive(prost_helpers::AnyPB)]
74#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
75pub struct ActorLocation {
76 #[prost(uint32, tag = "2", wrapper = "crate::id::WorkerId")]
77 pub worker_node_id: crate::id::WorkerId,
78}
79#[derive(prost_helpers::AnyPB)]
80#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
81pub struct WorkerNode {
82 #[prost(uint32, tag = "1", wrapper = "crate::id::WorkerId")]
83 pub id: crate::id::WorkerId,
84 #[prost(enumeration = "WorkerType", tag = "2")]
85 pub r#type: i32,
86 #[prost(message, optional, tag = "3")]
87 pub host: ::core::option::Option<HostAddress>,
88 #[prost(enumeration = "worker_node::State", tag = "4")]
89 pub state: i32,
90 #[prost(message, optional, tag = "6")]
91 pub property: ::core::option::Option<worker_node::Property>,
92 #[prost(uint32, optional, tag = "7")]
94 pub transactional_id: ::core::option::Option<u32>,
95 #[prost(message, optional, tag = "8")]
99 pub resource: ::core::option::Option<worker_node::Resource>,
100 #[prost(uint64, optional, tag = "9")]
104 pub started_at: ::core::option::Option<u64>,
105}
106pub mod worker_node {
108 #[derive(prost_helpers::AnyPB)]
110 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
111 pub struct Property {
112 #[prost(bool, tag = "1")]
113 pub is_streaming: bool,
114 #[prost(bool, tag = "2")]
115 pub is_serving: bool,
116 #[prost(string, tag = "4")]
118 pub internal_rpc_host_addr: ::prost::alloc::string::String,
119 #[prost(uint32, tag = "6")]
120 pub parallelism: u32,
121 #[prost(string, optional, tag = "7")]
123 pub resource_group: ::core::option::Option<::prost::alloc::string::String>,
124 #[prost(bool, tag = "8")]
126 pub is_iceberg_compactor: bool,
127 }
128 #[derive(prost_helpers::AnyPB)]
129 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
130 pub struct Resource {
131 #[prost(string, tag = "1")]
132 pub rw_version: ::prost::alloc::string::String,
133 #[prost(uint64, tag = "2")]
134 pub total_memory_bytes: u64,
135 #[prost(uint64, tag = "3")]
136 pub total_cpu_cores: u64,
137 #[prost(string, tag = "4")]
140 pub hostname: ::prost::alloc::string::String,
141 }
142 #[derive(prost_helpers::AnyPB)]
143 #[derive(
144 Clone,
145 Copy,
146 Debug,
147 PartialEq,
148 Eq,
149 Hash,
150 PartialOrd,
151 Ord,
152 ::prost::Enumeration
153 )]
154 #[repr(i32)]
155 pub enum State {
156 Unspecified = 0,
157 Starting = 1,
158 Running = 2,
159 }
160 impl State {
161 pub fn as_str_name(&self) -> &'static str {
166 match self {
167 Self::Unspecified => "UNSPECIFIED",
168 Self::Starting => "STARTING",
169 Self::Running => "RUNNING",
170 }
171 }
172 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
174 match value {
175 "UNSPECIFIED" => Some(Self::Unspecified),
176 "STARTING" => Some(Self::Starting),
177 "RUNNING" => Some(Self::Running),
178 _ => None,
179 }
180 }
181 }
182}
183#[derive(prost_helpers::AnyPB)]
184#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
185pub struct ClusterResource {
186 #[prost(uint64, tag = "1")]
187 pub total_memory_bytes: u64,
188 #[prost(uint64, tag = "2")]
189 pub total_cpu_cores: u64,
190}
191#[derive(prost_helpers::AnyPB)]
192#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
193pub struct Buffer {
194 #[prost(enumeration = "buffer::CompressionType", tag = "1")]
195 pub compression: i32,
196 #[prost(bytes = "vec", tag = "2")]
197 pub body: ::prost::alloc::vec::Vec<u8>,
198}
199pub mod buffer {
201 #[derive(prost_helpers::AnyPB)]
202 #[derive(
203 Clone,
204 Copy,
205 Debug,
206 PartialEq,
207 Eq,
208 Hash,
209 PartialOrd,
210 Ord,
211 ::prost::Enumeration
212 )]
213 #[repr(i32)]
214 pub enum CompressionType {
215 Unspecified = 0,
216 None = 1,
217 }
218 impl CompressionType {
219 pub fn as_str_name(&self) -> &'static str {
224 match self {
225 Self::Unspecified => "UNSPECIFIED",
226 Self::None => "NONE",
227 }
228 }
229 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
231 match value {
232 "UNSPECIFIED" => Some(Self::Unspecified),
233 "NONE" => Some(Self::None),
234 _ => None,
235 }
236 }
237 }
238}
239#[derive(prost_helpers::AnyPB)]
241#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
242pub struct WorkerSlotMapping {
243 #[prost(uint32, repeated, tag = "1")]
244 pub original_indices: ::prost::alloc::vec::Vec<u32>,
245 #[prost(uint64, repeated, tag = "2")]
246 pub data: ::prost::alloc::vec::Vec<u64>,
247}
248#[derive(prost_helpers::AnyPB)]
249#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
250pub struct BatchQueryCommittedEpoch {
251 #[prost(uint64, tag = "1")]
252 pub epoch: u64,
253 #[prost(uint64, tag = "2", wrapper = "crate::id::HummockVersionId")]
254 pub hummock_version_id: crate::id::HummockVersionId,
255}
256#[derive(prost_helpers::AnyPB)]
257#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
258pub struct BatchQueryEpoch {
259 #[prost(oneof = "batch_query_epoch::Epoch", tags = "1, 2, 3, 4")]
260 pub epoch: ::core::option::Option<batch_query_epoch::Epoch>,
261}
262pub mod batch_query_epoch {
264 #[derive(prost_helpers::AnyPB)]
265 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Oneof)]
266 pub enum Epoch {
267 #[prost(message, tag = "1")]
268 Committed(super::BatchQueryCommittedEpoch),
269 #[prost(uint64, tag = "2")]
270 Current(u64),
271 #[prost(uint64, tag = "3")]
272 Backup(u64),
273 #[prost(uint64, tag = "4")]
274 TimeTravel(u64),
275 }
276}
277#[derive(prost_helpers::AnyPB)]
278#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
279pub struct OrderType {
280 #[prost(enumeration = "Direction", tag = "1")]
281 pub direction: i32,
282 #[prost(enumeration = "NullsAre", tag = "2")]
283 pub nulls_are: i32,
284}
285#[derive(prost_helpers::AnyPB)]
287#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
288pub struct ColumnOrder {
289 #[prost(uint32, tag = "1")]
290 pub column_index: u32,
291 #[prost(message, optional, tag = "2")]
292 pub order_type: ::core::option::Option<OrderType>,
293}
294#[derive(prost_helpers::AnyPB)]
295#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
296pub struct Uint32Vector {
297 #[prost(uint32, repeated, tag = "1")]
298 pub data: ::prost::alloc::vec::Vec<u32>,
299}
300#[derive(prost_helpers::AnyPB)]
301#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
302pub struct OptionalUint32 {
303 #[prost(uint32, optional, tag = "1")]
304 pub value: ::core::option::Option<u32>,
305}
306#[derive(prost_helpers::AnyPB)]
307#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
308pub struct OptionalUint64 {
309 #[prost(uint64, optional, tag = "1")]
310 pub value: ::core::option::Option<u64>,
311}
312#[derive(prost_helpers::AnyPB)]
313#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
314#[repr(i32)]
315pub enum WorkerType {
316 Unspecified = 0,
317 Frontend = 1,
318 ComputeNode = 2,
319 RiseCtl = 3,
320 Compactor = 4,
321 Meta = 5,
322}
323impl WorkerType {
324 pub fn as_str_name(&self) -> &'static str {
329 match self {
330 Self::Unspecified => "WORKER_TYPE_UNSPECIFIED",
331 Self::Frontend => "WORKER_TYPE_FRONTEND",
332 Self::ComputeNode => "WORKER_TYPE_COMPUTE_NODE",
333 Self::RiseCtl => "WORKER_TYPE_RISE_CTL",
334 Self::Compactor => "WORKER_TYPE_COMPACTOR",
335 Self::Meta => "WORKER_TYPE_META",
336 }
337 }
338 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
340 match value {
341 "WORKER_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
342 "WORKER_TYPE_FRONTEND" => Some(Self::Frontend),
343 "WORKER_TYPE_COMPUTE_NODE" => Some(Self::ComputeNode),
344 "WORKER_TYPE_RISE_CTL" => Some(Self::RiseCtl),
345 "WORKER_TYPE_COMPACTOR" => Some(Self::Compactor),
346 "WORKER_TYPE_META" => Some(Self::Meta),
347 _ => None,
348 }
349 }
350}
351#[derive(prost_helpers::AnyPB)]
352#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
353#[repr(i32)]
354pub enum Direction {
355 Unspecified = 0,
356 Ascending = 1,
357 Descending = 2,
358}
359impl Direction {
360 pub fn as_str_name(&self) -> &'static str {
365 match self {
366 Self::Unspecified => "DIRECTION_UNSPECIFIED",
367 Self::Ascending => "DIRECTION_ASCENDING",
368 Self::Descending => "DIRECTION_DESCENDING",
369 }
370 }
371 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
373 match value {
374 "DIRECTION_UNSPECIFIED" => Some(Self::Unspecified),
375 "DIRECTION_ASCENDING" => Some(Self::Ascending),
376 "DIRECTION_DESCENDING" => Some(Self::Descending),
377 _ => None,
378 }
379 }
380}
381#[derive(prost_helpers::AnyPB)]
382#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
383#[repr(i32)]
384pub enum NullsAre {
385 Unspecified = 0,
386 Largest = 1,
387 Smallest = 2,
388}
389impl NullsAre {
390 pub fn as_str_name(&self) -> &'static str {
395 match self {
396 Self::Unspecified => "NULLS_ARE_UNSPECIFIED",
397 Self::Largest => "NULLS_ARE_LARGEST",
398 Self::Smallest => "NULLS_ARE_SMALLEST",
399 }
400 }
401 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
403 match value {
404 "NULLS_ARE_UNSPECIFIED" => Some(Self::Unspecified),
405 "NULLS_ARE_LARGEST" => Some(Self::Largest),
406 "NULLS_ARE_SMALLEST" => Some(Self::Smallest),
407 _ => None,
408 }
409 }
410}
411#[derive(prost_helpers::AnyPB)]
412#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
413#[repr(i32)]
414pub enum ObjectType {
415 Unspecified = 0,
416 Database = 1,
417 Schema = 2,
418 Table = 3,
419 Mview = 4,
420 Source = 5,
421 Sink = 6,
422 View = 7,
423 Index = 8,
424 Function = 9,
425 Connection = 10,
426 Subscription = 11,
427 Secret = 12,
428}
429impl ObjectType {
430 pub fn as_str_name(&self) -> &'static str {
435 match self {
436 Self::Unspecified => "UNSPECIFIED",
437 Self::Database => "DATABASE",
438 Self::Schema => "SCHEMA",
439 Self::Table => "TABLE",
440 Self::Mview => "MVIEW",
441 Self::Source => "SOURCE",
442 Self::Sink => "SINK",
443 Self::View => "VIEW",
444 Self::Index => "INDEX",
445 Self::Function => "FUNCTION",
446 Self::Connection => "CONNECTION",
447 Self::Subscription => "SUBSCRIPTION",
448 Self::Secret => "SECRET",
449 }
450 }
451 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
453 match value {
454 "UNSPECIFIED" => Some(Self::Unspecified),
455 "DATABASE" => Some(Self::Database),
456 "SCHEMA" => Some(Self::Schema),
457 "TABLE" => Some(Self::Table),
458 "MVIEW" => Some(Self::Mview),
459 "SOURCE" => Some(Self::Source),
460 "SINK" => Some(Self::Sink),
461 "VIEW" => Some(Self::View),
462 "INDEX" => Some(Self::Index),
463 "FUNCTION" => Some(Self::Function),
464 "CONNECTION" => Some(Self::Connection),
465 "SUBSCRIPTION" => Some(Self::Subscription),
466 "SECRET" => Some(Self::Secret),
467 _ => None,
468 }
469 }
470}
471#[derive(prost_helpers::AnyPB)]
472#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
473#[repr(i32)]
474pub enum DistanceType {
475 Unspecified = 0,
476 L1 = 1,
477 L2Sqr = 2,
478 Cosine = 3,
479 InnerProduct = 4,
480}
481impl DistanceType {
482 pub fn as_str_name(&self) -> &'static str {
487 match self {
488 Self::Unspecified => "DISTANCE_TYPE_UNSPECIFIED",
489 Self::L1 => "DISTANCE_TYPE_L1",
490 Self::L2Sqr => "DISTANCE_TYPE_L2_SQR",
491 Self::Cosine => "DISTANCE_TYPE_COSINE",
492 Self::InnerProduct => "DISTANCE_TYPE_INNER_PRODUCT",
493 }
494 }
495 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
497 match value {
498 "DISTANCE_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
499 "DISTANCE_TYPE_L1" => Some(Self::L1),
500 "DISTANCE_TYPE_L2_SQR" => Some(Self::L2Sqr),
501 "DISTANCE_TYPE_COSINE" => Some(Self::Cosine),
502 "DISTANCE_TYPE_INNER_PRODUCT" => Some(Self::InnerProduct),
503 _ => None,
504 }
505 }
506}
507#[derive(prost_helpers::AnyPB)]
508#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
509#[repr(i32)]
510pub enum ThrottleType {
511 Unspecified = 0,
512 Dml = 1,
513 Backfill = 2,
514 Source = 3,
515 Sink = 4,
516}
517impl ThrottleType {
518 pub fn as_str_name(&self) -> &'static str {
523 match self {
524 Self::Unspecified => "THROTTLE_TYPE_UNSPECIFIED",
525 Self::Dml => "THROTTLE_TYPE_DML",
526 Self::Backfill => "THROTTLE_TYPE_BACKFILL",
527 Self::Source => "THROTTLE_TYPE_SOURCE",
528 Self::Sink => "THROTTLE_TYPE_SINK",
529 }
530 }
531 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
533 match value {
534 "THROTTLE_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
535 "THROTTLE_TYPE_DML" => Some(Self::Dml),
536 "THROTTLE_TYPE_BACKFILL" => Some(Self::Backfill),
537 "THROTTLE_TYPE_SOURCE" => Some(Self::Source),
538 "THROTTLE_TYPE_SINK" => Some(Self::Sink),
539 _ => None,
540 }
541 }
542}