summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorMattia Rizzolo <mattia@mapreri.org>2015-09-12 11:31:09 +0000
committerHolger Levsen <holger@layer-acht.org>2015-09-12 16:35:48 +0200
commita6eada0f94cb015c4c57cd3dd117656fdb5d5793 (patch)
treed73ad565ab813211089fc674e356dbda6e8b5a73 /bin
parenteb6591ab06a5a635573e841ad4ec1d72259c1240 (diff)
downloadjenkins.debian.net-a6eada0f94cb015c4c57cd3dd117656fdb5d5793.tar.xz
reproducible: scheduler: add a comment to explain how LIMITS work
Diffstat (limited to 'bin')
-rwxr-xr-xbin/reproducible_scheduler.py17
1 files changed, 16 insertions, 1 deletions
diff --git a/bin/reproducible_scheduler.py b/bin/reproducible_scheduler.py
index 2d0e6701..26f6783b 100755
--- a/bin/reproducible_scheduler.py
+++ b/bin/reproducible_scheduler.py
@@ -26,7 +26,22 @@ from reproducible_html_live_status import generate_schedule
from reproducible_html_packages import gen_packages_html
from reproducible_html_packages import purge_old_pages
-# FIXME: these limits were understandable when the code was merged but now need some explaination
+"""
+How the scheduler chose which limit to apply:
+everything depends on how many packages are already scheduled, in a 3 steps
+process. Let's go by an example:
+ 'unstable': {1: (250, 40), 2: (350, 20), '*': 5},
+if total < 250:
+ 40
+elif total < 350:
+ 20
+else:
+ 5
+ * 1st step, if there are less than 250 packages in the queue, schedule 40
+ * 2nd step, if there are less than 350 packages in the queue, schedule 20
+ * 3rd step, schedule 5
+So, the 3rd step happens only when there are more than 350 packages queued up.
+"""
LIMITS = {
'untested': {
'amd64': {