Add zuul version to status.json

It'll help us to determine whether we're running a version of zuul that has
added support for some new feature.

The version_string() from pbr's version_info used to collect zuul version.

Change-Id: Id451f15538258ab2dec8e3e8f000cff4a8b7b20d
This commit is contained in:
Sergey Lukjanov 2013-12-27 01:21:04 +04:00
parent aea6cf6487
commit 5ba961bcc8
1 changed files with 6 additions and 0 deletions

View File

@ -31,6 +31,7 @@ import layoutvalidator
import model
from model import ActionReporter, Pipeline, Project, ChangeQueue, EventFilter
import merger
from zuul import version as zuul_version
statsd = extras.try_import('statsd.statsd')
@ -130,6 +131,8 @@ class Scheduler(threading.Thread):
self.management_event_queue = Queue.Queue()
self.layout = model.Layout()
self.zuul_version = zuul_version.version_info.version_string()
def stop(self):
self._stopped = True
self.wake_event.set()
@ -761,6 +764,9 @@ class Scheduler(threading.Thread):
def formatStatusJSON(self):
data = {}
data['zuul_version'] = self.zuul_version
if self._pause:
ret = '<p><b>Queue only mode:</b> preparing to '
if self._exit: