From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms9.migadu.com with LMTPS id UKyzCbgcWGS69AAASxT56A (envelope-from ) for ; Sun, 07 May 2023 23:48:40 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id IIulCbgcWGSUKgEA9RJhRA (envelope-from ) for ; Sun, 07 May 2023 23:48:40 +0200 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id E140CA009 for ; Sun, 7 May 2023 23:48:39 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pvmEw-0004KY-E9; Sun, 07 May 2023 17:48:22 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pvmEv-0004KP-GH for guix-devel@gnu.org; Sun, 07 May 2023 17:48:21 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pvmEv-0001eD-8h for guix-devel@gnu.org; Sun, 07 May 2023 17:48:21 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:Date:Subject:To:From:in-reply-to: references; bh=KXHszNXExWXb2kHMuHr3I2SSalAdKtB1hmtjD5R+9NM=; b=ThaUd8RZ2DfrhC D87wZ+y7PjmtSmSOKwl6XMaIPaCngBxPbRNhdiuFuqJsqSzzZYr2gXh2gWRFNb0rUHap0Z2iwJ8IE pIIUOzKRtlIACn+7mqefgx3k3f7eCCAkb3ydVOCL2CxAWXfFTbJw+LEwUpQnT/fbnsQpJZB32DazT l0+byuWEQTEqZY5ESj/1Up++nhmCbIqsNHw2/xuvcfqfgQvyC4ntmNlIbvr4zDjtEgxgP8WXqoKpf 4KyprhiK6ZOKcjJYi/G4Z9oRPj9uXxBYR6vuiCYRMJ7JE9sBDbPnwREIUcxUVESXMtET9x9OXBz4A ZEUkERXv8A3nbkgrPiyQ==; Received: from 91-160-117-201.subs.proxad.net ([91.160.117.201] helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pvmEu-00072U-SC for guix-devel@gnu.org; Sun, 07 May 2023 17:48:21 -0400 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: Guix Devel Subject: GNU Shepherd 0.10.0rc2 available for testing! X-URL: http://www.fdn.fr/~lcourtes/ X-Revolutionary-Date: Octidi 18 =?utf-8?Q?Flor=C3=A9al?= an 231 de la =?utf-8?Q?R=C3=A9volution=2C?= jour de la Corbeille-d'or X-PGP-Key-ID: 0x090B11993D9AEBB5 X-PGP-Key: http://www.fdn.fr/~lcourtes/ludovic.asc X-PGP-Fingerprint: 3CE4 6455 8A84 FDC6 9DB4 0CFB 090B 1199 3D9A EBB5 X-OS: x86_64-pc-linux-gnu Date: Sun, 07 May 2023 23:48:18 +0200 Message-ID: <877ctjg6e5.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" X-BeenThere: guix-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+larch=yhetil.org@gnu.org Sender: guix-devel-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Seal: i=1; s=key1; d=yhetil.org; t=1683496120; a=rsa-sha256; cv=none; b=exZjfvMTLSpXozoL4zmHb+8az6pVFy05jGFQIxKanjGde6W+0K/CJvPCzoearkeggHauHO a3uHaeAYr94/psEpWA3dQBdrZJaCp9vnZWzLP9g1y8Ar7w+vRXF6pkbqPV7USFd/aDfaDL HdniHNkfJ2j88ZLcNr/Udkct5ZBS0NiqXuc4af3NcaSgDc1Rgui5H6G49S9c1Ygd8LfjDh P62flRIKB4G1iUL4J5WhoijxvjhFVxmgNlDNs4rlYS0lzL8UNZGkF+q8qeGKvmTOE7W/UC iLlMdPPW527FBI7vKgpQ/WR1bTJmkRL9PiM86CFPsOHvkV0a/4X5eZhk/zGKTg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gnu.org header.s=fencepost-gnu-org header.b=ThaUd8RZ; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "guix-devel-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-devel-bounces+larch=yhetil.org@gnu.org" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1683496120; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=KXHszNXExWXb2kHMuHr3I2SSalAdKtB1hmtjD5R+9NM=; b=M+iDIGOISotclN12RoiqpcweIyfuKfzLELB8vajAvA3pBshtNh1OawFBnGmqzxGYuAx2p1 8DajuDD3DZoS0z/aMY9EKRWxmSF7YE250nIhHJ1qxgovVZx/bsdhhgSAhXTQDA8zv2xuZT vC72kv1LMCW0C1IxaO+10lUFaDfFgx1QBK6XbzU6uJxmdFfl1P8je0QVo6mP0u9Z2s088J NodAfod9ssFdmBFdw7An6stTZG+ZgTgN4NYsILot8ebQSQYJq2llN7Urf5fOZoorHVd3y7 mUFnxvwlzLBu/hmdKuBXboICw6zdt7Xj9+HOHt5i94mtZ8CbUUGctn7b6+aRzw== X-Migadu-Scanner: scn1.migadu.com Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gnu.org header.s=fencepost-gnu-org header.b=ThaUd8RZ; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "guix-devel-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-devel-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -8.28 X-Spam-Score: -8.28 X-Migadu-Queue-Id: E140CA009 X-TUID: Sw8aDm3Pf7uL --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Hello Guix! I am pleased to announce that the second and hopefully last release candidate of version 0.10.0 of the GNU Shepherd is available for testing! There have been 16 commits since 0.10.0rc1=C2=B9: a couple of bug fixes and improvements to tests that were flaky or racy. If you=E2=80=99re using Guix System or Guix Home, check out the instructions below to give it a try. Please report success or failure! If you had problems with previous versions, please check if they=E2=80=99re still ther= e. code: https://alpha.gnu.org/gnu/shepherd/shepherd-0.10.0rc2.tar.gz signature: https://alpha.gnu.org/gnu/shepherd/shepherd-0.10.0rc2.tar.gz.s= ig sha256: 0hqqj1m6aa85m0nc2yikl72kqkqmg8xp90cglxf4843jwm4m8rwz In your operating system configuration (and similarly for your =E2=80=98home-environment=E2=80=99), make the following changes: (use-modules (gnu packages admin)) (define shepherd-next (package (inherit shepherd) (version "0.10.0rc2") (source (origin (method url-fetch) (uri (string-append "https://alpha.gnu.org/gnu/shepherd/shepherd-" version ".tar.gz")) (sha256 (base32 "0hqqj1m6aa85m0nc2yikl72kqkqmg8xp90cglxf4843jwm4m8rwz")))= ))) (operating-system ;; =E2=80=A6 (essential-services (modify-services (operating-system-default-essential-services this-operating-system) (shepherd-root-service-type config =3D> (shepherd-configuration (shepherd shepherd-next)))))) You can then reconfigure, reboot, and enjoy! You can also help with translation: https://translationproject.org/domain/shepherd.html My goal is for 0.10.x to be the last series before 1.0. The list of changes is quite long=E2=80=94see the =E2=80=98NEWS=E2=80=99 excerpt below. Feedback more than welcome! Ludo=E2=80=99. =C2=B9 https://lists.gnu.org/archive/html/guix-devel/2023-04/msg00396.html * Changes in 0.10.0 (yet to be released) ** Distinguish =E2=80=98starting=E2=80=99 and =E2=80=98stopping=E2=80=99 in= termediate service statuses In previous version, a service would be either =E2=80=9Crunning=E2=80=9D or= =E2=80=9Cstopped=E2=80=9D. The intermediate states =E2=80=9Cstarting=E2=80=9D and =E2=80=9Cstopping=E2=80= =9D are now properly captured and you can see them when running =E2=80=98herd status=E2=80=99. ** =E2=80=98start=E2=80=99 and =E2=80=98stop=E2=80=99 block when service is= already being started/stopped With previous version, a client running =E2=80=98herd start SERVICE=E2=80= =99 while SERVICE is already being started would cause shepherd to attempt to start a second instance of that service, ultimately resulting in confusion, disappointment, and frustration. This is no longer the case: when a service is already being started/stopped, additional invocation of =E2=80=98herd start=E2=80=99 or =E2=80=98herd stop= =E2=80=99 now block until the service is running/stopped. ** =E2=80=98shepherd=E2=80=99 starts services in parallel Services started with =E2=80=98start-in-the-background=E2=80=99 and more ge= nerally service dependencies get started in parallel. This can reduce startup times in case of a =E2=80=9Cwide=E2=80=9D service dependency graph with some services tha= t take a while to start. ** =E2=80=98shepherd=E2=80=99 keeps track of failures and status change tim= es For each service, shepherd maintains an event log including the time of rec= ent status changes as well as the time of startup failures, if any. The =E2=80= =98herd status SERVICE=E2=80=99 command now shows the time when the service entered= its current status and whether it failed to start; =E2=80=98herd status=E2=80= =99 also prominently lists services that failed to start. ** New =E2=80=98herd log=E2=80=99 command Related to the previous item, the new =E2=80=98herd log=E2=80=99 command di= splays an aggregate of the service event logs, showing the time at which each service changed statuses. ** New =E2=80=98herd graph=E2=80=99 command The new =E2=80=98herd graph=E2=80=99 command emits a Graphviz/Dot represent= ation of the service dependency graph, which can be viewed for example with =E2=80=98xdo= t=E2=80=99: herd graph | xdot - Guix System users get similar information with =E2=80=98guix system shepher= d-graph=E2=80=99 (and likewise for Guix Home). The difference here is that this reflects the current system status, showing transient services, services that failed to start, and so on. ** =E2=80=98herd=E2=80=99 output is colorized At long last! We hope you=E2=80=99ll enjoy a little bit of coloring to hig= hlight important bits in the output of various commands. ** New services shipped: =E2=80=98monitoring=E2=80=99 and =E2=80=98repl=E2= =80=99 The Shepherd now ships with optional services=E2=80=94see =E2=80=9CService = Collection=E2=80=9D in the manual. The =E2=80=98monitoring=E2=80=99 service logs resource usage of th= e =E2=80=98shepherd=E2=80=99 process itself. The =E2=80=98repl=E2=80=99 service runs a read-eval-print = loop (REPL) in the =E2=80=98shepherd=E2=80=99 so you can hack it live=E2=80=94enjoy it, but ha= ndle it with care! ** Socket-actived, systemd-style services can now be started eagerly The =E2=80=98make-systemd-constructor=E2=80=99 procedure has a new #:lazy-s= tart? parameter. It defaults to #true, meaning that the process is started lazily, on the fi= rst connection to one of its sockets, as was the case in 0.9.x. Passing #:lazy-start? #false instructs shepherd to instead start the process eagerl= y, as soon as the listening sockets are ready. This is useful for services that require socket activation as a startup synchronization mechanism, yet are expected to run as soon as possible. An example is =E2=80=98guix publish --advertise=E2=80=99: it should be started= eagerly so it can start advertising itself via Avahi. ** Each registered name maps to exactly one service There used to be a fuzzy notion of =E2=80=9Cconflicting services=E2=80=9D, = when a given service name could potentially refer to more than one service. This has proved to be confusing more than anything else; now, each registered service name refers to exactly one service. The interface related to that feature, such as the =E2=80=98conflicts-with=E2=80=99 method, is done. ** For systemd and inetd services, retry =E2=80=98bind=E2=80=99 upon EADDRI= NUSE Services started with =E2=80=98make-systemd-constructor=E2=80=99 and =E2=80= =98make-inetd-constructor=E2=80=99 will now retry several times when =E2=80=98bind=E2=80=99 returns EADDRINUSE= (=E2=80=9CAddress already in use=E2=80=9D) for their listening socket(s). ** =E2=80=98system=E2=80=99 and =E2=80=98make-system-constructor=E2=80=99 a= re now non-blocking In versions up to 0.9.3, calling Guile=E2=80=99s =E2=80=98system=E2=80=99 p= rocedure (which is what =E2=80=98make-system-constructor=E2=80=99 does) would block the =E2=80=98sh= epherd=E2=80=99 process until the shell spawned by =E2=80=98system=E2=80=99 has terminated. This is no longe= r the case. ** GOOPS interface is deprecated When it was created in 2002, the Shepherd (n=C3=A9e dmd) embraced GOOPS, Gu= ile=E2=80=99s object-oriented programming system, then a brand new and promising approach for 21st century programs. In hindsight, while there were a couple of clas= ses and a bunch of methods, the code base was not really making much use of GOO= PS. The current maintainer deemed it unnecessary and encouraging a programming style at odds with the shiny horizon of purely functional, actor-style programming. The GOOPS interface is still available in 0.10.0; for example, you can still write ~(make #:provides =E2=80=A6)~ in your configuration file. = However, GOOPS support will be removed in the next major series, most likely labeled 1.0. A new interface has been defined. Check out the =E2=80=9CLegacy GOOPS Inte= rface=E2=80=9D section of the manual for more information, and email guix-devel@gnu.org if you have any questions or concerns. ** Interfaces removed and changed Several obscure or undocumented interfaces were removed: - support for the =E2=80=98unknown=E2=80=99 service; - support for =E2=80=9Cpersistency=E2=80=9D (sic); - the =E2=80=98cd=E2=80=99 action of the =E2=80=98root=E2=80=99 service; - the =E2=80=98launch-service=E2=80=99 procedure of (shepherd service). New deprecations: - =E2=80=98make-actions=E2=80=99 is deprecated in favor of =E2=80=98actio= ns=E2=80=99; - calling =E2=80=98register-services=E2=80=99 with an arbitrary number of= arguments is now deprecated; you should now call it with a single argument, the list of services to register. ** Major internal overhaul As you can guess from the list of user-visible changes above, the Shepherd = has undergone a major internal overhaul. The 0.9.x series introduced the use of Fibers, Guile=E2=80=99s lightweight concurrent facility; shepherd took adva= ntage of it notably with the introduction of systemd-style and inetd-style services. T= his new stable series takes it further. In particular, each record has an associated fiber called the =E2=80=9Cservice controller=E2=80=9D. Following the actor model, each of t= hese fibers reacts to messages it receives, be they event notification=E2=80=94e.g., process termination=E2=80=94or user requests=E2=80=94e.g., querying the service sta= tus, requesting that the service be stopped. Other noteworthy actors include the =E2=80=9C= process monitor=E2=80=9D and the =E2=80=9Cservice registry=E2=80=9D. This has allowed us to address a number of race conditions while also leadi= ng to clearer code with linear flows that one can more easily reason about. Overall, it makes the code base much more pleasant to work with and certain= ly easier to hack than other implementations mired in the =E2=80=9Ccallback he= ll=E2=80=9D. Documentation has been overhauled as well to reflect all these changes. Ch= eck out the new subsections under =E2=80=9CServices=E2=80=9D for more informati= on. --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQJBBAEBCgArFiEEPORkVYqE/cadtAz7CQsRmT2a67UFAmRYHKINHGx1ZG9AZ251 Lm9yZwAKCRAJCxGZPZrrteacEACNxrYOr3WUAFwjp6LLECQw/eZBhg2yYoqkxlYX OvGz3V7hVy0nAtUjDGTMK8hriJyj+VzAIk7gWyQUxvHIlxtS72QKOdALlVi7wj1b 6D7oZCjBmd5Y6AmCAR1PokO3sjk4xATHkTQ/VlrbTb9szKktk0H3WZQBkZSxoy8S 2fw+qsfow/mDNyZwZ5kkq1YG6xa1FkKok5qwDvbOn2zBPvVQe3viZEvvZ1Nvtx2e 7hKG1w+xv/dEG06KVHgSpY9xlxfRtn997H0mlgLIAh5z7mzyhJvJRXvdg44pjBQ8 axjleHPYwD7NXVDxXoWZu05oI3enslV5P0uxtFS0iIXF3xHjzOi2ScuLTO6xpY3+ w7PWaR8SQQo3yLuhVSSIV3uiWsl+ExRT/y/aPoK6nAotzINqytnajhKn1ErS+V4s ZD7iPcHQ+WK7n1sN3pSzZA/fPT91MUsZWnTcjVpNqdPocZqDNgbGJVZipqQFcDGA fkQCVHw4rhQPBHSfro+XnH/t9dNVx0EQ8HbMDLL5Ih/kkzZMlncHZ73HHOUr/NRp 93PJI3lm7eRFM0Wp241uiA/uipmb7f3Yji+3Xg/ZvWhci3cBu2wHYKPmdrEm1vDm NCq9VXI5rr9ECw1WKDnPtF/3SepFGDfkSeLGDEJfu43uWpHlAB1Ity5Twa8GOHte qWhmkg== =FypV -----END PGP SIGNATURE----- --=-=-=--