Browse Source

Report the build execute_time via mqtt

Reporting the execute_time helps to distinguish between the preparation
phase and the actual execution phase.

Change-Id: Ib578efb39cede37996c3516e1a9a251d6ed8a4b0
changes/45/633945/1
Benedikt Loeffler 3 years ago
parent
commit
81f4177559
  1. 1
      tests/unit/test_connection.py
  2. 1
      zuul/driver/mqtt/mqttreporter.py

1
tests/unit/test_connection.py

@ -492,6 +492,7 @@ class TestMQTTConnection(ZuulTestCase):
'test')
self.assertEquals(mqtt_payload['buildset']['builds'][0]['result'],
'SUCCESS')
self.assertIn('execute_time', mqtt_payload['buildset']['builds'][0])
self.assertIn('timestamp', mqtt_payload)
self.assertIn('enqueue_time', mqtt_payload)

1
zuul/driver/mqtt/mqttreporter.py

@ -61,6 +61,7 @@ class MQTTReporter(BaseReporter):
'uuid': build.uuid,
'start_time': build.start_time,
'end_time': build.end_time,
'execute_time': build.execute_time,
'log_url': url,
'result': result,
})

Loading…
Cancel
Save