Slightly randomize all timeouts.
This commit is contained in:
parent
717ea66d7b
commit
edc08b73a9
6 changed files with 11 additions and 11 deletions
|
|
@ -282,7 +282,7 @@ void retry_outgoing(outgoing_t *outgoing) {
|
|||
outgoing->timeout = maxtimeout;
|
||||
|
||||
timeout_set(&outgoing->ev, retry_outgoing_handler, outgoing);
|
||||
event_add(&outgoing->ev, &(struct timeval){outgoing->timeout, 0});
|
||||
event_add(&outgoing->ev, &(struct timeval){outgoing->timeout, rand() % 100000});
|
||||
|
||||
logger(DEBUG_CONNECTIONS, LOG_NOTICE,
|
||||
"Trying to re-establish outgoing connection in %d seconds",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue