remove unused GUC options - strict_statement_checking and enforce_two_phase_commit
authorTomas Vondra <[email protected]>
Mon, 22 Aug 2016 22:05:24 +0000 (00:05 +0200)
committerPavan Deolasee <[email protected]>
Tue, 18 Oct 2016 10:07:44 +0000 (15:37 +0530)
These two options were ineffective - defined and listed in the sample
configuration file, but attached to unreferenced variables.

src/backend/pgxc/plan/planner.c
src/backend/pgxc/pool/execRemote.c
src/backend/utils/misc/guc.c
src/backend/utils/misc/postgresql.conf.sample
src/include/pgxc/execRemote.h
src/include/pgxc/planner.h

index 0212c8773673d3961c1de79b3d4e09f09b240ef9..d00d7b8ffad88fb5434a7d4a24d1cc2e0d6fbb8c 100644 (file)
@@ -61,8 +61,6 @@
 #include "utils/timestamp.h"
 #include "utils/date.h"
 
-/* Forbid unsafe SQL statements */
-bool           StrictStatementChecking = true;
 
 static bool contains_temp_tables(List *rtable);
 static PlannedStmt *pgxc_FQS_planner(Query *query, ParamListInfo boundParams);
index 380626bea45feb3ed3a7cecf097da6813b52c88c..46561765914d7e93f0f9888c84e4905013284ebf 100644 (file)
@@ -57,8 +57,6 @@
 #include "parser/parsetree.h"
 #include "pgxc/xc_maintenance_mode.h"
 
-/* Enforce the use of two-phase commit when temporary objects are used */
-bool EnforceTwoPhaseCommit = true;
 /*
  * We do not want it too long, when query is terminating abnormally we just
  * want to read in already available data, if datanode connection will reach a
index 9c9571f54a51f50f87684351b63bbeb7007b8b81..d2022d24e600f8dfe2d7c8a02ea34978a447395f 100644 (file)
@@ -1726,25 +1726,6 @@ static struct config_bool ConfigureNamesBool[] =
                false,
                check_persistent_connections, NULL, NULL
        },
-       {
-               {"strict_statement_checking", PGC_USERSET, DEVELOPER_OPTIONS,
-                       gettext_noop("Forbid statements that are not safe for the cluster"),
-                       NULL
-               },
-               &StrictStatementChecking,
-               true,
-               NULL, NULL, NULL
-       },
-       {
-               {"enforce_two_phase_commit", PGC_SUSET, XC_HOUSEKEEPING_OPTIONS,
-                       gettext_noop("Enforce the use of two-phase commit on transactions that"
-                                       "made use of temporary objects"),
-                       NULL
-               },
-               &EnforceTwoPhaseCommit,
-               true,
-               NULL, NULL, NULL
-       },
        {
                {"xc_maintenance_mode", PGC_SUSET, XC_HOUSEKEEPING_OPTIONS,
                    gettext_noop("Turn on XC maintenance mode."),
index adcb200ca748049198ffa18df39e24c97301c47c..1de0a847d8363407d6ef99cb98f22653349d31b1 100644 (file)
 
 #gtm_backup_barrier = off              # Specify to backup gtm restart point for each barrier.
 
-##------------------------------------------------------------------------------
-# OTHER PG-XC OPTIONS
-#------------------------------------------------------------------------------
-#strict_statement_checking = on                # Forbid PG-XC-unsafe SQL
-                                       # Enabling is useful for development
-#enforce_two_phase_commit = on         # Enforce the usage of two-phase commit on transactions
-                                       # where temporary objects are used or ON COMMIT actions
-                                       # are pending.
-                                       # Usage of commit instead of two-phase commit may break
-                                       # data consistency so use at your own risk.
 
 #------------------------------------------------------------------------------
 # CONFIG FILE INCLUDES
index d8c1d6fa1cda779ffeb1102b200d6408a3f57c97..4cbcbec4ad7057d61e1aaaba7a0f509298006def 100644 (file)
@@ -32,9 +32,6 @@
 #include "tcop/pquery.h"
 #include "utils/snapshot.h"
 
-/* GUC parameters */
-extern bool EnforceTwoPhaseCommit;
-
 /* Outputs of handle_response() */
 #define RESPONSE_EOF EOF
 #define RESPONSE_COMPLETE 0
index f6357cd71155555da0c01d23b9328621987c4c5b..62c07c821b9a411458b185a50d85bf1e038efec1 100644 (file)
@@ -207,9 +207,6 @@ typedef enum
        SS_UPDATES_DISTRIBUTION_COLUMN  /* query updates distribution column */
 } ShippabilityStat;
 
-/* forbid SQL if unsafe, useful to turn off for development */
-extern bool StrictStatementChecking;
-
 extern bool pgxc_shippability_walker(Node *node, Shippability_context *sc_context);
 extern bool pgxc_test_shippability_reason(Shippability_context *context,
                                                                                        ShippabilityStat reason);