From Fedora Project Wiki

< CI

Revision as of 12:44, 21 June 2018 by Psss (talk | contribs) (Initial version)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Introduction

This document specifies details of messages, which should be sent out by Upstream/Downstream CI systems to fedmsg/UMB on events related to artifacts testing. Currently there is low unification of these messages and there are various types of messages sent out by the CI systems. Unification will make it possible to build simpler microservices which will provide useful features for everyone.

Namespace

The messages will use a unique UMB virtual topic namespace to mitigate collisions with other systems:

  • UMB: /topic/VirtualTopic.eng.ci
  • fedmsg: org.fedoraproject.prod.ci

For all the tests on all the artifacts the systems will use this topic naming convention:

  • UMB: /topic/VirtualTopic.eng.ci.<artifact>.test.{queued,running,complete,error}
  • fedmsg: org.fedoraproject.prod.ci.<artifact>.test.{queued,running,complete,error}

where

  • <artifact> - is one of the tested artifacts, see ARTIFACT special field definition, i.e. brew-build, redhat-container-image etc.
  • queued (optional) - testing has been queued, but not yet started
  • running (optional) - testing has been started and is in progress
  • complete (mandatory) - testing has been completed
  • error (mandatory) - testing has aborted, it was not finished (e.g. because of infrastructure error, CI system error, etc.)

Note that a test failure is not an error. Test failures should be exposed under the ci.test.complete topic.


Messages Anatomy

This section defines the contents of the messages without headers. All data should be stored in the body of the message. Additional fields can be added to the messages as required by the senders, although it is advised to document them here.

Syntax requirements for field names

  • Use only characters [a-z0-9_]
  • No spaces are allowed in the name of the field
  • For separation of multi-word strings in field names use the underscore character
  • Boolean value must be one of “true” or “false”

Requirements for field values

  • If a field contains multiple values a list must be used for it
  • e.g. recipients: [ “mvadkert”, “optak” ]

Special field values

ARTIFACT

Can be one of the defined build artifacts. This includes: