Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pyTR7-00058s-6p for pgsql-hackers@arkaria.postgresql.org; Mon, 15 May 2023 08:20:05 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1pyTR5-0007bZ-Sr for pgsql-hackers@arkaria.postgresql.org; Mon, 15 May 2023 08:20:03 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pyTR5-0007bQ-KC for pgsql-hackers@lists.postgresql.org; Mon, 15 May 2023 08:20:03 +0000 Received: from mail-wm1-x333.google.com ([2a00:1450:4864:20::333]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1pyTR2-002q5j-BB for pgsql-hackers@lists.postgresql.org; Mon, 15 May 2023 08:20:02 +0000 Received: by mail-wm1-x333.google.com with SMTP id 5b1f17b1804b1-3f417ea5252so66386165e9.0 for ; Mon, 15 May 2023 01:20:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1684138799; x=1686730799; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=v4Y+lvDOIukl+dJ4H56fF9T0uVUwADhzTMXBDff8zKE=; b=agJGIgnEqsyzhbAOgUO8+XapYsiQGcvM5LYtddwwkI8sYhR01ja1sLwToSrHgSMsKF dsoaefhwC18cNJsEyF6Fs+tfRNLDvz+N/tWCyCDwSmwlylnoA3HPR+WRRyvmeLGKyHcz B16YLMN4jmr7QZEDS0YQZNhpOOW/MW6wS2tXNNBFXl67BddI5A8OxqjqbCkHEbx5WbPq QCD84M8ZChX5mU07ztt8I59l2eMLNKhQ7IM5WAPstfG0mhOZ31pRZeLzhwXJDl4Zj7Lh s8buRLV85Y6X2u/wLfwv2tXTZiQmD5Sk8hMLArXiRppyqUT9b2n6wDZYIJEwB02VQeRv m7Nw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1684138799; x=1686730799; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=v4Y+lvDOIukl+dJ4H56fF9T0uVUwADhzTMXBDff8zKE=; b=ETzinozjJbtXQnu2XmzoWxAz61LNE/jkWZPxYfRpS0Gr0gN6hqig428QpsVxax4zoa 6QUGoJ3lxPXD1ixS2zcjegjqwucl0V6SydUWWUWwqcGNlc3qON/vjUONPa9ClReYIBqG JgUZyi9Wt04j++l3xK5Oi+YEIXafaRslJ53G9Y0SYUtA290btMAJutbCqLwcr+91PKU5 AsJbDMR9OLmYnPJXMfaIy3sZ1mguRbXfzB0Kd4nVOSvXrTGXLhK7dldfaADofn9hnnhZ YgFQp3KAIs1KXOHBoyuVHT60SFcv0CMWCkVKMKldkBKgUY4Is6m5fPZLSJFnL6Ny63HA UarA== X-Gm-Message-State: AC+VfDzwSlzLkDjhiT5yGJhkKHIkRNvK7YMLESZ7N/5xL46NCOInH/74 VHH6+Rsq1NBter0xdcuL+6E= X-Google-Smtp-Source: ACHHUZ5jXF6g8ezwnzwOr6EBvs23w8qUdVo/LzpWrb7IP63RHmRrCbcLW4MRcO83pLqpCO6320/pww== X-Received: by 2002:a5d:58d9:0:b0:2f9:1224:2474 with SMTP id o25-20020a5d58d9000000b002f912242474mr24233132wrf.23.1684138799546; Mon, 15 May 2023 01:19:59 -0700 (PDT) Received: from [192.168.5.184] ([54.239.6.186]) by smtp.gmail.com with ESMTPSA id e3-20020adff343000000b002fefe2edb72sm31524670wrp.17.2023.05.15.01.19.58 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 15 May 2023 01:19:58 -0700 (PDT) Message-ID: <700b3fb8-37b9-cec5-1ee2-3a490568651e@gmail.com> Date: Mon, 15 May 2023 10:18:42 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:102.0) Gecko/20100101 Thunderbird/102.11.0 Subject: Re: Autogenerate some wait events code and documentation Content-Language: en-US To: Michael Paquier Cc: PostgreSQL Hackers References: <2e649ed7-6c66-5d6a-16d4-5d5367d40e69@gmail.com> <64fc361e-f4ed-45eb-0cfb-c8110872530d@gmail.com> <124bdcea-bdc8-e3d2-2357-0c6a857bc557@gmail.com> From: "Drouvot, Bertrand" In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Hi, On 5/6/23 4:23 AM, Michael Paquier wrote: > On Thu, May 04, 2023 at 08:39:49AM +0200, Drouvot, Bertrand wrote: >> On 5/1/23 1:59 AM, Michael Paquier wrote: >> I'm not sure I like it. First, it does break the "Note" ordering as compare >> to the current documentation. That's not a big deal though. >> >> Secondly, what If we need to add some note(s) in the future for >> another wait class? Having all the notes after all the tables are >> generated would sound weird to me. > > Appending these notes at the end of all the tables does not strike me > as a big dea, TBH. But, well, my sole opinion is not the final choice > either. For now, I am mostly tempted to keep the generation script as > minimalistic as possible. > I agree that's not a big deal and I'm not against having these notes at the end of all the tables. >> We could discuss another approach for the "Note" part if there is a >> need to add one for an existing/new wait class though. > means, that was more a NIT comment from my side. > Documenting what's expected from the wait event classes is critical in > the .txt file as that's what developers are going to look at when > adding a new wait event. Adding them in the header is less appealing > to me considering that is it now generated, and the docs provide a lot > of explanation as well. > Your argument that the header is now generated makes me change my mind: I know think that having the comments in the .txt file is enough. >>> This has as extra consequence to require a change in >>> wait_event.h so as PG_WAIT_BUFFER_PIN is renamed to PG_WAIT_BUFFERPIN, >>> equally fine by me. Logically, this rename should be done in a patch >>> of its own, for clarity. >> >> Yes, I can look at it. >> [...] >> Agree, I'll look at this. > > Thanks! Please find the dedicated patch proposal in [1]. [1]: https://www.postgresql.org/message-id/c6f35117-4b20-4c78-1df5-d3056010dcf5%40gmail.com Regards, -- Bertrand Drouvot PostgreSQL Contributors Team RDS Open Source Databases Amazon Web Services: https://aws.amazon.com