From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:403:4789::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms9.migadu.com with LMTPS id 6MtPEKI2A2VHowAAauVa8A:P1 (envelope-from ) for ; Thu, 14 Sep 2023 18:36:50 +0200 Received: from aspmx1.migadu.com ([2001:41d0:403:4789::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id 6MtPEKI2A2VHowAAauVa8A (envelope-from ) for ; Thu, 14 Sep 2023 18:36:50 +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 D4A363C2C8 for ; Thu, 14 Sep 2023 18:36:49 +0200 (CEST) Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gnu.org header.s=fencepost-gnu-org header.b=Xec5B8So; 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"; dmarc=pass (policy=none) header.from=gnu.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1694709410; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=wmgoPt1YgRN7eHGq83+uUOzJPEtcqkKZROgv3iCBPp0=; b=pG0C+dFsf/65nNK/PlcbW8zH7gJgsPv2oWbIa28AyzEF3nwKhjXrv8aOucb/kpvIufwveK qHw8PcgjyfZ6EAR+VpfHTmAotlImhEhB691OEY+23AIfzFa4u9bRDkS30FucTKBi4mv6f7 dNITvoAbE1BIqP2eizLLtQymGvqTQjbZNkhHao3KCVUT2S7WtPS4IVefi0sODzl7Z55FH1 x6NCsECD3KeGLKdaFi/GSoeqD62zGgOkjxO5/m9NR3nncgv98L/HCUwrrfAoHWTWIMQz0K aue7r+iGfTamOrWP/9ngzOwe5UDpvGmUCm4pC/YpY9/cmXWi3K4d3ZqE3QfDcg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gnu.org header.s=fencepost-gnu-org header.b=Xec5B8So; 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"; dmarc=pass (policy=none) header.from=gnu.org ARC-Seal: i=1; s=key1; d=yhetil.org; t=1694709410; a=rsa-sha256; cv=none; b=ah2Xs7i1+n65dmTiJl/O7b/XhIRG+rqi5cxOkEQoQMEUzHtd0OouSwX1Xr+T0TeLtcqhJp Skv+S49uWmw+04p4gOlkDuKWkZlZklh9YTV+gXTwOw84IzkKbpSDldU9/Ittj49W7DFEO1 XPL8PamtRqUO7EaZie8nHiaR4z5zU1/cTwRiZjh80jDZA5ff3ojp7252fsaur8fIi8cvmo Zv4BflZwG7oLf0k7tN6UY7KLxaDY/WLjATnVLT3zdJrWg7q646H9NmahZ7RMJcMSNWfShO YDpSvKCyUclQzuqruefHeTj78ApYvL8uON1n1ex6w0YqcpIANV5Ii131Gy7OTQ== Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qgpK7-0004Yf-SJ; Thu, 14 Sep 2023 12:36:11 -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 1qgpK6-0004YR-Pj for guix-devel@gnu.org; Thu, 14 Sep 2023 12:36:11 -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 1qgpK6-0000Zx-DF; Thu, 14 Sep 2023 12:36:10 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:In-Reply-To:Date:References:Subject:To: From; bh=wmgoPt1YgRN7eHGq83+uUOzJPEtcqkKZROgv3iCBPp0=; b=Xec5B8SoJ2gvkZW852cW HkLBwM65rj4/znaie4qz6/cP1rr0QKzvAG6ziw6k6SojrwqCVL+TJXLAMEAL8TDwo+QvWt9EHe1Qp d8KQ3Z5rM9wVw7M9oz213rk53RA6OxdIHBUwc7Zdx+nfMwuYb9LjGnK0hKAz2F1WTldjUwX9Ju0at w4pKz0j0WIu0JXl/74wOH0nTgsQOh5llBAaUNQMLN1Q1OJmR45jCJVYfB9Swv2B3YijaAZbWls8PK NWQLO6vbZQEBRMFXkZDNrZLJ3EiINMYY+YI+4aDM3XdDmvjA/5wsnMpVYqyvJyn8n9/ogpeTO3zT1 +oEtLZOuWQRA0Q==; From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: Christopher Baines Cc: guix-devel@gnu.org Subject: Re: Implementing the guix-dameon in Guile References: <875y4et4up.fsf@cbaines.net> <87il8cc27p.fsf@gnu.org> <87o7i4sprt.fsf@cbaines.net> X-URL: http://www.fdn.fr/~lcourtes/ X-Revolutionary-Date: Octidi 28 Fructidor an 231 de la =?utf-8?Q?R=C3=A9vo?= =?utf-8?Q?lution=2C?= jour du =?utf-8?Q?Ma=C3=AFs?= 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: Thu, 14 Sep 2023 18:36:07 +0200 In-Reply-To: <87o7i4sprt.fsf@cbaines.net> (Christopher Baines's message of "Thu, 14 Sep 2023 16:53:16 +0100") Message-ID: <87sf7g7lvs.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable 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 X-Migadu-Scanner: mx1.migadu.com X-Migadu-Spam-Score: -3.81 X-Spam-Score: -3.81 X-Migadu-Queue-Id: D4A363C2C8 X-TUID: GT08ICGs4DxQ Christopher Baines skribis: > I'm not very familiar with actors, but I guess that's similar to having > a bunch of cooperating fibers which handle different things. Yes. Specifically, actors here are a fiber together with a channel; each actor looks like: (let loop ((state =E2=80=A6)) (match (get-message channel) ;; handle request and call =E2=80=98loop=E2=80=99 )) The actor keeps serving requests it gets on its channel. It makes quite a difference when you start framing it this way. When I first fiberized Cuirass years ago, I=E2=80=99d just use =E2=80=98spawn-fibe= r=E2=80=99 here and there where concurrency was needed. Thinking in terms of actors makes the code clearer, allows you to think about =E2=80=9Cconcurrency units=E2= =80=9D, respect separation of concerns, and so on. (Our Spritely comrades would explain this much better!) Ludo=E2=80=99.