Add executor-specific setup time support
This will allow us to make the setup time TTL for k8s-based builds much lower (on the order of a minute), which means faster timeouts and fallbacks (which is a better user experience).
This commit is contained in:
parent
9aac68fbeb
commit
ef41e57aad
3 changed files with 12 additions and 3 deletions
|
@ -55,6 +55,13 @@ class BuilderExecutor(object):
|
|||
""" Name returns the unique name for this executor. """
|
||||
return self.executor_config.get('NAME') or self.__class__.__name__
|
||||
|
||||
@property
|
||||
def setup_time(self):
|
||||
""" Returns the amount of time (in seconds) to wait for the execution to start for the build.
|
||||
If None, the manager's default will be used.
|
||||
"""
|
||||
return self.executor_config.get('SETUP_TIME')
|
||||
|
||||
@coroutine
|
||||
def start_builder(self, realm, token, build_uuid):
|
||||
""" Create a builder with the specified config. Returns a unique id which can be used to manage
|
||||
|
|
Reference in a new issue