momento_protos/protosocket/
cache.rs1#[derive(Clone, PartialEq, ::prost::Message)]
4pub struct CacheCommand {
5 #[prost(uint64, tag = "2")]
8 pub message_id: u64,
9 #[prost(uint32, tag = "3")]
11 pub control_code: u32,
12 #[prost(oneof = "cache_command::RpcKind", tags = "10")]
14 pub rpc_kind: ::core::option::Option<cache_command::RpcKind>,
15}
16pub mod cache_command {
18 #[derive(Clone, PartialEq, ::prost::Oneof)]
20 pub enum RpcKind {
21 #[prost(message, tag = "10")]
22 Unary(super::Unary),
23 }
24}
25#[derive(Clone, PartialEq, ::prost::Message)]
27pub struct Unary {
28 #[prost(oneof = "unary::Command", tags = "1, 2, 3, 4")]
29 pub command: ::core::option::Option<unary::Command>,
30}
31pub mod unary {
33 #[derive(Clone, PartialEq, ::prost::Oneof)]
34 pub enum Command {
35 #[prost(message, tag = "1")]
41 Auth(super::AuthenticateCommand),
42 #[prost(message, tag = "2")]
44 Get(super::GetCommand),
45 #[prost(message, tag = "3")]
47 Set(super::SetCommand),
48 #[prost(message, tag = "4")]
50 Delete(super::DeleteCommand),
51 }
52}
53#[derive(Clone, PartialEq, ::prost::Message)]
55pub struct CacheResponse {
56 #[prost(uint64, tag = "1")]
58 pub message_id: u64,
59 #[prost(uint32, tag = "2")]
61 pub control_code: u32,
62 #[prost(oneof = "cache_response::Kind", tags = "9, 10, 11, 12, 13")]
64 pub kind: ::core::option::Option<cache_response::Kind>,
65}
66pub mod cache_response {
68 #[derive(Clone, PartialEq, ::prost::Oneof)]
70 pub enum Kind {
71 #[prost(message, tag = "9")]
72 Error(super::super::common::CommandError),
73 #[prost(message, tag = "10")]
74 Auth(super::AuthenticateResponse),
75 #[prost(message, tag = "11")]
76 Get(super::GetResponse),
77 #[prost(message, tag = "12")]
78 Set(super::SetResponse),
79 #[prost(message, tag = "13")]
80 Delete(super::DeleteResponse),
81 }
82}
83#[derive(Clone, PartialEq, ::prost::Message)]
84pub struct AuthenticateCommand {
85 #[prost(string, tag = "1")]
86 pub token: ::prost::alloc::string::String,
87}
88#[derive(Clone, Copy, PartialEq, ::prost::Message)]
89pub struct AuthenticateResponse {}
90#[derive(Clone, PartialEq, ::prost::Message)]
91pub struct GetCommand {
92 #[prost(string, tag = "1")]
93 pub namespace: ::prost::alloc::string::String,
94 #[prost(bytes = "vec", tag = "2")]
95 pub key: ::prost::alloc::vec::Vec<u8>,
96}
97#[derive(Clone, PartialEq, ::prost::Message)]
98pub struct GetResponse {
99 #[prost(bytes = "vec", tag = "1")]
100 pub value: ::prost::alloc::vec::Vec<u8>,
101}
102#[derive(Clone, PartialEq, ::prost::Message)]
103pub struct SetCommand {
104 #[prost(string, tag = "1")]
105 pub namespace: ::prost::alloc::string::String,
106 #[prost(bytes = "vec", tag = "2")]
107 pub key: ::prost::alloc::vec::Vec<u8>,
108 #[prost(bytes = "vec", tag = "3")]
109 pub value: ::prost::alloc::vec::Vec<u8>,
110 #[prost(uint64, tag = "4")]
111 pub ttl_milliseconds: u64,
112}
113#[derive(Clone, Copy, PartialEq, ::prost::Message)]
114pub struct SetResponse {}
115#[derive(Clone, PartialEq, ::prost::Message)]
116pub struct DeleteCommand {
117 #[prost(string, tag = "1")]
118 pub namespace: ::prost::alloc::string::String,
119 #[prost(bytes = "vec", tag = "2")]
120 pub key: ::prost::alloc::vec::Vec<u8>,
121}
122#[derive(Clone, Copy, PartialEq, ::prost::Message)]
123pub struct DeleteResponse {}