Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tv9wm-001ETJ-Ck for pgsql-hackers@arkaria.postgresql.org; Thu, 20 Mar 2025 07:04:08 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1tv9wl-000sH4-3H for pgsql-hackers@arkaria.postgresql.org; Thu, 20 Mar 2025 07:04:07 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tv9wk-000sGv-Jm for pgsql-hackers@lists.postgresql.org; Thu, 20 Mar 2025 07:04:06 +0000 Received: from mail-wm1-x32c.google.com ([2a00:1450:4864:20::32c]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.96) (envelope-from ) id 1tv9wg-00050U-0a for pgsql-hackers@lists.postgresql.org; Thu, 20 Mar 2025 07:04:04 +0000 Received: by mail-wm1-x32c.google.com with SMTP id 5b1f17b1804b1-43d0359b1fcso2412935e9.0 for ; Thu, 20 Mar 2025 00:04:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1742454240; x=1743059040; darn=lists.postgresql.org; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=666vO5YsaezNPqEKKgXlrX74JI3e2o2KTfA/wvn/p24=; b=S5ihCIeG3Y/mRre0JhkeZcirBT8J/19GtOBIVcFXhuF02gdFVhNn7dz9+ZF3Cm9ONP iNo1TpcM+Era8Xh6Uc51d9KMpZY9YdGHc0IB120DCEglmp+oSk/ihv+GsBblTPWIA2hE P5i78O0bcWBpcFmcf5/cX+/vcXafMCUMiT8N8AArv9EH8QOjZlGuzKaEVAUzBtV+e49y OSKhqs7WJZuGvmn8gRPAs3deg3LESuSQVdH9vovpkr4lZMIK3ygWuikHdiuAcyBSBvGt PmHXGw2nfPQ6z1N7LknFh/AHWlUVqXZ/OIa28dxPwM9nMSOxZOGFqCBGPaevFYdc+7bw xZPA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1742454240; x=1743059040; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=666vO5YsaezNPqEKKgXlrX74JI3e2o2KTfA/wvn/p24=; b=F1ECXpbVrSIR5wv9EAOQe2Vv64O51Xfe04S9Nt/ppRR+rvgKMghIIIm7KFBjn9bbvW SmnV+bscmA1fiWIbfuJN8SUhebJ3Uo5BUeiMCj2RrHQ/QYZzrGb90UYgvtE3f/R87qSw Y6nuhJ1oV1vdnEypoTMJ7AE+6g6QxC/jJ1T2YZv8jrC8PGWIfmVAmlJTbezA9KeUxrMZ XkOD42II+tfWDxPJBE+oEMob8bMgZJbAyB2FZefYF30f2gPcjNYpn1NRlppCHx7ckV2n u5pP1v5laTWqhlPnZYSmM+tDHz/USdhyax8pfGDexrfVBkRa2ktUrjMtuCWGFBgcbYGN CxQA== X-Forwarded-Encrypted: i=1; AJvYcCXkUFMcjQwNAqHt0BbiWuJiPni5jwKzNwzs12e6gcvrS9UQ6sHK8vGKja1Bb1aTEu8Sfqm6//17/cc0z7uS@lists.postgresql.org X-Gm-Message-State: AOJu0YyJRbYB/RT0kPdrtx9MH1mCGR/dPXOvSByAp+nTRq37rNarcQ77 6fncqcCppT4Je8xTa9VVDxeHS/JeKrx0tNOYj/NbOxXEoQV3HzpX X-Gm-Gg: ASbGnctd347zJTWNyNYCup/dbYLwv4ilg4vXO90KTDgNPUxtdz4pwAm3hQfX1lmRaY8 irnDW+zpsgML66qrFdcjU7Iryh4+/4jPYiHZCkMjoeHoHYQphoNZbRoh9xVP/NbhRWt+vEByuD5 /zNoSwxoO0bpJ4dy3U8p5iaOEm6Byf0gxpb+TGxk9lMutntBkJAtsP5/aqwiszWDS4suLDSDmNt tjbz5OP3KCAkKdHD/5Q37rExq9kCToNnsEaBvHVoAnmg4hbYThOKCinsnQYpZDoE4xpYZ1k9+hA RevuM5fMe8nZwfDh1twP51rBPMKVHUADUmIeq3QUK59OzChgjsWa X-Google-Smtp-Source: AGHT+IH15BGASqTjzXOZEzFtDiOjeb/VR4xd+UE+i4zWWVrWIiTT8EdW8malju9UyaqqoJOqALE+Aw== X-Received: by 2002:a05:600c:ac6:b0:439:91c7:895a with SMTP id 5b1f17b1804b1-43d49172281mr17266105e9.7.1742454239766; Thu, 20 Mar 2025 00:03:59 -0700 (PDT) Received: from [10.59.3.23] ([90.121.90.131]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-43d440ed5e0sm38841555e9.37.2025.03.20.00.03.59 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 20 Mar 2025 00:03:59 -0700 (PDT) Message-ID: <8e8b6f17-e1e6-4b16-84d4-37ded802c787@gmail.com> Date: Thu, 20 Mar 2025 08:03:58 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: making EXPLAIN extensible To: Sami Imseih Cc: Robert Haas , Tom Lane , Jeff Davis , Thom Brown , PostgreSQL Hackers References: <2234935.1741809008@sss.pgh.pa.us> <2c9376aa-9c66-4662-9803-3d9bc2afead1@gmail.com> Content-Language: en-US From: Andrei Lepikhov 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 On 19/3/2025 21:51, Sami Imseih wrote: >> Why do you think this hook is not redundant? > what is it redundant with? > >> It would be better to add the parameter "type: EXPLAIN_ONLY | >> ANALYZE_ONLY | BOTH" to the RegisterExtensionExplainOption() routine. >> This value will be saved inside the ExplainExtensionOption structure and >> processed by the core inside the ParseExplainOptionList. > > hmm, IIUC, what you are describing is flag that will be limited to > only check if an option can be used with EXPLAIN_ONLY, ANALYZE_ONLY > or both. But what about if I have a case to check against between other > extension options? let's say ExtensionAOptionA and ExtensionAoptionB. > How would that work with the way you are suggesting? That makes sense. It would be more effective to include the meaningful example in Robert's extension for v7-0001. I'm sorry, I was confused; previously, the difficulties faced by extension developers were always attributed to him (refer to the discussion on the selectivity hook). However, now you're introducing a hook for a trivial operation that could simply be resolved at the end of execution within a per-node hook with tiny inconsistency in output. I'm pleased to see a change in the narrative. -- regards, Andrei Lepikhov