v9-0001-Standardize-parameter-descriptions-in-auto_explain.patch

text/x-patch

Filename: v9-0001-Standardize-parameter-descriptions-in-auto_explain.patch
Type: text/x-patch
Part: 0
Message: Re: describe special values in GUC descriptions more consistently

Patch

Format: format-patch
Series: patch v9-0001
Subject: Standardize parameter descriptions in auto_explain
File+
contrib/auto_explain/auto_explain.c 2 2
From 44f60949a4636eb649d29d752a55a8410213d12e Mon Sep 17 00:00:00 2001
From: Ilia Evdokimov <ilya.evdokimov@tantorlabs.com>
Date: Tue, 18 Feb 2025 01:02:15 +0300
Subject: [PATCH v9] Standardize parameter descriptions in auto_explain

Align the descriptions of log_min_duration and log_parameter_max_length
in auto_explain with the formatting conventions used for other GUC parameters,
as established in commit 977d865.

Remove the description of the zero value for log_parameter_max_length,
as there are numerous examples of similar "max" GUC parameters that
do not explicitly mention zero, as its meaning is considered clear.
---
 contrib/auto_explain/auto_explain.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/contrib/auto_explain/auto_explain.c b/contrib/auto_explain/auto_explain.c
index f1ad876e82..1c6f840e30 100644
--- a/contrib/auto_explain/auto_explain.c
+++ b/contrib/auto_explain/auto_explain.c
@@ -93,7 +93,7 @@ _PG_init(void)
 	/* Define custom GUC variables. */
 	DefineCustomIntVariable("auto_explain.log_min_duration",
 							"Sets the minimum execution time above which plans will be logged.",
-							"Zero prints all plans. -1 turns this feature off.",
+							"-1 disables logging plans. 0 means log all plans.",
 							&auto_explain_log_min_duration,
 							-1,
 							-1, INT_MAX,
@@ -105,7 +105,7 @@ _PG_init(void)
 
 	DefineCustomIntVariable("auto_explain.log_parameter_max_length",
 							"Sets the maximum length of query parameters to log.",
-							"Zero logs no query parameters, -1 logs them in full.",
+							"-1 means log parameter values in full.",
 							&auto_explain_log_parameter_max_length,
 							-1,
 							-1, INT_MAX,
-- 
2.34.1