diff options
author | priscilla <priscilla.huang@efrei.net> | 2023-01-23 08:25:49 -0500 |
---|---|---|
committer | priscilla <priscilla.huang@efrei.net> | 2023-01-23 08:25:49 -0500 |
commit | 4ba9ffaaeef83a05964bee764c419d9006a6767d (patch) | |
tree | 3f8c3e4936d7391bbdfd99b909bcb9983d1e50f3 /src/backenddb | |
parent | 03ce25438c251820ff556c66f11b22659f7a896f (diff) | |
download | merchant-4ba9ffaaeef83a05964bee764c419d9006a6767d.tar.gz merchant-4ba9ffaaeef83a05964bee764c419d9006a6767d.tar.bz2 merchant-4ba9ffaaeef83a05964bee764c419d9006a6767d.zip |
backend pending webhook
Diffstat (limited to 'src/backenddb')
-rw-r--r-- | src/backenddb/plugin_merchantdb_postgres.c | 12 | ||||
-rw-r--r-- | src/backenddb/test_merchantdb.c | 2 |
2 files changed, 11 insertions, 3 deletions
diff --git a/src/backenddb/plugin_merchantdb_postgres.c b/src/backenddb/plugin_merchantdb_postgres.c index 230417e7..e87021ea 100644 --- a/src/backenddb/plugin_merchantdb_postgres.c +++ b/src/backenddb/plugin_merchantdb_postgres.c @@ -7773,7 +7773,7 @@ postgres_lookup_all_webhooks (void *cls, struct GNUNET_PQ_QueryParam params[] = { GNUNET_PQ_query_param_string (instance_id), GNUNET_PQ_query_param_uint64 (&min_row), - GNUNET_PQ_query_param_uint64 (&max_results64), + GNUNET_PQ_query_param_uint64 (&max_results64), GNUNET_PQ_query_param_end }; @@ -7800,16 +7800,24 @@ postgres_lookup_all_webhooks (void *cls, * @param next_attempt when we should make the next request to the webhook * @return database result code */ +<<<<<<< HEAD static enum GNUNET_DB_QueryStatus postgres_update_pending_webhook (void *cls, uint64_t webhook_serial, struct GNUNET_TIME_Absolute next_attempt) // maybe add: http status of failure? +======= + static enum GNUNET_DB_QueryStatus + postgres_update_pending_webhook(void *cls, + uint64_t webhook_serial, + const struct TALER_MERCHANTDB_PendingWebhookDetails *pwb) + // maybe add: http status of failure? +>>>>>>> ee56051c (backend for pending webhook) { struct PostgresClosure *pg = cls; struct GNUNET_PQ_QueryParam params[] = { GNUNET_PQ_query_param_uint64 (&webhook_serial), - GNUNET_PQ_query_param_absolute_time (&next_attempt), + GNUNET_PQ_query_param_absolute_time (&pwb->next_attempt), GNUNET_PQ_query_param_end }; diff --git a/src/backenddb/test_merchantdb.c b/src/backenddb/test_merchantdb.c index 69a376aa..cbf4e4b6 100644 --- a/src/backenddb/test_merchantdb.c +++ b/src/backenddb/test_merchantdb.c @@ -7909,7 +7909,7 @@ test_update_pending_webhook (const struct InstanceData *instance, TEST_COND_RET_ON_FAIL (expected_result == plugin->update_pending_webhook (plugin->cls, pwebhook->webhook_serial, - pwebhook->pwebhook.next_attempt), + &pwebhook->pwebhook), "Update pending webhook failed\n"); return 0; } |