Please add Postgres BDR support for migrations #770
Labels
No Label
backport/done
backport/v1
blocked
db
oracle
db
sqlserver
duplicate
feature
cache
frontport/done
frontport/main
invalid
kind
breaking
kind
bug
kind
build
kind
dependencies
kind
docs
kind
driver
kind
enhancement
kind
feature
kind
performance
kind
proposal
kind
question
kind
refactor
kind
testing
need
feedback
need
test
proposal:accepted
RaspBerry Pi
regression
skip-changelog
upstream
wip
wontfix
No Milestone
No Assignees
1 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: xorm/xorm#770
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
BDR is an open-source multi-master solution for Postgres backed by 2ndquadrant. XORM already works great with it in case of DML (I use it with Gitea). But during migrations (DML) I often encounter the following issues:
Adding column to an existing table with a default value:
Solution for is easy:
Sequences are not global
This causes problems only on the long-run. It should just try to execute:
ALTER SEQUENCE table_id_seq USING bdr;
It will fail if it's s not a BDR database, but still better. It's not that important by the way. I could just set default_sequenceam = 'bdr' in the server's configuration.
Actually there could be another issue:
ERROR: Cannot run UPDATE or DELETE on table table_name because it does not have a PRIMARY KEY.
But I think there is nothing to do with this, the schema should make sure there is a primary key on all the tables.
So to summerize, if only the first problem can be solved I would be very happy. Actually this would benefit any use who uses logical level replication.