-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
drop replication slot, if it already exists.
- Loading branch information
Showing
1 changed file
with
11 additions
and
5 deletions.
There are no files selected for viewing
16 changes: 11 additions & 5 deletions
16
...rc/main/resources/db_nakadiproducer/migrations/V2/V2133546886.1.4__create_publication.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,12 @@ | ||
CREATE PUBLICATION nakadi_producer_eventlog | ||
FOR TABLE nakadi_events.event_log; | ||
CREATE PUBLICATION nakadi_producer_fes | ||
FOR TABLE nakadi_events.event_log; | ||
|
||
COMMENT ON PUBLICATION nakadi_producer_eventlog | ||
IS 'Publication for collecting event data data via Fabric Event Streams.' | ||
'If you didn''t set FES up, it won''t be used and do no harm.'; | ||
COMMENT ON PUBLICATION nakadi_producer_fes | ||
IS 'Publication for collecting event data data via Fabric Event Streams.' | ||
'If you didn''t set FES up, it won''t be used and do no harm.'; | ||
|
||
-- We drop the slot in case it already exists (e.g. created by Patroni from the database manifest), | ||
-- as it needs to be created after the publication. | ||
SELECT pg_drop_replication_slot(slot_name) | ||
FROM pg_replication_slots | ||
WHERE slot_name = 'nakadi_producer_fes'; |