The bandwidth history interval may soon change from 900 seconds to something else. Make sure that this doesn't break the parser. Related to #13838 and 13988.
- Use properties to build impl classes in DescriptorSourceFactory. - Move DescriptorParseException out of impl package. For extra backward compatibility, keep a copy of that class in impl, but deprecate it. - Tidy up the build file. Patch by iwakeh. Implements #12868.
Example of a valid line that is now allowed: bridge-ip-transports meek=32,obfs3_websocket=8,websocket=64
Extra-info descriptors contain lots of comma-separated key=value lists that we store in SortedMap instances. But those occupy a lot of memory, and it's not certain that we'll ever want to use the contained keys or values. New approach: when parsing a descriptor, use regular expressions to check if lines are valid, and delay parsing into maps until needed.
Related to 5caa384. Similarly, keeping these sets around just wastes heap space.
If we can easily determine the number of List or Set elements, we can as well store their contents in arrays and convert those to List or Set instances when requested. This can save us some memory and doesn't cost much performance.
Better fix for #12403.