Received: by 2002:a05:6a10:c7c6:0:0:0:0 with SMTP id h6csp2885841pxy; Tue, 3 Aug 2021 18:45:49 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwEjJGZiAAUiAyYpF57k8An02c1E9Tkws5ARDJsU9csqcAB4ES0McTteHRfQXgf64fy9rWO X-Received: by 2002:a17:906:9fc1:: with SMTP id hj1mr23038760ejc.103.1628041549629; Tue, 03 Aug 2021 18:45:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1628041549; cv=none; d=google.com; s=arc-20160816; b=dlw7mJY6rRI7ci3OjSUC2biAGvktvJodlCsFy10e6ThOwrQzwGp4pfDHGVxMi3zeM0 Hv6Y5v7L12TVfEuu1R4vm289hzCYZE/r7MZoeCHca0kt8shddO4TJDW+SwYHrisjeM1+ wkAdI0czrjWWmRU2EDLO0vv5iAZ73d+vnCDofHGw7QlZb+lnN1w15YQT82peN6DDfjKj tkqZ/Ux8fySu6FQgytiBQjdO9gKKy87jPAULNf3nzKYgPnGapYf9sTKPd81ULPEzo/V9 xtiYVuYlFRkJaSTLxsoV3bg9EPEz2pTDKiNfySK8jv2mHu7P+kWNcBrKyq+uUrTsvD0W 7taA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:date:references:in-reply-to:subject :cc:to:from:mime-version:content-transfer-encoding:dkim-signature :dkim-signature; bh=2iqGxMnHm/QxYs7OHUI6RNP8L3x4sdHsx6v9fS4n5A4=; b=lYcz8qJhK9hJ8r4PwK1Vi3tTvW/rTyuw/I0ltsqzSaH60n/VdRIccZitIzHH5l3q52 YueP2tqPuM7JY/VlAIuQtvKW6aDqQp1eSeToUwxbiVvRGEgc5TpLQMUNgf95kY5uu1qy 1a5XNurwfQxzIVFqyrJdLPgQSyiMjzlFhVgjMwg3KVroOWack6iYIkhRC1O7y1sSzWUQ TtM/pKk8IUP6S6ixB9syRGENUgn3jQYw2127hal3HqSISi47gm95jR19G23EP0+aW/tr zZ2uxPoe83WmkGXiJkWcSrda8wAFfw4Dm6zJ/njXIS4Lw0m+b1u7tfIlyYJiHSuRHgDj yaYA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b="O8yqce/L"; dkim=neutral (no key) header.i=@suse.de; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id p21si574838ejz.397.2021.08.03.18.45.15; Tue, 03 Aug 2021 18:45:49 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b="O8yqce/L"; dkim=neutral (no key) header.i=@suse.de; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231837AbhHDA6J (ORCPT + 99 others); Tue, 3 Aug 2021 20:58:09 -0400 Received: from smtp-out1.suse.de ([195.135.220.28]:35454 "EHLO smtp-out1.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231875AbhHDA6I (ORCPT ); Tue, 3 Aug 2021 20:58:08 -0400 Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 30BE6220F9; Wed, 4 Aug 2021 00:57:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1628038676; h=from:from:reply-to: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; bh=2iqGxMnHm/QxYs7OHUI6RNP8L3x4sdHsx6v9fS4n5A4=; b=O8yqce/LCm9KMVo7u52i3y81scI3DfBOsMOv+sFc/KSrA9bX/LcbfMP325+XZsli0tsi2j 6FmGfMbxyWwBzY9xiVFlda9sI48pVOUpnlCG4B+7KyKRDU2W8OiljqBCIXD5FHcXPxUGRR jaeAUSEhCe3R1a4HeYyA8oHA+PKFzcY= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1628038676; h=from:from:reply-to: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; bh=2iqGxMnHm/QxYs7OHUI6RNP8L3x4sdHsx6v9fS4n5A4=; b=gYqxkpTe9ZTH0aop+JBkkPGGZb3C72O7FQL7BV1CRi1JEtOsJdzO/0AO9YthRit3HlEAA9 KVOGeM1i4iVrcHCA== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 93A4D13B18; Wed, 4 Aug 2021 00:57:54 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id LT+HFBLmCWFYIAAAMHmgww (envelope-from ); Wed, 04 Aug 2021 00:57:54 +0000 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit MIME-Version: 1.0 From: "NeilBrown" To: "Trond Myklebust" Cc: "bfields@fieldses.org" , "plambri@redhat.com" , "linux-nfs@vger.kernel.org" , "bcodding@redhat.com" Subject: Re: cto changes for v4 atomic open In-reply-to: <08db3d70a6a4799a7f3a6f5227335403f5a148dd.camel@hammerspace.com> References: , , <20210803203051.GA3043@fieldses.org>, <3feb71ab232b26df6d63111ee8226f6bb7e8dc36.camel@hammerspace.com>, <20210803213642.GA4042@fieldses.org>, , <162803443497.32159.4120609262211305187@noble.neil.brown.name>, <08db3d70a6a4799a7f3a6f5227335403f5a148dd.camel@hammerspace.com> Date: Wed, 04 Aug 2021 10:57:51 +1000 Message-id: <162803867150.32159.9013174090922030713@noble.neil.brown.name> Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org On Wed, 04 Aug 2021, Trond Myklebust wrote: > > No. What you propose is to optimise for a fringe case, which we cannot > guarantee will work anyway. I'd much rather optimise for the common > case, which is the only case with predictable semantics. > "predictable"?? As I understand it (I haven't examined the code) the current semantics includes: If a file is open for read, some other client changed the file, and the file is then opened, then the second open might see new data, or might see old data, depending on whether the requested data is still in cache or not. I find this to be less predictable than the easy-to-understand semantics that Bruce has quoted: - revalidate on every open, flush on every close I'm suggesting we optimize for fringe cases, I'm suggesting we provide semantics that are simple, documentated, and predictable. Thanks, NeilBrown