pgsql: Expose sequence page LSN via pg_get_sequence_data.

From: Amit Kapila <akapila(at)postgresql(dot)org>
To: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: pgsql: Expose sequence page LSN via pg_get_sequence_data.
Date: 2025-10-06 08:37:30
Message-ID: E1v5gio-000JHr-2D@gemulon.postgresql.org
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Expose sequence page LSN via pg_get_sequence_data.

This patch enhances the pg_get_sequence_data function to include the
page-level LSN (Log Sequence Number) of the sequence. This additional
metadata will be used by upcoming patches to support synchronization
of sequences during logical replication.

By exposing the LSN, we enable more accurate tracking of sequence
changes, which is essential for maintaining consistency across
replicated nodes.

Author: vignesh C <vignesh21(at)gmail(dot)com>
Reviewed-by: shveta malik <shveta(dot)malik(at)gmail(dot)com>
Reviewed-by: Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com>
Reviewed-by: Hayato Kuroda <kuroda(dot)hayato(at)fujitsu(dot)com>
Reviewed-by: Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>
Discussion: https://www.postgresql.org/message-id/CAA4eK1LC+KJiAkSrpE_NwvNdidw9F2os7GERUeSxSKv71gXysQ@mail.gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/b93172ca59f4ae317b2b9dfbf7f342b237101256

Modified Files
--------------
src/backend/commands/sequence.c | 10 ++++++++--
src/include/catalog/catversion.h | 2 +-
src/include/catalog/pg_proc.dat | 4 ++--
src/test/regress/expected/sequence.out | 8 ++++----
src/test/regress/sql/sequence.sql | 2 +-
5 files changed, 16 insertions(+), 10 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Andrew Dunstan 2025-10-06 11:55:43 pgsql: Revert "Improve docs syntax checking"
Previous Message Michael Paquier 2025-10-06 07:26:56 pgsql: Add comment in ginxlog.h about block used with ginxlogInsertList