Permalink
Browse files

Bug 520227 - fixing merging issues for try builds - now using NoMerge…

…Scheduler in misc.py p=lsblakk r=catlee
  • Loading branch information...
1 parent ebff0e1 commit 3c00c04b3a60fd8ad4a8cff92d5b1d9583adf699 @lsblakk lsblakk committed Mar 12, 2010
Showing with 11 additions and 22 deletions.
  1. +9 −4 misc.py
  2. +2 −18 scheduler.py
View
13 misc.py
@@ -502,15 +502,20 @@ def generateBranchObjects(config, name):
# schedulers
# this one gets triggered by the HG Poller
- mergeBuilds=config.get('enable_merging', True)
- branchObjects['schedulers'].append(MozScheduler(
+ extra_args = {}
+ if config.get('enable_merging'):
+ schedulerClass = MozScheduler
+ extra_args['idleTimeout'] = config.get('idle_timeout', None)
+ else:
+ schedulerClass = NoMergeScheduler
+
+ branchObjects['schedulers'].append(schedulerClass(
name=name,
branch=config['repo_path'],
treeStableTimer=3*60,
- idleTimeout=config.get('idle_timeout', None),
builderNames=builders + unittestBuilders + debugBuilders,
fileIsImportant=lambda c: isHgPollerTriggered(c, config['hgurl']),
- mergeBuilds=mergeBuilds,
+ **extra_args
))
for scheduler_branch, test_builders, merge in triggeredUnittestBuilders:
View
@@ -30,8 +30,7 @@ class MozScheduler(Scheduler):
'fileIsImportant', 'properties', 'idleTimeout')
def __init__(self, name, branch, treeStableTimer, builderNames,
- idleTimeout=None, fileIsImportant=None, mergeBuilds=True,
- properties={}):
+ idleTimeout=None, fileIsImportant=None, properties={}):
"""
@param name: the name of this Scheduler
@param branch: The branch name that the Scheduler should pay
@@ -58,9 +57,6 @@ def __init__(self, name, branch, treeStableTimer, builderNames,
build is triggered by an important change.
The default value of None means that all
Changes are important.
-
- @param mergeBuilds: set to True by default since most schedulers expect merged
- builds, if set to false there will be no merging of builds
@param properties: properties to apply to all builds started from this
scheduler
@@ -87,19 +83,7 @@ def stopTimer(self):
self.idleTimer = None
def fireTimer(self):
- if self.mergeBuilds:
- Scheduler.fireTimer(self)
- else:
- for change in self.importantChanges:
- changes = [change]
- if self.unimportantChanges:
- changes.extend(self.unimportantChanges)
- self.unimportantChanges = []
- # submit
- ss = NoMergeSourceStamp(changes=changes)
- bs = buildset.BuildSet(self.builderNames, ss)
- self.submitBuildSet(bs)
- self.importantChanges = []
+ Scheduler.fireTimer(self)
self.setIdleTimer()
def doIdleBuild(self):

0 comments on commit 3c00c04

Please sign in to comment.