Diff
Modified: trunk/Tools/BuildSlaveSupport/ews-build/factories.py (244531 => 244532)
--- trunk/Tools/BuildSlaveSupport/ews-build/factories.py 2019-04-23 00:16:37 UTC (rev 244531)
+++ trunk/Tools/BuildSlaveSupport/ews-build/factories.py 2019-04-23 00:16:48 UTC (rev 244532)
@@ -21,18 +21,16 @@
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-from buildbot.process import factory, properties
+from buildbot.process import factory
from buildbot.steps import trigger
from steps import *
-Property = properties.Property
-
class Factory(factory.BuildFactory):
- def __init__(self, platform, configuration=None, architectures=None, buildOnly=True, additionalArguments=None, checkRelevance=False, **kwargs):
+ def __init__(self, platform, configuration=None, architectures=None, buildOnly=True, triggers=None, additionalArguments=None, checkRelevance=False, **kwargs):
factory.BuildFactory.__init__(self)
- self.addStep(ConfigureBuild(platform, configuration, architectures, buildOnly, additionalArguments))
+ self.addStep(ConfigureBuild(platform, configuration, architectures, buildOnly, triggers, additionalArguments))
if checkRelevance:
self.addStep(CheckPatchRelevance())
self.addStep(ValidatePatch())
@@ -66,25 +64,12 @@
class BuildFactory(Factory):
- def __init__(self, platform, configuration=None, architectures=None, additionalArguments=None, triggers=None, **kwargs):
- Factory.__init__(self, platform, configuration, architectures, False, additionalArguments)
+ def __init__(self, platform, configuration=None, architectures=None, triggers=None, additionalArguments=None, **kwargs):
+ Factory.__init__(self, platform, configuration, architectures, False, triggers, additionalArguments)
self.addStep(KillOldProcesses())
self.addStep(CompileWebKit())
- if triggers:
- self.addStep(trigger.Trigger(schedulerNames=triggers, set_properties=self.propertiesToPassToTriggers() or {}))
- def propertiesToPassToTriggers(self):
- return {
- "patch_id": Property("patch_id"),
- "bug_id": Property("bug_id"),
- "configuration": Property("configuration"),
- "platform": Property("platform"),
- "fullPlatform": Property("fullPlatform"),
- "architecture": Property("architecture"),
- "owner": Property("owner"),
- }
-
class TestFactory(Factory):
LayoutTestClass = None
APITestClass = None
Modified: trunk/Tools/BuildSlaveSupport/ews-build/steps.py (244531 => 244532)
--- trunk/Tools/BuildSlaveSupport/ews-build/steps.py 2019-04-23 00:16:37 UTC (rev 244531)
+++ trunk/Tools/BuildSlaveSupport/ews-build/steps.py 2019-04-23 00:16:48 UTC (rev 244532)
@@ -23,7 +23,7 @@
from buildbot.plugins import steps, util
from buildbot.process import buildstep, logobserver, properties
from buildbot.process.results import Results, SUCCESS, FAILURE, WARNINGS, SKIPPED, EXCEPTION, RETRY
-from buildbot.steps import master, shell, transfer
+from buildbot.steps import master, shell, transfer, trigger
from buildbot.steps.source import git
from buildbot.steps.worker import CompositeStepMixin
from twisted.internet import defer
@@ -43,7 +43,7 @@
description = ["configuring build"]
descriptionDone = ["Configured build"]
- def __init__(self, platform, configuration, architectures, buildOnly, additionalArguments):
+ def __init__(self, platform, configuration, architectures, buildOnly, triggers, additionalArguments):
super(ConfigureBuild, self).__init__()
self.platform = platform
if platform != 'jsc-only':
@@ -52,6 +52,7 @@
self.configuration = configuration
self.architecture = " ".join(architectures) if architectures else None
self.buildOnly = buildOnly
+ self.triggers = triggers
self.additionalArguments = additionalArguments
def start(self):
@@ -65,6 +66,8 @@
self.setProperty('architecture', self.architecture, 'config.json')
if self.buildOnly:
self.setProperty("buildOnly", self.buildOnly, 'config.json')
+ if self.triggers:
+ self.setProperty('triggers', self.triggers, 'config.json')
if self.additionalArguments:
self.setProperty("additionalArguments", self.additionalArguments, 'config.json')
@@ -383,6 +386,23 @@
return not self.doStepIf(step)
+class Trigger(trigger.Trigger):
+ def __init__(self, schedulerNames, **kwargs):
+ set_properties = self.propertiesToPassToTriggers() or {}
+ super(Trigger, self).__init__(schedulerNames=schedulerNames, set_properties=set_properties, **kwargs)
+
+ def propertiesToPassToTriggers(self):
+ return {
+ 'patch_id': properties.Property('patch_id'),
+ 'bug_id': properties.Property('bug_id'),
+ 'configuration': properties.Property('configuration'),
+ 'platform': properties.Property('platform'),
+ 'fullPlatform': properties.Property('fullPlatform'),
+ 'architecture': properties.Property('architecture'),
+ 'owner': properties.Property('owner'),
+ }
+
+
class TestWithFailureCount(shell.Test):
failedTestsFormatString = "%d test%s failed"
failedTestCount = 0
@@ -674,7 +694,15 @@
kwargs['blocksize'] = 1024 * 256
transfer.FileUpload.__init__(self, **kwargs)
+ def finished(self, results):
+ if results == SUCCESS:
+ triggers = self.getProperty('triggers', None)
+ if triggers:
+ self.build.addStepsAfterCurrentStep([Trigger(schedulerNames=triggers)])
+ return super(UploadBuiltProduct, self).finished(results)
+
+
class DownloadBuiltProduct(shell.ShellCommand):
command = ['python', 'Tools/BuildSlaveSupport/download-built-product',
WithProperties('--platform=%(platform)s'), WithProperties('--%(configuration)s'),
Modified: trunk/Tools/ChangeLog (244531 => 244532)
--- trunk/Tools/ChangeLog 2019-04-23 00:16:37 UTC (rev 244531)
+++ trunk/Tools/ChangeLog 2019-04-23 00:16:48 UTC (rev 244532)
@@ -1,3 +1,20 @@
+2019-04-22 Aakash Jain <aakash_j...@apple.com>
+
+ [ews-build] Trigger queues only after uploading the archive
+ https://bugs.webkit.org/show_bug.cgi?id=197180
+
+ Reviewed by Lucas Forschler.
+
+ * BuildSlaveSupport/ews-build/factories.py:
+ (Factory.__init__):
+ (BuildFactory.__init__): Remove trigger step from factories.
+ (BuildFactory.propertiesToPassToTriggers): Deleted.
+ * BuildSlaveSupport/ews-build/steps.py:
+ (ConfigureBuild.__init__): Confiure triggers property.
+ (Trigger): Step to trigger other queues.
+ (Trigger.propertiesToPassToTriggers): Method to construct properties to pass to triggerred builds.
+ (UploadBuiltProduct.finished): Trigger builds after upload is successful.
+
2019-04-22 Alex Christensen <achristen...@webkit.org>
Deprecate WKContextCreateWithInjectedBundlePath