Received: by 2002:a05:6359:6284:b0:131:369:b2a3 with SMTP id se4csp4691842rwb; Tue, 8 Aug 2023 12:11:41 -0700 (PDT) X-Google-Smtp-Source: AGHT+IG72/r/smiNTDDvsyyy4FXIB54cfAtqbGVMN4MPT+JT1QmrMjvrq6IqAuhmgaOXQYUYSugG X-Received: by 2002:a17:906:2d9:b0:99c:c59:2280 with SMTP id 25-20020a17090602d900b0099c0c592280mr376497ejk.51.1691521900849; Tue, 08 Aug 2023 12:11:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1691521900; cv=none; d=google.com; s=arc-20160816; b=R4jaQwHaCEj8Zpq7x3oxG1GMO/CcpeygphGvAH7UnkZtrOCYNGqgMZc1c8Sv6UrNcp u3LZ6cKkqJZs6kJGmvNjpltAFObfHgdG/amGt0yK5oW5eHMaP3jJ8CJw/a/YcciiBvpk k9oJMPFtatQ25fT6edPNP+dVH01QzLE07ch/Bvgj2Tf9CnkAN9squUDDi+IEqJ+XXtJO N3kssfcOhBGyfEItjKKsj8yvA/2FVK+Dw4+2U7LCdvZvQciIrGZVMbGq1Ut7uInJyXta qxKNQLc2sFcjLu0TJsFKAwXYoxiXZvMO6hpncw2ewlHkel9EFCb6lef8yt7leZ75o0S6 R0Dw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:user-agent :content-transfer-encoding:references:in-reply-to:date:cc:to:from :subject:message-id:dkim-signature; bh=c7JmN8O5Svb8Sccj3cuJnX4lY+0bQ1b0ac5E7//Onag=; fh=95mRf9+w9OSWmQetBCLSLa/1nplQkNdWnI7YCWJzUtg=; b=06+6+q6nlnN7tD6+bXdGK1W2IXEMrGcgHRPxNUctlJWInbQ2aU664TAofmWCVXhfaX pL7IkQPQw9CM45MjmtUYx7c7gSRGltuwZMTm308bTxGnIBG1yVMRMNB5lmu+zFa8aK6Z OVyyc3V+UZzcv+SlxvjynGVMJKGLSbE64GOQOqF6hbXYodDcC+2SttJsMB0DfVFFvCuh Gr0GsU2+oijrm3hR87V9+etZy0MjS1+iK5Dv9UG+4DTmYG8HBM8LJ6MMvVfV19agR0rQ uc3JRDYDfVc1ZLJeVj/Rl8GZjzsaX6GnTJn0N4VxZwP87hErc8hxdpCGuskpo2ISGYTi zF0A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="IaQND/kI"; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id n24-20020a17090695d800b0099cb0abecd9si6475565ejy.802.2023.08.08.12.11.12; Tue, 08 Aug 2023 12:11:40 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="IaQND/kI"; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231767AbjHHSqf (ORCPT + 99 others); Tue, 8 Aug 2023 14:46:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39252 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231586AbjHHSqO (ORCPT ); Tue, 8 Aug 2023 14:46:14 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 51ED011E92F for ; Tue, 8 Aug 2023 09:50:15 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id B1DA96259D for ; Tue, 8 Aug 2023 14:20:46 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 895E5C433C9; Tue, 8 Aug 2023 14:20:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1691504446; bh=QyGjQCt1JKDY8q5VBpdGkZyOmNX6t+/gtmfuPi5xneo=; h=Subject:From:To:Cc:Date:In-Reply-To:References:From; b=IaQND/kIAv8aEm5BtCmW+TavTSxvbuFMo/wG2fNlAgZWdvkZxmrinUKfIjncXvlAI WrSsHnMaXCeWYnoQLjUToGhsEpNrls7MIdLX0bCbc2RKn6ZKFcsbKmF4teHda8wRtB YnEYIF0RC9gciMKSv+NVggbTWXI7Aft3fD7cgIag5xe6s0gfeD+GNWdj83De254F9G dpxiOoyIF69pu1IWSj3JPaF5xLa5wxLw5tVvuCDZZxMe+y0lttbPFfdK1niVtZHSkC wkjFdHAbYjZmGMKfAjrT+fA5WagLnOQKcX4ZTTuO0N1mNFWGKglEwvTJ+8p1AxCp8R 4OMrQEs+MImNQ== Message-ID: Subject: Re: [PATCH] NFSD: add version field to nfsd_rpc_status_show handler From: Jeff Layton To: Chuck Lever Cc: NeilBrown , Lorenzo Bianconi , linux-nfs@vger.kernel.org, lorenzo.bianconi@redhat.com Date: Tue, 08 Aug 2023 10:20:44 -0400 In-Reply-To: References: <6431d0ea2295a1e128f83cd76a419dee161e4c44.1691482815.git.lorenzo@kernel.org> <169149440399.32308.1010201101079709026@noble.neil.brown.name> Content-Type: text/plain; charset="ISO-8859-15" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.48.4 (3.48.4-1.fc38) MIME-Version: 1.0 X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org On Tue, 2023-08-08 at 10:03 -0400, Chuck Lever wrote: > On Tue, Aug 08, 2023 at 09:48:42AM -0400, Jeff Layton wrote: > > On Tue, 2023-08-08 at 09:24 -0400, Chuck Lever wrote: > > > On Tue, Aug 08, 2023 at 09:33:23PM +1000, NeilBrown wrote: > > > > On Tue, 08 Aug 2023, Lorenzo Bianconi wrote: > > > > > Introduce version field to nfsd_rpc_status handler in order to he= lp > > > > > the user to maintain backward compatibility. > > > >=20 > > > > I wonder if this really helps. What do I do if I see a version tha= t I > > > > don't understand? Ignore the whole file? That doesn't make for a = good > > > > user experience. > > >=20 > > > There is no UX consideration here. A user browsing the file directly > > > will not care about the version. > > >=20 > > > This file is intended to be parsable by scripts and they have to > > > keep up with the occasional changes in format. Scripts can handle an > > > unrecogized version however they like. > > >=20 > > > This is what we typically get with a made-up format that isn't .ini > > > or JSON or XML. The file format isn't self-documenting. The final > > > field on each row is a variable number of tokens, so it will be > > > nearly impossible to simply add another field without breaking > > > something. > > >=20 > >=20 > > It shouldn't be a variable number of tokens per line. >=20 > That's how NFSv4 COMPOUND operations are displayed. For example: >=20 > 0x5d58666f 0x000000d1 0x000186a3 NFSv4 COMPOUND 0000062034739371 192.168.= 103.67 0 192.168.103.56 20049 OP_SEQUENCE OP_PUTFH OP_READ >=20 > The list of operations in the displayed compound are currently > blank-separated tokens at the end of each row. >=20 Oh! That's a bug in missed in my latest review then. The operations field was delimited by ':' chars at one point. Lorenzo, did you mean to change that? IMO, the list of operations should be one field, separated by a distinct delimiter (like ':'). >=20 > > If there is, then that's a bug, IMO. We do want it to be simple to > > just add a new field, published version info notwithstanding. >=20 > They could be wrapped in curly braces, or separated by commas, to > make them all one token. >=20 > I haven't looked at NFSv3 output yet, but I expect those extra > tokens won't even be there in that case. >=20 That's probably another bug. Anything not a v4 COMPOUND should have something as a placeholder. It could just be a single '-' character. > JSON, yaml, or xml would all address the extensibility problem, just > as an alternative thought. >=20 It would probably be fairly simple to output well-formed yaml instead. JSON and XML are a bit more of a pain. For now, we can change the output. We do need to have this settled before this goes to Linus' tree though. --=20 Jeff Layton