pglogical icon indicating copy to clipboard operation
pglogical copied to clipboard

UPDATEs are not replicated ((tuple not found). Resolution: skip.)

Open oleksandrg opened this issue 3 years ago • 1 comments

Updates from TABLE A(PK column is integer) are correctly replicated but for TABLE B(PK varying(36)) all updates are failed with the same data:

PostgresSQL version:

  • provider: 13.3
  • subscriber: 13.3

Extensions (on btoh):

  • pglogical 2.3.4
  • postgis 3.1.2
  • uuid-ossp 1.1

Test Tables: TABLE A:

CREATE TABLE myschema.test_idint (
    geometry public.geometry,
    id integer NOT NULL,
    note text
);
ALTER TABLE ONLY myschema.test_idint
    ADD CONSTRAINT test_idint_pkey PRIMARY KEY (id);

TABLE B:

CREATE TABLE myschema.test_idtext (
    id character varying(36) NOT NULL,
    geometry public.geometry,
    note text
);
ALTER TABLE ONLY myschema.test_idtext
    ADD CONSTRAINT test_idtext_pkey PRIMARY KEY (id);
2021-08-11 15:04:03.416 EEST [9706] CONTEXT:  apply (unknown action) in commit before 0/0, xid 0 committed at 2000-01-01 02:00:00+02 (action #0) from node replorigin 1
2021-08-11 15:04:03.416 EEST [9706] DEBUG:  changeset origin forwarding enabled: t
2021-08-11 15:04:03.416 EEST [9706] CONTEXT:  apply (unknown action) in commit before 0/0, xid 0 committed at 2000-01-01 02:00:00+02 (action #0) from node replorigin 1
2021-08-11 15:04:25.455 EEST [9713] DEBUG:  autovacuum: processing database "subreplica"
2021-08-11 15:04:30.841 EEST [9706] LOG:  CONFLICT: remote UPDATE on relation myschema.test_idtext replica identity index test_idtext_pkey (tuple not found). Resolution: skip.
2021-08-11 15:04:30.841 EEST [9706] DETAIL:  remote tuple {id[varchar]:(null) geometry[geometry]:(null) note[text]:note2_update} in xact origin=1,timestamp=2021-08-11 15:04:30.839311+03,commit_lsn=0/215CC50
2021-08-11 15:04:30.841 EEST [9706] CONTEXT:  apply UPDATE from remote relation myschema.test_idtext in commit before 0/215CC50, xid 507 committed at 2021-08-11 15:04:30.839311+03 (action #2) from node replorigin 1

Data was the same for both tables except PK. dmls.zip

Any ideas how we can resolve this? Thank you in advance

oleksandrg avatar Aug 11 '21 13:08 oleksandrg

Have you got your answer yet??

imaddi47 avatar Mar 06 '22 21:03 imaddi47