From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1.migadu.com ([2001:41d0:1008:1e59::1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms1.migadu.com with LMTPS id 4A2cG8MjW2YVygAAA41jLg (envelope-from ) for ; Sat, 01 Jun 2024 15:36:03 +0200 Received: from aspmx1.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1.migadu.com with LMTPS id kGMjFsMjW2biBAEA62LTzQ (envelope-from ) for ; Sat, 01 Jun 2024 15:36:03 +0200 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gnu.org header.s=fencepost-gnu-org header.b=fPDVeLe7; 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=1717248963; 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=DdRC4MzWcGmW+FsJjYKigwl5MVqxVxQcjhe1/ibusuE=; b=Cdgt8TPUy6D8YKEpK/7JRd4SmUklFVrpW+SBH2KLqJYsTtea82ms8u1TX5nWD+QZwmABXv Mo6YgAxfAKHQ5yGoYbYsCOXkAtB5t9vs+vPMkwHUTmW6latuU3+JaX/wwXdaLdN+qEIX/3 MDQ4PtfLUuA+sL75l0yQtFXcb4rs6PAOgBlq2NniYjqyzlirrl6aVHhRnGpd8X1RaylOZs +5ckx69vzeRofHxWMmQRQbaEaJFN/ZRcUn32e9RYymmT90EFrvdvWz5jsVkcZpr+7316hx QGyzJZZ5I0DhOy1rD1Vd9lIGMuNV4mtJwEUQSSHbv5vOo0aDMzN0Vyes/dRx9Q== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1717248963; a=rsa-sha256; cv=none; b=kOcAk+E07lDgLQ9aGUQ98t/DMpU8jIQyxqjvkC3zkokMyfDAXfGJdVPJ6xcCjFdj6K+Wov MW6ZNdcnS8DX0Yss5dmAGHLeWgxIHe2kDWeTqHe/MIJu+05kyN1hiQFqQTwzsS+xO6t6aw L1a5ygQdAh8Kary1AKaxtQHSdcDMhbPWrzoIbW5VHUSq1JxMZLXMzcLLklO5HYjdgak+qo K7ngPNOFvGl/ESiIzcFHjJrKcIDSP9dvAXbhVVs6he4k+sO5ArO/aIwvBrenFoGCHHkuKw cejTnZsNX+3J9ozV4nYVV8m2AW+JW+5cWny0qBlQUerD8HvLggATz8CUMqzs5A== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gnu.org header.s=fencepost-gnu-org header.b=fPDVeLe7; 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" 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 45BF4E558 for ; Sat, 01 Jun 2024 15:36:03 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sDOtY-0001K6-8w; Sat, 01 Jun 2024 09:35:40 -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 1sDOtV-0001Jr-9e for guix-devel@gnu.org; Sat, 01 Jun 2024 09:35:37 -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 1sDOtU-0003Zx-ON; Sat, 01 Jun 2024 09:35:36 -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:References:In-Reply-To:Subject:To: From; bh=DdRC4MzWcGmW+FsJjYKigwl5MVqxVxQcjhe1/ibusuE=; b=fPDVeLe71/H0iC9pGBTE YfEYcQO6LAsTq1/ulmCD4Yx6nLV8yfNpbcCrXKQQVg2nfejoUcEooKdxblmoNHnubU6mV6efv+Cmx jXj6dtEDXEC2+4y9IAS6PeTOXIGc/FZ/ZGXQtwjcaQ2fdVzr/bLhSmhXejL95HDHnRCbSj5ObHNJp VaplBX31L6QbkkoeXV+Ao7AL9Jg4LWzLmFPTO2eTtmmKW1Ugn59Sm8qfjpJlYrUBB2xL9UXgy8iTi kI/KYR5RWJGf8mOgD0HdsGVAbCYeDIgiKlWnnjgQZgVsutZ34mtUwkG7nIrbAyZ687cp2ehTvCz4n 6i2Ud0khFNmkVQ==; From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: Felix Lechner Cc: guix-devel@gnu.org Subject: Re: Shepherd log rotation service In-Reply-To: <877cflu3zk.fsf@lease-up.com> (Felix Lechner's message of "Wed, 22 May 2024 10:54:23 -0700") References: <87ed9y4ygj.fsf@inria.fr> <877cflu3zk.fsf@lease-up.com> X-URL: http://www.fdn.fr/~lcourtes/ X-Revolutionary-Date: Quartidi 14 Prairial an 232 de la =?utf-8?Q?R=C3=A9v?= =?utf-8?Q?olution=2C?= jour de l'Acacia 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: Sat, 01 Jun 2024 15:35:34 +0200 Message-ID: <87frtwpyzd.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) 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-Spam-Score: -8.10 X-Spam-Score: -8.10 X-Migadu-Queue-Id: 45BF4E558 X-Migadu-Scanner: mx11.migadu.com X-TUID: 4x/dNTWf+/ij Hi, Felix Lechner skribis: > I should will make an immediate dent in my 200 MB log file for Fcgiwrap, > but not for an Rspamd file of similar size. Also, my Nginx log file > with 1.3 GB will remain unaffected. Most significantly, it simplifies a > lot of code. Right. I think we should augment =E2=80=98log-rotation-service=E2=80=99 so= it can also take care of =E2=80=9Cdetached logs=E2=80=9D (logs not created by #:log-fil= e). This is necessary for nginx and others. > Should log-rotation-service be called make-log-rotation-service? I don=E2=80=99t think so. :-) This is consistent with =E2=80=98repl-servi= ce=E2=80=99 and =E2=80=98monitoring-service=E2=80=99. > Should the key #:rotation-size-threshold be renamed to size-threshold? > I'm not asking to change the name of the variable holding the default > value. The current key looks longer than needed in this code: Hmm, not sure about this one. > Also, is it good practice, in log-rotation-service, to use an optional > argument (for event) together with keyword arguments? Why not use > keyword arguments all around? It=E2=80=99s good practice=E2=80=94there=E2=80=99s no ambiguity at the lang= uage level. Whether it=E2=80=99s good style is a different story. My thinking here is = that =E2=80=98event=E2=80=99 is the =E2=80=9Cmost important=E2=80=9D parameter, = hence this special treatment. > Finally, are there truly no (Shepherd) service requirements? Or will > any Shepherd service that uses #:log-file automatically make sure that > the file-system is available? Currently we use #:log-file in Guix System without worrying specifying any =E2=80=98file-system-=E2=80=99 requirement. The assumption is that /va= r/log is on the root file system. Dropping this assumption would complicate things=E2=80=A6 (This is unrelated to the log rotation service though.) Thanks, Ludo=E2=80=99.