diff options
author | Matthias Wachs <wachs@net.in.tum.de> | 2014-01-22 10:40:04 +0000 |
---|---|---|
committer | Matthias Wachs <wachs@net.in.tum.de> | 2014-01-22 10:40:04 +0000 |
commit | 7c241d90b842906019706995a48ba93eaa7acb9e (patch) | |
tree | a81ada9bd8137347183306d9f57017c88a84a549 /src/ats-tests/gnunet-ats-sim.c | |
parent | 611a4740a7425e70f073e8183f96d51fa065502d (diff) | |
download | gnunet-7c241d90b842906019706995a48ba93eaa7acb9e.tar.gz gnunet-7c241d90b842906019706995a48ba93eaa7acb9e.zip |
improvements
Diffstat (limited to 'src/ats-tests/gnunet-ats-sim.c')
-rw-r--r-- | src/ats-tests/gnunet-ats-sim.c | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/src/ats-tests/gnunet-ats-sim.c b/src/ats-tests/gnunet-ats-sim.c index 0b0e9dd7e..b394cb8a4 100644 --- a/src/ats-tests/gnunet-ats-sim.c +++ b/src/ats-tests/gnunet-ats-sim.c | |||
@@ -18,8 +18,10 @@ | |||
18 | Boston, MA 02111-1307, USA. | 18 | Boston, MA 02111-1307, USA. |
19 | */ | 19 | */ |
20 | /** | 20 | /** |
21 | * @file ats/perf_ats.c | 21 | * @file ats-test/gnunet-ats-sim.c |
22 | * @brief ats benchmark: start peers and modify preferences, monitor change over time | 22 | * @brief ats traffic simulator: this tool uses the ats-test library to setup a |
23 | * topology and generate traffic between these peers. The traffic description | ||
24 | * is loaded from a experiment description file | ||
23 | * @author Christian Grothoff | 25 | * @author Christian Grothoff |
24 | * @author Matthias Wachs | 26 | * @author Matthias Wachs |
25 | */ | 27 | */ |
@@ -36,8 +38,14 @@ | |||
36 | #define TEST_MESSAGE_TYPE_PING 12345 | 38 | #define TEST_MESSAGE_TYPE_PING 12345 |
37 | #define TEST_MESSAGE_TYPE_PONG 12346 | 39 | #define TEST_MESSAGE_TYPE_PONG 12346 |
38 | 40 | ||
41 | /** | ||
42 | * Number of master peers to use | ||
43 | */ | ||
39 | static int c_masters; | 44 | static int c_masters; |
40 | 45 | ||
46 | /** | ||
47 | * Number of slave peers to use | ||
48 | */ | ||
41 | static int c_slaves; | 49 | static int c_slaves; |
42 | 50 | ||
43 | static int | 51 | static int |
@@ -76,6 +84,9 @@ static void topology_setup_done (void *cls, | |||
76 | struct BenchmarkPeer *slaves) | 84 | struct BenchmarkPeer *slaves) |
77 | { | 85 | { |
78 | GNUNET_log (GNUNET_ERROR_TYPE_INFO, "Topology setup complete!\n"); | 86 | GNUNET_log (GNUNET_ERROR_TYPE_INFO, "Topology setup complete!\n"); |
87 | |||
88 | |||
89 | /* Shutdown a topology with */ | ||
79 | GNUNET_ATS_TEST_shutdown_topology (); | 90 | GNUNET_ATS_TEST_shutdown_topology (); |
80 | } | 91 | } |
81 | 92 | ||
@@ -90,6 +101,7 @@ main (int argc, char *argv[]) | |||
90 | c_slaves = DEFAULT_NUM_SLAVES; | 101 | c_slaves = DEFAULT_NUM_SLAVES; |
91 | c_masters = DEFAULT_NUM_MASTERS; | 102 | c_masters = DEFAULT_NUM_MASTERS; |
92 | 103 | ||
104 | /* Setup a topology with */ | ||
93 | GNUNET_ATS_TEST_create_topology ("gnunet-ats-sim", "perf_ats_proportional_none.conf", | 105 | GNUNET_ATS_TEST_create_topology ("gnunet-ats-sim", "perf_ats_proportional_none.conf", |
94 | c_slaves, | 106 | c_slaves, |
95 | c_masters, | 107 | c_masters, |
@@ -101,4 +113,4 @@ main (int argc, char *argv[]) | |||
101 | &ats_performance_info_cb); | 113 | &ats_performance_info_cb); |
102 | return 0; | 114 | return 0; |
103 | } | 115 | } |
104 | /* end of file perf_ats_topogy.c */ | 116 | /* end of file gnunet-ats-sim.c */ |