From d10c626de47d8b048b663471c7785603a2ec8641 Mon Sep 17 00:00:00 2001 From: Tom Lane Date: Thu, 11 May 2017 11:49:59 -0400 Subject: Rename WAL-related functions and views to use "lsn" not "location". Per discussion, "location" is a rather vague term that could refer to multiple concepts. "LSN" is an unambiguous term for WAL locations and should be preferred. Some function names, view column names, and function output argument names used "lsn" already, but others used "location", as well as yet other terms such as "wal_position". Since we've already renamed a lot of things in this area from "xlog" to "wal" for v10, we may as well incur a bit more compatibility pain and make these names all consistent. David Rowley, minor additional docs hacking by me Discussion: https://postgr.es/m/CAKJS1f8O0njDKe8ePFQ-LK5-EjwThsDws6ohJ-+c6nWK+oUxtg@mail.gmail.com --- src/backend/access/transam/xlogfuncs.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/backend/access/transam/xlogfuncs.c') diff --git a/src/backend/access/transam/xlogfuncs.c b/src/backend/access/transam/xlogfuncs.c index 5041f0e2a94..aa47b0dcffc 100644 --- a/src/backend/access/transam/xlogfuncs.c +++ b/src/backend/access/transam/xlogfuncs.c @@ -351,7 +351,7 @@ pg_create_restore_point(PG_FUNCTION_ARGS) * to the kernel, but is not necessarily synced to disk. */ Datum -pg_current_wal_location(PG_FUNCTION_ARGS) +pg_current_wal_lsn(PG_FUNCTION_ARGS) { XLogRecPtr current_recptr; @@ -372,7 +372,7 @@ pg_current_wal_location(PG_FUNCTION_ARGS) * This function is mostly for debugging purposes. */ Datum -pg_current_wal_insert_location(PG_FUNCTION_ARGS) +pg_current_wal_insert_lsn(PG_FUNCTION_ARGS) { XLogRecPtr current_recptr; @@ -393,7 +393,7 @@ pg_current_wal_insert_location(PG_FUNCTION_ARGS) * This function is mostly for debugging purposes. */ Datum -pg_current_wal_flush_location(PG_FUNCTION_ARGS) +pg_current_wal_flush_lsn(PG_FUNCTION_ARGS) { XLogRecPtr current_recptr; @@ -415,7 +415,7 @@ pg_current_wal_flush_location(PG_FUNCTION_ARGS) * and synced to disk by walreceiver. */ Datum -pg_last_wal_receive_location(PG_FUNCTION_ARGS) +pg_last_wal_receive_lsn(PG_FUNCTION_ARGS) { XLogRecPtr recptr; @@ -434,7 +434,7 @@ pg_last_wal_receive_location(PG_FUNCTION_ARGS) * connections during recovery. */ Datum -pg_last_wal_replay_location(PG_FUNCTION_ARGS) +pg_last_wal_replay_lsn(PG_FUNCTION_ARGS) { XLogRecPtr recptr; @@ -621,7 +621,7 @@ pg_is_in_recovery(PG_FUNCTION_ARGS) * Compute the difference in bytes between two WAL locations. */ Datum -pg_wal_location_diff(PG_FUNCTION_ARGS) +pg_wal_lsn_diff(PG_FUNCTION_ARGS) { Datum result; -- cgit v1.2.3