postgresql/src/bin
Robert Haas ebfb814f7c walmethods.c/h: Make WalWriteMethod more object-oriented.
Normally when we use object-oriented programming techniques, we
provide a pointer to an object and then some way of looking up the
associated table of callbacks, but walmethods.c/h took the alternative
approach of providing only a pointer to the table of callbacks and
thus imposed the artificial restriction that there could only ever be
one object of each type, so that the callbacks could find it via a
global variable. That doesn't seem like the right idea, so revise the
approach.

Each callback which does not already have an argument of type
Walfile * now takes a pointer to the relevant WalWriteMethod *
so that these callbacks need not rely on there being only one
object of each type.

Freeing a WalWriteMethod is now performed via a callback provided
for that purpose rather than requiring the caller to know which
WAL method they want to free.

Discussion: http://postgr.es/m/CA+TgmoZS0Kw98fOoAcGz8B9iDhdqB4Be4e=vDZaJZ5A-xMYBqA@mail.gmail.com
2022-09-19 12:53:46 -04:00
..
initdb Don't allow creation of database with ICU locale with unsupported encoding 2022-09-16 09:41:33 +02:00
pg_amcheck Fix an assortment of improper usages of string functions 2022-09-06 13:19:44 +12:00
pg_archivecleanup Revert "Use wildcards instead of manually-maintained file lists in */nls.mk." 2022-07-13 14:29:10 -04:00
pg_basebackup walmethods.c/h: Make WalWriteMethod more object-oriented. 2022-09-19 12:53:46 -04:00
pg_checksums Replace pgwin32_is_junction() with lstat(). 2022-08-06 12:50:59 +12:00
pg_config Revert "Use wildcards instead of manually-maintained file lists in */nls.mk." 2022-07-13 14:29:10 -04:00
pg_controldata Revert "Use wildcards instead of manually-maintained file lists in */nls.mk." 2022-07-13 14:29:10 -04:00
pg_ctl Use SIGNAL_ARGS consistently to declare signal handlers. 2022-09-14 14:44:50 -04:00
pg_dump Assorted examples of expanded type-safer palloc/pg_malloc API 2022-09-12 08:45:03 +02:00
pg_resetwal Revert ill-considered change in pg_resetwal output. 2022-09-15 10:58:03 -04:00
pg_rewind Clean up inconsistent use of fflush(). 2022-08-29 13:55:41 -04:00
pg_test_fsync Use SIGNAL_ARGS consistently to declare signal handlers. 2022-09-14 14:44:50 -04:00
pg_test_timing Revert "Use wildcards instead of manually-maintained file lists in */nls.mk." 2022-07-13 14:29:10 -04:00
pg_upgrade Revert ill-considered change in pg_resetwal output. 2022-09-15 10:58:03 -04:00
pg_verifybackup Clean up inconsistent use of fflush(). 2022-08-29 13:55:41 -04:00
pg_waldump Use the terminology "WAL file" not "log file" more consistently. 2022-09-14 18:40:58 -04:00
pgbench Add missing serial commas 2022-09-19 06:35:01 -04:00
pgevent Update copyright for 2022 2022-01-07 19:04:57 -05:00
psql Assorted examples of expanded type-safer palloc/pg_malloc API 2022-09-12 08:45:03 +02:00
scripts Fix createdb tests for C locale 2022-09-16 11:10:41 +02:00
Makefile Update copyright for 2022 2022-01-07 19:04:57 -05:00