[Lsb-messages] /var/www/bzr/lsb/devel/buildbot-config r302: Add ForceScheduler to schedulers.

Jeff Licquia licquia at linuxfoundation.org
Sat Oct 27 19:34:10 UTC 2012


------------------------------------------------------------
revno: 302
committer: Jeff Licquia <licquia at linuxfoundation.org>
branch nick: buildbot-config
timestamp: Sat 2012-10-27 15:34:10 -0400
message:
  Add ForceScheduler to schedulers.
  
  This is new in buildbot 0.8.6, and is required to maintain the ability
  to force builds via the status targets.
modified:
  lsb_master.cfg
-------------- next part --------------
=== modified file 'lsb_master.cfg'
--- a/lsb_master.cfg	2012-09-28 21:00:42 +0000
+++ b/lsb_master.cfg	2012-10-27 19:34:10 +0000
@@ -19,6 +19,12 @@
 
 import lfbuildbot
 
+# ForceSchedulers are new for 0.8.6; don't fail if it's not present.
+try:
+    from buildbot.schedulers.forcesched import ForceScheduler
+except ImportError:
+    ForceScheduler = None
+
 # This buildbot config file defines the LSB builds that are needed.
 # 
 # Each project needs one build per architecture; this includes the
@@ -347,33 +353,39 @@
 #sch_build = scheduler.Nightly(name="build-sdk", branch=None,
 #                              builderNames=sch_sdk_names, hour=19, minute=0)
 
-# Accept multiple jobs via a job directory.  Since we have to report
-# which builders we might start, create a list of all projects to pass
-# in.
+# Since we have to report a list of all builders to several schedulers,
+# create a list of all projects to pass in.
 
-multi_builder_list = sch_sdk_names[:]
+all_builder_list = sch_sdk_names[:]
 
 arch_prj_list = lsb_pkg_subdir_projects.keys() + \
     ["appbat", "libbat"] + [x[0] for x in lsb_packaging_projects]
 
 for prj in arch_prj_list:
     if prj in lsb_arch_indep_projects:
-        multi_builder_list.append("%s-%s" % (prj, 
-                                             lsb_buildslave_arch_indep_arch))
+        all_builder_list.append("%s-%s" % (prj, 
+                                           lsb_buildslave_arch_indep_arch))
     else:
         for arch in lsb_archs:
-            multi_builder_list.append("%s-%s" % (prj, arch))
+            all_builder_list.append("%s-%s" % (prj, arch))
 
 for devchk_job in ["devchk", "build-sdk"]:
-    multi_builder_list.extend([devchk_job + "-" + x 
-                               for x in devchk_build_slaves])
+    all_builder_list.extend([devchk_job + "-" + x 
+                             for x in devchk_build_slaves])
+
+# ForceScheduler, for forcing builds via one of the status targets.
+
+if ForceScheduler:
+    sch_force = ForceScheduler(name="force", builderNames=all_builder_list)
+
+# Accept multiple jobs via a job directory.
 
 jobdir_repos = dict(lsb_packaging_projects)
 jobdir_repos["build-sdk"] = "build_env"
 jobdir_repos["libbat"] = "appbat"
 
 sch_jobdir = lfbuildbot.MultiScheduler(
-    name="sch_jobdir", builderNames=multi_builder_list, 
+    name="sch_jobdir", builderNames=all_builder_list, 
     jobdir="/opt/buildbot/jobdir", repos=jobdir_repos, archs=lsb_archs, 
     indep_prj=lsb_arch_indep_projects,
     indep_arch=lsb_buildslave_arch_indep_arch,
@@ -400,6 +412,8 @@
 # Set up first static set of schedulers.
 
 c['schedulers'] = [sch_jobdir, sch_devchk, sch_sdk]
+if ForceScheduler:
+    c['schedulers'].append(sch_force)
 
 # The rest of the schedulers (except the weekly one) react to events, 
 # such as a previous build succeeding or a change in version control,



More information about the lsb-messages mailing list