1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
#[derive(serde::Serialize, serde::Deserialize)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct WriteSessionParams {
#[prost(string, tag="1")]
pub topic: ::prost::alloc::string::String,
#[prost(bytes="vec", tag="2")]
pub source_id: ::prost::alloc::vec::Vec<u8>,
#[prost(uint32, tag="3")]
pub partition_group: u32,
#[prost(string, tag="4")]
pub preferred_cluster_name: ::prost::alloc::string::String,
}
#[derive(serde::Serialize, serde::Deserialize)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ClusterInfo {
#[prost(string, tag="1")]
pub endpoint: ::prost::alloc::string::String,
#[prost(string, tag="2")]
pub name: ::prost::alloc::string::String,
#[prost(bool, tag="3")]
pub available: bool,
}
#[derive(serde::Serialize, serde::Deserialize)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ReadSessionParams {
#[prost(string, tag="1")]
pub topic: ::prost::alloc::string::String,
#[prost(oneof="read_session_params::ReadRule", tags="2, 3")]
pub read_rule: ::core::option::Option<read_session_params::ReadRule>,
}
pub mod read_session_params {
#[derive(serde::Serialize, serde::Deserialize)]
#[derive(Clone, PartialEq, ::prost::Oneof)]
pub enum ReadRule {
#[prost(string, tag="2")]
MirrorToCluster(::prost::alloc::string::String),
#[prost(message, tag="3")]
AllOriginal(::pbjson_types::Empty),
}
}
#[derive(serde::Serialize, serde::Deserialize)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct WriteSessionClusters {
#[prost(message, repeated, tag="1")]
pub clusters: ::prost::alloc::vec::Vec<ClusterInfo>,
#[prost(enumeration="write_session_clusters::SelectionReason", tag="2")]
pub primary_cluster_selection_reason: i32,
}
pub mod write_session_clusters {
#[derive(serde::Serialize, serde::Deserialize)]
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum SelectionReason {
Unspecified = 0,
ClientPreference = 1,
ClientLocation = 2,
ConsistentDistribution = 3,
}
}
#[derive(serde::Serialize, serde::Deserialize)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ReadSessionClusters {
#[prost(message, repeated, tag="1")]
pub clusters: ::prost::alloc::vec::Vec<ClusterInfo>,
}
#[derive(serde::Serialize, serde::Deserialize)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct DiscoverClustersRequest {
#[prost(message, optional, tag="1")]
pub operation_params: ::core::option::Option<super::super::operations::OperationParams>,
#[prost(message, repeated, tag="2")]
pub write_sessions: ::prost::alloc::vec::Vec<WriteSessionParams>,
#[prost(message, repeated, tag="3")]
pub read_sessions: ::prost::alloc::vec::Vec<ReadSessionParams>,
#[prost(int64, tag="4")]
pub minimal_version: i64,
}
#[derive(serde::Serialize, serde::Deserialize)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct DiscoverClustersResponse {
#[prost(message, optional, tag="1")]
pub operation: ::core::option::Option<super::super::operations::Operation>,
}
#[derive(serde::Serialize, serde::Deserialize)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct DiscoverClustersResult {
#[prost(message, repeated, tag="1")]
pub write_sessions_clusters: ::prost::alloc::vec::Vec<WriteSessionClusters>,
#[prost(message, repeated, tag="2")]
pub read_sessions_clusters: ::prost::alloc::vec::Vec<ReadSessionClusters>,
#[prost(int64, tag="3")]
pub version: i64,
}