Finishes task-20162: removed six configuration properties:

DownloadCurrentConsensus,
DownloadCurrentMicrodescConsensus,
DownloadCurrentVotes,
DownloadMissingServerDescriptors,
DownloadMissingExtraInfoDescriptors,
and DownloadMissingMicrodescriptors

Each was replaced by hard-coded 'true'.
This commit is contained in:
iwakeh 2016-10-18 15:59:07 +02:00 committed by Karsten Loesing
parent 0397899166
commit 8bb7de37ad
5 changed files with 5 additions and 35 deletions

View File

@ -5,6 +5,8 @@
descriptors by a single 'OutPath' property.
- Introduced *Sources and *Origins properties to simplify
data source definition.
- Remove six properties for specifying what relay descriptors to
download and replace them with hard-coded 'true' values.
# Changes in version 1.0.2 - 2016-10-07

View File

@ -49,12 +49,6 @@ public enum Key {
CompressRelayDescriptorDownloads(Boolean.class),
DirectoryAuthoritiesAddresses(String[].class),
DirectoryAuthoritiesFingerprintsForVotes(String[].class),
DownloadCurrentConsensus(Boolean.class),
DownloadCurrentMicrodescConsensus(Boolean.class),
DownloadCurrentVotes(Boolean.class),
DownloadMissingServerDescriptors(Boolean.class),
DownloadMissingExtraInfoDescriptors(Boolean.class),
DownloadMissingMicrodescriptors(Boolean.class),
DownloadAllServerDescriptors(Boolean.class),
DownloadAllExtraInfoDescriptors(Boolean.class),
KeepDirectoryArchiveImportHistory(Boolean.class),

View File

@ -154,12 +154,8 @@ public class ArchiveWriter extends CollecTorMain {
config.getStringArray(Key.DirectoryAuthoritiesAddresses);
rdd = new RelayDescriptorDownloader(rdp, dirSources,
config.getStringArray(Key.DirectoryAuthoritiesFingerprintsForVotes),
config.getBool(Key.DownloadCurrentConsensus),
config.getBool(Key.DownloadCurrentMicrodescConsensus),
config.getBool(Key.DownloadCurrentVotes),
config.getBool(Key.DownloadMissingServerDescriptors),
config.getBool(Key.DownloadMissingExtraInfoDescriptors),
config.getBool(Key.DownloadMissingMicrodescriptors),
true, true, true, // download current consensus, microcons, and votes
true, true, true, // download missing serverdesc, extrainfo, and micro
config.getBool(Key.DownloadAllServerDescriptors),
config.getBool(Key.DownloadAllExtraInfoDescriptors),
config.getBool(Key.CompressRelayDescriptorDownloads));

View File

@ -95,28 +95,6 @@ DirectoryAuthoritiesAddresses = 128.31.0.39:9131,86.59.21.38,194.109.206.212,131
## votes
DirectoryAuthoritiesFingerprintsForVotes = 0232AF901C31A04EE9848595AF9BB7620D4C5B2E,14C131DFC5C6F93646BE72FA1401C02A8DF2E8B4,23D15D965BC35114467363C165C4F724B64B4F66,49015F787433103580E3B66A1707A00E60F2D15B,D586D18309DED4CD6D57C18FDB97EFA96D330566,E8A9C45EDE6D711294FADF8E7951F4DE6CA56B58,ED03BB616EB2F60BEC80151114BB25CEF515B226,EFCBE720AB3A82B99F9E953CD5BF50F7EEFC7B97
#
## Download the current consensus (only if DownloadRelayDescriptors is 1)
DownloadCurrentConsensus = true
#
## Download the current microdesc consensus (only if
## DownloadRelayDescriptors is true)
DownloadCurrentMicrodescConsensus = true
#
## Download current votes (only if DownloadRelayDescriptors is true)
DownloadCurrentVotes = true
#
## Download missing server descriptors (only if DownloadRelayDescriptors
## is true)
DownloadMissingServerDescriptors = true
#
## Download missing extra-info descriptors (only if
## DownloadRelayDescriptors is true)
DownloadMissingExtraInfoDescriptors = true
#
## Download missing microdescriptors (only if
## DownloadRelayDescriptors is true)
DownloadMissingMicrodescriptors = true
#
## Download all server descriptors from the directory authorities at most
## once a day (only if DownloadRelayDescriptors is true)
DownloadAllServerDescriptors = false

View File

@ -41,7 +41,7 @@ public class ConfigurationTest {
public void testKeyCount() throws Exception {
assertEquals("The number of properties keys in enum Key changed."
+ "\n This test class should be adapted.",
50, Key.values().length);
44, Key.values().length);
}
@Test()