diff options
author | Christian Grothoff <christian@grothoff.org> | 2016-06-24 20:17:39 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2016-06-24 20:17:39 +0000 |
commit | 3140154d46212e08e0d73ed891a66213a6813075 (patch) | |
tree | 018a55a3899207664b388fcf47a679ca54ca6fbf /src/include/gnunet_datastore_service.h | |
parent | d5fd881c2a044474b54ddf03b6ab8be8d2b75927 (diff) | |
download | gnunet-3140154d46212e08e0d73ed891a66213a6813075.tar.gz gnunet-3140154d46212e08e0d73ed891a66213a6813075.zip |
refactoring datastore API to use MQ API, also fixing misc. bugs in new mysql backend
Diffstat (limited to 'src/include/gnunet_datastore_service.h')
-rw-r--r-- | src/include/gnunet_datastore_service.h | 16 |
1 files changed, 1 insertions, 15 deletions
diff --git a/src/include/gnunet_datastore_service.h b/src/include/gnunet_datastore_service.h index e4b445bbb..f594d8fa6 100644 --- a/src/include/gnunet_datastore_service.h +++ b/src/include/gnunet_datastore_service.h | |||
@@ -92,7 +92,7 @@ GNUNET_DATASTORE_disconnect (struct GNUNET_DATASTORE_Handle *h, | |||
92 | * operation. | 92 | * operation. |
93 | * | 93 | * |
94 | * @param cls closure | 94 | * @param cls closure |
95 | * @param success #GNUNET_SYSERR on failure (including timeout/queue drop) | 95 | * @param success #GNUNET_SYSERR on failure |
96 | * #GNUNET_NO if content was already there | 96 | * #GNUNET_NO if content was already there |
97 | * #GNUNET_YES (or other positive value) on success | 97 | * #GNUNET_YES (or other positive value) on success |
98 | * @param min_expiration minimum expiration time required for 0-priority content to be stored | 98 | * @param min_expiration minimum expiration time required for 0-priority content to be stored |
@@ -149,7 +149,6 @@ GNUNET_DATASTORE_reserve (struct GNUNET_DATASTORE_Handle *h, | |||
149 | * @param queue_priority ranking of this request in the priority queue | 149 | * @param queue_priority ranking of this request in the priority queue |
150 | * @param max_queue_size at what queue size should this request be dropped | 150 | * @param max_queue_size at what queue size should this request be dropped |
151 | * (if other requests of higher priority are in the queue) | 151 | * (if other requests of higher priority are in the queue) |
152 | * @param timeout timeout for the operation | ||
153 | * @param cont continuation to call when done | 152 | * @param cont continuation to call when done |
154 | * @param cont_cls closure for @a cont | 153 | * @param cont_cls closure for @a cont |
155 | * @return NULL if the entry was not queued, otherwise a handle that can be used to | 154 | * @return NULL if the entry was not queued, otherwise a handle that can be used to |
@@ -169,7 +168,6 @@ GNUNET_DATASTORE_put (struct GNUNET_DATASTORE_Handle *h, | |||
169 | struct GNUNET_TIME_Absolute expiration, | 168 | struct GNUNET_TIME_Absolute expiration, |
170 | unsigned int queue_priority, | 169 | unsigned int queue_priority, |
171 | unsigned int max_queue_size, | 170 | unsigned int max_queue_size, |
172 | struct GNUNET_TIME_Relative timeout, | ||
173 | GNUNET_DATASTORE_ContinuationWithStatus cont, | 171 | GNUNET_DATASTORE_ContinuationWithStatus cont, |
174 | void *cont_cls); | 172 | void *cont_cls); |
175 | 173 | ||
@@ -188,7 +186,6 @@ GNUNET_DATASTORE_put (struct GNUNET_DATASTORE_Handle *h, | |||
188 | * @param queue_priority ranking of this request in the priority queue | 186 | * @param queue_priority ranking of this request in the priority queue |
189 | * @param max_queue_size at what queue size should this request be dropped | 187 | * @param max_queue_size at what queue size should this request be dropped |
190 | * (if other requests of higher priority are in the queue) | 188 | * (if other requests of higher priority are in the queue) |
191 | * @param timeout how long to wait at most for a response | ||
192 | * @param cont continuation to call when done | 189 | * @param cont continuation to call when done |
193 | * @param cont_cls closure for @a cont | 190 | * @param cont_cls closure for @a cont |
194 | * @return NULL if the entry was not queued, otherwise a handle that can be used to | 191 | * @return NULL if the entry was not queued, otherwise a handle that can be used to |
@@ -199,7 +196,6 @@ struct GNUNET_DATASTORE_QueueEntry * | |||
199 | GNUNET_DATASTORE_release_reserve (struct GNUNET_DATASTORE_Handle *h, | 196 | GNUNET_DATASTORE_release_reserve (struct GNUNET_DATASTORE_Handle *h, |
200 | uint32_t rid, unsigned int queue_priority, | 197 | uint32_t rid, unsigned int queue_priority, |
201 | unsigned int max_queue_size, | 198 | unsigned int max_queue_size, |
202 | struct GNUNET_TIME_Relative timeout, | ||
203 | GNUNET_DATASTORE_ContinuationWithStatus cont, | 199 | GNUNET_DATASTORE_ContinuationWithStatus cont, |
204 | void *cont_cls); | 200 | void *cont_cls); |
205 | 201 | ||
@@ -214,7 +210,6 @@ GNUNET_DATASTORE_release_reserve (struct GNUNET_DATASTORE_Handle *h, | |||
214 | * @param queue_priority ranking of this request in the priority queue | 210 | * @param queue_priority ranking of this request in the priority queue |
215 | * @param max_queue_size at what queue size should this request be dropped | 211 | * @param max_queue_size at what queue size should this request be dropped |
216 | * (if other requests of higher priority are in the queue) | 212 | * (if other requests of higher priority are in the queue) |
217 | * @param timeout how long to wait at most for a response | ||
218 | * @param cont continuation to call when done | 213 | * @param cont continuation to call when done |
219 | * @param cont_cls closure for @a cont | 214 | * @param cont_cls closure for @a cont |
220 | * @return NULL if the entry was not queued, otherwise a handle that can be used to | 215 | * @return NULL if the entry was not queued, otherwise a handle that can be used to |
@@ -228,7 +223,6 @@ GNUNET_DATASTORE_update (struct GNUNET_DATASTORE_Handle *h, | |||
228 | struct GNUNET_TIME_Absolute expiration, | 223 | struct GNUNET_TIME_Absolute expiration, |
229 | unsigned int queue_priority, | 224 | unsigned int queue_priority, |
230 | unsigned int max_queue_size, | 225 | unsigned int max_queue_size, |
231 | struct GNUNET_TIME_Relative timeout, | ||
232 | GNUNET_DATASTORE_ContinuationWithStatus cont, | 226 | GNUNET_DATASTORE_ContinuationWithStatus cont, |
233 | void *cont_cls); | 227 | void *cont_cls); |
234 | 228 | ||
@@ -246,7 +240,6 @@ GNUNET_DATASTORE_update (struct GNUNET_DATASTORE_Handle *h, | |||
246 | * @param queue_priority ranking of this request in the priority queue | 240 | * @param queue_priority ranking of this request in the priority queue |
247 | * @param max_queue_size at what queue size should this request be dropped | 241 | * @param max_queue_size at what queue size should this request be dropped |
248 | * (if other requests of higher priority are in the queue) | 242 | * (if other requests of higher priority are in the queue) |
249 | * @param timeout how long to wait at most for a response | ||
250 | * @param cont continuation to call when done | 243 | * @param cont continuation to call when done |
251 | * @param cont_cls closure for @a cont | 244 | * @param cont_cls closure for @a cont |
252 | * @return NULL if the entry was not queued, otherwise a handle that can be used to | 245 | * @return NULL if the entry was not queued, otherwise a handle that can be used to |
@@ -260,7 +253,6 @@ GNUNET_DATASTORE_remove (struct GNUNET_DATASTORE_Handle *h, | |||
260 | const void *data, | 253 | const void *data, |
261 | unsigned int queue_priority, | 254 | unsigned int queue_priority, |
262 | unsigned int max_queue_size, | 255 | unsigned int max_queue_size, |
263 | struct GNUNET_TIME_Relative timeout, | ||
264 | GNUNET_DATASTORE_ContinuationWithStatus cont, | 256 | GNUNET_DATASTORE_ContinuationWithStatus cont, |
265 | void *cont_cls); | 257 | void *cont_cls); |
266 | 258 | ||
@@ -305,7 +297,6 @@ typedef void | |||
305 | * @param queue_priority ranking of this request in the priority queue | 297 | * @param queue_priority ranking of this request in the priority queue |
306 | * @param max_queue_size at what queue size should this request be dropped | 298 | * @param max_queue_size at what queue size should this request be dropped |
307 | * (if other requests of higher priority are in the queue) | 299 | * (if other requests of higher priority are in the queue) |
308 | * @param timeout how long to wait at most for a response | ||
309 | * @param proc function to call on a matching value; | 300 | * @param proc function to call on a matching value; |
310 | * or with a NULL value if no datum matches | 301 | * or with a NULL value if no datum matches |
311 | * @param proc_cls closure for @a proc | 302 | * @param proc_cls closure for @a proc |
@@ -319,7 +310,6 @@ GNUNET_DATASTORE_get_key (struct GNUNET_DATASTORE_Handle *h, | |||
319 | enum GNUNET_BLOCK_Type type, | 310 | enum GNUNET_BLOCK_Type type, |
320 | unsigned int queue_priority, | 311 | unsigned int queue_priority, |
321 | unsigned int max_queue_size, | 312 | unsigned int max_queue_size, |
322 | struct GNUNET_TIME_Relative timeout, | ||
323 | GNUNET_DATASTORE_DatumProcessor proc, | 313 | GNUNET_DATASTORE_DatumProcessor proc, |
324 | void *proc_cls); | 314 | void *proc_cls); |
325 | 315 | ||
@@ -339,7 +329,6 @@ GNUNET_DATASTORE_get_key (struct GNUNET_DATASTORE_Handle *h, | |||
339 | * @param queue_priority ranking of this request in the priority queue | 329 | * @param queue_priority ranking of this request in the priority queue |
340 | * @param max_queue_size at what queue size should this request be dropped | 330 | * @param max_queue_size at what queue size should this request be dropped |
341 | * (if other requests of higher priority are in the queue) | 331 | * (if other requests of higher priority are in the queue) |
342 | * @param timeout how long to wait at most for a response | ||
343 | * @param type allowed type for the operation (never zero) | 332 | * @param type allowed type for the operation (never zero) |
344 | * @param proc function to call on a random value; it | 333 | * @param proc function to call on a random value; it |
345 | * will be called once with a value (if available) | 334 | * will be called once with a value (if available) |
@@ -353,7 +342,6 @@ GNUNET_DATASTORE_get_zero_anonymity (struct GNUNET_DATASTORE_Handle *h, | |||
353 | uint64_t offset, | 342 | uint64_t offset, |
354 | unsigned int queue_priority, | 343 | unsigned int queue_priority, |
355 | unsigned int max_queue_size, | 344 | unsigned int max_queue_size, |
356 | struct GNUNET_TIME_Relative timeout, | ||
357 | enum GNUNET_BLOCK_Type type, | 345 | enum GNUNET_BLOCK_Type type, |
358 | GNUNET_DATASTORE_DatumProcessor proc, | 346 | GNUNET_DATASTORE_DatumProcessor proc, |
359 | void *proc_cls); | 347 | void *proc_cls); |
@@ -370,7 +358,6 @@ GNUNET_DATASTORE_get_zero_anonymity (struct GNUNET_DATASTORE_Handle *h, | |||
370 | * @param queue_priority ranking of this request in the priority queue | 358 | * @param queue_priority ranking of this request in the priority queue |
371 | * @param max_queue_size at what queue size should this request be dropped | 359 | * @param max_queue_size at what queue size should this request be dropped |
372 | * (if other requests of higher priority are in the queue) | 360 | * (if other requests of higher priority are in the queue) |
373 | * @param timeout how long to wait at most for a response | ||
374 | * @param proc function to call on a random value; it | 361 | * @param proc function to call on a random value; it |
375 | * will be called once with a value (if available) | 362 | * will be called once with a value (if available) |
376 | * and always once with a value of NULL. | 363 | * and always once with a value of NULL. |
@@ -382,7 +369,6 @@ struct GNUNET_DATASTORE_QueueEntry * | |||
382 | GNUNET_DATASTORE_get_for_replication (struct GNUNET_DATASTORE_Handle *h, | 369 | GNUNET_DATASTORE_get_for_replication (struct GNUNET_DATASTORE_Handle *h, |
383 | unsigned int queue_priority, | 370 | unsigned int queue_priority, |
384 | unsigned int max_queue_size, | 371 | unsigned int max_queue_size, |
385 | struct GNUNET_TIME_Relative timeout, | ||
386 | GNUNET_DATASTORE_DatumProcessor proc, | 372 | GNUNET_DATASTORE_DatumProcessor proc, |
387 | void *proc_cls); | 373 | void *proc_cls); |
388 | 374 | ||