From aed881d1e6999c9047829e39edbdcda5a9f0d9d8 Mon Sep 17 00:00:00 2001 From: Daniel Gustafsson Date: Fri, 30 Sep 2016 09:04:45 +0200 Subject: [PATCH] Set the upper bound on FTS Probe GUCs to 3600 seconds Using INT_MAX is problematic in the case of gp_fts_probe_timeout since calculations on it can overflow at INT_MAX. Using INT_MAX gp_fts_probe_interval won't overflow with current usage but running the FTS probe every INT_MAX seconds is nonsensical. --- src/backend/utils/misc/guc_gp.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/backend/utils/misc/guc_gp.c b/src/backend/utils/misc/guc_gp.c index 3ddec79338..428225e71e 100644 --- a/src/backend/utils/misc/guc_gp.c +++ b/src/backend/utils/misc/guc_gp.c @@ -4117,7 +4117,7 @@ struct config_int ConfigureNamesInt_gp[] = GUC_UNIT_S }, &gp_fts_probe_timeout, - 20, 0, INT_MAX, NULL, NULL + 20, 0, 3600, NULL, NULL }, { @@ -4127,7 +4127,7 @@ struct config_int ConfigureNamesInt_gp[] = GUC_UNIT_S }, &gp_fts_probe_interval, - 60, 10, INT_MAX, NULL, NULL + 60, 10, 3600, NULL, NULL }, { -- GitLab