[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [GSoC] Continuous integration tool à la Hydra.

From: Mathieu Lirzin
Subject: Re: [GSoC] Continuous integration tool à la Hydra.
Date: Mon, 25 Jul 2016 02:30:10 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux)

Hello Guix!

Here is a third update on my GSoC project after the second month.

As a reminder, Hydra ( is a Nix-based
continuous build system which is used by Guix to compile packages on
different platforms and to distribute packages substitutes.  The aim of
this project is to replace Hydra with a more integrated software written
in Guile, named “Cuirass”.

Since my second update I have first fixed a major bug.  When building
different branches of Guix and evaluating package derivations the
results were always the same.  The issue was that the evaluations were
happening in the same Guile process which does not play well with module
changes.  To fix that I have used a separate process + pipe to get the
evaluation results.

In the last update, I have introduced usage of SRFI-9 records for
specifications, jobs, and builds.  While they are nice to organize data,
they have major drawbacks:

- not flexible when you want to informally create a container.
- require serialization when passing them throught pipes.

For those reasons I have switched to good ol' alists, which are flexible,
persistant, directly readable and don't require messing with load paths.
The downside is of course that there is no compile time checks when
manipulating data.

As stated in my last update.  I have been working on storing data in a
database.  For that I have decided to use Guile-sqlite3.  The principal
efforts have consist of using an external schema file and design it.

I have come up with this, but this will likely evolve in the future:

--8<---------------cut here---------------start------------->8---
CREATE TABLE Specifications (
  repo_name     TEXT NOT NULL,
  url           TEXT NOT NULL,
  load_path     TEXT NOT NULL,
  file          TEXT NOT NULL,
  proc          TEXT NOT NULL,
  arguments     TEXT NOT NULL,
  -- The following columns are optional.
  branch        TEXT,
  tag           TEXT,
  revision      TEXT

CREATE TABLE Evaluations (
  derivation    TEXT NOT NULL PRIMARY KEY,
  job_name      TEXT NOT NULL,
  specification INTEGER NOT NULL,
  FOREIGN KEY (specification) REFERENCES Specifications (id)

  derivation      TEXT NOT NULL,
  log             TEXT NOT NULL,
  output          TEXT,         -- NULL if build failed
  FOREIGN KEY (derivation) REFERENCES Evaluations (derivation)
--8<---------------cut here---------------end--------------->8---

The next step will be to continue improving the database communication,
and start looking how to implement the HTTP API.

For those willing to follow my work, a Git repository is available here:

Everyone is of course welcome to provide any feedback.


Mathieu Lirzin

reply via email to

[Prev in Thread] Current Thread [Next in Thread]