Skip to content

Extra associated data in 'Commit search' page #11

@benmandrew

Description

@benmandrew

It would be useful to have more information associated with each job, for example:

  • Running time (end_time - start_time)
  • Job status, e.g. waiting to start, started running, failed

Other fields can be requested in comments below.

Current system

The commit search page is currently backed by a database with the following schema:

ci_build_index (
  label  TEXT NOT NULL,
  hash   TEXT NOT NULL,
  job_id TEXT NOT NULL,
  PRIMARY KEY (label, hash, job_id)
)

where job_id is for example linux-arm64-5.0, encoding the OS, architecture, and OCaml version of the job.

On job creation a database record is immediately entered into ci_build_index. We have no current way of modifying existing records, making changing data like those detailed above more difficult to keep in sync.

What would be required

  1. A database migration system would be required to change the deployed DB schema to the one desired. This system already exists in index.ml of ocurrent/ocaml-ci.
  2. DB queries would have to be written to be able to update records.
  3. At all points in the code where relevent job events occur, the right DB queries would have to be run. If any are missed then the in-memory and database state could fall out of sync.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions