mirror of
https://github.com/postgres/postgres.git
synced 2025-10-13 18:28:01 +03:00
Switch pg_promote to be parallel-safe
pg_promote uses nothing relying on a global state, so it is fine to mark it as parallel-safe, conclusion based on a detailed analysis from Robert Haas. This also fixes an inconsistency where pg_proc.dat missed to mark the function with its previous value for proparallel, update which does not matter now as the default is used. Based on a discussion between multiple folks: Laurenz Albe, Robert Haas, Amit Kapila, Tom Lane and myself. Discussion: https://postgr.es/m/20181029082530.GL14242@paquier.xyz
This commit is contained in:
@@ -1030,7 +1030,7 @@ CREATE OR REPLACE FUNCTION pg_stop_backup (
|
|||||||
CREATE OR REPLACE FUNCTION
|
CREATE OR REPLACE FUNCTION
|
||||||
pg_promote(wait boolean DEFAULT true, wait_seconds integer DEFAULT 60)
|
pg_promote(wait boolean DEFAULT true, wait_seconds integer DEFAULT 60)
|
||||||
RETURNS boolean STRICT VOLATILE LANGUAGE INTERNAL AS 'pg_promote'
|
RETURNS boolean STRICT VOLATILE LANGUAGE INTERNAL AS 'pg_promote'
|
||||||
PARALLEL RESTRICTED;
|
PARALLEL SAFE;
|
||||||
|
|
||||||
-- legacy definition for compatibility with 9.3
|
-- legacy definition for compatibility with 9.3
|
||||||
CREATE OR REPLACE FUNCTION
|
CREATE OR REPLACE FUNCTION
|
||||||
|
@@ -53,6 +53,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
/* yyyymmddN */
|
/* yyyymmddN */
|
||||||
#define CATALOG_VERSION_NO 201811051
|
#define CATALOG_VERSION_NO 201811061
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
Reference in New Issue
Block a user