aboutsummaryrefslogtreecommitdiff
path: root/src/or/entrynodes.h
diff options
context:
space:
mode:
authorMike Perry <mikeperry-git@fscked.org>2013-01-18 19:37:16 -0800
committerMike Perry <mikeperry-git@fscked.org>2013-01-18 19:46:21 -0800
commite13e30221ef6715cafa93bbffc156583c8b58ecf (patch)
tree09b12822e6f3b3dafbe610a35617e8c8c2f4777c /src/or/entrynodes.h
parentee421e68d5231e3962b45f8bbfc6505c8e6f3315 (diff)
downloadtor-e13e30221ef6715cafa93bbffc156583c8b58ecf.tar
tor-e13e30221ef6715cafa93bbffc156583c8b58ecf.tar.gz
Implement Path use bias accounting.
Path use bias measures how often we can actually succeed using the circuits we actually try to use. It is a subset of path bias accounting, but it is computed as a separate statistic because the rate of client circuit use may vary depending on use case.
Diffstat (limited to 'src/or/entrynodes.h')
-rw-r--r--src/or/entrynodes.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/or/entrynodes.h b/src/or/entrynodes.h
index 1e52ba28e..e6c973c95 100644
--- a/src/or/entrynodes.h
+++ b/src/or/entrynodes.h
@@ -61,6 +61,9 @@ typedef struct entry_guard_t {
* attempted, but none succeeded. */
double timeouts; /**< Number of 'right-censored' circuit timeouts for this
* guard. */
+ double use_attempts; /**< Number of circuits we tried to use with streams */
+ double use_successes; /**< Number of successfully used circuits using
+ * this guard as first hop. */
} entry_guard_t;
entry_guard_t *entry_guard_get_by_id_digest(const char *digest);
@@ -113,8 +116,8 @@ int find_transport_by_bridge_addrport(const tor_addr_t *addr, uint16_t port,
int validate_pluggable_transports_config(void);
-double pathbias_get_closed_count(entry_guard_t *gaurd);
-double pathbias_get_success_count(entry_guard_t *guard);
+double pathbias_get_close_success_count(entry_guard_t *guard);
+double pathbias_get_use_success_count(entry_guard_t *guard);
#endif