Remove migration paths to 9.3-1, introduce 9.3-2

pull/3700/head
Hanefi Önaldı 2020-04-02 17:30:25 +03:00
parent 710970407f
commit d1223bd6cc
No known key found for this signature in database
GPG Key ID: 45A2ACB84E394FBA
9 changed files with 47 additions and 8 deletions

View File

@ -1,6 +1,6 @@
# Citus extension
comment = 'Citus distributed database'
default_version = '9.3-1'
default_version = '9.3-2'
module_pathname = '$libdir/citus'
relocatable = false
schema = pg_catalog

View File

@ -0,0 +1,2 @@
/* we've some issues with versioning, and we're fixing it by bumping version */
/* from 9.2-2 to 9.2-4 see #3673 for details */

View File

@ -1,6 +0,0 @@
/* citus--9.2-2--9.3-1 */
/* bump version to 9.3-1 */
#include "udfs/citus_extradata_container/9.3-1.sql"
#include "udfs/update_distributed_table_colocation/9.3-1.sql"

View File

@ -0,0 +1,6 @@
/* citus--9.2-4--9.3-2 */
/* bump version to 9.3-2 */
#include "udfs/citus_extradata_container/9.3-2.sql"
#include "udfs/update_distributed_table_colocation/9.3-2.sql"

View File

@ -0,0 +1,18 @@
/* citus--9.3-1--9.2-4 */
/* this is an unusual upgrade path, we are doing it because */
/* we have accidentally tagged master branch with v9.2-3 */
/* however master branch was already bumped to v9.3-1 */
/* with this file, we are undoing the catalog changes that */
/* have happened between 9.2-2 to 9.3-1, and making 9.2-4 */
/* as the release that we can */
-- undo the changes for citus_extradata_container that happened on citus 9.3
DROP FUNCTION IF EXISTS pg_catalog.citus_extradata_container(INTERNAL);
CREATE FUNCTION pg_catalog.citus_extradata_container(INTERNAL)
RETURNS void
LANGUAGE C
AS 'MODULE_PATHNAME', $$citus_extradata_container$$;
COMMENT ON FUNCTION pg_catalog.citus_extradata_container(INTERNAL)
IS 'placeholder function to store additional data in postgres node trees';
DROP FUNCTION IF EXISTS pg_catalog.update_distributed_table_colocation(regclass, text);

View File

@ -119,7 +119,17 @@ ALTER EXTENSION citus UPDATE TO '9.0-1';
ALTER EXTENSION citus UPDATE TO '9.0-2';
ALTER EXTENSION citus UPDATE TO '9.1-1';
ALTER EXTENSION citus UPDATE TO '9.2-1';
ALTER EXTENSION citus UPDATE TO '9.3-1';
ALTER EXTENSION citus UPDATE TO '9.2-2';
ALTER EXTENSION citus UPDATE TO '9.2-4';
/*
* As we mistakenly bumped schema version to 9.3-1 (in previous
* release), we support updating citus schema from 9.3-1 to 9.2-4,
* but we do not support explicitly updating it to to 9.3-1.
* Hence below update (to 9.3-1) command should fail.
*/
ALTER EXTENSION citus UPDATE TO '9.3-1';
ERROR: extension "citus" has no update path from version "9.2-4" to version "9.3-1"
ALTER EXTENSION citus UPDATE TO '9.3-2';
-- show running version
SHOW citus.version;
citus.version

View File

@ -120,7 +120,16 @@ ALTER EXTENSION citus UPDATE TO '9.0-1';
ALTER EXTENSION citus UPDATE TO '9.0-2';
ALTER EXTENSION citus UPDATE TO '9.1-1';
ALTER EXTENSION citus UPDATE TO '9.2-1';
ALTER EXTENSION citus UPDATE TO '9.2-2';
ALTER EXTENSION citus UPDATE TO '9.2-4';
/*
* As we mistakenly bumped schema version to 9.3-1 (in previous
* release), we support updating citus schema from 9.3-1 to 9.2-4,
* but we do not support explicitly updating it to to 9.3-1.
* Hence below update (to 9.3-1) command should fail.
*/
ALTER EXTENSION citus UPDATE TO '9.3-1';
ALTER EXTENSION citus UPDATE TO '9.3-2';
-- show running version
SHOW citus.version;