Fix various typos
This fixes many spelling mistakes in comments, but a few references to invalid parameter names, function names and option names too in comments and also some in string constants Also, fix an #undef that was undefining the incorrect definition Author: Alexander Lakhin Reviewed-by: Justin Pryzby Discussion: https://postgr.es/m/d5f68d19-c0fc-91a9-118d-7c6a5a3f5fad@gmail.com
This commit is contained in:
parent
e39d512f3e
commit
b4dbf3e924
@ -1009,7 +1009,7 @@ check_tuple_header(HeapCheckContext *ctx)
|
|||||||
* TOAST tuples -- are eligible for pruning.
|
* TOAST tuples -- are eligible for pruning.
|
||||||
*
|
*
|
||||||
* Sets *xmin_commit_status_ok to true if the commit status of xmin is known
|
* Sets *xmin_commit_status_ok to true if the commit status of xmin is known
|
||||||
* and false otherwise. If it's set to true, then also set *xid_commit_status
|
* and false otherwise. If it's set to true, then also set *xmin_commit_status
|
||||||
* to the actual commit status.
|
* to the actual commit status.
|
||||||
*/
|
*/
|
||||||
static bool
|
static bool
|
||||||
|
@ -401,7 +401,7 @@ GetWALBlockInfo(FunctionCallInfo fcinfo, XLogReaderState *record,
|
|||||||
values, nulls);
|
values, nulls);
|
||||||
}
|
}
|
||||||
|
|
||||||
#undef PG_GET_WAL_FPI_BLOCK_COLS
|
#undef PG_GET_WAL_BLOCK_INFO_COLS
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -1686,7 +1686,7 @@ pgfdw_abort_cleanup(ConnCacheEntry *entry, bool toplevel)
|
|||||||
*
|
*
|
||||||
* Returns true if the abort command or cancel request is successfully issued,
|
* Returns true if the abort command or cancel request is successfully issued,
|
||||||
* false otherwise. If the abort command is successfully issued, the given
|
* false otherwise. If the abort command is successfully issued, the given
|
||||||
* connection cache entry is appended to *pending_entries. Othewise, if the
|
* connection cache entry is appended to *pending_entries. Otherwise, if the
|
||||||
* cancel request is successfully issued, it is appended to *cancel_requested.
|
* cancel request is successfully issued, it is appended to *cancel_requested.
|
||||||
*/
|
*/
|
||||||
static bool
|
static bool
|
||||||
|
@ -5016,7 +5016,7 @@ postgresGetAnalyzeInfoForForeignTable(Relation relation, bool *can_tablesample)
|
|||||||
pgfdw_report_error(ERROR, res, conn, false, sql.data);
|
pgfdw_report_error(ERROR, res, conn, false, sql.data);
|
||||||
|
|
||||||
if (PQntuples(res) != 1 || PQnfields(res) != 2)
|
if (PQntuples(res) != 1 || PQnfields(res) != 2)
|
||||||
elog(ERROR, "unexpected result from deparseAnalyzeTuplesSql query");
|
elog(ERROR, "unexpected result from deparseAnalyzeInfoSql query");
|
||||||
reltuples = strtod(PQgetvalue(res, 0, 0), NULL);
|
reltuples = strtod(PQgetvalue(res, 0, 0), NULL);
|
||||||
relkind = *(PQgetvalue(res, 0, 1));
|
relkind = *(PQgetvalue(res, 0, 1));
|
||||||
}
|
}
|
||||||
|
@ -2963,7 +2963,7 @@ endif
|
|||||||
# generation happens during install, so that's not a real issue.
|
# generation happens during install, so that's not a real issue.
|
||||||
nls_mo_targets = []
|
nls_mo_targets = []
|
||||||
if libintl.found() and meson.version().version_compare('>=0.60')
|
if libintl.found() and meson.version().version_compare('>=0.60')
|
||||||
# use range() to avoid the flattening of the list that forech() would do
|
# use range() to avoid the flattening of the list that foreach() would do
|
||||||
foreach off : range(0, nls_targets.length())
|
foreach off : range(0, nls_targets.length())
|
||||||
# i18n.gettext() list containing 1) list of built .mo files 2) maintainer
|
# i18n.gettext() list containing 1) list of built .mo files 2) maintainer
|
||||||
# -pot target 3) maintainer -pot target
|
# -pot target 3) maintainer -pot target
|
||||||
|
@ -254,7 +254,7 @@ perform_base_backup(basebackup_options *opt, bbsink *sink)
|
|||||||
|
|
||||||
total_checksum_failures = 0;
|
total_checksum_failures = 0;
|
||||||
|
|
||||||
/* Allocate backup related varilables. */
|
/* Allocate backup related variables. */
|
||||||
backup_state = (BackupState *) palloc0(sizeof(BackupState));
|
backup_state = (BackupState *) palloc0(sizeof(BackupState));
|
||||||
tablespace_map = makeStringInfo();
|
tablespace_map = makeStringInfo();
|
||||||
|
|
||||||
|
@ -1403,7 +1403,7 @@ GetResultRTEPermissionInfo(ResultRelInfo *relinfo, EState *estate)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* GetResultRelCheckAsUser
|
* ExecGetResultRelCheckAsUser
|
||||||
* Returns the user to modify passed-in result relation as
|
* Returns the user to modify passed-in result relation as
|
||||||
*
|
*
|
||||||
* The user is chosen by looking up the relation's or, if a child table, its
|
* The user is chosen by looking up the relation's or, if a child table, its
|
||||||
|
@ -904,7 +904,7 @@ ExecInsert(ModifyTableContext *context,
|
|||||||
* If these are the first tuples stored in the buffers, add the
|
* If these are the first tuples stored in the buffers, add the
|
||||||
* target rel and the mtstate to the
|
* target rel and the mtstate to the
|
||||||
* es_insert_pending_result_relations and
|
* es_insert_pending_result_relations and
|
||||||
* es_insert_pending_modifytables lists respectively, execpt in
|
* es_insert_pending_modifytables lists respectively, except in
|
||||||
* the case where flushing was done above, in which case they
|
* the case where flushing was done above, in which case they
|
||||||
* would already have been added to the lists, so no need to do
|
* would already have been added to the lists, so no need to do
|
||||||
* this.
|
* this.
|
||||||
|
@ -343,7 +343,7 @@ contains_multiexpr_param(Node *node, void *context)
|
|||||||
* the RTEs in 'src_rtable' to now point to the perminfos' indexes in
|
* the RTEs in 'src_rtable' to now point to the perminfos' indexes in
|
||||||
* *dst_perminfos.
|
* *dst_perminfos.
|
||||||
*
|
*
|
||||||
* Note that this changes both 'dst_rtable' and 'dst_perminfo' destructively,
|
* Note that this changes both 'dst_rtable' and 'dst_perminfos' destructively,
|
||||||
* so the caller should have better passed safe-to-modify copies.
|
* so the caller should have better passed safe-to-modify copies.
|
||||||
*/
|
*/
|
||||||
void
|
void
|
||||||
|
@ -2046,7 +2046,7 @@ ExtendBufferedRelShared(ExtendBufferedWhat eb,
|
|||||||
io_start = pgstat_prepare_io_time();
|
io_start = pgstat_prepare_io_time();
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Note: if smgzerorextend fails, we will end up with buffers that are
|
* Note: if smgrzeroextend fails, we will end up with buffers that are
|
||||||
* allocated but not marked BM_VALID. The next relation extension will
|
* allocated but not marked BM_VALID. The next relation extension will
|
||||||
* still select the same block number (because the relation didn't get any
|
* still select the same block number (because the relation didn't get any
|
||||||
* longer on disk) and so future attempts to extend the relation will find
|
* longer on disk) and so future attempts to extend the relation will find
|
||||||
|
@ -164,7 +164,7 @@
|
|||||||
* PredicateLockPage(Relation relation, BlockNumber blkno,
|
* PredicateLockPage(Relation relation, BlockNumber blkno,
|
||||||
* Snapshot snapshot)
|
* Snapshot snapshot)
|
||||||
* PredicateLockTID(Relation relation, ItemPointer tid, Snapshot snapshot,
|
* PredicateLockTID(Relation relation, ItemPointer tid, Snapshot snapshot,
|
||||||
* TransactionId insert_xid)
|
* TransactionId tuple_xid)
|
||||||
* PredicateLockPageSplit(Relation relation, BlockNumber oldblkno,
|
* PredicateLockPageSplit(Relation relation, BlockNumber oldblkno,
|
||||||
* BlockNumber newblkno)
|
* BlockNumber newblkno)
|
||||||
* PredicateLockPageCombine(Relation relation, BlockNumber oldblkno,
|
* PredicateLockPageCombine(Relation relation, BlockNumber oldblkno,
|
||||||
|
@ -597,7 +597,7 @@ mdzeroextend(SMgrRelation reln, ForkNumber forknum,
|
|||||||
/*
|
/*
|
||||||
* Even if we don't want to use fallocate, we can still extend a
|
* Even if we don't want to use fallocate, we can still extend a
|
||||||
* bit more efficiently than writing each 8kB block individually.
|
* bit more efficiently than writing each 8kB block individually.
|
||||||
* pg_pwrite_zeroes() (via FileZero()) uses
|
* pg_pwrite_zeros() (via FileZero()) uses
|
||||||
* pg_pwritev_with_retry() to avoid multiple writes or needing a
|
* pg_pwritev_with_retry() to avoid multiple writes or needing a
|
||||||
* zeroed buffer for the whole length of the extension.
|
* zeroed buffer for the whole length of the extension.
|
||||||
*/
|
*/
|
||||||
|
@ -4825,7 +4825,7 @@ RoleMembershipCacheCallback(Datum arg, int cacheid, uint32 hashvalue)
|
|||||||
* Get a list of roles that the specified roleid is a member of
|
* Get a list of roles that the specified roleid is a member of
|
||||||
*
|
*
|
||||||
* Type ROLERECURSE_MEMBERS recurses through all grants; ROLERECURSE_PRIVS
|
* Type ROLERECURSE_MEMBERS recurses through all grants; ROLERECURSE_PRIVS
|
||||||
* recurses only through inheritable grants; and ROLERECURSE_SETROLe recurses
|
* recurses only through inheritable grants; and ROLERECURSE_SETROLE recurses
|
||||||
* only through grants with set_option.
|
* only through grants with set_option.
|
||||||
*
|
*
|
||||||
* Since indirect membership testing is relatively expensive, we cache
|
* Since indirect membership testing is relatively expensive, we cache
|
||||||
@ -5020,7 +5020,7 @@ member_can_set_role(Oid member, Oid role)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Permission violation eror unless able to SET ROLE to target role.
|
* Permission violation error unless able to SET ROLE to target role.
|
||||||
*/
|
*/
|
||||||
void
|
void
|
||||||
check_can_set_role(Oid member, Oid role)
|
check_can_set_role(Oid member, Oid role)
|
||||||
|
@ -1043,7 +1043,7 @@ array_agg_array_combine(PG_FUNCTION_ARGS)
|
|||||||
state1->nitems += state2->nitems;
|
state1->nitems += state2->nitems;
|
||||||
|
|
||||||
state1->dims[0] += state2->dims[0];
|
state1->dims[0] += state2->dims[0];
|
||||||
/* remaing dims already match, per test above */
|
/* remaining dims already match, per test above */
|
||||||
|
|
||||||
Assert(state1->array_type == state2->array_type);
|
Assert(state1->array_type == state2->array_type);
|
||||||
Assert(state1->element_type == state2->element_type);
|
Assert(state1->element_type == state2->element_type);
|
||||||
|
@ -1387,7 +1387,7 @@ check_GUC_name_for_parameter_acl(const char *name)
|
|||||||
*
|
*
|
||||||
* This performs two sanity checks. First, it checks that the initial
|
* This performs two sanity checks. First, it checks that the initial
|
||||||
* value of a GUC is the same when declared and when loaded to prevent
|
* value of a GUC is the same when declared and when loaded to prevent
|
||||||
* anybody looking at the C declarations of these GUCS from being fooled by
|
* anybody looking at the C declarations of these GUCs from being fooled by
|
||||||
* mismatched values. Second, it checks for incorrect flag combinations.
|
* mismatched values. Second, it checks for incorrect flag combinations.
|
||||||
*
|
*
|
||||||
* The following validation rules apply for the values:
|
* The following validation rules apply for the values:
|
||||||
@ -6272,7 +6272,7 @@ ProcessGUCArray(ArrayType *array, ArrayType *usersetArray,
|
|||||||
userSetDatum = BoolGetDatum(false);
|
userSetDatum = BoolGetDatum(false);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* USER SET values are appliciable only for PGC_USERSET parameters. We
|
* USER SET values are applicable only for PGC_USERSET parameters. We
|
||||||
* use InvalidOid as role in order to evade possible privileges of the
|
* use InvalidOid as role in order to evade possible privileges of the
|
||||||
* current user.
|
* current user.
|
||||||
*/
|
*/
|
||||||
@ -6365,8 +6365,8 @@ GUCArrayAdd(ArrayType *array, ArrayType **usersetArray,
|
|||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Recheck permissons if we found an option without USER SET
|
* Recheck permissions if we found an option without USER SET
|
||||||
* flag while we're setting an optionn with USER SET flag.
|
* flag while we're setting an option with USER SET flag.
|
||||||
*/
|
*/
|
||||||
if (!currentUserSet && user_set)
|
if (!currentUserSet && user_set)
|
||||||
(void) validate_option_array_item(name, value,
|
(void) validate_option_array_item(name, value,
|
||||||
|
@ -87,7 +87,7 @@ static size_t ps_buffer_cur_len; /* nominal strlen(ps_buffer) */
|
|||||||
static size_t ps_buffer_fixed_size; /* size of the constant prefix */
|
static size_t ps_buffer_fixed_size; /* size of the constant prefix */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Length of ps_buffer before the suffix was appeneded to the end, or 0 if we
|
* Length of ps_buffer before the suffix was appended to the end, or 0 if we
|
||||||
* didn't set a suffix.
|
* didn't set a suffix.
|
||||||
*/
|
*/
|
||||||
static size_t ps_buffer_nosuffix_len;
|
static size_t ps_buffer_nosuffix_len;
|
||||||
|
@ -1382,7 +1382,7 @@ MemoryContextAllocAligned(MemoryContext context,
|
|||||||
alloc_size = size + PallocAlignedExtraBytes(alignto);
|
alloc_size = size + PallocAlignedExtraBytes(alignto);
|
||||||
|
|
||||||
#ifdef MEMORY_CONTEXT_CHECKING
|
#ifdef MEMORY_CONTEXT_CHECKING
|
||||||
/* ensure there's space for a sentinal byte */
|
/* ensure there's space for a sentinel byte */
|
||||||
alloc_size += 1;
|
alloc_size += 1;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -521,7 +521,7 @@ ResourceOwnerReleaseInternal(ResourceOwner owner,
|
|||||||
{
|
{
|
||||||
/*
|
/*
|
||||||
* Abort failed buffer IO. AbortBufferIO()->TerminateBufferIO() calls
|
* Abort failed buffer IO. AbortBufferIO()->TerminateBufferIO() calls
|
||||||
* ResourceOwnerForgetBufferIOs(), so we just have to iterate till
|
* ResourceOwnerForgetBufferIO(), so we just have to iterate till
|
||||||
* there are none.
|
* there are none.
|
||||||
*
|
*
|
||||||
* Needs to be before we release buffer pins.
|
* Needs to be before we release buffer pins.
|
||||||
|
@ -342,7 +342,7 @@ LZ4Stream_get_error(CompressFileHandle *CFH)
|
|||||||
/*
|
/*
|
||||||
* Initialize an already alloc'ed LZ4State struct for subsequent calls.
|
* Initialize an already alloc'ed LZ4State struct for subsequent calls.
|
||||||
*
|
*
|
||||||
* Creates the necessary contexts for either compresion or decompression. When
|
* Creates the necessary contexts for either compression or decompression. When
|
||||||
* compressing data (indicated by compressing=true), it additionally writes the
|
* compressing data (indicated by compressing=true), it additionally writes the
|
||||||
* LZ4 header in the output stream.
|
* LZ4 header in the output stream.
|
||||||
*
|
*
|
||||||
|
@ -137,7 +137,7 @@ static const int dbObjectTypePriority[] =
|
|||||||
PRIO_DEFAULT_ACL, /* DO_DEFAULT_ACL */
|
PRIO_DEFAULT_ACL, /* DO_DEFAULT_ACL */
|
||||||
PRIO_TRANSFORM, /* DO_TRANSFORM */
|
PRIO_TRANSFORM, /* DO_TRANSFORM */
|
||||||
PRIO_LARGE_OBJECT, /* DO_LARGE_OBJECT */
|
PRIO_LARGE_OBJECT, /* DO_LARGE_OBJECT */
|
||||||
PRIO_LARGE_OBJECT_DATA, /* DO_LARGE_OJECT_DATA */
|
PRIO_LARGE_OBJECT_DATA, /* DO_LARGE_OBJECT_DATA */
|
||||||
PRIO_PRE_DATA_BOUNDARY, /* DO_PRE_DATA_BOUNDARY */
|
PRIO_PRE_DATA_BOUNDARY, /* DO_PRE_DATA_BOUNDARY */
|
||||||
PRIO_POST_DATA_BOUNDARY, /* DO_POST_DATA_BOUNDARY */
|
PRIO_POST_DATA_BOUNDARY, /* DO_POST_DATA_BOUNDARY */
|
||||||
PRIO_EVENT_TRIGGER, /* DO_EVENT_TRIGGER */
|
PRIO_EVENT_TRIGGER, /* DO_EVENT_TRIGGER */
|
||||||
|
@ -1923,7 +1923,7 @@ dumpTimestamp(const char *msg)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Helper function for rolenamehash hash table.
|
* Helper function for rolename_hash hash table.
|
||||||
*/
|
*/
|
||||||
static uint32
|
static uint32
|
||||||
hash_string_pointer(char *s)
|
hash_string_pointer(char *s)
|
||||||
|
@ -71,7 +71,7 @@ $node->issues_sql_like(
|
|||||||
'vacuumdb --no-process-main');
|
'vacuumdb --no-process-main');
|
||||||
$node->command_fails(
|
$node->command_fails(
|
||||||
[ 'vacuumdb', '--analyze-only', '--no-process-main', 'postgres' ],
|
[ 'vacuumdb', '--analyze-only', '--no-process-main', 'postgres' ],
|
||||||
'--analyze-only and --no-process_main specified together');
|
'--analyze-only and --no-process-main specified together');
|
||||||
$node->issues_sql_like(
|
$node->issues_sql_like(
|
||||||
[ 'vacuumdb', '--no-process-toast', 'postgres' ],
|
[ 'vacuumdb', '--no-process-toast', 'postgres' ],
|
||||||
qr/statement: VACUUM \(PROCESS_TOAST FALSE, SKIP_DATABASE_STATS\).*;/,
|
qr/statement: VACUUM \(PROCESS_TOAST FALSE, SKIP_DATABASE_STATS\).*;/,
|
||||||
|
@ -63,4 +63,4 @@ extern void offset_elem_desc(StringInfo buf, void *offset, void *data);
|
|||||||
extern void redirect_elem_desc(StringInfo buf, void *offset, void *data);
|
extern void redirect_elem_desc(StringInfo buf, void *offset, void *data);
|
||||||
extern void oid_elem_desc(StringInfo buf, void *relid, void *data);
|
extern void oid_elem_desc(StringInfo buf, void *relid, void *data);
|
||||||
|
|
||||||
#endif /* RMGRDESC_UTILS_H */
|
#endif /* RMGRDESC_UTILS_H_ */
|
||||||
|
@ -36,7 +36,7 @@ struct iovec
|
|||||||
#define PG_IOV_MAX Min(IOV_MAX, 32)
|
#define PG_IOV_MAX Min(IOV_MAX, 32)
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Note that pg_preadv and pg_writev have a pg_ prefix as a warning that the
|
* Note that pg_preadv and pg_pwritev have a pg_ prefix as a warning that the
|
||||||
* Windows implementations have the side-effect of changing the file position.
|
* Windows implementations have the side-effect of changing the file position.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -44,7 +44,7 @@
|
|||||||
|
|
||||||
#include "mb/pg_wchar.h"
|
#include "mb/pg_wchar.h"
|
||||||
|
|
||||||
#include "miscadmin.h" /* needed by stacktoodeep */
|
#include "miscadmin.h" /* needed by rstacktoodeep */
|
||||||
|
|
||||||
|
|
||||||
/* overrides for regguts.h definitions, if any */
|
/* overrides for regguts.h definitions, if any */
|
||||||
|
@ -37,8 +37,8 @@
|
|||||||
* In some cases, for example when memory allocations become large, it's
|
* In some cases, for example when memory allocations become large, it's
|
||||||
* possible fields 3 and 4 above are not large enough to store the values
|
* possible fields 3 and 4 above are not large enough to store the values
|
||||||
* required for the chunk. In this case, the MemoryContext can choose to mark
|
* required for the chunk. In this case, the MemoryContext can choose to mark
|
||||||
* the chunk as "external" by calling the MemoryChunkSetExternal() function.
|
* the chunk as "external" by calling the MemoryChunkSetHdrMaskExternal()
|
||||||
* When this is done, fields 3 and 4 are unavailable for use by the
|
* function. When this is done, fields 3 and 4 are unavailable for use by the
|
||||||
* MemoryContext and it's up to the MemoryContext itself to devise its own
|
* MemoryContext and it's up to the MemoryContext itself to devise its own
|
||||||
* method for getting the reference to the block.
|
* method for getting the reference to the block.
|
||||||
*
|
*
|
||||||
|
@ -146,7 +146,7 @@ typedef int (*SortTupleComparator) (const SortTuple *a, const SortTuple *b,
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
* The public part of a Tuple sort operation state. This data structure
|
* The public part of a Tuple sort operation state. This data structure
|
||||||
* containsthe definition of sort-variant-specific interface methods and
|
* contains the definition of sort-variant-specific interface methods and
|
||||||
* the part of Tuple sort operation state required by their implementations.
|
* the part of Tuple sort operation state required by their implementations.
|
||||||
*/
|
*/
|
||||||
typedef struct
|
typedef struct
|
||||||
@ -189,7 +189,7 @@ typedef struct
|
|||||||
* Function to do some specific release of resources for the sort variant.
|
* Function to do some specific release of resources for the sort variant.
|
||||||
* In particular, this function should free everything stored in the "arg"
|
* In particular, this function should free everything stored in the "arg"
|
||||||
* field, which wouldn't be cleared on reset of the Tuple sort memory
|
* field, which wouldn't be cleared on reset of the Tuple sort memory
|
||||||
* contextes. This can be NULL if nothing specific needs to be done.
|
* contexts. This can be NULL if nothing specific needs to be done.
|
||||||
*/
|
*/
|
||||||
void (*freestate) (Tuplesortstate *state);
|
void (*freestate) (Tuplesortstate *state);
|
||||||
|
|
||||||
|
@ -624,7 +624,7 @@ pqsecure_open_gss(PGconn *conn)
|
|||||||
|
|
||||||
if (conn->gssdeleg && pg_strcasecmp(conn->gssdeleg, "enable") == 0)
|
if (conn->gssdeleg && pg_strcasecmp(conn->gssdeleg, "enable") == 0)
|
||||||
{
|
{
|
||||||
/* Acquire credentials if possbile */
|
/* Acquire credentials if possible */
|
||||||
if (conn->gcred == GSS_C_NO_CREDENTIAL)
|
if (conn->gcred == GSS_C_NO_CREDENTIAL)
|
||||||
(void) pg_GSS_have_cred_cache(&conn->gcred);
|
(void) pg_GSS_have_cred_cache(&conn->gcred);
|
||||||
|
|
||||||
|
@ -14,17 +14,17 @@ if ($ENV{PG_TEST_EXTRA} !~ /\bload_balance\b/)
|
|||||||
|
|
||||||
# This tests loadbalancing based on a DNS entry that contains multiple records
|
# This tests loadbalancing based on a DNS entry that contains multiple records
|
||||||
# for different IPs. Since setting up a DNS server is more effort than we
|
# for different IPs. Since setting up a DNS server is more effort than we
|
||||||
# consider reasonable to run this test, this situation is instead immitated by
|
# consider reasonable to run this test, this situation is instead imitated by
|
||||||
# using a hosts file where a single hostname maps to multiple different IP
|
# using a hosts file where a single hostname maps to multiple different IP
|
||||||
# addresses. This test requires the adminstrator to add the following lines to
|
# addresses. This test requires the administrator to add the following lines to
|
||||||
# the hosts file (if we detect that this hasn't happend we skip the test):
|
# the hosts file (if we detect that this hasn't happened we skip the test):
|
||||||
#
|
#
|
||||||
# 127.0.0.1 pg-loadbalancetest
|
# 127.0.0.1 pg-loadbalancetest
|
||||||
# 127.0.0.2 pg-loadbalancetest
|
# 127.0.0.2 pg-loadbalancetest
|
||||||
# 127.0.0.3 pg-loadbalancetest
|
# 127.0.0.3 pg-loadbalancetest
|
||||||
#
|
#
|
||||||
# Windows or Linux are required to run this test because these OSes allow
|
# Windows or Linux are required to run this test because these OSes allow
|
||||||
# binding to 127.0.0.2 and 127.0.0.3 addresess by default, but other OSes
|
# binding to 127.0.0.2 and 127.0.0.3 addresses by default, but other OSes
|
||||||
# don't. We need to bind to different IP addresses, so that we can use these
|
# don't. We need to bind to different IP addresses, so that we can use these
|
||||||
# different IP addresses in the hosts file.
|
# different IP addresses in the hosts file.
|
||||||
#
|
#
|
||||||
|
@ -400,7 +400,7 @@ pgreadlink(const char *path, char *buf, size_t size)
|
|||||||
* If the path starts with "\??\" followed by a "drive absolute" path
|
* If the path starts with "\??\" followed by a "drive absolute" path
|
||||||
* (known to Windows APIs as RtlPathTypeDriveAbsolute), then strip that
|
* (known to Windows APIs as RtlPathTypeDriveAbsolute), then strip that
|
||||||
* prefix. This undoes some of the transformation performed by
|
* prefix. This undoes some of the transformation performed by
|
||||||
* pqsymlink(), to get back to a format that users are used to seeing. We
|
* pgsymlink(), to get back to a format that users are used to seeing. We
|
||||||
* don't know how to transform other path types that might be encountered
|
* don't know how to transform other path types that might be encountered
|
||||||
* outside PGDATA, so we just return them directly.
|
* outside PGDATA, so we just return them directly.
|
||||||
*/
|
*/
|
||||||
|
@ -413,7 +413,7 @@ test_query(
|
|||||||
$node->connect_ok(
|
$node->connect_ok(
|
||||||
$node->connstr('postgres')
|
$node->connstr('postgres')
|
||||||
. " user=test1 host=$host hostaddr=$hostaddr gssencmode=disable require_auth=gss",
|
. " user=test1 host=$host hostaddr=$hostaddr gssencmode=disable require_auth=gss",
|
||||||
"GSS authentication requested, works with non-encyrpted GSS");
|
"GSS authentication requested, works with non-encrypted GSS");
|
||||||
$node->connect_ok(
|
$node->connect_ok(
|
||||||
$node->connstr('postgres')
|
$node->connstr('postgres')
|
||||||
. " user=test1 host=$host hostaddr=$hostaddr gssencmode=require require_auth=gss",
|
. " user=test1 host=$host hostaddr=$hostaddr gssencmode=require require_auth=gss",
|
||||||
|
@ -19,7 +19,7 @@ LdapServer - class for an LDAP server for testing pg_hba.conf authentication
|
|||||||
|
|
||||||
use LdapServer;
|
use LdapServer;
|
||||||
|
|
||||||
# have we found openldap binaies suitable for setting up a server?
|
# have we found openldap binaries suitable for setting up a server?
|
||||||
my $ldap_binaries_found = $LdapServer::setup;
|
my $ldap_binaries_found = $LdapServer::setup;
|
||||||
|
|
||||||
# create a server with the given root password and auth type
|
# create a server with the given root password and auth type
|
||||||
@ -254,7 +254,7 @@ sub _ldapenv
|
|||||||
|
|
||||||
=over
|
=over
|
||||||
|
|
||||||
=item ldap_add(filename)
|
=item ldapadd_file(filename)
|
||||||
|
|
||||||
filename is the path to a file containing LDIF data which is added to the LDAP
|
filename is the path to a file containing LDIF data which is added to the LDAP
|
||||||
server.
|
server.
|
||||||
|
@ -9,7 +9,7 @@ ldap_password_func_sources = files(
|
|||||||
if host_system == 'windows'
|
if host_system == 'windows'
|
||||||
ldap_password_func_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
|
ldap_password_func_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
|
||||||
'--NAME', 'ldap_password_func',
|
'--NAME', 'ldap_password_func',
|
||||||
'--FILEDESC', 'set hook to mutate ldapbindpassw',])
|
'--FILEDESC', 'set hook to mutate ldapbindpasswd',])
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ldap_password_func = shared_module('ldap_password_func',
|
ldap_password_func = shared_module('ldap_password_func',
|
||||||
|
@ -68,7 +68,7 @@ use Test::More;
|
|||||||
|
|
||||||
=over
|
=over
|
||||||
|
|
||||||
=item PostgreSQL::Test::BackroundPsql->new(interactive, @params)
|
=item PostgreSQL::Test::BackgroundPsql->new(interactive, @params)
|
||||||
|
|
||||||
Builds a new object of class C<PostgreSQL::Test::BackgroundPsql> for either
|
Builds a new object of class C<PostgreSQL::Test::BackgroundPsql> for either
|
||||||
an interactive or background session and starts it. If C<interactive> is
|
an interactive or background session and starts it. If C<interactive> is
|
||||||
@ -201,7 +201,7 @@ sub query
|
|||||||
$self->{timeout}->start() if (defined($self->{query_timer_restart}));
|
$self->{timeout}->start() if (defined($self->{query_timer_restart}));
|
||||||
|
|
||||||
# Feed the query to psql's stdin, followed by \n (so psql processes the
|
# Feed the query to psql's stdin, followed by \n (so psql processes the
|
||||||
# line), by a ; (so that psql issues the query, if it doesnt't include a ;
|
# line), by a ; (so that psql issues the query, if it doesn't include a ;
|
||||||
# itself), and a separator echoed with \echo, that we can wait on.
|
# itself), and a separator echoed with \echo, that we can wait on.
|
||||||
my $banner = "background_psql: QUERY_SEPARATOR";
|
my $banner = "background_psql: QUERY_SEPARATOR";
|
||||||
$self->{stdin} .= "$query\n;\n\\echo $banner\n";
|
$self->{stdin} .= "$query\n;\n\\echo $banner\n";
|
||||||
|
@ -276,7 +276,7 @@ test_status_print(bool ok, const char *testname, double runtime, bool parallel)
|
|||||||
* Testnumbers are padded to 5 characters to ensure that testnames align
|
* Testnumbers are padded to 5 characters to ensure that testnames align
|
||||||
* vertically (assuming at most 9999 tests). Testnames are prefixed with
|
* vertically (assuming at most 9999 tests). Testnames are prefixed with
|
||||||
* a leading character to indicate being run in parallel or not. A leading
|
* a leading character to indicate being run in parallel or not. A leading
|
||||||
* '+' indicates a parellel test, '-' indicates a single test.
|
* '+' indicates a parallel test, '-' indicates a single test.
|
||||||
*/
|
*/
|
||||||
emit_tap_output(TEST_STATUS, "%sok %-5i%*s %c %-*s %8.0f ms",
|
emit_tap_output(TEST_STATUS, "%sok %-5i%*s %c %-*s %8.0f ms",
|
||||||
(ok ? "" : "not "),
|
(ok ? "" : "not "),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user