diff options
author | Taylor Yu <catalyst@torproject.org> | 2018-12-17 09:31:16 -0600 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2018-12-21 14:15:35 -0500 |
commit | 85542ee5a0b37bf5b572b9beeda3cb8038ecd88e (patch) | |
tree | b89e4f059e60abbfe6cc71448e3a48c20f3cd7b7 /src/feature/nodelist/nodelist.c | |
parent | 936c93e562deaba62f0d32f7e7fda770c5604318 (diff) | |
download | tor-85542ee5a0b37bf5b572b9beeda3cb8038ecd88e.tar.gz tor-85542ee5a0b37bf5b572b9beeda3cb8038ecd88e.zip |
The big bootstrap phase redefinition
Redefine the set of bootstrap phases to allow display of finer-grained
progress in the early connection stages of connecting to a relay.
This includes adding intermediate phases for proxy and PT connections.
Also add a separate new phase to indicate obtaining enough directory
info to build circuits so we can report that independently of actually
initiating an ORCONN to build the first application circuit.
Previously, we would claim to be connecting to a relay when we had
merely finished obtaining directory info.
Part of ticket 27167.
Diffstat (limited to 'src/feature/nodelist/nodelist.c')
-rw-r--r-- | src/feature/nodelist/nodelist.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/feature/nodelist/nodelist.c b/src/feature/nodelist/nodelist.c index e1d5e4d3fa..d94e73f48f 100644 --- a/src/feature/nodelist/nodelist.c +++ b/src/feature/nodelist/nodelist.c @@ -2546,7 +2546,7 @@ count_loading_descriptors_progress(void) if (fraction > 1.0) return 0; /* it's not the number of descriptors holding us back */ return BOOTSTRAP_STATUS_LOADING_DESCRIPTORS + (int) - (fraction*(BOOTSTRAP_STATUS_CONN_OR-1 - + (fraction*(BOOTSTRAP_STATUS_ENOUGH_DIRINFO-1 - BOOTSTRAP_STATUS_LOADING_DESCRIPTORS)); } @@ -2633,6 +2633,7 @@ update_router_have_minimum_dir_info(void) /* If paths have just become available in this update. */ if (res && !have_min_dir_info) { control_event_client_status(LOG_NOTICE, "ENOUGH_DIR_INFO"); + control_event_boot_dir(BOOTSTRAP_STATUS_ENOUGH_DIRINFO, 0); log_info(LD_DIR, "We now have enough directory information to build circuits."); } |