summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorHolger Levsen <holger@layer-acht.org>2016-01-18 20:59:18 +0100
committerHolger Levsen <holger@layer-acht.org>2016-01-18 20:59:18 +0100
commitc550b4f24995c54d3744cf56ebf5bf2e3979758c (patch)
tree9be8ca7cb23b9241640723516bd69361cc898945 /bin
parent04408e63e4f70e147901cc88269f0423cda0a2b8 (diff)
downloadjenkins.debian.net-c550b4f24995c54d3744cf56ebf5bf2e3979758c.tar.xz
reproducible: schedule 255 packages with status 404 (and refactor)
Diffstat (limited to 'bin')
-rwxr-xr-xbin/reproducible_scheduler.py17
1 files changed, 10 insertions, 7 deletions
diff --git a/bin/reproducible_scheduler.py b/bin/reproducible_scheduler.py
index b9dece33..99acd349 100755
--- a/bin/reproducible_scheduler.py
+++ b/bin/reproducible_scheduler.py
@@ -39,6 +39,8 @@ Then, for each category (totally _untested_ packages, _new_ versions,
_ftbfs+depwait_ packages and _old_ versions) it depends on how many packages are
already scheduled in that category, in a 3 steps process.
+Only when scheduling old versions MINIMUM_AGE is respected.
+
Let's go by an example:
'unstable': {1: (250, 40), 2: (350, 20), '*': 5},
@@ -58,11 +60,14 @@ else:
So, the 3rd step happens only when there are more than 350 packages queued up.
-Finally, MINIMUM_AGE is respected when scheduling old versions.
+LIMITS_404 defines how many packages with status 404 are rescheduled at max.
"""
+# only old packages older than this will be rescheduled
+MINIMUM_AGE = {'amd64': 7, 'armhf': 28}
+# maximum queue size, see explainations above
MAXIMA = {'amd64': 750, 'armhf': 600}
-
+# limits, see explainations above
LIMITS = {
'untested': {
'amd64': {
@@ -113,9 +118,8 @@ LIMITS = {
}
}
}
-
-# only old packages older than this will be rescheduled
-MINIMUM_AGE = {'amd64': 7, 'armhf': 28}
+# maximum amount of packages with status 404 which will be rescheduled
+LIMIT_404 = 255
class Limit:
@@ -477,8 +481,7 @@ def schedule_404_versions(arch, total):
for suite in SUITES:
log.info('Requesting 404 packages in %s/%s...',
suite, arch)
- # hard code the limit to 42 as 404s rarely happen anyway
- packages[suite] = query_404_versions(suite, arch, 42)
+ packages[suite] = query_404_versions(suite, arch, LIMIT_404)
log.info('Received ' + str(len(packages[suite])) +
' 404 packages in ' + suite + '/' + arch + ' to schedule.')
log.info('--------------------------------------------------------------')