aboutsummaryrefslogtreecommitdiff
path: root/src/exchangedb/plugin_exchangedb_postgres.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/exchangedb/plugin_exchangedb_postgres.c')
-rw-r--r--src/exchangedb/plugin_exchangedb_postgres.c62
1 files changed, 31 insertions, 31 deletions
diff --git a/src/exchangedb/plugin_exchangedb_postgres.c b/src/exchangedb/plugin_exchangedb_postgres.c
index 04455808..3b06ed40 100644
--- a/src/exchangedb/plugin_exchangedb_postgres.c
+++ b/src/exchangedb/plugin_exchangedb_postgres.c
@@ -3922,7 +3922,7 @@ prepare_statements (struct PostgresClosure *pg)
"INSERT INTO extensions"
"(extension_id"
",name"
- ",config"
+ ",manifest"
") VALUES "
"($1, $2, $3);",
3),
@@ -4206,18 +4206,18 @@ prepare_statements (struct PostgresClosure *pg)
" AND start_row=$2"
" AND end_row=$3",
3),
- /* Used in #postgres_set_extension_config */
+ /* Used in #postgres_set_extension_manifest */
GNUNET_PQ_make_prepare (
- "set_extension_config",
- "INSERT INTO extensions (name, config) VALUES ($1, $2) "
+ "set_extension_manifest",
+ "INSERT INTO extensions (name, manifest) VALUES ($1, $2) "
"ON CONFLICT (name) "
- "DO UPDATE SET config=$2",
+ "DO UPDATE SET manifest=$2",
2),
- /* Used in #postgres_get_extension_config */
+ /* Used in #postgres_get_extension_manifest */
GNUNET_PQ_make_prepare (
- "get_extension_config",
+ "get_extension_manifest",
"SELECT "
- " config "
+ " manifest "
"FROM extensions"
" WHERE name=$1;",
1),
@@ -15199,25 +15199,25 @@ postgres_delete_shard_locks (void *cls)
/**
- * Function called to save the configuration of an extension
- * (age-restriction, peer2peer, ...). After successful storage of the
- * configuration it triggers the corresponding event.
+ * Function called to save the manifest of an extension
+ * (age_restriction, poliy_merchant_refund, ...). After successful storage of
+ * the manifest it triggers the corresponding event.
*
* @param cls the @e cls of this struct with the plugin-specific state
* @param extension_name the name of the extension
- * @param config JSON object of the configuration as string
+ * @param manifest JSON object of the manifest as string
* @return transaction status code
*/
enum GNUNET_DB_QueryStatus
-postgres_set_extension_config (void *cls,
- const char *extension_name,
- const char *config)
+postgres_set_extension_manifest (void *cls,
+ const char *extension_name,
+ const char *manifest)
{
struct PostgresClosure *pg = cls;
struct GNUNET_PQ_QueryParam pcfg =
- (NULL == config || 0 == *config)
+ (NULL == manifest || 0 == *manifest)
? GNUNET_PQ_query_param_null ()
- : GNUNET_PQ_query_param_string (config);
+ : GNUNET_PQ_query_param_string (manifest);
struct GNUNET_PQ_QueryParam params[] = {
GNUNET_PQ_query_param_string (extension_name),
pcfg,
@@ -15225,24 +15225,24 @@ postgres_set_extension_config (void *cls,
};
return GNUNET_PQ_eval_prepared_non_select (pg->conn,
- "set_extension_config",
+ "set_extension_manifest",
params);
}
/**
- * Function called to get the configuration of an extension
- * (age-restriction, peer2peer, ...)
+ * Function called to get the manifest of an extension
+ * (age_restriction, policy_merchant_refund, ...)
*
* @param cls the @e cls of this struct with the plugin-specific state
* @param extension_name the name of the extension
- * @param[out] config JSON object of the configuration as string
+ * @param[out] manifest Manifest of the extension encoded as JSON object
* @return transaction status code
*/
enum GNUNET_DB_QueryStatus
-postgres_get_extension_config (void *cls,
+postgres_get_extension_manifest (void *cls,
const char *extension_name,
- char **config)
+ char **manifest)
{
struct PostgresClosure *pg = cls;
struct GNUNET_PQ_QueryParam params[] = {
@@ -15252,15 +15252,15 @@ postgres_get_extension_config (void *cls,
bool is_null;
struct GNUNET_PQ_ResultSpec rs[] = {
GNUNET_PQ_result_spec_allow_null (
- GNUNET_PQ_result_spec_string ("config",
- config),
+ GNUNET_PQ_result_spec_string ("manifest",
+ manifest),
&is_null),
GNUNET_PQ_result_spec_end
};
- *config = NULL;
+ *manifest = NULL;
return GNUNET_PQ_eval_prepared_singleton_select (pg->conn,
- "get_extension_config",
+ "get_extension_manifest",
params,
rs);
}
@@ -17231,10 +17231,10 @@ libtaler_plugin_exchangedb_postgres_init (void *cls)
= &postgres_release_revolving_shard;
plugin->delete_shard_locks
= &postgres_delete_shard_locks;
- plugin->set_extension_config
- = &postgres_set_extension_config;
- plugin->get_extension_config
- = &postgres_get_extension_config;
+ plugin->set_extension_manifest
+ = &postgres_set_extension_manifest;
+ plugin->get_extension_manifest
+ = &postgres_get_extension_manifest;
plugin->insert_partner
= &postgres_insert_partner;
plugin->insert_contract