Bug #349 - case insensitivity with cluster name when processing DDL
authorChristopher Browne <cbbrowne@ca.afilias.info>
Tue, 16 Dec 2014 20:30:40 +0000 (15:30 -0500)
committerChristopher Browne <cbbrowne@ca.afilias.info>
Tue, 16 Dec 2014 20:32:06 +0000 (15:32 -0500)
Cluster name wasn't properly quoted when processing sequence update, this logic only runs when doing DDL.

Added config change to regression tests to have StudlyCase names to ensure this is noticed in future

Conflicts:
RELEASE

RELEASE
clustertest/conf/disorder.properties.sample
clustertest/conf/slonyregress.sample.properties
src/backend/slony1_funcs.c
tests/settings.ik

diff --git a/RELEASE b/RELEASE
index bf71f86946633913075d6ff865a3d4227eb04b34..159de720a59de2b6f56efa9ee7b8c41a3b6e2cd1 100644 (file)
--- a/RELEASE
+++ b/RELEASE
@@ -10,3 +10,4 @@
        the 2.3 branch.
 
    - Bug 352 :: Issues with PostgreSQL "head" (what shall become 9.5 or so).  It is pretty usual for #include files to shift a bit and for functions to change arguments a bit.
+   - Bug 349 :: Issue with quoting of cluster name - only hit when processing DDL
index 36e0c590360197750f88e05cebbd957bfc6d3274..c67e13c69f1af8a533a71ea19830177fec2d4d9d 100644 (file)
@@ -74,7 +74,7 @@ database.db6.password.slony=slon
 slonik.path=/usr/local/pgsql8.3/bin/slonik
 slon.path=/usr/local/pgsql8.3/bin/slon
 ### slon.loglevel=4
-clustername=disorder_replica
+clustername=Disorder_Replica
 slony_dump.path=/usr/local/pgsql8.3/bin/slony1_dump.sh
 
 output.directory=results
index eeadb539c887291014633e8b65ba786488da38d6..491678f6d4d4d9d578b6ee3a249959763cb22463 100644 (file)
@@ -49,7 +49,7 @@ slonik.path=/usr/local/pgsql8.3/bin/slonik
 slon.path=/usr/local/pgsql8.3/bin/slon
 #slonik.path=/usr/local/pgsql8.3/bin/slonik
 #slon.path=/usr/local/pgsql8.3/bin/slon
-clustername=slonyregress
+clustername=SlonyRegress
 
 output.directory=results
 log4j.conf=conf/log4j.properties
index acc902b34790d41a6d77fe2a0ac104cdcc0e959a..22d55be7ab1da2da790265628ddbba465e32c64f 100644 (file)
@@ -1102,7 +1102,7 @@ versionFunc(logApply) (PG_FUNCTION_ARGS)
                        argtypes[1] = INT4OID;
                        argtypes[2] = INT8OID;
 
-                       snprintf(query, 1023, "select %s.sequenceSetValue($1," \
+                       snprintf(query, 1023, "select \"%s\".sequenceSetValue($1," \
                                         "$2,NULL,$3,true); ", tg->tg_trigger->tgargs[0]);
                        plan = SPI_prepare(query, 3, argtypes);
                        if (plan == NULL)
index 7730facacfe9f2ee5463764be79327f9b68770c4..a7fa41d572b8546e7b598820fba4d0c6ecaaf73b 100644 (file)
@@ -2,7 +2,7 @@
 # This file contains the various sets of possible DB
 # configuration defaults/overrides
 
-CLUSTER1=${CLUSTER1:-"slony_regress1"}
+CLUSTER1=${CLUSTER1:-"Slony_Regress1"}
 CLUSTER2=${CLUSTER2:-"slony_regress2"}
 CLUSTER3=${CLUSTER3:-"slony_regress3"}