Annotate logs around build completion and cancellation
The logs around build completion and cancelations should be annotated with the event that triggered the action. Change-Id: Ifd039d0314a32647a0ec9ebe9bff064e503e0452
This commit is contained in:
@@ -877,14 +877,14 @@ class PipelineManager(object):
|
||||
self.sched.cancelJob(build_set, job, final=True)
|
||||
|
||||
def onBuildCompleted(self, build):
|
||||
log = get_annotated_logger(self.log, build.zuul_event_id)
|
||||
item = build.build_set.item
|
||||
|
||||
self.log.debug("Build %s of %s completed" % (build, item.change))
|
||||
log.debug("Build %s of %s completed" % (build, item.change))
|
||||
|
||||
item.setResult(build)
|
||||
item.pipeline.tenant.semaphore_handler.release(item, build.job)
|
||||
self.log.debug("Item %s status is now:\n %s" %
|
||||
(item, item.formatStatus()))
|
||||
log.debug("Item %s status is now:\n %s", item, item.formatStatus())
|
||||
|
||||
if build.retry:
|
||||
if build.build_set.getJobNodeSet(build.job.name):
|
||||
@@ -899,8 +899,8 @@ class PipelineManager(object):
|
||||
build.failed and build.job.voting):
|
||||
# If fail-fast is set and the build is not successful
|
||||
# cancel all remaining jobs.
|
||||
self.log.debug("Build %s failed and fail-fast enabled, canceling "
|
||||
"running builds", build)
|
||||
log.debug("Build %s failed and fail-fast enabled, canceling "
|
||||
"running builds", build)
|
||||
self._cancelRunningBuilds(build.build_set)
|
||||
|
||||
return True
|
||||
|
||||
Reference in New Issue
Block a user