diff options
author | Marcello Stanisci <marcello.stanisci@inria.fr> | 2017-06-02 13:51:17 +0200 |
---|---|---|
committer | Marcello Stanisci <marcello.stanisci@inria.fr> | 2017-06-02 13:51:17 +0200 |
commit | fc6ee7d0f6bb4c88f969baebc9a677d77cbc386e (patch) | |
tree | fb4a602b871867e0d5bb81727bc7293b0ead6b82 /src | |
parent | 64929e237de3249c5180df62a9bd0c5f62da39af (diff) | |
download | merchant-fc6ee7d0f6bb4c88f969baebc9a677d77cbc386e.tar.gz merchant-fc6ee7d0f6bb4c88f969baebc9a677d77cbc386e.tar.bz2 merchant-fc6ee7d0f6bb4c88f969baebc9a677d77cbc386e.zip |
more diagnostics when storing/retrieving contract terms
Diffstat (limited to 'src')
-rw-r--r-- | src/backenddb/plugin_merchantdb_postgres.c | 21 |
1 files changed, 17 insertions, 4 deletions
diff --git a/src/backenddb/plugin_merchantdb_postgres.c b/src/backenddb/plugin_merchantdb_postgres.c index 52996904..34266a7a 100644 --- a/src/backenddb/plugin_merchantdb_postgres.c +++ b/src/backenddb/plugin_merchantdb_postgres.c @@ -521,6 +521,11 @@ postgres_find_contract_terms (void *cls, PGresult *result; unsigned int i; + GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, + "finding contract term, order_id: '%s', merchant_pub: '%s'.\n", + order_id, + TALER_B2S (merchant_pub)); + struct GNUNET_PQ_QueryParam params[] = { GNUNET_PQ_query_param_string (order_id), GNUNET_PQ_query_param_auto_from_type (merchant_pub), @@ -584,6 +589,12 @@ postgres_insert_contract_terms (void *cls, &h_contract_terms)) return GNUNET_SYSERR; + GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, + "inserting contract_terms: order_id: %s, merchant_pub: %s, h_contract_terms: %s.\n", + order_id, + TALER_B2S (merchant_pub), + GNUNET_h2s (&h_contract_terms)); + struct GNUNET_PQ_QueryParam params[] = { GNUNET_PQ_query_param_string (order_id), GNUNET_PQ_query_param_auto_from_type (merchant_pub), @@ -659,8 +670,9 @@ postgres_store_transaction (void *cls, }; GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, - "Storing transaction with h_contract_terms '%s'\n", - GNUNET_h2s (h_contract_terms)); + "Storing transaction with h_contract_terms '%s', merchant_pub '%s'.\n", + GNUNET_h2s (h_contract_terms), + TALER_B2S (merchant_pub)); result = GNUNET_PQ_exec_prepared (pg->conn, "insert_transaction", @@ -1118,8 +1130,9 @@ postgres_find_transaction (void *cls, }; GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, - "Finding transaction for h_contract_terms '%s'\n", - GNUNET_h2s (h_contract_terms)); + "Finding transaction for h_contract_terms '%s', merchant_pub: '%s'.\n", + GNUNET_h2s (h_contract_terms), + TALER_B2S (merchant_pub)); result = GNUNET_PQ_exec_prepared (pg->conn, "find_transaction", |