From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id W1YHI2YnnmBUVAEAgWs5BA (envelope-from ) for ; Fri, 14 May 2021 09:31:50 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id sEkuHmYnnmACAwAAB5/wlQ (envelope-from ) for ; Fri, 14 May 2021 07:31:50 +0000 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 428AB233D8 for ; Fri, 14 May 2021 09:31:50 +0200 (CEST) Received: from localhost ([::1]:55030 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lhSIX-0008Ft-Ee for larch@yhetil.org; Fri, 14 May 2021 03:31:49 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:49742) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lhSI5-0008Fk-RQ for guix-devel@gnu.org; Fri, 14 May 2021 03:31:22 -0400 Received: from mira.cbaines.net ([2a01:7e00:e000:2f8:fd4d:b5c7:13fb:3d27]:48387) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lhSI2-000747-8u; Fri, 14 May 2021 03:31:21 -0400 Received: from localhost (unknown [IPv6:2a02:8010:68c1:0:8ac0:b4c7:f5c8:7caa]) by mira.cbaines.net (Postfix) with ESMTPSA id 188AE27BC78; Fri, 14 May 2021 08:31:13 +0100 (BST) Received: from capella (localhost [127.0.0.1]) by localhost (OpenSMTPD) with ESMTP id be91b3db; Fri, 14 May 2021 07:31:12 +0000 (UTC) References: <87mtvhnsn6.fsf@cbaines.net> <874kfyufzg.fsf@gnu.org> <87wnsthpyn.fsf@cbaines.net> <87tun9zabg.fsf_-_@gnu.org> User-agent: mu4e 1.4.15; emacs 27.1 From: Christopher Baines To: Ludovic =?utf-8?Q?Court=C3=A8s?= Subject: Re: bug#47897: [PATCH] substitutes: Don't cache negative lookups or transient errors. In-reply-to: <87tun9zabg.fsf_-_@gnu.org> Date: Fri, 14 May 2021 08:31:09 +0100 Message-ID: <874kf5epqa.fsf@cbaines.net> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" Received-SPF: pass client-ip=2a01:7e00:e000:2f8:fd4d:b5c7:13fb:3d27; envelope-from=mail@cbaines.net; helo=mira.cbaines.net X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: guix-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: guix-devel@gnu.org, 47897@debbugs.gnu.org Errors-To: guix-devel-bounces+larch=yhetil.org@gnu.org Sender: "Guix-devel" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1620977510; 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:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post; bh=rh3pifofQ5yjznZaEFtDwU5Pfhu7ETvpkJ019fmNPQs=; b=NZIF3GvsjehCzBB6Twa06TkqbigTqgdFCHE26//SitT6xKBf+HwB63itkPyDFFiXju/j6O JqscwQxwSbkL7C25W2OCyMDj+ETvYkOVK2EIyzC4Q0RRWsgGWnz8UAyfcfoqhCqWIZ/rrN IBkhh1L3rFm0/fVoz0UJLdFcEqGXW88ad64vPRVB09EMZIbmBF59NVuTgSrljnc9ChvB3T 3uaoxRweTFDNfesQORGMwQRbzyr5MdPEuCgham6S0DjZRS0fYo++aJGE7gVbSmrsA8Wzi2 eFbojlneVEcHw3M2z33x7Bxb3MgZQ6pfalbBgxIpooqg9n+wr4mCPgSHaxBsaw== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1620977510; a=rsa-sha256; cv=none; b=HCMSGSPxqNOb4utXgrD863rIOpXh18mBRwafcb+eo7CTDiF6XDT9GcD6Xv/Beg9Lf/aiMj utRGKmCHuOwnj5hFDMwN35WX1gfZzLtWCuP9RhNPx+FUP4wgkgFGL4EJSlq1TnH0hPAljJ JKH9QxWk+OV6KhykrGYTqgCsnGwDYl/13utKUOpD0UKnQQYS4VCtfTyc5mNvT4gpasipmb 6njQQMBRp2tfsj1zA2e2hT5fQMOLnnTq+Wf6wKldWf4ZIw+ylWStCBzJtYQ2Syk7VYiq9M uM1itFzum9ExcsaKKYu5/uHgthlMpWQPkB+XGyZHzqyZk3yY9UyJfPzXMwdthA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of guix-devel-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-devel-bounces@gnu.org X-Migadu-Spam-Score: -4.55 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of guix-devel-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-devel-bounces@gnu.org X-Migadu-Queue-Id: 428AB233D8 X-Spam-Score: -4.55 X-Migadu-Scanner: scn0.migadu.com X-TUID: l7p35dMDIPLA --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Ludovic Court=C3=A8s writes: > Hi, > > Christopher Baines skribis: > >>> Now, the penalty it imposes is annoying. I=E2=80=99ve sometimes found = myself >>> working around it, too (because I knew the server was going to have the >>> store item sooner than 1h). >>> >>> Rather than removing it entirely, I can think of these options: >>> >>> 1. Reduce the default negative timeouts. >> >> I think reducing it is good, as you say, it's possible to override the >> default from the server side. Just in case someone wants caching >> behaviour, it might be worth keeping that functionality at least. > > OK, let=E2=80=99s do that. > >>> 2. Add an option to =E2=80=98guix publish=E2=80=99 (and to the Coordi= nator?) so they >>> send a =E2=80=98Cache-Control=E2=80=99 header with the chosen TTL = on 404. That >>> way, if the server operator doesn=E2=80=99t mind extra load, they = can run >>> =E2=80=9Cguix publish --negative-ttl=3D0=E2=80=9D. >> >> That sounds sensible. The Guix Build Coordinator doesn't do any serving, >> that's left to something else like nginx. For the deployments I maintain >> though, I don't think I'm setting the relevant headers, but I'll look at >> changing that. > > Cool. > >> Going back to the %narinfo-transient-error-ttl, if I'm correct in saying >> that it's not possible to override that, maybe that should also use the >> relevant header value if set? > > Correct, =E2=80=98%narinfo-transient-error-ttl=E2=80=99 cannot be overrid= den. We can > halve it if you think that=E2=80=99s useful, thought when that happens, i= t means > something=E2=80=99s wrong with the server (returning 500 or similar). > > I=E2=80=99ve sent patches to address this, lemme know what you think! The patches you've sent look good. --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQKlBAEBCgCPFiEEPonu50WOcg2XVOCyXiijOwuE9XcFAmCeJz5fFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDNF ODlFRUU3NDU4RTcyMEQ5NzU0RTBCMjVFMjhBMzNCMEI4NEY1NzcRHG1haWxAY2Jh aW5lcy5uZXQACgkQXiijOwuE9XeYRA/+IpdxSoaVxtfa2ScTBNvlH99k0xVw3RBN FGVOvxa+bZimKwQjUzbT/tQz5xZqOhHbD6AeCvuYy0ilfktZqaEpaC2Abcy/n/KU ayWvUpaAMoE6VAGgn0TuD91WIWEPdrgibp/wCTVsezTIR6F8z6XMeyErSKztkdNp kKF8d86RxaCw/sVprO3o6iirsfX+ZI76WEW8P25VXhIqK8hy1H1ZcPQ8XPPKtL+k AnOfycEq+M3Q64NTnLfRHq7qet0juU/ttuszfgRktekXVWjAYVhvZ+3OXt+UqLcN UotpeOEFioCIJx8nwYJYOOVK4/JbUgwx2MvecX7UbnscrW42Tp6WFHy7hL2OmcPT Mkgzl+Y7OZ+cnRSxsXnO8CzutTUPHQzJq2i9ZWmctE7hsnr+hZ8vyWGc3NITZDAm xdY64g8FB4cWV2a0JKA4lAaxZZEu1SqNvKfLRobj7uevphk+GusnRGMcdaVjvRzK zrc4gEcL7cLsEikruSz9y0/0SAqAxUVov/PkOU0BRPWLOeUToEa5h6ypKhDlfpoF 5rgMbSTvXkHksKRBrX08uI6AqlOJrswQt+elhkdW3DRJzC50gPx74ipWlqL20YsG m4iAivyvR78ho+3/e3txAXWFvFClwqME8nw1f7GMzB7bxXQng/dmHDL/05YUPalI emBhOobfsAk= =Ym9E -----END PGP SIGNATURE----- --=-=-=--