Extend descriptorCutOff by 6 hours.

Fixes #19828.
This commit is contained in:
Karsten Loesing 2020-03-09 12:17:39 +01:00
parent 2b90d656d1
commit a87ce0d02f
2 changed files with 8 additions and 2 deletions

View File

@ -4,6 +4,10 @@
- Simplify logging configuration.
- Set default locale `US` and default time zone `UTC` at the
beginning of the execution.
- Download missing server and extra-info descriptors that have been
published up to 30 hours ago: 24 hours for the maximum age of
descriptors to be referenced plus 6 hours for the time between
generating votes and processing a consensus.
# Changes in version 1.14.1 - 2020-01-16

View File

@ -183,7 +183,9 @@ public class RelayDescriptorDownloader {
/**
* Cut-off time for missing server and extra-info descriptors, formatted
* "yyyy-MM-dd HH:mm:ss". This time is initialized as the current system
* time minus 24 hours.
* time minus 30 hours (24 hours for the maximum age of descriptors to be
* referenced plus 6 hours for the time between generating votes and
* processing a consensus).
*/
private String descriptorCutOff;
@ -329,7 +331,7 @@ public class RelayDescriptorDownloader {
long now = System.currentTimeMillis();
this.currentValidAfter = format.format((now / (60L * 60L * 1000L))
* (60L * 60L * 1000L));
this.descriptorCutOff = format.format(now - 24L * 60L * 60L * 1000L);
this.descriptorCutOff = format.format(now - 30L * 60L * 60L * 1000L);
this.currentTimestamp = format.format(now);
this.downloadAllDescriptorsCutOff = format.format(now
- 23L * 60L * 60L * 1000L - 30L * 60L * 1000L);