From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:470:142:3::10]:57378) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ihDuJ-0006OC-GP for guix-patches@gnu.org; Tue, 17 Dec 2019 09:33:04 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ihDuI-0007jQ-FT for guix-patches@gnu.org; Tue, 17 Dec 2019 09:33:03 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:34917) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1ihDuI-0007ih-C9 for guix-patches@gnu.org; Tue, 17 Dec 2019 09:33:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ihDuI-0004C5-8Y for guix-patches@gnu.org; Tue, 17 Dec 2019 09:33:02 -0500 Subject: [bug#38649] [PATCH] Parallelize `guix package` Resent-Message-ID: From: Ludovic =?UTF-8?Q?Court=C3=A8s?= References: Date: Tue, 17 Dec 2019 15:32:10 +0100 In-Reply-To: (Leo Prikler's message of "Tue, 17 Dec 2019 15:18:44 +0100") Message-ID: <87tv5zrpjp.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: Leo Prikler Cc: julien lepiller , 38649@debbugs.gnu.org Hi Leo, (Cc: Julien, who worked on this part.) Leo Prikler skribis: > Yesterday I had an interesting conversation on IRC about the behaviour > of multiple `guix package` processes running in parallel.=20 > Specifically, when two transactions target the same profile (usually > /var/guix/profiles/per-user/$USER/guix-profile) at the same time, one > of them will fail to claim the lock and abort. 0001 makes it so that > the process waits for the lock. 0002 makes it so that packages > specified via -i can be built in parallel. I actually like the current behavior, FWIW. Julien came up with this locking mostly so that people do not inadvertently attempt to perform several operations concurrently. The key word here is =E2=80=9Cinadvertently=E2=80=9D: IMO, there=E2=80=99s = no reason to run multiple =E2=80=98guix package=E2=80=99 on the same profile concurrently. = With a wait-for-lock policy, the result would be non-deterministic: you cannot tell which one of the two processes will complete first. WDYT? Thanks, Ludo=E2=80=99.