mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-24 20:33:31 +01:00
Merge remote branch 'origin/maint-0.2.2'
This commit is contained in:
commit
a38274b1ce
4
changes/bug2004
Normal file
4
changes/bug2004
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
o Minor features
|
||||||
|
- Log less aggressively about circuit timeout changes, and improve some
|
||||||
|
other circuit timeout messages. Resolves bug 2004.
|
||||||
|
|
@ -259,8 +259,9 @@ circuit_build_times_new_consensus_params(circuit_build_times_t *cbt,
|
|||||||
|
|
||||||
if (num > 0 && num != cbt->liveness.num_recent_circs) {
|
if (num > 0 && num != cbt->liveness.num_recent_circs) {
|
||||||
int8_t *recent_circs;
|
int8_t *recent_circs;
|
||||||
log_notice(LD_CIRC, "Changing recent timeout size from %d to %d",
|
log_notice(LD_CIRC, "The Tor Directory Consensus has changed how many "
|
||||||
cbt->liveness.num_recent_circs, num);
|
"circuits we must track to detect network failures from %d "
|
||||||
|
"to %d.", cbt->liveness.num_recent_circs, num);
|
||||||
|
|
||||||
tor_assert(cbt->liveness.timeouts_after_firsthop);
|
tor_assert(cbt->liveness.timeouts_after_firsthop);
|
||||||
|
|
||||||
@ -593,8 +594,10 @@ circuit_build_times_shuffle_and_store_array(circuit_build_times_t *cbt,
|
|||||||
{
|
{
|
||||||
int n = num_times;
|
int n = num_times;
|
||||||
if (num_times > CBT_NCIRCUITS_TO_OBSERVE) {
|
if (num_times > CBT_NCIRCUITS_TO_OBSERVE) {
|
||||||
log_notice(LD_CIRC, "Decreasing circuit_build_times size from %d to %d",
|
log_notice(LD_CIRC, "The number of circuit times that this Tor version "
|
||||||
num_times, CBT_NCIRCUITS_TO_OBSERVE);
|
"uses to calculate build times is less than the number stored "
|
||||||
|
"in your state file. Decreasing the circuit time history from "
|
||||||
|
"%d to %d.", num_times, CBT_NCIRCUITS_TO_OBSERVE);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* This code can only be run on a compact array */
|
/* This code can only be run on a compact array */
|
||||||
@ -1075,7 +1078,7 @@ circuit_build_times_network_close(circuit_build_times_t *cbt,
|
|||||||
if (cbt->liveness.nonlive_timeouts == 1) {
|
if (cbt->liveness.nonlive_timeouts == 1) {
|
||||||
log_notice(LD_CIRC,
|
log_notice(LD_CIRC,
|
||||||
"Tor has not observed any network activity for the past %d "
|
"Tor has not observed any network activity for the past %d "
|
||||||
"seconds. Disabling circuit build timeout code.",
|
"seconds. Disabling circuit build timeout recording.",
|
||||||
(int)(now - cbt->liveness.network_last_live));
|
(int)(now - cbt->liveness.network_last_live));
|
||||||
} else {
|
} else {
|
||||||
log_info(LD_CIRC,
|
log_info(LD_CIRC,
|
||||||
@ -1159,7 +1162,7 @@ circuit_build_times_network_check_changed(circuit_build_times_t *cbt)
|
|||||||
control_event_buildtimeout_set(cbt, BUILDTIMEOUT_SET_EVENT_RESET);
|
control_event_buildtimeout_set(cbt, BUILDTIMEOUT_SET_EVENT_RESET);
|
||||||
|
|
||||||
log_notice(LD_CIRC,
|
log_notice(LD_CIRC,
|
||||||
"Network connection speed appears to have changed. Resetting "
|
"Your network connection speed appears to have changed. Resetting "
|
||||||
"timeout to %lds after %d timeouts and %d buildtimes.",
|
"timeout to %lds after %d timeouts and %d buildtimes.",
|
||||||
tor_lround(cbt->timeout_ms/1000), timeout_count,
|
tor_lround(cbt->timeout_ms/1000), timeout_count,
|
||||||
total_build_times);
|
total_build_times);
|
||||||
@ -1297,7 +1300,7 @@ circuit_build_times_set_timeout_worker(circuit_build_times_t *cbt)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (max_time < INT32_MAX/2 && cbt->close_ms > 2*max_time) {
|
if (max_time < INT32_MAX/2 && cbt->close_ms > 2*max_time) {
|
||||||
log_notice(LD_CIRC,
|
log_info(LD_CIRC,
|
||||||
"Circuit build measurement period of %dms is more than twice "
|
"Circuit build measurement period of %dms is more than twice "
|
||||||
"the maximum build time we have ever observed. Capping it to "
|
"the maximum build time we have ever observed. Capping it to "
|
||||||
"%dms.", (int)cbt->close_ms, 2*max_time);
|
"%dms.", (int)cbt->close_ms, 2*max_time);
|
||||||
|
Loading…
Reference in New Issue
Block a user