Re: Logical Replication of sequences
vignesh C <vignesh21@gmail.com>
Commits
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Doc: Add documentation for sequence synchronization.
- 55cefadde874 19 (unreleased) landed
-
Remove unused assignment in CREATE PUBLICATION grammar.
- bfb7419b0bbe 19 (unreleased) landed
-
Add seq_sync_error_count to subscription statistics.
- f6a4c498dcf6 19 (unreleased) landed
-
Fix few issues in commit 5509055d69.
- 5a4eba558aa7 19 (unreleased) landed
-
Add sequence synchronization for logical replication.
- 5509055d6956 19 (unreleased) landed
-
Add worker type argument to logical replication worker functions.
- 3e8e05596a02 19 (unreleased) landed
-
Introduce "REFRESH SEQUENCES" for subscriptions.
- f0b3573c3aac 19 (unreleased) landed
-
Refactor logical worker synchronization code into a separate file.
- 41c674d2e31e 19 (unreleased) landed
-
Standardize use of REFRESH PUBLICATION in code and messages.
- 2436b8c047ff 19 (unreleased) landed
-
Add "ALL SEQUENCES" support to publications.
- 96b378497346 19 (unreleased) landed
-
Expose sequence page LSN via pg_get_sequence_data.
- b93172ca59f4 19 (unreleased) landed
-
Resume conflict-relevant data retention automatically.
- 0d48d393d465 19 (unreleased) cited
-
Post-commit review fixes for 228c370868.
- 1f7e9ba3ac4e 19 (unreleased) cited
-
Generate GUC tables from .dat file
- 63599896545c 19 (unreleased) cited
On Tue, 7 Oct 2025 at 10:53, shveta malik <shveta.malik@gmail.com> wrote: > > On Mon, Oct 6, 2025 at 4:33 PM vignesh C <vignesh21@gmail.com> wrote: > > > > > > Here is the rebased remaining patches. > > > > Thank You for the patches, please find a few comment on 001: > > 1) > Shall we have 'pg_publication_sequences' created in the first patch > itself to help verify which all sequences are added to ALL SEQ > publications? Currently it is in 4th patch. Moved it to 0001 patch > 2) > postgres=# create publication pub1 for all sequences WITH(publish='insert'); > ERROR: publication parameters are not supported for publications > defined as FOR ALL SEQUENCES > > postgres=# alter publication pub1 add table tab1; > ERROR: Tables or sequences cannot be added to or dropped from > publication defined FOR ALL TABLES, ALL SEQUENCES, or both > > a) First msg has 'as', while second does not. Shall we make both the > same? I think we can get rid of 'as'. The second error message is changed now based on another comment, so both of them will have as now. > b) Shouldn't the error msg start with lower case (second one)? Updated > 3) > + * Process all_objects_list to set all_tables/all_sequences. > > can we please replace 'all_tables/all_sequences' with 'all_tables > and/or all_sequences' Updated > 4) > +/* > + * Publication types supported by FOR ALL ... > + */ > +typedef enum PublicationAllObjType > > Should it be: > 'Types of objects supported by FOR ALL publications' Modified > 5) > +-- Specifying both ALL TABLES and ALL SEQUENCES along with WITH > clause should throw a warning > +SET client_min_messages = 'NOTICE'; > +CREATE PUBLICATION regress_pub_for_allsequences_alltables_withcaluse > FOR ALL SEQUENCES, ALL TABLES WITH (publish = 'insert'); > +NOTICE: publication parameters are not applicable to sequence > synchronization and will be ignored > > Comment can be changed to say it will emit/raise a NOTICE (instead of warning). Modified > 6) > commit msg: > -- > Note: This patch currently supports only the "ALL SEQUENCES" clause. > Handling of clauses such as "FOR SEQUENCE" and "FOR SEQUENCES IN SCHEMA" > will be addressed in a subsequent patch. > -- > > This seems misleading, as we are not planning the "FOR SEQUENCE" in > the current set of patches, maybe we can rephrase it a bit. Modified Thanks for the comments, the v20251007 patch attached at [1] has the changes for the same. [1] - https://www.postgresql.org/message-id/CALDaNm3NJBiXpQ3uY8%3DXhSPd6jBn2rTJS6wJZSFo6m2pzW5hqw%40mail.gmail.com Regards, Vignesh