From 02716c4084c76630f35a5fcc4d2ef4e17d7e1b00 Mon Sep 17 00:00:00 2001 From: Christian Grothoff Date: Mon, 16 May 2022 15:43:40 +0200 Subject: -add skeleton logic for purse expiration --- src/exchangedb/plugin_exchangedb_postgres.c | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) (limited to 'src/exchangedb/plugin_exchangedb_postgres.c') diff --git a/src/exchangedb/plugin_exchangedb_postgres.c b/src/exchangedb/plugin_exchangedb_postgres.c index 4d5efb9c..ab282f4f 100644 --- a/src/exchangedb/plugin_exchangedb_postgres.c +++ b/src/exchangedb/plugin_exchangedb_postgres.c @@ -13554,6 +13554,25 @@ postgres_insert_purse_request ( } +/** + * Function called to clean up one expired purse. + * + * @param cls the @e cls of this struct with the plugin-specific state + * @param start_time select purse expired after this time + * @param end_time select purse expired before this time + * @return transaction status code (#GNUNET_DB_STATUS_SUCCESS_NO_RESULTS if no purse expired in the given time interval). + */ +static enum GNUNET_DB_QueryStatus +postgres_expire_purse ( + void *cls, + struct GNUNET_TIME_Absolute start_time, + struct GNUNET_TIME_Absolute end_time) +{ + GNUNET_break (0); + return GNUNET_DB_STATUS_HARD_ERROR; +} + + /** * Function called to obtain information about a purse. * @@ -14283,6 +14302,8 @@ libtaler_plugin_exchangedb_postgres_init (void *cls) = &postgres_insert_purse_request; plugin->select_purse_request = &postgres_select_purse_request; + plugin->expire_purse + = &postgres_expire_purse; plugin->select_purse = &postgres_select_purse; plugin->select_purse_by_merge_pub -- cgit v1.2.3