*/
static unsigned int do_find_peer;
+/**
+ * Whether or not to insert gauger data.
+ */
+static unsigned int insert_gauger_data;
+
#if ONLY_TESTING
/**
* Are we currently trying to connect two peers repeatedly?
GNUNET_asprintf (&temp_get_string,
"DHT Successful GETs (trial %d)", trial_to_run);
GNUNET_asprintf (&revision_str, "%llu", revision);
- GAUGER_ID("DHT_TESTING", temp_get_string, cumulative_successful_gets / (double)cumulative_num_gets, "percent successful", revision_str);
+ if (GNUNET_YES == insert_gauger_data)
+ GAUGER_ID("DHT_TESTING", temp_get_string, cumulative_successful_gets / (double)cumulative_num_gets, "percent successful", revision_str);
fprintf (
stderr,
"Finished trial, had %llu successful gets out of %llu total, %.2f percent succeeded\n",
"DHT Profiler Connection failed (trial %d)",
trial_to_run);
GNUNET_asprintf (&revision_str, "%llu", revision);
- GAUGER_ID("DHT_TESTING", temp_conn_string, conns_per_sec_total, "conns/s", revision_str);
- GAUGER_ID("DHT_TESTING", temp_conn_failed_string, failed_conns_per_sec_total, "failed_conns", revision_str);
+
+ if (GNUNET_YES == insert_gauger_data)
+ GAUGER_ID("DHT_TESTING", temp_conn_string, conns_per_sec_total, "conns/s", revision_str);
+ if (GNUNET_YES == insert_gauger_data)
+ GAUGER_ID("DHT_TESTING", temp_conn_failed_string, failed_conns_per_sec_total, "failed_conns", revision_str);
+
GNUNET_free(temp_conn_string);
GNUNET_free(temp_conn_failed_string);
GNUNET_asprintf (&temp_conn_string,
&temp_conn_failed_string,
"DHT Profiler Total Connections failed (trial %d)",
trial_to_run);
- GAUGER_ID("DHT_TESTING", temp_conn_string, total_connections, "conns", revision_str);
- GAUGER_ID("DHT_TESTING", temp_conn_failed_string, failed_connections, "failed conns", revision_str);
+ if (GNUNET_YES == insert_gauger_data)
+ GAUGER_ID("DHT_TESTING", temp_conn_string, total_connections, "conns", revision_str);
+ if (GNUNET_YES == insert_gauger_data)
+ GAUGER_ID("DHT_TESTING", temp_conn_failed_string, failed_connections, "failed conns", revision_str);
GNUNET_free(temp_conn_string);
GNUNET_free(temp_conn_failed_string);
GNUNET_free(revision_str);
"do_find_peer"))
do_find_peer = GNUNET_YES;
+ if (GNUNET_NO == GNUNET_CONFIGURATION_get_value_yesno (cfg, "dht",
+ "insert_gauger_data"))
+ insert_gauger_data = GNUNET_YES;
+
if (GNUNET_YES == GNUNET_CONFIGURATION_get_value_yesno (cfg, "dht",
"republish"))
in_dht_replication = GNUNET_YES;