gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[taler-merchant] branch master updated: more logging


From: gnunet
Subject: [taler-merchant] branch master updated: more logging
Date: Wed, 10 Jan 2024 11:12:25 +0100

This is an automated email from the git hooks/post-receive script.

grothoff pushed a commit to branch master
in repository merchant.

The following commit(s) were added to refs/heads/master by this push:
     new be24c4b9 more logging
be24c4b9 is described below

commit be24c4b9fd68cca3e5b330642183a3b3d6d24b8c
Author: Christian Grothoff <christian@grothoff.org>
AuthorDate: Wed Jan 10 11:12:23 2024 +0100

    more logging
---
 src/backend/taler-merchant-depositcheck.c | 27 +++++++++++++++++++++++----
 1 file changed, 23 insertions(+), 4 deletions(-)

diff --git a/src/backend/taler-merchant-depositcheck.c 
b/src/backend/taler-merchant-depositcheck.c
index 7e25c902..424868de 100644
--- a/src/backend/taler-merchant-depositcheck.c
+++ b/src/backend/taler-merchant-depositcheck.c
@@ -364,12 +364,23 @@ select_work (void *cls);
 static void
 run_at (struct GNUNET_TIME_Absolute deadline)
 {
-  if (GNUNET_TIME_absolute_cmp (deadline,
-                                >,
-                                next_deadline))
+  if ( (NULL != task) &&
+       (GNUNET_TIME_absolute_cmp (deadline,
+                                  >,
+                                  next_deadline)) )
+  {
+    GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+                "Not scheduling for %s yet, already have earlier task 
pending\n",
+                GNUNET_TIME_absolute2s (deadline));
     return;
+  }
   if (NULL == keys)
+  {
+    GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+                "Not scheduling for %s yet, no /keys available\n",
+                GNUNET_TIME_absolute2s (deadline));
     return; /* too early */
+  }
   if (NULL != task)
     GNUNET_SCHEDULER_cancel (task);
   next_deadline = deadline;
@@ -527,7 +538,7 @@ static void
 pending_deposits_cb (
   void *cls,
   uint64_t deposit_serial,
-  struct GNUNET_TIME_Absolute wire_deadline, /* missing in DB! Funky migration 
needed! */
+  struct GNUNET_TIME_Absolute wire_deadline,
   const struct TALER_PrivateContractHashP *h_contract_terms,
   const struct TALER_MerchantPrivateKeyP *merchant_priv,
   const char *instance_id,
@@ -541,6 +552,9 @@ pending_deposits_cb (
   (void) cls;
   if (GNUNET_TIME_absolute_is_future (wire_deadline))
   {
+    GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+                "Pending deposit has deadline in the future at %s\n",
+                GNUNET_TIME_absolute2s (wire_deadline));
     run_at (wire_deadline);
     return;
   }
@@ -561,6 +575,8 @@ pending_deposits_cb (
   if (GNUNET_TIME_absolute_is_past (keys->key_data_expiration.abs_time))
   {
     /* Parent should re-start us, then we will re-fetch /keys */
+    GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+                "/keys expired, shutting down\n");
     GNUNET_SCHEDULER_shutdown ();
     return;
   }
@@ -644,6 +660,9 @@ select_work (void *cls)
                                              retry,
                                              &pending_deposits_cb,
                                              NULL);
+    GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+                "Looking up pending deposits query status was %d\n",
+                (int) qs);
     switch (qs)
     {
     case GNUNET_DB_STATUS_HARD_ERROR:

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]