summaryrefslogtreecommitdiff
path: root/src/testing/testing_api_cmd_merchant_get_order.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2021-08-25 17:23:35 +0200
committerChristian Grothoff <christian@grothoff.org>2021-08-25 17:23:35 +0200
commit696278ce80c7613e39c24e138dd6c99116080adb (patch)
tree31e85cf7bb872d79ac6f2c4d50dc7831a20d7692 /src/testing/testing_api_cmd_merchant_get_order.c
parent5672080efcaca68ed2d301adf1673d45f7638a16 (diff)
downloadmerchant-696278ce80c7613e39c24e138dd6c99116080adb.tar.gz
merchant-696278ce80c7613e39c24e138dd6c99116080adb.tar.bz2
merchant-696278ce80c7613e39c24e138dd6c99116080adb.zip
complete implementation of #6956: long polling triggers via database backend
Diffstat (limited to 'src/testing/testing_api_cmd_merchant_get_order.c')
-rw-r--r--src/testing/testing_api_cmd_merchant_get_order.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/testing/testing_api_cmd_merchant_get_order.c b/src/testing/testing_api_cmd_merchant_get_order.c
index 26dd0399..34c2b0b0 100644
--- a/src/testing/testing_api_cmd_merchant_get_order.c
+++ b/src/testing/testing_api_cmd_merchant_get_order.c
@@ -143,6 +143,9 @@ merchant_get_order_cb (
struct MerchantGetOrderState *gos = cls;
gos->ogh = NULL;
+ GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+ "GET /private/orders/$ID completed with status %u\n",
+ hr->http_status);
if (gos->http_status != hr->http_status)
{
GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
@@ -870,7 +873,7 @@ conclude_task (void *cls)
/**
- * Callback to process a GET /orders/$ID request
+ * Callback to process a GET /private/orders/$ID request
*
* @param cls closure
* @param hr HTTP response details
@@ -886,6 +889,9 @@ merchant_poll_order_cb (
struct MerchantPollOrderStartState *pos = cls;
pos->ogh = NULL;
+ GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+ "GET /private/orders/$ID finished with status %u.\n",
+ hr->http_status);
pos->http_status = hr->http_status;
switch (hr->http_status)
{
@@ -1017,6 +1023,12 @@ merchant_poll_order_conclude_run (void *cls,
GNUNET_assert (poll_cmd->run == &merchant_poll_order_start_run);
pos = poll_cmd->cls;
pos->cs = poc;
+ GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+ "Waiting on GET /private/orders/$ID of %s (%s)\n",
+ poc->start_reference,
+ (NULL == pos->ogh)
+ ? "finished"
+ : "active");
if (NULL == pos->ogh)
poc->task = GNUNET_SCHEDULER_add_now (&conclude_task,
poc);