summaryrefslogtreecommitdiff
path: root/src/include/replication
diff options
context:
space:
mode:
authorPeter Geoghegan2022-09-20 02:18:36 +0000
committerPeter Geoghegan2022-09-20 02:18:36 +0000
commitbfcf1b34805f70df48eedeec237230d0cc1154a6 (patch)
treebaf824c317ecf02c49d758e75e72d69c5b6a4ec6 /src/include/replication
parentc47885bd8b6997ccb0cc1997f61f6f98a79ce32a (diff)
Harmonize parameter names in storage and AM code.
Make sure that function declarations use names that exactly match the corresponding names from function definitions in storage, catalog, access method, executor, and logical replication code, as well as in miscellaneous utility/library code. Like other recent commits that cleaned up function parameter names, this commit was written with help from clang-tidy. Later commits will do the same for other parts of the codebase. Author: Peter Geoghegan <pg@bowt.ie> Reviewed-By: David Rowley <dgrowleyml@gmail.com> Discussion: https://postgr.es/m/CAH2-WznJt9CMM9KJTMjJh_zbL5hD9oX44qdJ4aqZtjFi-zA3Tg@mail.gmail.com
Diffstat (limited to 'src/include/replication')
-rw-r--r--src/include/replication/logical.h3
-rw-r--r--src/include/replication/logicalproto.h6
-rw-r--r--src/include/replication/origin.h4
-rw-r--r--src/include/replication/slot.h3
-rw-r--r--src/include/replication/walsender.h2
5 files changed, 10 insertions, 8 deletions
diff --git a/src/include/replication/logical.h b/src/include/replication/logical.h
index edadacd5893..4ad019e25a2 100644
--- a/src/include/replication/logical.h
+++ b/src/include/replication/logical.h
@@ -133,7 +133,8 @@ extern void DecodingContextFindStartpoint(LogicalDecodingContext *ctx);
extern bool DecodingContextReady(LogicalDecodingContext *ctx);
extern void FreeDecodingContext(LogicalDecodingContext *ctx);
-extern void LogicalIncreaseXminForSlot(XLogRecPtr lsn, TransactionId xmin);
+extern void LogicalIncreaseXminForSlot(XLogRecPtr current_lsn,
+ TransactionId xmin);
extern void LogicalIncreaseRestartDecodingForSlot(XLogRecPtr current_lsn,
XLogRecPtr restart_lsn);
extern void LogicalConfirmReceivedLocation(XLogRecPtr lsn);
diff --git a/src/include/replication/logicalproto.h b/src/include/replication/logicalproto.h
index a771ab8ff33..7eaa4c97eda 100644
--- a/src/include/replication/logicalproto.h
+++ b/src/include/replication/logicalproto.h
@@ -219,7 +219,7 @@ extern LogicalRepRelId logicalrep_read_update(StringInfo in,
bool *has_oldtuple, LogicalRepTupleData *oldtup,
LogicalRepTupleData *newtup);
extern void logicalrep_write_delete(StringInfo out, TransactionId xid,
- Relation rel, TupleTableSlot *oldtuple,
+ Relation rel, TupleTableSlot *oldslot,
bool binary);
extern LogicalRepRelId logicalrep_read_delete(StringInfo in,
LogicalRepTupleData *oldtup);
@@ -235,7 +235,7 @@ extern void logicalrep_write_rel(StringInfo out, TransactionId xid,
extern LogicalRepRelation *logicalrep_read_rel(StringInfo in);
extern void logicalrep_write_typ(StringInfo out, TransactionId xid,
Oid typoid);
-extern void logicalrep_read_typ(StringInfo out, LogicalRepTyp *ltyp);
+extern void logicalrep_read_typ(StringInfo in, LogicalRepTyp *ltyp);
extern void logicalrep_write_stream_start(StringInfo out, TransactionId xid,
bool first_segment);
extern TransactionId logicalrep_read_stream_start(StringInfo in,
@@ -243,7 +243,7 @@ extern TransactionId logicalrep_read_stream_start(StringInfo in,
extern void logicalrep_write_stream_stop(StringInfo out);
extern void logicalrep_write_stream_commit(StringInfo out, ReorderBufferTXN *txn,
XLogRecPtr commit_lsn);
-extern TransactionId logicalrep_read_stream_commit(StringInfo out,
+extern TransactionId logicalrep_read_stream_commit(StringInfo in,
LogicalRepCommitData *commit_data);
extern void logicalrep_write_stream_abort(StringInfo out, TransactionId xid,
TransactionId subxid);
diff --git a/src/include/replication/origin.h b/src/include/replication/origin.h
index 2d1b5e5c28c..2a50d10b524 100644
--- a/src/include/replication/origin.h
+++ b/src/include/replication/origin.h
@@ -38,8 +38,8 @@ extern PGDLLIMPORT XLogRecPtr replorigin_session_origin_lsn;
extern PGDLLIMPORT TimestampTz replorigin_session_origin_timestamp;
/* API for querying & manipulating replication origins */
-extern RepOriginId replorigin_by_name(const char *name, bool missing_ok);
-extern RepOriginId replorigin_create(const char *name);
+extern RepOriginId replorigin_by_name(const char *roname, bool missing_ok);
+extern RepOriginId replorigin_create(const char *roname);
extern void replorigin_drop_by_name(const char *name, bool missing_ok, bool nowait);
extern bool replorigin_by_oid(RepOriginId roident, bool missing_ok,
char **roname);
diff --git a/src/include/replication/slot.h b/src/include/replication/slot.h
index 8c9f3321d50..81e31f002a3 100644
--- a/src/include/replication/slot.h
+++ b/src/include/replication/slot.h
@@ -195,7 +195,8 @@ extern void ReplicationSlotsShmemInit(void);
/* management of individual slots */
extern void ReplicationSlotCreate(const char *name, bool db_specific,
- ReplicationSlotPersistency p, bool two_phase);
+ ReplicationSlotPersistency persistency,
+ bool two_phase);
extern void ReplicationSlotPersist(void);
extern void ReplicationSlotDrop(const char *name, bool nowait);
diff --git a/src/include/replication/walsender.h b/src/include/replication/walsender.h
index d99a21b0771..8336a6e7198 100644
--- a/src/include/replication/walsender.h
+++ b/src/include/replication/walsender.h
@@ -36,7 +36,7 @@ extern PGDLLIMPORT int wal_sender_timeout;
extern PGDLLIMPORT bool log_replication_commands;
extern void InitWalSender(void);
-extern bool exec_replication_command(const char *query_string);
+extern bool exec_replication_command(const char *cmd_string);
extern void WalSndErrorCleanup(void);
extern void WalSndResourceCleanup(bool isCommit);
extern void WalSndSignals(void);