From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:43263) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dr91S-0003y3-HV for guix-patches@gnu.org; Sun, 10 Sep 2017 16:40:07 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dr91R-0007w9-OG for guix-patches@gnu.org; Sun, 10 Sep 2017 16:40:06 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:51091) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dr91R-0007w5-KB for guix-patches@gnu.org; Sun, 10 Sep 2017 16:40:05 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1dr91R-0000jd-BY for guix-patches@gnu.org; Sun, 10 Sep 2017 16:40:05 -0400 Subject: [bug#27876] [PATCH v2 1/3] cuirass: Store new information in database to prepare new HTTP API integration. Resent-Message-ID: From: ludo@gnu.org (Ludovic =?UTF-8?Q?Court=C3=A8s?=) References: <20170730100759.17734-1-m.othacehe@gmail.com> <20170801195124.7030-1-m.othacehe@gmail.com> <87o9ql89lp.fsf@gnu.org> <87pob1m2bk.fsf@gmail.com> <871sngapjy.fsf@gnu.org> <87lglomhxo.fsf@gmail.com> <878thm907s.fsf@gnu.org> <87a822vg4r.fsf@gmail.com> Date: Sun, 10 Sep 2017 22:38:59 +0200 In-Reply-To: <87a822vg4r.fsf@gmail.com> (Mathieu Othacehe's message of "Sun, 10 Sep 2017 15:26:44 +0200") Message-ID: <87shfu5lwc.fsf@gnu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: Mathieu Othacehe Cc: 27876-done@debbugs.gnu.org Howdy, Mathieu Othacehe skribis: >> Basically, between two subsequent evaluations, 99% of the derivations >> are exactly the same (assuming an evaluation is triggered at each git >> push, and each git push adds/modifies just a handful of packages). If >> we record new builds for these 99%, even though nothing has changed, >> then that=E2=80=99s potentially bad, no? > > Hmm, you're right but the situation is already problematic. > > On each evaluation, N new entries will appear in Derivations table > (because the primary key is on derivation,evaluation tuple). > > N new entries will also appear in Builds table (both with primary key on > id or on derivation,evaluation,output tuple). > > When build start/stop will be detected, only a small part of N > (derivations which were rebuilt), will be added to Builds. Checking for > pre-existing builds with the same derivation will become useless unless > I'm wrong. > > So there's still the problem of Derivations table growing from N at each > commit. I'm not sure what to do about it. Maybe removing the > "evaluation" field, and puting primary key on "derivation" only would be > better ? You=E2=80=99re right, I don=E2=80=99t know off the top of my head. Perhaps= we should check the schemas that Hydra uses, it should be similar. Future work! Ludo=E2=80=99.