Skip to content

Commit c248d17

Browse files
committed
Message tuning
1 parent 1dff2a0 commit c248d17

File tree

11 files changed

+42
-42
lines changed

11 files changed

+42
-42
lines changed

src/backend/access/transam/xlog.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
* Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
88
* Portions Copyright (c) 1994, Regents of the University of California
99
*
10-
* $PostgreSQL: pgsql/src/backend/access/transam/xlog.c,v 1.383 2010/03/19 11:05:14 sriggs Exp $
10+
* $PostgreSQL: pgsql/src/backend/access/transam/xlog.c,v 1.384 2010/03/21 00:17:58 petere Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -3876,22 +3876,22 @@ ValidXLOGHeader(XLogPageHeader hdr, int emode)
38763876
snprintf(sysident_str, sizeof(sysident_str), UINT64_FORMAT,
38773877
ControlFile->system_identifier);
38783878
ereport(emode,
3879-
(errmsg("WAL file is from different system"),
3880-
errdetail("WAL file SYSID is %s, pg_control SYSID is %s",
3879+
(errmsg("WAL file is from different database system"),
3880+
errdetail("WAL file database system identifier is %s, pg_control database system identifier is %s.",
38813881
fhdrident_str, sysident_str)));
38823882
return false;
38833883
}
38843884
if (longhdr->xlp_seg_size != XLogSegSize)
38853885
{
38863886
ereport(emode,
3887-
(errmsg("WAL file is from different system"),
3887+
(errmsg("WAL file is from different database system"),
38883888
errdetail("Incorrect XLOG_SEG_SIZE in page header.")));
38893889
return false;
38903890
}
38913891
if (longhdr->xlp_xlog_blcksz != XLOG_BLCKSZ)
38923892
{
38933893
ereport(emode,
3894-
(errmsg("WAL file is from different system"),
3894+
(errmsg("WAL file is from different database system"),
38953895
errdetail("Incorrect XLOG_BLCKSZ in page header.")));
38963896
return false;
38973897
}
@@ -8202,7 +8202,7 @@ pg_stop_backup(PG_FUNCTION_ARGS)
82028202
ereport(WARNING,
82038203
(errmsg("pg_stop_backup still waiting for all required WAL segments to be archived (%d seconds elapsed)",
82048204
waits),
8205-
errhint("Check that your archive_command is executing properly. "
8205+
errhint("Check that your archive_command is executing properly. "
82068206
"pg_stop_backup can be cancelled safely, "
82078207
"but the database backup will not be usable without all the WAL segments.")));
82088208
}

src/backend/executor/nodeWindowAgg.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
* Portions Copyright (c) 1994, Regents of the University of California
2828
*
2929
* IDENTIFICATION
30-
* $PostgreSQL: pgsql/src/backend/executor/nodeWindowAgg.c,v 1.12 2010/02/26 02:00:42 momjian Exp $
30+
* $PostgreSQL: pgsql/src/backend/executor/nodeWindowAgg.c,v 1.13 2010/03/21 00:17:58 petere Exp $
3131
*
3232
*-------------------------------------------------------------------------
3333
*/
@@ -1230,7 +1230,7 @@ ExecWindowAgg(WindowAggState *winstate)
12301230
if (isnull)
12311231
ereport(ERROR,
12321232
(errcode(ERRCODE_NULL_VALUE_NOT_ALLOWED),
1233-
errmsg("frame starting offset must not be NULL")));
1233+
errmsg("frame starting offset must not be null")));
12341234
/* copy value into query-lifespan context */
12351235
get_typlenbyval(exprType((Node *) winstate->startOffset->expr),
12361236
&len, &byval);
@@ -1256,7 +1256,7 @@ ExecWindowAgg(WindowAggState *winstate)
12561256
if (isnull)
12571257
ereport(ERROR,
12581258
(errcode(ERRCODE_NULL_VALUE_NOT_ALLOWED),
1259-
errmsg("frame ending offset must not be NULL")));
1259+
errmsg("frame ending offset must not be null")));
12601260
/* copy value into query-lifespan context */
12611261
get_typlenbyval(exprType((Node *) winstate->endOffset->expr),
12621262
&len, &byval);

src/backend/libpq/auth.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $PostgreSQL: pgsql/src/backend/libpq/auth.c,v 1.196 2010/03/13 14:55:57 momjian Exp $
11+
* $PostgreSQL: pgsql/src/backend/libpq/auth.c,v 1.197 2010/03/21 00:17:58 petere Exp $
1212
*
1313
*-------------------------------------------------------------------------
1414
*/
@@ -2271,7 +2271,7 @@ CheckLDAPAuth(Port *port)
22712271
*c == '/')
22722272
{
22732273
ereport(LOG,
2274-
(errmsg("invalid character in username for LDAP authentication")));
2274+
(errmsg("invalid character in user name for LDAP authentication")));
22752275
return STATUS_ERROR;
22762276
}
22772277
}
@@ -2636,7 +2636,7 @@ CheckRADIUSAuth(Port *port)
26362636
if (!pg_md5_binary(cryptvector, RADIUS_VECTOR_LENGTH + strlen(port->hba->radiussecret), encryptedpassword))
26372637
{
26382638
ereport(LOG,
2639-
(errmsg("could not perform md5 encryption of password")));
2639+
(errmsg("could not perform MD5 encryption of password")));
26402640
pfree(cryptvector);
26412641
return STATUS_ERROR;
26422642
}
@@ -2825,7 +2825,7 @@ CheckRADIUSAuth(Port *port)
28252825
else
28262826
{
28272827
ereport(LOG,
2828-
(errmsg("RADIUS response has invalid code (%i) for user '%s'",
2828+
(errmsg("RADIUS response has invalid code (%i) for user \"%s\"",
28292829
receivepacket->code, port->user_name)));
28302830
return STATUS_ERROR;
28312831
}

src/backend/libpq/hba.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
*
1111
*
1212
* IDENTIFICATION
13-
* $PostgreSQL: pgsql/src/backend/libpq/hba.c,v 1.202 2010/03/08 09:57:26 mha Exp $
13+
* $PostgreSQL: pgsql/src/backend/libpq/hba.c,v 1.203 2010/03/21 00:17:58 petere Exp $
1414
*
1515
*-------------------------------------------------------------------------
1616
*/
@@ -1271,7 +1271,7 @@ parse_hba_line(List *line, int line_num, HbaLine *parsedline)
12711271
{
12721272
ereport(LOG,
12731273
(errcode(ERRCODE_CONFIG_FILE_ERROR),
1274-
errmsg("cannot use ldapbasedn, ldapbinddn, ldapbindpasswd or ldapsearchattribute together with ldapprefix"),
1274+
errmsg("cannot use ldapbasedn, ldapbinddn, ldapbindpasswd, or ldapsearchattribute together with ldapprefix"),
12751275
errcontext("line %d of configuration file \"%s\"",
12761276
line_num, HbaFileName)));
12771277
return false;
@@ -1281,7 +1281,7 @@ parse_hba_line(List *line, int line_num, HbaLine *parsedline)
12811281
{
12821282
ereport(LOG,
12831283
(errcode(ERRCODE_CONFIG_FILE_ERROR),
1284-
errmsg("authentication method \"ldap\" requires argument \"ldapbasedn\", \"ldapprefix\" or \"ldapsuffix\" to be set"),
1284+
errmsg("authentication method \"ldap\" requires argument \"ldapbasedn\", \"ldapprefix\", or \"ldapsuffix\" to be set"),
12851285
errcontext("line %d of configuration file \"%s\"",
12861286
line_num, HbaFileName)));
12871287
return false;
@@ -1747,7 +1747,7 @@ check_usermap(const char *usermap_name,
17471747
return STATUS_OK;
17481748
}
17491749
ereport(LOG,
1750-
(errmsg("provided username (%s) and authenticated username (%s) don't match",
1750+
(errmsg("provided user name (%s) and authenticated user name (%s) do not match",
17511751
auth_user, pg_role)));
17521752
return STATUS_ERROR;
17531753
}

src/backend/libpq/pqcomm.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
* Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
3131
* Portions Copyright (c) 1994, Regents of the University of California
3232
*
33-
* $PostgreSQL: pgsql/src/backend/libpq/pqcomm.c,v 1.208 2010/03/13 16:56:37 momjian Exp $
33+
* $PostgreSQL: pgsql/src/backend/libpq/pqcomm.c,v 1.209 2010/03/21 00:17:58 petere Exp $
3434
*
3535
*-------------------------------------------------------------------------
3636
*/
@@ -843,7 +843,7 @@ pq_getbyte_if_available(unsigned char *c)
843843
#else
844844
if (!pg_set_noblock(MyProcPort->sock))
845845
ereport(ERROR,
846-
(errmsg("couldn't put socket to non-blocking mode: %m")));
846+
(errmsg("could not set socket to non-blocking mode: %m")));
847847
#endif
848848
MyProcPort->noblock = true;
849849
PG_TRY();
@@ -889,7 +889,7 @@ pq_getbyte_if_available(unsigned char *c)
889889
#else
890890
if (!pg_set_block(MyProcPort->sock))
891891
ereport(FATAL,
892-
(errmsg("couldn't put socket to blocking mode: %m")));
892+
(errmsg("could not set socket to blocking mode: %m")));
893893
#endif
894894
MyProcPort->noblock = false;
895895
PG_RE_THROW();
@@ -900,7 +900,7 @@ pq_getbyte_if_available(unsigned char *c)
900900
#else
901901
if (!pg_set_block(MyProcPort->sock))
902902
ereport(FATAL,
903-
(errmsg("couldn't put socket to blocking mode: %m")));
903+
(errmsg("could not set socket to blocking mode: %m")));
904904
#endif
905905
MyProcPort->noblock = false;
906906

src/backend/replication/libpqwalreceiver/libpqwalreceiver.c

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
*
1111
*
1212
* IDENTIFICATION
13-
* $PostgreSQL: pgsql/src/backend/replication/libpqwalreceiver/libpqwalreceiver.c,v 1.7 2010/03/19 19:19:38 sriggs Exp $
13+
* $PostgreSQL: pgsql/src/backend/replication/libpqwalreceiver/libpqwalreceiver.c,v 1.8 2010/03/21 00:17:58 petere Exp $
1414
*
1515
*-------------------------------------------------------------------------
1616
*/
@@ -102,7 +102,7 @@ libpqrcv_connect(char *conninfo, XLogRecPtr startpoint)
102102
{
103103
PQclear(res);
104104
ereport(ERROR,
105-
(errmsg("could not receive the SYSID and timeline ID from "
105+
(errmsg("could not receive database system identifier and timeline ID from "
106106
"the primary server: %s",
107107
PQerrorMessage(streamConn))));
108108
}
@@ -114,7 +114,7 @@ libpqrcv_connect(char *conninfo, XLogRecPtr startpoint)
114114
PQclear(res);
115115
ereport(ERROR,
116116
(errmsg("invalid response from primary server"),
117-
errdetail("expected 1 tuple with 2 fields, got %d tuples with %d fields",
117+
errdetail("Expected 1 tuple with 2 fields, got %d tuples with %d fields.",
118118
ntuples, nfields)));
119119
}
120120
primary_sysid = PQgetvalue(res, 0, 0);
@@ -129,8 +129,8 @@ libpqrcv_connect(char *conninfo, XLogRecPtr startpoint)
129129
{
130130
PQclear(res);
131131
ereport(ERROR,
132-
(errmsg("system differs between the primary and standby"),
133-
errdetail("the primary SYSID is %s, standby SYSID is %s",
132+
(errmsg("database system identifier differs between the primary and standby"),
133+
errdetail("The primary's identifier is %s, the standby's identifier is %s.",
134134
primary_sysid, standby_sysid)));
135135
}
136136

@@ -152,7 +152,7 @@ libpqrcv_connect(char *conninfo, XLogRecPtr startpoint)
152152
res = PQexec(streamConn, cmd);
153153
if (PQresultStatus(res) != PGRES_COPY_OUT)
154154
ereport(ERROR,
155-
(errmsg("could not start XLOG streaming: %s",
155+
(errmsg("could not start WAL streaming: %s",
156156
PQerrorMessage(streamConn))));
157157
PQclear(res);
158158

@@ -275,7 +275,7 @@ libpqrcv_receive(int timeout, unsigned char *type, char **buffer, int *len)
275275

276276
if (PQconsumeInput(streamConn) == 0)
277277
ereport(ERROR,
278-
(errmsg("could not receive data from XLOG stream: %s",
278+
(errmsg("could not receive data from WAL stream: %s",
279279
PQerrorMessage(streamConn))));
280280
}
281281
justconnected = false;
@@ -297,12 +297,12 @@ libpqrcv_receive(int timeout, unsigned char *type, char **buffer, int *len)
297297
}
298298
PQclear(res);
299299
ereport(ERROR,
300-
(errmsg("could not receive data from XLOG stream: %s",
300+
(errmsg("could not receive data from WAL stream: %s",
301301
PQerrorMessage(streamConn))));
302302
}
303303
if (rawlen < -1)
304304
ereport(ERROR,
305-
(errmsg("could not receive data from XLOG stream: %s",
305+
(errmsg("could not receive data from WAL stream: %s",
306306
PQerrorMessage(streamConn))));
307307

308308
/* Return received messages to caller */

src/backend/replication/walreceiver.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
*
3030
*
3131
* IDENTIFICATION
32-
* $PostgreSQL: pgsql/src/backend/replication/walreceiver.c,v 1.6 2010/02/26 02:00:57 momjian Exp $
32+
* $PostgreSQL: pgsql/src/backend/replication/walreceiver.c,v 1.7 2010/03/21 00:17:58 petere Exp $
3333
*
3434
*-------------------------------------------------------------------------
3535
*/
@@ -283,7 +283,7 @@ WalReceiverMain(void)
283283
*/
284284
if (!RecoveryInProgress())
285285
ereport(FATAL,
286-
(errmsg("cannot continue XLOG streaming, recovery has already ended")));
286+
(errmsg("cannot continue WAL streaming, recovery has already ended")));
287287

288288
/* Process any requests or signals received recently */
289289
ProcessWalRcvInterrupts();

src/backend/storage/lmgr/lock.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $PostgreSQL: pgsql/src/backend/storage/lmgr/lock.c,v 1.195 2010/02/26 02:01:00 momjian Exp $
11+
* $PostgreSQL: pgsql/src/backend/storage/lmgr/lock.c,v 1.196 2010/03/21 00:17:58 petere Exp $
1212
*
1313
* NOTES
1414
* A lock table is a shared memory hash table. When
@@ -516,7 +516,7 @@ LockAcquireExtended(const LOCKTAG *locktag,
516516
lockmode > RowExclusiveLock)
517517
ereport(ERROR,
518518
(errcode(ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE),
519-
errmsg("cannot acquire lockmode %s on database objects while recovery is in progress",
519+
errmsg("cannot acquire lock mode %s on database objects while recovery is in progress",
520520
lockMethodTable->lockModeNames[lockmode]),
521521
errhint("Only RowExclusiveLock or less can be acquired on database objects during recovery.")));
522522

src/backend/tcop/postgres.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $PostgreSQL: pgsql/src/backend/tcop/postgres.c,v 1.591 2010/02/26 02:01:01 momjian Exp $
11+
* $PostgreSQL: pgsql/src/backend/tcop/postgres.c,v 1.592 2010/03/21 00:17:58 petere Exp $
1212
*
1313
* NOTES
1414
* this is the "main" module of the postgres backend and
@@ -2273,7 +2273,7 @@ errdetail_recovery_conflict(void)
22732273
errdetail("User was holding a relation lock for too long.");
22742274
break;
22752275
case PROCSIG_RECOVERY_CONFLICT_TABLESPACE:
2276-
errdetail("User was or may have been using tablespace that must be dropped.");
2276+
errdetail("User was or might have been using tablespace that must be dropped.");
22772277
break;
22782278
case PROCSIG_RECOVERY_CONFLICT_SNAPSHOT:
22792279
errdetail("User query might have needed to see row versions that must be removed.");

src/backend/utils/init/postinit.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $PostgreSQL: pgsql/src/backend/utils/init/postinit.c,v 1.205 2010/03/19 19:19:38 sriggs Exp $
11+
* $PostgreSQL: pgsql/src/backend/utils/init/postinit.c,v 1.206 2010/03/21 00:17:59 petere Exp $
1212
*
1313
*
1414
*-------------------------------------------------------------------------
@@ -222,8 +222,8 @@ PerformAuthentication(Port *port)
222222
*/
223223
if (am_walsender)
224224
ereport(LOG,
225-
(errmsg("connection authorized: user=%s database=replication",
226-
port->user_name)));
225+
(errmsg("connection authorized: user=%s database=%s",
226+
port->user_name, "replication")));
227227
else if (Log_connections)
228228
ereport(LOG,
229229
(errmsg("connection authorized: user=%s database=%s",

src/backend/utils/misc/guc.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
* Written by Peter Eisentraut <peter_e@gmx.net>.
1111
*
1212
* IDENTIFICATION
13-
* $PostgreSQL: pgsql/src/backend/utils/misc/guc.c,v 1.543 2010/02/26 02:01:14 momjian Exp $
13+
* $PostgreSQL: pgsql/src/backend/utils/misc/guc.c,v 1.544 2010/03/21 00:17:59 petere Exp $
1414
*
1515
*--------------------------------------------------------------------
1616
*/
@@ -1246,7 +1246,7 @@ static struct config_bool ConfigureNamesBool[] =
12461246

12471247
{
12481248
{"lo_compat_privileges", PGC_SUSET, COMPAT_OPTIONS_PREVIOUS,
1249-
gettext_noop("Enables backward compatibility mode for privilege checks on large objects"),
1249+
gettext_noop("Enables backward compatibility mode for privilege checks on large objects."),
12501250
gettext_noop("Skips privilege checks when reading or modifying large objects, "
12511251
"for compatibility with PostgreSQL releases prior to 9.0.")
12521252
},
@@ -1378,7 +1378,7 @@ static struct config_int ConfigureNamesInt[] =
13781378

13791379
{
13801380
{"max_standby_delay", PGC_SIGHUP, WAL_SETTINGS,
1381-
gettext_noop("Sets the maximum delay to avoid conflict processing on Hot Standby servers."),
1381+
gettext_noop("Sets the maximum delay to avoid conflict processing on hot standby servers."),
13821382
NULL
13831383
},
13841384
&MaxStandbyDelay,

0 commit comments

Comments
 (0)