Previous: Merging Build Requests, Up: Builders

4.10.3 Prioritizing Builds

The BuilderConfig parameter nextBuild can be use to prioritize build requests within a builder. Note that this is orthogonal to see Prioritizing Builders, which controls the order in which builders are called on to start their builds.

     def nextBuild(bldr, requests):
         for r in requests:
             if r.source.branch == 'release':
                 return r
         return requests[0]
     c['builders'] = [
       BuilderConfig(name='test', factory=f,
             slavenames=['slave1', 'slave2', 'slave3', 'slave4']),