Parcourir la source

Use exponential backoff for router descriptor downloads from consensuses

Andrea Shepard il y a 8 ans
Parent
commit
6370c4ee87
1 fichiers modifiés avec 2 ajouts et 0 suppressions
  1. 2 0
      src/or/routerparse.c

+ 2 - 0
src/or/routerparse.c

@@ -3204,6 +3204,8 @@ networkstatus_parse_vote_from_string(const char *s, const char **eos_out,
                                                      NULL, NULL,
                                                      ns->consensus_method,
                                                      flav)))
+        /* Use exponential-backoff scheduling when downloading microdescs */
+        rs->dl_status.backoff = DL_SCHED_RANDOM_EXPONENTIAL;
         smartlist_add(ns->routerstatus_list, rs);
     }
   }