momento 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,332 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # source: cacheclient.proto
3
+
4
+ require 'google/protobuf'
5
+
6
+ Google::Protobuf::DescriptorPool.generated_pool.build do
7
+ add_file("cacheclient.proto", :syntax => :proto3) do
8
+ add_message "cache_client._GetRequest" do
9
+ optional :cache_key, :bytes, 1
10
+ end
11
+ add_message "cache_client._GetResponse" do
12
+ optional :result, :enum, 1, "cache_client.ECacheResult"
13
+ optional :cache_body, :bytes, 2
14
+ optional :message, :string, 3
15
+ end
16
+ add_message "cache_client._DeleteRequest" do
17
+ optional :cache_key, :bytes, 1
18
+ end
19
+ add_message "cache_client._DeleteResponse" do
20
+ end
21
+ add_message "cache_client._SetRequest" do
22
+ optional :cache_key, :bytes, 1
23
+ optional :cache_body, :bytes, 2
24
+ optional :ttl_milliseconds, :uint64, 3
25
+ end
26
+ add_message "cache_client._SetResponse" do
27
+ optional :result, :enum, 1, "cache_client.ECacheResult"
28
+ optional :message, :string, 2
29
+ end
30
+ add_message "cache_client._DictionaryGetRequest" do
31
+ optional :dictionary_name, :bytes, 1
32
+ repeated :fields, :bytes, 2
33
+ end
34
+ add_message "cache_client._DictionaryGetResponse" do
35
+ oneof :dictionary do
36
+ optional :found, :message, 1, "cache_client._DictionaryGetResponse._Found"
37
+ optional :missing, :message, 2, "cache_client._DictionaryGetResponse._Missing"
38
+ end
39
+ end
40
+ add_message "cache_client._DictionaryGetResponse._DictionaryGetResponsePart" do
41
+ optional :result, :enum, 1, "cache_client.ECacheResult"
42
+ optional :cache_body, :bytes, 2
43
+ end
44
+ add_message "cache_client._DictionaryGetResponse._Found" do
45
+ repeated :items, :message, 1, "cache_client._DictionaryGetResponse._DictionaryGetResponsePart"
46
+ end
47
+ add_message "cache_client._DictionaryGetResponse._Missing" do
48
+ end
49
+ add_message "cache_client._DictionaryFetchRequest" do
50
+ optional :dictionary_name, :bytes, 1
51
+ end
52
+ add_message "cache_client._DictionaryFieldValuePair" do
53
+ optional :field, :bytes, 1
54
+ optional :value, :bytes, 2
55
+ end
56
+ add_message "cache_client._DictionaryFetchResponse" do
57
+ oneof :dictionary do
58
+ optional :found, :message, 1, "cache_client._DictionaryFetchResponse._Found"
59
+ optional :missing, :message, 2, "cache_client._DictionaryFetchResponse._Missing"
60
+ end
61
+ end
62
+ add_message "cache_client._DictionaryFetchResponse._Found" do
63
+ repeated :items, :message, 1, "cache_client._DictionaryFieldValuePair"
64
+ end
65
+ add_message "cache_client._DictionaryFetchResponse._Missing" do
66
+ end
67
+ add_message "cache_client._DictionarySetRequest" do
68
+ optional :dictionary_name, :bytes, 1
69
+ repeated :items, :message, 2, "cache_client._DictionaryFieldValuePair"
70
+ optional :ttl_milliseconds, :uint64, 3
71
+ optional :refresh_ttl, :bool, 4
72
+ end
73
+ add_message "cache_client._DictionarySetResponse" do
74
+ end
75
+ add_message "cache_client._DictionaryIncrementRequest" do
76
+ optional :dictionary_name, :bytes, 1
77
+ optional :field, :bytes, 2
78
+ optional :amount, :int64, 3
79
+ optional :ttl_milliseconds, :uint64, 4
80
+ optional :refresh_ttl, :bool, 5
81
+ end
82
+ add_message "cache_client._DictionaryIncrementResponse" do
83
+ optional :value, :int64, 1
84
+ end
85
+ add_message "cache_client._DictionaryDeleteRequest" do
86
+ optional :dictionary_name, :bytes, 1
87
+ oneof :delete do
88
+ optional :some, :message, 2, "cache_client._DictionaryDeleteRequest.Some"
89
+ optional :all, :message, 3, "cache_client._DictionaryDeleteRequest.All"
90
+ end
91
+ end
92
+ add_message "cache_client._DictionaryDeleteRequest.Some" do
93
+ repeated :fields, :bytes, 1
94
+ end
95
+ add_message "cache_client._DictionaryDeleteRequest.All" do
96
+ end
97
+ add_message "cache_client._DictionaryDeleteResponse" do
98
+ end
99
+ add_message "cache_client._SetFetchRequest" do
100
+ optional :set_name, :bytes, 1
101
+ end
102
+ add_message "cache_client._SetFetchResponse" do
103
+ oneof :set do
104
+ optional :found, :message, 1, "cache_client._SetFetchResponse._Found"
105
+ optional :missing, :message, 2, "cache_client._SetFetchResponse._Missing"
106
+ end
107
+ end
108
+ add_message "cache_client._SetFetchResponse._Found" do
109
+ repeated :elements, :bytes, 1
110
+ end
111
+ add_message "cache_client._SetFetchResponse._Missing" do
112
+ end
113
+ add_message "cache_client._SetUnionRequest" do
114
+ optional :set_name, :bytes, 1
115
+ repeated :elements, :bytes, 2
116
+ optional :ttl_milliseconds, :uint64, 3
117
+ optional :refresh_ttl, :bool, 4
118
+ end
119
+ add_message "cache_client._SetUnionResponse" do
120
+ end
121
+ add_message "cache_client._SetDifferenceRequest" do
122
+ optional :set_name, :bytes, 1
123
+ oneof :difference do
124
+ optional :minuend, :message, 2, "cache_client._SetDifferenceRequest._Minuend"
125
+ optional :subtrahend, :message, 3, "cache_client._SetDifferenceRequest._Subtrahend"
126
+ end
127
+ end
128
+ add_message "cache_client._SetDifferenceRequest._Minuend" do
129
+ repeated :elements, :bytes, 1
130
+ end
131
+ add_message "cache_client._SetDifferenceRequest._Subtrahend" do
132
+ oneof :subtrahend_set do
133
+ optional :set, :message, 1, "cache_client._SetDifferenceRequest._Subtrahend._Set"
134
+ optional :identity, :message, 2, "cache_client._SetDifferenceRequest._Subtrahend._Identity"
135
+ end
136
+ end
137
+ add_message "cache_client._SetDifferenceRequest._Subtrahend._Set" do
138
+ repeated :elements, :bytes, 1
139
+ end
140
+ add_message "cache_client._SetDifferenceRequest._Subtrahend._Identity" do
141
+ end
142
+ add_message "cache_client._SetDifferenceResponse" do
143
+ oneof :set do
144
+ optional :found, :message, 1, "cache_client._SetDifferenceResponse._Found"
145
+ optional :missing, :message, 2, "cache_client._SetDifferenceResponse._Missing"
146
+ end
147
+ end
148
+ add_message "cache_client._SetDifferenceResponse._Found" do
149
+ end
150
+ add_message "cache_client._SetDifferenceResponse._Missing" do
151
+ end
152
+ add_message "cache_client._ListPushFrontRequest" do
153
+ optional :list_name, :bytes, 1
154
+ optional :value, :bytes, 2
155
+ optional :ttl_milliseconds, :uint64, 3
156
+ optional :refresh_ttl, :bool, 4
157
+ proto3_optional :truncate_back_to_size, :uint32, 5
158
+ end
159
+ add_message "cache_client._ListPushFrontResponse" do
160
+ optional :list_length, :uint32, 1
161
+ end
162
+ add_message "cache_client._ListPushBackRequest" do
163
+ optional :list_name, :bytes, 1
164
+ optional :value, :bytes, 2
165
+ optional :ttl_milliseconds, :uint64, 3
166
+ optional :refresh_ttl, :bool, 4
167
+ proto3_optional :truncate_front_to_size, :uint32, 5
168
+ end
169
+ add_message "cache_client._ListPushBackResponse" do
170
+ optional :list_length, :uint32, 1
171
+ end
172
+ add_message "cache_client._ListPopFrontRequest" do
173
+ optional :list_name, :bytes, 1
174
+ end
175
+ add_message "cache_client._ListPopFrontResponse" do
176
+ oneof :list do
177
+ optional :found, :message, 1, "cache_client._ListPopFrontResponse._Found"
178
+ optional :missing, :message, 2, "cache_client._ListPopFrontResponse._Missing"
179
+ end
180
+ end
181
+ add_message "cache_client._ListPopFrontResponse._Found" do
182
+ optional :front, :bytes, 1
183
+ end
184
+ add_message "cache_client._ListPopFrontResponse._Missing" do
185
+ end
186
+ add_message "cache_client._ListPopBackRequest" do
187
+ optional :list_name, :bytes, 1
188
+ end
189
+ add_message "cache_client._ListPopBackResponse" do
190
+ oneof :list do
191
+ optional :found, :message, 1, "cache_client._ListPopBackResponse._Found"
192
+ optional :missing, :message, 2, "cache_client._ListPopBackResponse._Missing"
193
+ end
194
+ end
195
+ add_message "cache_client._ListPopBackResponse._Found" do
196
+ optional :back, :bytes, 1
197
+ end
198
+ add_message "cache_client._ListPopBackResponse._Missing" do
199
+ end
200
+ add_message "cache_client._ListRange" do
201
+ optional :begin_index, :uint32, 1
202
+ optional :count, :uint32, 2
203
+ end
204
+ add_message "cache_client._ListEraseRequest" do
205
+ optional :list_name, :bytes, 1
206
+ oneof :erase do
207
+ optional :some, :message, 2, "cache_client._ListEraseRequest._ListRanges"
208
+ optional :all, :message, 3, "cache_client._ListEraseRequest._All"
209
+ end
210
+ end
211
+ add_message "cache_client._ListEraseRequest._All" do
212
+ end
213
+ add_message "cache_client._ListEraseRequest._ListRanges" do
214
+ repeated :ranges, :message, 1, "cache_client._ListRange"
215
+ end
216
+ add_message "cache_client._ListEraseResponse" do
217
+ end
218
+ add_message "cache_client._ListRemoveRequest" do
219
+ optional :list_name, :bytes, 1
220
+ oneof :remove do
221
+ optional :all_elements_with_value, :bytes, 2
222
+ end
223
+ end
224
+ add_message "cache_client._ListRemoveResponse" do
225
+ end
226
+ add_message "cache_client._ListFetchRequest" do
227
+ optional :list_name, :bytes, 1
228
+ end
229
+ add_message "cache_client._ListFetchResponse" do
230
+ oneof :list do
231
+ optional :found, :message, 1, "cache_client._ListFetchResponse._Found"
232
+ optional :missing, :message, 2, "cache_client._ListFetchResponse._Missing"
233
+ end
234
+ end
235
+ add_message "cache_client._ListFetchResponse._Found" do
236
+ repeated :values, :bytes, 1
237
+ end
238
+ add_message "cache_client._ListFetchResponse._Missing" do
239
+ end
240
+ add_message "cache_client._ListLengthRequest" do
241
+ optional :list_name, :bytes, 1
242
+ end
243
+ add_message "cache_client._ListLengthResponse" do
244
+ oneof :list do
245
+ optional :found, :message, 1, "cache_client._ListLengthResponse._Found"
246
+ optional :missing, :message, 2, "cache_client._ListLengthResponse._Missing"
247
+ end
248
+ end
249
+ add_message "cache_client._ListLengthResponse._Found" do
250
+ optional :length, :uint32, 1
251
+ end
252
+ add_message "cache_client._ListLengthResponse._Missing" do
253
+ end
254
+ add_enum "cache_client.ECacheResult" do
255
+ value :Invalid, 0
256
+ value :Ok, 1
257
+ value :Hit, 2
258
+ value :Miss, 3
259
+ end
260
+ end
261
+ end
262
+
263
+ module Momento
264
+ module CacheClient
265
+ GetRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._GetRequest").msgclass
266
+ GetResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._GetResponse").msgclass
267
+ DeleteRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._DeleteRequest").msgclass
268
+ DeleteResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._DeleteResponse").msgclass
269
+ SetRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._SetRequest").msgclass
270
+ SetResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._SetResponse").msgclass
271
+ DictionaryGetRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._DictionaryGetRequest").msgclass
272
+ DictionaryGetResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._DictionaryGetResponse").msgclass
273
+ DictionaryGetResponse::DictionaryGetResponsePart = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._DictionaryGetResponse._DictionaryGetResponsePart").msgclass
274
+ DictionaryGetResponse::Found = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._DictionaryGetResponse._Found").msgclass
275
+ DictionaryGetResponse::Missing = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._DictionaryGetResponse._Missing").msgclass
276
+ DictionaryFetchRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._DictionaryFetchRequest").msgclass
277
+ DictionaryFieldValuePair = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._DictionaryFieldValuePair").msgclass
278
+ DictionaryFetchResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._DictionaryFetchResponse").msgclass
279
+ DictionaryFetchResponse::Found = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._DictionaryFetchResponse._Found").msgclass
280
+ DictionaryFetchResponse::Missing = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._DictionaryFetchResponse._Missing").msgclass
281
+ DictionarySetRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._DictionarySetRequest").msgclass
282
+ DictionarySetResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._DictionarySetResponse").msgclass
283
+ DictionaryIncrementRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._DictionaryIncrementRequest").msgclass
284
+ DictionaryIncrementResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._DictionaryIncrementResponse").msgclass
285
+ DictionaryDeleteRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._DictionaryDeleteRequest").msgclass
286
+ DictionaryDeleteRequest::Some = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._DictionaryDeleteRequest.Some").msgclass
287
+ DictionaryDeleteRequest::All = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._DictionaryDeleteRequest.All").msgclass
288
+ DictionaryDeleteResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._DictionaryDeleteResponse").msgclass
289
+ SetFetchRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._SetFetchRequest").msgclass
290
+ SetFetchResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._SetFetchResponse").msgclass
291
+ SetFetchResponse::Found = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._SetFetchResponse._Found").msgclass
292
+ SetFetchResponse::Missing = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._SetFetchResponse._Missing").msgclass
293
+ SetUnionRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._SetUnionRequest").msgclass
294
+ SetUnionResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._SetUnionResponse").msgclass
295
+ SetDifferenceRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._SetDifferenceRequest").msgclass
296
+ SetDifferenceRequest::Minuend = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._SetDifferenceRequest._Minuend").msgclass
297
+ SetDifferenceRequest::Subtrahend = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._SetDifferenceRequest._Subtrahend").msgclass
298
+ SetDifferenceRequest::Subtrahend::Set = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._SetDifferenceRequest._Subtrahend._Set").msgclass
299
+ SetDifferenceRequest::Subtrahend::Identity = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._SetDifferenceRequest._Subtrahend._Identity").msgclass
300
+ SetDifferenceResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._SetDifferenceResponse").msgclass
301
+ SetDifferenceResponse::Found = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._SetDifferenceResponse._Found").msgclass
302
+ SetDifferenceResponse::Missing = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._SetDifferenceResponse._Missing").msgclass
303
+ ListPushFrontRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListPushFrontRequest").msgclass
304
+ ListPushFrontResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListPushFrontResponse").msgclass
305
+ ListPushBackRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListPushBackRequest").msgclass
306
+ ListPushBackResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListPushBackResponse").msgclass
307
+ ListPopFrontRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListPopFrontRequest").msgclass
308
+ ListPopFrontResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListPopFrontResponse").msgclass
309
+ ListPopFrontResponse::Found = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListPopFrontResponse._Found").msgclass
310
+ ListPopFrontResponse::Missing = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListPopFrontResponse._Missing").msgclass
311
+ ListPopBackRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListPopBackRequest").msgclass
312
+ ListPopBackResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListPopBackResponse").msgclass
313
+ ListPopBackResponse::Found = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListPopBackResponse._Found").msgclass
314
+ ListPopBackResponse::Missing = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListPopBackResponse._Missing").msgclass
315
+ ListRange = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListRange").msgclass
316
+ ListEraseRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListEraseRequest").msgclass
317
+ ListEraseRequest::All = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListEraseRequest._All").msgclass
318
+ ListEraseRequest::ListRanges = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListEraseRequest._ListRanges").msgclass
319
+ ListEraseResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListEraseResponse").msgclass
320
+ ListRemoveRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListRemoveRequest").msgclass
321
+ ListRemoveResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListRemoveResponse").msgclass
322
+ ListFetchRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListFetchRequest").msgclass
323
+ ListFetchResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListFetchResponse").msgclass
324
+ ListFetchResponse::Found = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListFetchResponse._Found").msgclass
325
+ ListFetchResponse::Missing = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListFetchResponse._Missing").msgclass
326
+ ListLengthRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListLengthRequest").msgclass
327
+ ListLengthResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListLengthResponse").msgclass
328
+ ListLengthResponse::Found = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListLengthResponse._Found").msgclass
329
+ ListLengthResponse::Missing = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client._ListLengthResponse._Missing").msgclass
330
+ ECacheResult = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("cache_client.ECacheResult").enummodule
331
+ end
332
+ end
@@ -0,0 +1,42 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # Source: cacheclient.proto for package 'cache_client'
3
+
4
+ require 'grpc'
5
+ require_relative 'cacheclient_pb'
6
+
7
+ module Momento
8
+ module CacheClient
9
+ module Scs
10
+ class Service
11
+
12
+ include ::GRPC::GenericService
13
+
14
+ self.marshal_class_method = :encode
15
+ self.unmarshal_class_method = :decode
16
+ self.service_name = 'cache_client.Scs'
17
+
18
+ rpc :Get, ::Momento::CacheClient::GetRequest, ::Momento::CacheClient::GetResponse
19
+ rpc :Set, ::Momento::CacheClient::SetRequest, ::Momento::CacheClient::SetResponse
20
+ rpc :Delete, ::Momento::CacheClient::DeleteRequest, ::Momento::CacheClient::DeleteResponse
21
+ rpc :DictionaryGet, ::Momento::CacheClient::DictionaryGetRequest, ::Momento::CacheClient::DictionaryGetResponse
22
+ rpc :DictionaryFetch, ::Momento::CacheClient::DictionaryFetchRequest, ::Momento::CacheClient::DictionaryFetchResponse
23
+ rpc :DictionarySet, ::Momento::CacheClient::DictionarySetRequest, ::Momento::CacheClient::DictionarySetResponse
24
+ rpc :DictionaryIncrement, ::Momento::CacheClient::DictionaryIncrementRequest, ::Momento::CacheClient::DictionaryIncrementResponse
25
+ rpc :DictionaryDelete, ::Momento::CacheClient::DictionaryDeleteRequest, ::Momento::CacheClient::DictionaryDeleteResponse
26
+ rpc :SetFetch, ::Momento::CacheClient::SetFetchRequest, ::Momento::CacheClient::SetFetchResponse
27
+ rpc :SetUnion, ::Momento::CacheClient::SetUnionRequest, ::Momento::CacheClient::SetUnionResponse
28
+ rpc :SetDifference, ::Momento::CacheClient::SetDifferenceRequest, ::Momento::CacheClient::SetDifferenceResponse
29
+ rpc :ListPushFront, ::Momento::CacheClient::ListPushFrontRequest, ::Momento::CacheClient::ListPushFrontResponse
30
+ rpc :ListPushBack, ::Momento::CacheClient::ListPushBackRequest, ::Momento::CacheClient::ListPushBackResponse
31
+ rpc :ListPopFront, ::Momento::CacheClient::ListPopFrontRequest, ::Momento::CacheClient::ListPopFrontResponse
32
+ rpc :ListPopBack, ::Momento::CacheClient::ListPopBackRequest, ::Momento::CacheClient::ListPopBackResponse
33
+ rpc :ListErase, ::Momento::CacheClient::ListEraseRequest, ::Momento::CacheClient::ListEraseResponse
34
+ rpc :ListRemove, ::Momento::CacheClient::ListRemoveRequest, ::Momento::CacheClient::ListRemoveResponse
35
+ rpc :ListFetch, ::Momento::CacheClient::ListFetchRequest, ::Momento::CacheClient::ListFetchResponse
36
+ rpc :ListLength, ::Momento::CacheClient::ListLengthRequest, ::Momento::CacheClient::ListLengthResponse
37
+ end
38
+
39
+ Stub = Service.rpc_stub_class
40
+ end
41
+ end
42
+ end
@@ -0,0 +1,71 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # source: controlclient.proto
3
+
4
+ require 'google/protobuf'
5
+
6
+ Google::Protobuf::DescriptorPool.generated_pool.build do
7
+ add_file("controlclient.proto", :syntax => :proto3) do
8
+ add_message "control_client._DeleteCacheRequest" do
9
+ optional :cache_name, :string, 1
10
+ end
11
+ add_message "control_client._DeleteCacheResponse" do
12
+ end
13
+ add_message "control_client._CreateCacheRequest" do
14
+ optional :cache_name, :string, 1
15
+ end
16
+ add_message "control_client._CreateCacheResponse" do
17
+ end
18
+ add_message "control_client._ListCachesRequest" do
19
+ optional :next_token, :string, 1
20
+ end
21
+ add_message "control_client._Cache" do
22
+ optional :cache_name, :string, 1
23
+ end
24
+ add_message "control_client._ListCachesResponse" do
25
+ repeated :cache, :message, 1, "control_client._Cache"
26
+ optional :next_token, :string, 2
27
+ end
28
+ add_message "control_client._CreateSigningKeyRequest" do
29
+ optional :ttl_minutes, :uint32, 1
30
+ end
31
+ add_message "control_client._CreateSigningKeyResponse" do
32
+ optional :key, :string, 1
33
+ optional :expires_at, :uint64, 2
34
+ end
35
+ add_message "control_client._RevokeSigningKeyRequest" do
36
+ optional :key_id, :string, 1
37
+ end
38
+ add_message "control_client._RevokeSigningKeyResponse" do
39
+ end
40
+ add_message "control_client._SigningKey" do
41
+ optional :key_id, :string, 1
42
+ optional :expires_at, :uint64, 2
43
+ end
44
+ add_message "control_client._ListSigningKeysRequest" do
45
+ optional :next_token, :string, 1
46
+ end
47
+ add_message "control_client._ListSigningKeysResponse" do
48
+ repeated :signing_key, :message, 1, "control_client._SigningKey"
49
+ optional :next_token, :string, 2
50
+ end
51
+ end
52
+ end
53
+
54
+ module Momento
55
+ module ControlClient
56
+ DeleteCacheRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("control_client._DeleteCacheRequest").msgclass
57
+ DeleteCacheResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("control_client._DeleteCacheResponse").msgclass
58
+ CreateCacheRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("control_client._CreateCacheRequest").msgclass
59
+ CreateCacheResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("control_client._CreateCacheResponse").msgclass
60
+ ListCachesRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("control_client._ListCachesRequest").msgclass
61
+ Cache = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("control_client._Cache").msgclass
62
+ ListCachesResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("control_client._ListCachesResponse").msgclass
63
+ CreateSigningKeyRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("control_client._CreateSigningKeyRequest").msgclass
64
+ CreateSigningKeyResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("control_client._CreateSigningKeyResponse").msgclass
65
+ RevokeSigningKeyRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("control_client._RevokeSigningKeyRequest").msgclass
66
+ RevokeSigningKeyResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("control_client._RevokeSigningKeyResponse").msgclass
67
+ SigningKey = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("control_client._SigningKey").msgclass
68
+ ListSigningKeysRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("control_client._ListSigningKeysRequest").msgclass
69
+ ListSigningKeysResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("control_client._ListSigningKeysResponse").msgclass
70
+ end
71
+ end
@@ -0,0 +1,29 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # Source: controlclient.proto for package 'control_client'
3
+
4
+ require 'grpc'
5
+ require_relative 'controlclient_pb'
6
+
7
+ module Momento
8
+ module ControlClient
9
+ module ScsControl
10
+ class Service
11
+
12
+ include ::GRPC::GenericService
13
+
14
+ self.marshal_class_method = :encode
15
+ self.unmarshal_class_method = :decode
16
+ self.service_name = 'control_client.ScsControl'
17
+
18
+ rpc :CreateCache, ::Momento::ControlClient::CreateCacheRequest, ::Momento::ControlClient::CreateCacheResponse
19
+ rpc :DeleteCache, ::Momento::ControlClient::DeleteCacheRequest, ::Momento::ControlClient::DeleteCacheResponse
20
+ rpc :ListCaches, ::Momento::ControlClient::ListCachesRequest, ::Momento::ControlClient::ListCachesResponse
21
+ rpc :CreateSigningKey, ::Momento::ControlClient::CreateSigningKeyRequest, ::Momento::ControlClient::CreateSigningKeyResponse
22
+ rpc :RevokeSigningKey, ::Momento::ControlClient::RevokeSigningKeyRequest, ::Momento::ControlClient::RevokeSigningKeyResponse
23
+ rpc :ListSigningKeys, ::Momento::ControlClient::ListSigningKeysRequest, ::Momento::ControlClient::ListSigningKeysResponse
24
+ end
25
+
26
+ Stub = Service.rpc_stub_class
27
+ end
28
+ end
29
+ end
@@ -0,0 +1,52 @@
1
+ require 'grpc'
2
+ require 'momento/controlclient_pb'
3
+
4
+ module Momento
5
+ # Responses specific to create_cache.
6
+ class CreateCacheResponse < Response
7
+ # Build a Momento::CreateCacheResponse from a block of code
8
+ # which returns a Momento::ControlClient::CreateCacheResponse.
9
+ #
10
+ # @return [Momento::CreateCacheResponse]
11
+ # @raise [StandardError] when the exception is not recognized.
12
+ # @raise [TypeError] when the response is not recognized.
13
+ def self.from_block
14
+ response = yield
15
+ rescue GRPC::AlreadyExists
16
+ return AlreadyExists.new
17
+ rescue GRPC::BadStatus => e
18
+ Error.new(grpc_exception: e)
19
+ else
20
+ raise TypeError unless response.is_a?(Momento::ControlClient::CreateCacheResponse)
21
+
22
+ return Success.new
23
+ end
24
+
25
+ def already_exists?
26
+ false
27
+ end
28
+
29
+ def success?
30
+ false
31
+ end
32
+
33
+ # A cache with that name already exists.
34
+ class AlreadyExists < CreateCacheResponse
35
+ def already_exists?
36
+ true
37
+ end
38
+ end
39
+
40
+ # The cache was created.
41
+ class Success < CreateCacheResponse
42
+ def success?
43
+ true
44
+ end
45
+ end
46
+
47
+ # There was an error creating the cache.
48
+ class Error < CreateCacheResponse
49
+ include ::Momento::Response::Error
50
+ end
51
+ end
52
+ end
@@ -0,0 +1,39 @@
1
+ require 'grpc'
2
+ require 'momento/controlclient_pb'
3
+
4
+ module Momento
5
+ # Responses specific to delete_cache
6
+ class DeleteCacheResponse < Response
7
+ # Build a Momento::DeleteCacheResponse from a block of code
8
+ # which returns a Momento::ControlClient::DeleteCacheResponse..
9
+ #
10
+ # @return [Momento::DeleteCacheResponse]
11
+ # @raise [StandardError] when the exception is not recognized.
12
+ # @raise [TypeError] when the response is not recognized.
13
+ def self.from_block
14
+ response = yield
15
+ rescue GRPC::BadStatus => e
16
+ Error.new(grpc_exception: e)
17
+ else
18
+ raise TypeError unless response.is_a?(Momento::ControlClient::DeleteCacheResponse)
19
+
20
+ return Success.new
21
+ end
22
+
23
+ def success?
24
+ false
25
+ end
26
+
27
+ # There was an error deleting the cache.
28
+ class Error < DeleteCacheResponse
29
+ include ::Momento::Response::Error
30
+ end
31
+
32
+ # The cache was deleted.
33
+ class Success < DeleteCacheResponse
34
+ def success?
35
+ true
36
+ end
37
+ end
38
+ end
39
+ end
@@ -0,0 +1,33 @@
1
+ require 'grpc'
2
+ require 'momento/cacheclient_pb'
3
+
4
+ module Momento
5
+ # Responses specific to delete.
6
+ class DeleteResponse < Response
7
+ def self.from_block
8
+ response = yield
9
+ rescue GRPC::BadStatus => e
10
+ Error.new(grpc_exception: e)
11
+ else
12
+ raise TypeError unless response.is_a?(Momento::CacheClient::DeleteResponse)
13
+
14
+ Success.new
15
+ end
16
+
17
+ def success?
18
+ false
19
+ end
20
+
21
+ # The item was deleted from the cache.
22
+ class Success < DeleteResponse
23
+ def success?
24
+ true
25
+ end
26
+ end
27
+
28
+ # There was an error deleting the item from the cache.
29
+ class Error < DeleteResponse
30
+ include Momento::Response::Error
31
+ end
32
+ end
33
+ end