Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions include/spock.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@
#include "spock_fe.h"
#include "spock_node.h"

#define SPOCK_VERSION "6.0.0-devel"
#define SPOCK_VERSION_NUM 60000
#define SPOCK_VERSION "5.1.0"
#define SPOCK_VERSION_NUM 50100

#define EXTENSION_NAME "spock"
#define SPOCK_SECLABEL_PROVIDER "spock"
Expand Down
27 changes: 25 additions & 2 deletions sql/spock--5.0.6--6.0.0-devel.sql → sql/spock--5.0.6--5.1.0.sql
Original file line number Diff line number Diff line change
@@ -1,7 +1,30 @@
/* spock--5.0.6--6.0.0-devel.sql */
/* spock--5.0.6--5.1.0.sql */

-- complain if script is sourced in psql, rather than via ALTER EXTENSION
\echo Use "ALTER EXTENSION spock UPDATE TO '6.0.0-devel'" to load this file. \quit
\echo Use "ALTER EXTENSION spock UPDATE TO '5.1.0'" to load this file. \quit

-- Fix sub_skip_schema column type: was added as text in 5.0.1->5.0.2, must be text[]
ALTER TABLE spock.subscription
ALTER COLUMN sub_skip_schema TYPE text[] USING sub_skip_schema::text[];

-- Drop functions removed from the 5.1.0 fresh install (present since 5.0.0 but no longer needed)
DROP FUNCTION IF EXISTS spock.convert_column_to_int8(regclass, smallint);
DROP FUNCTION IF EXISTS spock.convert_sequence_to_snowflake(regclass);

-- Add IMMUTABLE PARALLEL SAFE to md5_agg_sfunc (was missing in earlier definitions)
CREATE OR REPLACE FUNCTION spock.md5_agg_sfunc(text, anyelement)
RETURNS text
AS $$ SELECT md5($1 || $2::text) $$
LANGUAGE sql IMMUTABLE PARALLEL SAFE;

-- Add named parameters to spock_gen_slot_name (originally created without names in 5.0.0)
CREATE OR REPLACE FUNCTION spock.spock_gen_slot_name(
dbname name,
provider_node name,
subscription name
) RETURNS name
AS 'MODULE_PATHNAME'
LANGUAGE C IMMUTABLE STRICT PARALLEL SAFE;

DROP VIEW IF EXISTS spock.lag_tracker;
DROP TABLE IF EXISTS spock.progress;
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion tests/regress/expected/init_1.out
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ CREATE EXTENSION IF NOT EXISTS spock;
List of installed extensions
Name | Version | Default version | Schema | Description
-------+-------------+-----------------+--------+--------------------------------
spock | 6.0.0-devel | 6.0.0-devel | spock | PostgreSQL Logical Replication
spock | 5.1.0 | 5.1.0 | spock | PostgreSQL Logical Replication
(1 row)

SELECT * FROM spock.node_create(node_name := 'test_provider', dsn := (SELECT provider_dsn FROM spock_regress_variables()) || ' user=super');
Expand Down
2 changes: 1 addition & 1 deletion tests/regress/expected/init_fail.out
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ SET client_min_messages = 'warning';
\set VERBOSITY terse
DO $$
BEGIN
CREATE EXTENSION IF NOT EXISTS spock VERSION '6.0.0-devel';
CREATE EXTENSION IF NOT EXISTS spock VERSION '5.1.0';
END;
$$;
ALTER EXTENSION spock UPDATE;
Expand Down
2 changes: 1 addition & 1 deletion tests/regress/sql/init_fail.sql
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ SET client_min_messages = 'warning';

DO $$
BEGIN
CREATE EXTENSION IF NOT EXISTS spock VERSION '6.0.0-devel';
CREATE EXTENSION IF NOT EXISTS spock VERSION '5.1.0';
END;
$$;
ALTER EXTENSION spock UPDATE;
Expand Down
2 changes: 2 additions & 0 deletions tests/tap/schedule
Original file line number Diff line number Diff line change
Expand Up @@ -43,3 +43,5 @@ test: 015_forward_origin_advance
test: 016_crash_recovery_progress
test: 016_sub_disable_missing_relation
test: 017_zodan_3n_timeout
# Upgrade schema match test (builds from source, slow):
#test: 018_upgrade_schema_match
Loading
Loading