Package buildbot :: Package schedulers :: Module forcesched :: Class ForceScheduler
[frames] | no frames]

Class ForceScheduler

source code

 twisted.application.service.Service --+        
                                       |        
twisted.application.service.MultiService --+    
                                           |    
                    util.ComparableMixin --+    
                                           |    
                              object --+   |    
                                       |   |    
                   util.state.StateMixin --+    
                                           |    
                          base.BaseScheduler --+
                                               |
                                              ForceScheduler

ForceScheduler implements the backend for a UI to allow customization of builds. For example, a web form be populated to trigger a build.

Instance Methods
 
__init__(self, name, builderNames, username=UserNameParameter(), reason=StringParameter(name="reason",default="force build",length=20), codebases=None, properties=[NestedParameter(name='',fields=[AnyPropertyParameter("propert..., branch=None, revision=None, repository=None, project=None)
Initialize a ForceScheduler.
source code
 
startService(self) source code
 
stopService(self) source code
 
gatherPropertiesAndChanges(*args, **kwargs) source code
 
force(*args, **kwargs)
We check the parameters, and launch the build, if everything is correct
source code

Inherited from base.BaseScheduler: __provides__, addBuildsetForChanges, addBuildsetForLatest, addBuildsetForSourceStamp, addBuildsetForSourceStampDetails, addBuildsetForSourceStampSetDetails, findNewSchedulerInstance, getPendingBuildTimes, gotChange, listBuilderNames, startConsumingChanges

Inherited from twisted.application.service.MultiService: __iter__, addService, getServiceNamed, privilegedStartService, removeService

Inherited from twisted.application.service.Service: __getstate__, __providedBy__, disownServiceParent, setName, setServiceParent

Inherited from util.ComparableMixin: __cmp__, __hash__

Inherited from util.state.StateMixin: getState, setState

Inherited from object: __delattr__, __format__, __getattribute__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables
  compare_attrs = ('name', 'builderNames', 'reason', 'username',...

Inherited from base.BaseScheduler: DefaultCodebases, __implemented__

Inherited from twisted.application.service.Service: parent, running

Instance Variables

Inherited from base.BaseScheduler: builderNames, name, properties

Properties

Inherited from object: __class__

Method Details

__init__(self, name, builderNames, username=UserNameParameter(), reason=StringParameter(name="reason",default="force build",length=20), codebases=None, properties=[NestedParameter(name='',fields=[AnyPropertyParameter("propert..., branch=None, revision=None, repository=None, project=None)
(Constructor)

source code 

Initialize a ForceScheduler.

The UI will provide a set of fields to the user; these fields are driven by a corresponding child class of BaseParameter.

Use NestedParameter to provide logical groupings for parameters.

The branch/revision/repository/project fields are deprecated and provided only for backwards compatibility. Using a Codebase(name='') will give the equivalent behavior.

Parameters:
  • name (unicode) - name of this scheduler (used as a key for state)
  • builderNames (list of unicode) - list of builders this scheduler may start
  • username - the "owner" for a build (may not be shown depending on the Auth configuration for the master)
  • reason (BaseParameter or None (to disable this field)) - the "reason" for a build
  • codebases (list of string's or CodebaseParameter's; None will generate a default, but [] will remove all codebases) - the codebases for a build
  • properties (list of BaseParameter's) - extra properties to configure the build
Overrides: object.__init__

startService(self)

source code 
Overrides: twisted.application.service.Service.startService

stopService(self)

source code 
Overrides: twisted.application.service.Service.stopService

gatherPropertiesAndChanges(*args, **kwargs)

source code 
Decorators:
  • @defer.inlineCallbacks

force(*args, **kwargs)

source code 

We check the parameters, and launch the build, if everything is correct

Decorators:
  • @defer.inlineCallbacks

Class Variable Details

compare_attrs

Value:
('name', 'builderNames', 'reason', 'username', 'forcedProperties')