[or-cvs] r10909: Miscounted created circuits for aggregate stats. (torflow/trunk)
mikeperry at seul.org
mikeperry at seul.org
Mon Jul 23 01:34:46 UTC 2007
Author: mikeperry
Date: 2007-07-22 21:34:46 -0400 (Sun, 22 Jul 2007)
New Revision: 10909
Modified:
torflow/trunk/metatroller.py
Log:
Miscounted created circuits for aggregate stats.
Modified: torflow/trunk/metatroller.py
===================================================================
--- torflow/trunk/metatroller.py 2007-07-22 23:34:37 UTC (rev 10908)
+++ torflow/trunk/metatroller.py 2007-07-23 01:34:46 UTC (rev 10909)
@@ -25,7 +25,7 @@
# TODO: Move these to config file
control_host = "127.0.0.1"
-control_port = 9051
+control_port = 9061
meta_host = "127.0.0.1"
meta_port = 9052
max_detach = 3
@@ -462,17 +462,16 @@
if c.remote_reason: rreason = c.remote_reason
else: rreason = "NONE"
reason = c.event_name+":"+c.status+":"+lreason+":"+rreason
- if c.status == "EXTENDED":
+ if c.status == "LAUNCHED":
# Update circ_chosen count
self.circ_count += 1
+ elif c.status == "EXTENDED":
delta = c.arrived_at - self.circuits[c.circ_id].last_extended_at
r_ext = c.path[-1]
if r_ext[0] != '$': r_ext = self.name_to_key[r_ext]
self.routers[r_ext[1:]].total_extend_time += delta
self.routers[r_ext[1:]].total_extended += 1
elif c.status == "FAILED":
- # update selection count
- self.circ_count += 1
for r in self.circuits[c.circ_id].path: r.circ_chosen += 1
if len(c.path)-1 < 0: start_f = 0
More information about the tor-commits
mailing list