gnunet-svn
[Top][All Lists]
Advanced

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

[libeufin] 01/02: /admin/add-incoming


From: gnunet
Subject: [libeufin] 01/02: /admin/add-incoming
Date: Wed, 07 Jun 2023 12:13:26 +0200

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

ms pushed a commit to branch master
in repository libeufin.

commit 09f8c0632548ab365ecb0b06ce9d50ea50b1e4e0
Author: MS <ms@taler.net>
AuthorDate: Wed Jun 7 11:53:13 2023 +0200

    /admin/add-incoming
    
    When proxying to Sandbox fails, Nexus fails as well.
---
 nexus/src/main/kotlin/tech/libeufin/nexus/Taler.kt | 17 ++++++-----------
 1 file changed, 6 insertions(+), 11 deletions(-)

diff --git a/nexus/src/main/kotlin/tech/libeufin/nexus/Taler.kt 
b/nexus/src/main/kotlin/tech/libeufin/nexus/Taler.kt
index 2da8bb45..5a59401a 100644
--- a/nexus/src/main/kotlin/tech/libeufin/nexus/Taler.kt
+++ b/nexus/src/main/kotlin/tech/libeufin/nexus/Taler.kt
@@ -568,7 +568,7 @@ private suspend fun historyIncoming(call: ApplicationCall) {
 
 /**
  * This call proxies /admin/add/incoming to the Sandbox,
- * which is the service keeping the transactions ledger.
+ * which is the service keeping the transaction ledger.
  * The credentials are ASSUMED to be exchange/x (user/pass).
  *
  * In the future, a dedicated "add-incoming" facade should
@@ -613,16 +613,11 @@ private suspend fun addIncoming(call: ApplicationCall) {
         )
     }
     val client = HttpClient { followRedirects = true }
-    try {
-        client.post(fromDb.first) {
-            setBody(currentBody)
-            basicAuth("exchange", "x")
-            contentType(ContentType.Application.Json)
-        }
-    } catch (e: ClientRequestException) {
-        logger.error("Proxying /admin/add/incoming to the Sandbox failed: $e")
-    } catch (e: Exception) {
-        logger.error("Could not proxy /admin/add/incoming to the Sandbox: $e")
+    client.post(fromDb.first) {
+        setBody(currentBody)
+        basicAuth("exchange", "x")
+        contentType(ContentType.Application.Json)
+        expectSuccess = true
     }
     /**
      * At this point, Sandbox booked the payment.  Now the "row_id"

-- 
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]