summaryrefslogtreecommitdiff
path: root/apt-pkg/contrib/srvrec.h
AgeCommit message (Collapse)Author
2017-07-12Reformat and sort all includes with clang-formatJulian Andres Klode
This makes it easier to see which headers includes what. The changes were done by running git grep -l '#\s*include' \ | grep -E '.(cc|h)$' \ | xargs sed -i -E 's/(^\s*)#(\s*)include/\1#\2 include/' To modify all include lines by adding a space, and then running ./git-clang-format.sh.
2015-10-30srvrec: Do not expose C++11 tuple use in headerJulian Andres Klode
This makes non-C++11 reverse deps wishing to use it FTBFS.
2015-09-14srv test: do 100 pulls twice and compare listDavid Kalnischkies
The previous implementation was still a bit unstable in terms of failing at times. Lets try if we have more luck with this one. Git-Dch: Ignore
2015-09-01use clock() as source for SRV randomnessDavid Kalnischkies
Initializing a random number generator with the time since epoch could be good enough, but reaches its limits in test code as the 100 iterations might very well happen in the same second and hence the seed number is always the sameā€¦ clock() has a way lower resolution so it changes more often and not unimportant: If many users start the update at the same time it isn't to unlikely the SRV record will be ordered in the same second choosing the same for them all, but it seems less likely that the exact same clock() time has passed for them. And if I have to touch this, lets change a few other things as well to make me and/or compilers a bit happier (clang complained about the usage of a GNU extension in the testcase for example).
2015-08-20Add basic (non weight adjusted) shuffling for SrvRecords selectionMichael Vogt
Also add "Debug::Acquire::SrvRecs" debug option and the option "Acquire::EnableSrvRecods" to allow disabling this lookup.
2015-08-18cleanupMichael Vogt
2014-05-23WIP start randomizingMichael Vogt
2014-05-22WIP make connect use GetSrvRecordsMichael Vogt
2014-05-20add sorting by priorityMichael Vogt
2014-05-20add GetSrvRecord helper to apt-pkg/contrib/srvrec.{cc,h}Michael Vogt