Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/spock_conflict.c
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ conflict_resolve_by_timestamp(RepOriginId local_origin_id,
cmp = timestamptz_cmp_internal(remote_ts, local_ts);

/*
* The logic bellow assumes last update wins, we invert the logic by
* The logic below assumes last update wins, we invert the logic by
* inverting result of timestamp comparison if first update wins was
* requested.
*/
Expand Down Expand Up @@ -134,14 +134,14 @@ conflict_resolve_by_timestamp(RepOriginId local_origin_id,

if (loc_node->tiebreaker < rmt_node->tiebreaker)
{
/* TODO: Need diagnostig logging for ACE here */
/* TODO: Need diagnostic logging for ACE here */
elog(LOG, "CONFLICT: current node=%d wins over %d by tiebreaker", loc_node->id, rmt_node->id);
*resolution = SpockResolution_KeepLocal;
return false;
}
else
{
/* TODO: Need diagnostig logging for ACE here */
/* TODO: Need diagnostic logging for ACE here */
elog(LOG, "CONFLICT: remote node=%d wins over %d by tiebreaker", rmt_node->id, loc_node->id);
*resolution = SpockResolution_ApplyRemote;
return true;
Expand Down
2 changes: 1 addition & 1 deletion src/spock_dependency.c
Original file line number Diff line number Diff line change
Expand Up @@ -695,7 +695,7 @@ reportDependentObjects(const ObjectAddresses *targetObjects,
int my_log_min_messages;

/*
* This is cludge for Windows (Postgres des not define the GUC variables
* This is kludge for Windows (Postgres does not define the GUC variables
* as PGDDLIMPORT)
*/
my_client_min_messages = atoi(GetConfigOptionByName("client_min_messages",
Expand Down
2 changes: 1 addition & 1 deletion src/spock_failover_slots.c
Original file line number Diff line number Diff line change
Expand Up @@ -523,7 +523,7 @@ wait_for_primary_slot_catchup(ReplicationSlot *slot, RemoteSlot *remote_slot)

/*
* Append the dbname of the remote slot. We don't use a generic db like
* postgres here because plugin callback bellow might want to invoke
* postgres here because plugin callback below might want to invoke
* extension functions.
*/
make_sync_failover_slots_dsn(&connstr, remote_slot->database);
Expand Down
2 changes: 1 addition & 1 deletion src/spock_functions.c
Original file line number Diff line number Diff line change
Expand Up @@ -430,7 +430,7 @@ spock_alter_node_drop_interface(PG_FUNCTION_ARGS)
if (oldif == NULL)
ereport(ERROR,
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
errmsg("interface \"%s\" for node node \"%s\" not found",
errmsg("interface \"%s\" for node \"%s\" not found",
if_name, node_name)));

other_subs = get_node_subscriptions(node->id, true);
Expand Down
2 changes: 1 addition & 1 deletion src/spock_group.c
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ spock_group_shmem_request(void)
#endif

/*
* This is cludge for Windows (Postgres does not define the GUC variable
* This is kludge for Windows (Postgres does not define the GUC variable
* as PGDDLIMPORT)
*/
napply_groups = atoi(GetConfigOptionByName("max_worker_processes", NULL,
Expand Down
2 changes: 1 addition & 1 deletion src/spock_manager.c
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ manage_apply_workers(void)
if (!wlc)
apply = NULL;

/* Skip if the worker was alrady registered. */
/* Skip if the worker was already registered. */
if (spock_worker_running(apply))
continue;

Expand Down
4 changes: 2 additions & 2 deletions src/spock_node.c
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ validate_subscription_name(const char *name)
if (strlen(name) == 0)
ereport(ERROR,
(errcode(ERRCODE_INVALID_NAME),
errmsg("subscription name \"%s\" is too short", name)));
errmsg("subscription name \"%s\" is too short", name)));

if (strlen(name) >= NAMEDATALEN)
ereport(ERROR,
Expand Down Expand Up @@ -748,7 +748,7 @@ get_node_interface_by_name(Oid nodeid, const char *name, bool missing_ok)
return NULL;
}
else
elog(ERROR, "node interface \"%s\" not found for nod %u",
elog(ERROR, "node interface \"%s\" not found for node %u",
name, nodeid);
}

Expand Down
2 changes: 1 addition & 1 deletion src/spock_output_plugin.c
Original file line number Diff line number Diff line change
Expand Up @@ -1363,7 +1363,7 @@ spock_output_plugin_shmem_request(void)
prev_shmem_request_hook();

/*
* This is cludge for Windows (Postgres des not define the GUC variable as
* This is kludge for Windows (Postgres does not define the GUC variable as
* PGDDLIMPORT)
*/
nworkers = atoi(GetConfigOptionByName("max_worker_processes", NULL,
Expand Down
2 changes: 1 addition & 1 deletion src/spock_relcache.c
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,7 @@ spock_relcache_invalidate_callback(Datum arg, Oid reloid)

hash_seq_init(&status, SpockRelationHash);

/* TODO, use inverse lookup hastable */
/* TODO, use inverse lookup hashtable */
while ((entry = (SpockRelation *) hash_seq_search(&status)) != NULL)
{
if (entry->reloid == reloid)
Expand Down
2 changes: 1 addition & 1 deletion src/spock_repset.c
Original file line number Diff line number Diff line change
Expand Up @@ -1408,7 +1408,7 @@ replication_set_remove_seq(Oid setid, Oid seqoid, bool from_drop)
tuple = systable_getnext(scan);

/*
* Remove the tuple if found, if not found report error uless this
* Remove the tuple if found, if not found report error unless this
* function was called as result of table drop.
*/
if (HeapTupleIsValid(tuple))
Expand Down
2 changes: 1 addition & 1 deletion src/spock_rpc.c
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,7 @@ spock_drop_remote_slot(PGconn *conn, const char *slot_name)
return;
}

/* Slot found, validate that it's BDR slot */
/* Slot found, validate that it's spock slot */
if (PQgetisnull(res, 0, 0))
elog(ERROR, "Unexpectedly null field %s", PQfname(res, 0));

Expand Down
14 changes: 7 additions & 7 deletions src/spock_sync.c
Original file line number Diff line number Diff line change
Expand Up @@ -305,14 +305,14 @@ restore_structure(SpockSubscription *sub, const char *srcfile,
cmdargv[cmdargc++] = NULL;

/*
* TODO: misleading error message takes place here if an error is
* interrupted execution.
* TODO: misleading error message can occur if an error interrupts
* execution.
*/
if (exec_cmd(pg_restore, cmdargv) != 0)
ereport(ERROR,
(errcode_for_file_access(),
errmsg("could not execute pg_restore (\"%s\"): %m", pg_restore),
errhint("explore error log to realise the origin of the issue")));
errhint("check the error log to determine the cause of the issue")));
}

/*
Expand Down Expand Up @@ -351,8 +351,8 @@ ensure_replication_slot_snapshot(PGconn *sql_conn, PGconn *repl_conn,
const char *sqlstate = PQresultErrorField(res, PG_DIAG_SQLSTATE);

/*
* If our slot already exist but is not used, it's leftover from
* previous unsucessful attempt to synchronize table, try dropping it
* If our slot already exists but is not used, it's leftover from
* previous unsuccessful attempt to synchronize table, try dropping it
* and recreating.
*/
if (sqlstate &&
Expand Down Expand Up @@ -467,7 +467,7 @@ adjust_progress_info(PGconn *origin_conn, PGconn *target_conn)
sap.remote_insert_lsn = str_to_lsn(remote_insert_lsn);

/*
* We don't actually received a single WAL record - just assume
* We don't actually receive a single WAL record - just assume
* we've got the last commit only. Don't set it to the Invalid
* value in case someone uses tracking data in state monitoring
* scripts.
Expand Down Expand Up @@ -575,7 +575,7 @@ start_copy_target_tx(PGconn *conn, const char *origin_name)

/*
* Set correct origin if target db supports it. We must do this before
* starting the transaction otherwise the status code bellow would get
* starting the transaction otherwise the status code below would get
* much more complicated.
*/
if (PQserverVersion(conn) >= 90500)
Expand Down
2 changes: 1 addition & 1 deletion src/spock_worker.c
Original file line number Diff line number Diff line change
Expand Up @@ -804,7 +804,7 @@ spock_worker_shmem_request(void)
prev_shmem_request_hook();

/*
* This is cludge for Windows (Postgres des not define the GUC variable as
* This is kludge for Windows (Postgres does not define the GUC variable as
* PGDDLIMPORT)
*/
nworkers = atoi(GetConfigOptionByName("max_worker_processes", NULL,
Expand Down