gnunet-svn
[Top][All Lists]
Advanced

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

[taler-exchange] branch master updated: add support for taler-merchant-e


From: gnunet
Subject: [taler-exchange] branch master updated: add support for taler-merchant-exchange to taler-unified-setup.sh
Date: Wed, 10 Jan 2024 13:33:33 +0100

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

grothoff pushed a commit to branch master
in repository exchange.

The following commit(s) were added to refs/heads/master by this push:
     new b8a07ff3 add support for taler-merchant-exchange to 
taler-unified-setup.sh
b8a07ff3 is described below

commit b8a07ff3a314ae0e72441563f6580e07b3c83773
Author: Christian Grothoff <christian@grothoff.org>
AuthorDate: Wed Jan 10 13:33:12 2024 +0100

    add support for taler-merchant-exchange to taler-unified-setup.sh
---
 src/exchangedb/exchange_do_deposit.sql            |  1 -
 src/exchangedb/exchange_do_reserves_in_insert.sql |  1 -
 src/kyclogic/plugin_kyclogic_oauth2.c             | 17 ++++++++++++++-
 src/testing/taler-unified-setup.sh                | 25 ++++++++++++++++-------
 4 files changed, 34 insertions(+), 10 deletions(-)

diff --git a/src/exchangedb/exchange_do_deposit.sql 
b/src/exchangedb/exchange_do_deposit.sql
index 1156c7de..c89e9e47 100644
--- a/src/exchangedb/exchange_do_deposit.sql
+++ b/src/exchangedb/exchange_do_deposit.sql
@@ -42,7 +42,6 @@ AS $$
 DECLARE
   wtsi INT8; -- wire target serial id
   bdsi INT8; -- batch_deposits serial id
-  curs REFCURSOR;
   i INT4;
   ini_amount_with_fee taler_amount;
   ini_coin_pub BYTEA;
diff --git a/src/exchangedb/exchange_do_reserves_in_insert.sql 
b/src/exchangedb/exchange_do_reserves_in_insert.sql
index d2347bde..1be06f06 100644
--- a/src/exchangedb/exchange_do_reserves_in_insert.sql
+++ b/src/exchangedb/exchange_do_reserves_in_insert.sql
@@ -30,7 +30,6 @@ RETURNS SETOF exchange_do_array_reserve_insert_return_type
 LANGUAGE plpgsql
 AS $$
 DECLARE
-  curs REFCURSOR;
   conflict BOOL;
   dup BOOL;
   uuid INT8;
diff --git a/src/kyclogic/plugin_kyclogic_oauth2.c 
b/src/kyclogic/plugin_kyclogic_oauth2.c
index 7c57b5ae..53b03e1e 100644
--- a/src/kyclogic/plugin_kyclogic_oauth2.c
+++ b/src/kyclogic/plugin_kyclogic_oauth2.c
@@ -1060,6 +1060,15 @@ handle_curl_proof_finished (void *cls,
   ph->job = NULL;
   switch (response_code)
   {
+  case 0:
+    ph->status = TALER_KYCLOGIC_STATUS_PROVIDER_FAILED;
+    ph->response
+      = TALER_MHD_make_error (
+          TALER_EC_EXCHANGE_KYC_PROOF_BACKEND_INVALID_RESPONSE,
+          "No response from KYC gateway");
+    ph->http_status
+      = MHD_HTTP_BAD_GATEWAY;
+    break;
   case MHD_HTTP_OK:
     parse_proof_success_reply (ph,
                                j);
@@ -1304,11 +1313,17 @@ oauth2_proof (void *cls,
                                          ph);
     return ph;
   }
-
+  GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+              "Requesting OAuth 2.0 data via HTTP POST `%s'\n",
+              pd->token_url);
   GNUNET_assert (CURLE_OK ==
                  curl_easy_setopt (ph->eh,
                                    CURLOPT_URL,
                                    pd->token_url));
+  GNUNET_assert (CURLE_OK ==
+                 curl_easy_setopt (ph->eh,
+                                   CURLOPT_VERBOSE,
+                                   1));
   GNUNET_assert (CURLE_OK ==
                  curl_easy_setopt (ph->eh,
                                    CURLOPT_POST,
diff --git a/src/testing/taler-unified-setup.sh 
b/src/testing/taler-unified-setup.sh
index ee21ac61..ca58d983 100755
--- a/src/testing/taler-unified-setup.sh
+++ b/src/testing/taler-unified-setup.sh
@@ -76,6 +76,7 @@ START_BANK=0
 START_TRANSFER=0
 START_WIREWATCH=0
 START_DEPOSITCHECK=0
+START_MERCHANT_EXCHANGE=0
 USE_ACCOUNT="exchange-account-1"
 USE_VALGRIND=""
 WIRE_DOMAIN="x-taler-bank"
@@ -84,7 +85,7 @@ LOGLEVEL="DEBUG"
 DEFAULT_SLEEP="0.2"
 
 # Parse command-line options
-while getopts ':abc:d:efghkL:mMnr:stu:vwWD' OPTION; do
+while getopts ':abc:d:DeEfghkL:mMnr:stu:vwW' OPTION; do
     case "$OPTION" in
         a)
             START_AUDITOR="1"
@@ -98,12 +99,15 @@ while getopts ':abc:d:efghkL:mMnr:stu:vwWD' OPTION; do
         d)
             WIRE_DOMAIN="$OPTARG"
             ;;
-        D)  
+        D)
             START_DONAU="1"
             ;;
         e)
             START_EXCHANGE="1"
             ;;
+        E)
+            START_MERCHANT_EXCHANGE="1"
+            ;;
         f)
             START_FAKEBANK="1"
             ;;
@@ -117,22 +121,23 @@ while getopts ':abc:d:efghkL:mMnr:stu:vwWD' OPTION; do
             echo '  -d $METHOD   -- use wire method (default: x-taler-bank)'
             echo '  -D           -- start donau'
             echo '  -e           -- start exchange'
+            echo '  -E           -- start taler-merchant-exchange'
             echo '  -f           -- start fakebank'
-            echo '  -g           -- start aggregator'
+            echo '  -g           -- start taler-exchange-aggregator'
             echo '  -h           -- print this help'
             # shellcheck disable=SC2016
             echo '  -L $LOGLEVEL -- set log level'
-            echo '  -m           -- start merchant'
-            echo '  -M           -- start merchant-depositcheck'
+            echo '  -m           -- start taler-merchant'
+            echo '  -M           -- start taler-merchant-depositcheck'
             echo '  -n           -- start nexus'
             # shellcheck disable=SC2016
             echo '  -r $MEX      -- which exchange to use at the merchant 
(optional)'
             echo '  -s           -- start backup/sync'
-            echo '  -t           -- start transfer'
+            echo '  -t           -- start taler-exchange-transfer'
             # shellcheck disable=SC2016
             echo '  -u $SECTION  -- exchange account to use'
             echo '  -v           -- use valgrind'
-            echo '  -w           -- start wirewatch'
+            echo '  -w           -- start taler-exchange-wirewatch'
             echo '  -W           -- wait for signal'
             exit 0
             ;;
@@ -563,6 +568,12 @@ then
     $USE_VALGRIND taler-merchant-webhook \
                   -c "$CONF" \
                   -L "$LOGLEVEL" 2> taler-merchant-webhook.log &
+    if [ "1" = "$START_MERCHANT_EXCHANGE" ]
+    then
+        $USE_VALGRIND taler-merchant-exchange \
+                  -c "$CONF" \
+                  -L "$LOGLEVEL" 2> taler-merchant-exchange.log &
+    fi
     if [ "1" = "$START_DEPOSITCHECK" ]
     then
         $USE_VALGRIND taler-merchant-depositcheck \

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