pg.ddx.io pgsql-committers@postgresql.org mailing list archive
help / color / mirror / Atom feedpgsql: Improve the recently-added support for properly pluralized error
2+ messages / 2 participants
[nested] [flat]
* pgsql: Improve the recently-added support for properly pluralized error
@ 2009-06-04 18:33 Tom Lane <tgl@postgresql.org>
0 siblings, 0 replies; 2+ messages in thread
From: tgl@postgresql.org @ 2009-06-04 18:33 UTC (permalink / raw)
To: pgsql-committers
Log Message:
-----------
Improve the recently-added support for properly pluralized error messages
by extending the ereport() API to cater for pluralization directly. This
is better than the original method of calling ngettext outside the elog.c
code because (1) it avoids double translation, which wastes cycles and in
the worst case could give a wrong result; and (2) it avoids having to use
a different coding method in PL code than in the core backend. The
client-side uses of ngettext are not touched since neither of these concerns
is very pressing in the client environment. Per my proposal of yesterday.
Modified Files:
--------------
pgsql/doc/src/sgml:
nls.sgml (r1.17 -> r1.18)
(http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/doc/src/sgml/nls.sgml?r1=1.17&r2=1.18)
sources.sgml (r2.33 -> r2.34)
(http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/doc/src/sgml/sources.sgml?r1=2.33&r2=2.34)
pgsql/src/backend/catalog:
dependency.c (r1.87 -> r1.88)
(http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/catalog/dependency.c?r1=1.87&r2=1.88)
pg_proc.c (r1.162 -> r1.163)
(http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/catalog/pg_proc.c?r1=1.162&r2=1.163)
pg_shdepend.c (r1.32 -> r1.33)
(http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/catalog/pg_shdepend.c?r1=1.32&r2=1.33)
pgsql/src/backend/executor:
execQual.c (r1.246 -> r1.247)
(http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/executor/execQual.c?r1=1.246&r2=1.247)
pgsql/src/backend:
nls.mk (r1.25 -> r1.26)
(http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/nls.mk?r1=1.25&r2=1.26)
pgsql/src/backend/parser:
parse_func.c (r1.214 -> r1.215)
(http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/parser/parse_func.c?r1=1.214&r2=1.215)
pgsql/src/backend/postmaster:
bgwriter.c (r1.58 -> r1.59)
(http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/postmaster/bgwriter.c?r1=1.58&r2=1.59)
pgsql/src/backend/utils/error:
elog.c (r1.213 -> r1.214)
(http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/error/elog.c?r1=1.213&r2=1.214)
pgsql/src/include/utils:
elog.h (r1.99 -> r1.100)
(http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/include/utils/elog.h?r1=1.99&r2=1.100)
pgsql/src/pl/plperl:
nls.mk (r1.5 -> r1.6)
(http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/pl/plperl/nls.mk?r1=1.5&r2=1.6)
pgsql/src/pl/plpgsql/src:
nls.mk (r1.7 -> r1.8)
(http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/pl/plpgsql/src/nls.mk?r1=1.7&r2=1.8)
pl_exec.c (r1.241 -> r1.242)
(http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/pl/plpgsql/src/pl_exec.c?r1=1.241&r2=1.242)
pgsql/src/pl/plpython:
nls.mk (r1.4 -> r1.5)
(http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/pl/plpython/nls.mk?r1=1.4&r2=1.5)
plpython.c (r1.120 -> r1.121)
(http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/pl/plpython/plpython.c?r1=1.120&r2=1.121)
pgsql/src/pl/tcl:
nls.mk (r1.4 -> r1.5)
(http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/pl/tcl/nls.mk?r1=1.4&r2=1.5)
^ permalink raw reply [nested|flat] 2+ messages in thread
* pgsql: Push dedicated BumpBlocks to the tail of the blocks list
@ 2024-04-16 22:40 David Rowley <drowley@postgresql.org>
0 siblings, 0 replies; 2+ messages in thread
From: David Rowley @ 2024-04-16 22:40 UTC (permalink / raw)
To: pgsql-committers@lists.postgresql.org
Push dedicated BumpBlocks to the tail of the blocks list
BumpContext relies on using the head block from its 'blocks' field to
use as the current block to allocate new chunks to. When we receive an
allocation request larger than allocChunkLimit, we place these chunks on
a new dedicated block and, until now, we pushed the block onto the
*head* of the 'blocks' list.
This behavior caused the previous bump block to no longer be available
for new normal-sized (non-large) allocations and would result in blocks
only being partially filled if a large allocation request arrived before
the block became full.
Here adjust the code to push these dedicated blocks onto the *tail* of
the blocks list so that the head block remains intact and available to
be used by normal allocation request sizes until it becomes full.
In passing, make the elog(ERROR) calls for the unsupported callbacks
consistent. Likewise for the header comments for those functions.
Discussion: https://postgr.es/m/CAApHDvp9___r-ayJj0nZ6GD3MeCGwGZ0_6ZptWpwj+zqHtmwCw@mail.gmail.com
Discussion: https://postgr.es/m/CAApHDvqerXpzUnuDQfUEi3DZA+9=Ud9WSt3ruxN5b6PcOosx2g@mail.gmail.com
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/6d2fd66b9908d1557d7e49b1bdb4c597192f3729
Modified Files
--------------
src/backend/utils/mmgr/bump.c | 17 ++++++++++-------
src/test/regress/expected/sysviews.out | 2 +-
2 files changed, 11 insertions(+), 8 deletions(-)
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2024-04-16 22:40 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2009-06-04 18:33 pgsql: Improve the recently-added support for properly pluralized error Tom Lane <tgl@postgresql.org>
2024-04-16 22:40 pgsql: Push dedicated BumpBlocks to the tail of the blocks list David Rowley <drowley@postgresql.org>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox