summaryrefslogtreecommitdiff
path: root/src/datastore/perf_datastore_api.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2009-11-04 14:10:32 +0000
committerChristian Grothoff <christian@grothoff.org>2009-11-04 14:10:32 +0000
commitcf45b8dff29c366d51aa2e6ea6a64b99b514b9c9 (patch)
tree5cb37c041743daff5af528dbbe24f5c563ce702e /src/datastore/perf_datastore_api.c
parentb91546a3de767292e6472c6b1927480adba43d88 (diff)
downloadgnunet-cf45b8dff29c366d51aa2e6ea6a64b99b514b9c9.tar.gz
gnunet-cf45b8dff29c366d51aa2e6ea6a64b99b514b9c9.zip
bugfixes and redesigning scheduler API
Diffstat (limited to 'src/datastore/perf_datastore_api.c')
-rw-r--r--src/datastore/perf_datastore_api.c16
1 files changed, 4 insertions, 12 deletions
diff --git a/src/datastore/perf_datastore_api.c b/src/datastore/perf_datastore_api.c
index 2344dafe8..34adf0c7d 100644
--- a/src/datastore/perf_datastore_api.c
+++ b/src/datastore/perf_datastore_api.c
@@ -140,7 +140,6 @@ check_success (void *cls,
140 crc->phase = RP_CUT; 140 crc->phase = RP_CUT;
141 } 141 }
142 GNUNET_SCHEDULER_add_continuation (crc->sched, 142 GNUNET_SCHEDULER_add_continuation (crc->sched,
143 GNUNET_NO,
144 &run_continuation, 143 &run_continuation,
145 crc, 144 crc,
146 GNUNET_SCHEDULER_REASON_PREREQ_DONE); 145 GNUNET_SCHEDULER_REASON_PREREQ_DONE);
@@ -167,7 +166,6 @@ remove_next(void *cls,
167#endif 166#endif
168 GNUNET_assert (GNUNET_OK == success); 167 GNUNET_assert (GNUNET_OK == success);
169 GNUNET_SCHEDULER_add_continuation (crc->sched, 168 GNUNET_SCHEDULER_add_continuation (crc->sched,
170 GNUNET_NO,
171 &run_continuation, 169 &run_continuation,
172 crc, 170 crc,
173 GNUNET_SCHEDULER_REASON_PREREQ_DONE); 171 GNUNET_SCHEDULER_REASON_PREREQ_DONE);
@@ -214,18 +212,15 @@ delete_value (void *cls,
214 { 212 {
215 crc->phase = RP_REPORT; 213 crc->phase = RP_REPORT;
216 GNUNET_SCHEDULER_add_continuation (crc->sched, 214 GNUNET_SCHEDULER_add_continuation (crc->sched,
217 GNUNET_NO,
218 &run_continuation, 215 &run_continuation,
219 crc, 216 crc,
220 GNUNET_SCHEDULER_REASON_PREREQ_DONE); 217 GNUNET_SCHEDULER_REASON_PREREQ_DONE);
221 return; 218 return;
222 } 219 }
223 GNUNET_SCHEDULER_add_after (crc->sched, 220 GNUNET_SCHEDULER_add_with_priority (crc->sched,
224 GNUNET_NO, 221 GNUNET_SCHEDULER_PRIORITY_HIGH,
225 GNUNET_SCHEDULER_PRIORITY_HIGH, 222 &do_delete,
226 GNUNET_SCHEDULER_NO_TASK, 223 crc);
227 &do_delete,
228 crc);
229 return; 224 return;
230 } 225 }
231 stored_ops++; 226 stored_ops++;
@@ -303,7 +298,6 @@ run_continuation (void *cls,
303 crc->phase = RP_PUT; 298 crc->phase = RP_PUT;
304 crc->j = 0; 299 crc->j = 0;
305 GNUNET_SCHEDULER_add_continuation (crc->sched, 300 GNUNET_SCHEDULER_add_continuation (crc->sched,
306 GNUNET_NO,
307 &run_continuation, 301 &run_continuation,
308 crc, 302 crc,
309 GNUNET_SCHEDULER_REASON_PREREQ_DONE); 303 GNUNET_SCHEDULER_REASON_PREREQ_DONE);
@@ -335,7 +329,6 @@ run (void *cls,
335 crc->cfg = cfg; 329 crc->cfg = cfg;
336 crc->phase = RP_PUT; 330 crc->phase = RP_PUT;
337 GNUNET_SCHEDULER_add_continuation (crc->sched, 331 GNUNET_SCHEDULER_add_continuation (crc->sched,
338 GNUNET_NO,
339 &run_continuation, 332 &run_continuation,
340 crc, 333 crc,
341 GNUNET_SCHEDULER_REASON_PREREQ_DONE); 334 GNUNET_SCHEDULER_REASON_PREREQ_DONE);
@@ -364,7 +357,6 @@ check ()
364 "-L", "DEBUG", 357 "-L", "DEBUG",
365#endif 358#endif
366 "-c", "test_datastore_api_data.conf", NULL); 359 "-c", "test_datastore_api_data.conf", NULL);
367 sleep (1);
368 GNUNET_PROGRAM_run ((sizeof (argv) / sizeof (char *)) - 1, 360 GNUNET_PROGRAM_run ((sizeof (argv) / sizeof (char *)) - 1,
369 argv, "perf-datastore-api", "nohelp", 361 argv, "perf-datastore-api", "nohelp",
370 options, &run, NULL); 362 options, &run, NULL);