|
69 | 69 |
|
70 | 70 | pass('index predicates do not cause crash');
|
71 | 71 |
|
| 72 | +# We'll re-use these nodes below, so drop their replication state. |
| 73 | +# We don't bother to drop the tables though. |
| 74 | +$node_subscriber->safe_psql('postgres', "DROP SUBSCRIPTION sub1"); |
| 75 | +$node_publisher->safe_psql('postgres', "DROP PUBLICATION pub1"); |
| 76 | + |
72 | 77 | $node_publisher->stop('fast');
|
73 | 78 | $node_subscriber->stop('fast');
|
74 | 79 |
|
|
81 | 86 | # identity set before accepting updates. If it did not it would cause
|
82 | 87 | # an error when an update was attempted.
|
83 | 88 |
|
84 |
| -$node_publisher = PostgreSQL::Test::Cluster->new('publisher2'); |
85 |
| -$node_publisher->init(allows_streaming => 'logical'); |
86 |
| -$node_publisher->start; |
| 89 | +$node_publisher->rotate_logfile(); |
| 90 | +$node_publisher->start(); |
| 91 | + |
| 92 | +# Although we don't use node_subscriber in this test, keep its logfile |
| 93 | +# name in step with node_publisher for later tests. |
| 94 | +$node_subscriber->rotate_logfile(); |
87 | 95 |
|
88 | 96 | $node_publisher->safe_psql('postgres',
|
89 | 97 | "CREATE PUBLICATION pub FOR ALL TABLES");
|
|
102 | 110 | 'update to unlogged table without replica identity with FOR ALL TABLES publication'
|
103 | 111 | );
|
104 | 112 |
|
| 113 | +# Again, drop replication state but not tables. |
| 114 | +$node_publisher->safe_psql('postgres', "DROP PUBLICATION pub"); |
| 115 | + |
105 | 116 | $node_publisher->stop('fast');
|
106 | 117 |
|
| 118 | + |
107 | 119 | # Bug #16643 - https://postgr.es/m/16643-eaadeb2a1a58d28c@postgresql.org
|
108 | 120 | #
|
109 | 121 | # Initial sync doesn't complete; the protocol was not being followed per
|
|
226 | 238 | # target table's relcache was not being invalidated. This leads to skipping
|
227 | 239 | # UPDATE/DELETE operations during apply on the subscriber side as the columns
|
228 | 240 | # required to search corresponding rows won't get logged.
|
229 |
| -$node_publisher = PostgreSQL::Test::Cluster->new('publisher3'); |
230 |
| -$node_publisher->init(allows_streaming => 'logical'); |
231 |
| -$node_publisher->start; |
232 | 241 |
|
233 |
| -$node_subscriber = PostgreSQL::Test::Cluster->new('subscriber3'); |
234 |
| -$node_subscriber->init(allows_streaming => 'logical'); |
235 |
| -$node_subscriber->start; |
| 242 | +$node_publisher->rotate_logfile(); |
| 243 | +$node_publisher->start(); |
| 244 | + |
| 245 | +$node_subscriber->rotate_logfile(); |
| 246 | +$node_subscriber->start(); |
236 | 247 |
|
237 | 248 | $node_publisher->safe_psql('postgres',
|
238 | 249 | "CREATE TABLE tab_replidentity_index(a int not null, b int not null)");
|
|
0 commit comments