diff options
author | Christian Grothoff <christian@grothoff.org> | 2020-04-27 15:58:32 +0200 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2020-04-27 15:58:32 +0200 |
commit | e3d91bf74804871c5d7438a0b04265b69feba34a (patch) | |
tree | e8f03f09afcca6b645202059a7aade532c09dd59 /src/backend/taler-merchant-httpd.c | |
parent | 255f162ddb88e932d087574a52d959a7a1d5ba80 (diff) | |
download | merchant-e3d91bf74804871c5d7438a0b04265b69feba34a.tar.gz merchant-e3d91bf74804871c5d7438a0b04265b69feba34a.tar.bz2 merchant-e3d91bf74804871c5d7438a0b04265b69feba34a.zip |
db implementation of claiming
Diffstat (limited to 'src/backend/taler-merchant-httpd.c')
-rw-r--r-- | src/backend/taler-merchant-httpd.c | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/src/backend/taler-merchant-httpd.c b/src/backend/taler-merchant-httpd.c index 7406d1fc..f11d18ca 100644 --- a/src/backend/taler-merchant-httpd.c +++ b/src/backend/taler-merchant-httpd.c @@ -74,6 +74,13 @@ struct TALER_MERCHANTDB_Plugin *TMH_db; struct GNUNET_CONTAINER_MultiHashMap *TMH_by_id_map; /** + * How long do we need to keep information on paid contracts on file for tax + * or other legal reasons? Used to block deletions for younger transaction + * data. + */ +struct GNUNET_TIME_Relative TMH_legal_expiration; + +/** * The port we are running on */ static uint16_t port; @@ -1189,6 +1196,18 @@ run (void *cls, GNUNET_SCHEDULER_shutdown (); return; } + if (GNUNET_OK != + GNUNET_CONFIGURATION_get_value_time (cfg, + "merchant", + "LEGAL_PRESERVATION", + &TMH_legal_expiration)) + { + GNUNET_log_config_missing (GNUNET_ERROR_TYPE_ERROR, + "merchant", + "LEGAL_PRESERVATION"); + GNUNET_SCHEDULER_shutdown (); + return; + } if (GNUNET_YES == GNUNET_CONFIGURATION_get_value_yesno (cfg, "merchant", |