Skip to content

Commit 04a942e

Browse files
committed
Split up wal-logging items:
< * Allow control over which tables are WAL-logged [walcontrol] > * Allow WAL logging to be turned off for a table, but the table > might be dropped or truncated during crash recovery [walcontrol] < commit. To do this, only a single writer can modify the table, and < writes must happen only on new pages. Readers can continue accessing < the table. This would affect COPY, and perhaps INSERT/UPDATE too. < Another option is to avoid transaction logging entirely and truncate < or drop the table on crash recovery. These should be implemented < using ALTER TABLE, e.g. ALTER TABLE PERSISTENCE [ DROP | TRUNCATE | < STABLE | DEFAULT ]. Tables using non-default logging should not use < referential integrity with default-logging tables, and tables using < stable logging probably can not have indexes. One complexity is < the handling of indexes on TOAST tables. > commit. This should be implemented using ALTER TABLE, e.g. ALTER > TABLE PERSISTENCE [ DROP | TRUNCATE | DEFAULT ]. Tables using > non-default logging should not use referential integrity with > default-logging tables. A table without dirty buffers during a > crash could perhaps avoid the drop/truncate. > > * Allow WAL logging to be turned off for a table, but the table would > avoid being truncated/dropped [walcontrol] > > To do this, only a single writer can modify the table, and writes > must happen only on new pages so the new pages can be removed during > crash recovery. Readers can continue accessing the table. Such > tables probably cannot have indexes. One complexity is the handling > of indexes on TOAST tables.
1 parent 8bf47f4 commit 04a942e

File tree

2 files changed

+36
-27
lines changed

2 files changed

+36
-27
lines changed

doc/TODO

Lines changed: 17 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
PostgreSQL TODO List
33
====================
44
Current maintainer: Bruce Momjian (pgman@candle.pha.pa.us)
5-
Last updated: Fri Feb 3 22:23:19 EST 2006
5+
Last updated: Mon Feb 6 21:08:10 EST 2006
66

77
The most recent version of this document can be viewed at
88
http://www.postgresql.org/docs/faqs.TODO.html.
@@ -1024,19 +1024,24 @@ Write-Ahead Log
10241024
remove the 'fsync' parameter (which results in an an inconsistent
10251025
database) in favor of this capability.
10261026

1027-
* Allow control over which tables are WAL-logged [walcontrol]
1027+
* Allow WAL logging to be turned off for a table, but the table
1028+
might be dropped or truncated during crash recovery [walcontrol]
10281029

10291030
Allow tables to bypass WAL writes and just fsync() dirty pages on
1030-
commit. To do this, only a single writer can modify the table, and
1031-
writes must happen only on new pages. Readers can continue accessing
1032-
the table. This would affect COPY, and perhaps INSERT/UPDATE too.
1033-
Another option is to avoid transaction logging entirely and truncate
1034-
or drop the table on crash recovery. These should be implemented
1035-
using ALTER TABLE, e.g. ALTER TABLE PERSISTENCE [ DROP | TRUNCATE |
1036-
STABLE | DEFAULT ]. Tables using non-default logging should not use
1037-
referential integrity with default-logging tables, and tables using
1038-
stable logging probably can not have indexes. One complexity is
1039-
the handling of indexes on TOAST tables.
1031+
commit. This should be implemented using ALTER TABLE, e.g. ALTER
1032+
TABLE PERSISTENCE [ DROP | TRUNCATE | DEFAULT ]. Tables using
1033+
non-default logging should not use referential integrity with
1034+
default-logging tables. A table without dirty buffers during a
1035+
crash could perhaps avoid the drop/truncate.
1036+
1037+
* Allow WAL logging to be turned off for a table, but the table would
1038+
avoid being truncated/dropped [walcontrol]
1039+
1040+
To do this, only a single writer can modify the table, and writes
1041+
must happen only on new pages so the new pages can be removed during
1042+
crash recovery. Readers can continue accessing the table. Such
1043+
tables probably cannot have indexes. One complexity is the handling
1044+
of indexes on TOAST tables.
10401045

10411046

10421047
Optimizer / Executor

doc/src/FAQ/TODO.html

Lines changed: 19 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
<body bgcolor="#FFFFFF" text="#000000" link="#FF0000" vlink="#A00000" alink="#0000FF">
99
<h1><a name="section_1">PostgreSQL TODO List</a></h1>
1010
<p>Current maintainer: Bruce Momjian (<a href="mailto:pgman@candle.pha.pa.us">pgman@candle.pha.pa.us</a>)<br/>
11-
Last updated: Fri Feb 3 22:23:19 EST 2006
11+
Last updated: Mon Feb 6 21:08:10 EST 2006
1212
</p>
1313
<p>The most recent version of this document can be viewed at<br/>
1414
<a href="http://www.postgresql.org/docs/faqs.TODO.html">http://www.postgresql.org/docs/faqs.TODO.html</a>.
@@ -26,7 +26,7 @@ <h1><a name="section_2">Administration</a></h1>
2626

2727
<ul>
2828
<li>%Remove behavior of postmaster -o
29-
</li><li>-<em>%Allow pooled connections to list all prepared statements</em>
29+
</li><li>-*%Allow pooled connections to list all prepared statements*
3030
<p> This would allow an application inheriting a pooled connection to know
3131
the statements prepared in the current session.
3232
</p>
@@ -79,8 +79,8 @@ <h1><a name="section_2">Administration</a></h1>
7979
</li><li>%Allow postgresql.conf file values to be changed via an SQL
8080
API, perhaps using SET GLOBAL
8181
</li><li>Allow the server to be stopped/restarted via an SQL API
82-
</li><li>-<em>Issue a warning if a change-on-restart-only postgresql.conf value
83-
is modified and the server config files are reloaded</em>
82+
</li><li>-<em>Issue a warning if a change-on-restart-only postgresql.conf value</em>
83+
is modified and the server config files are reloaded
8484
</li><li>Mark change-on-restart-only values in postgresql.conf
8585
</li></ul>
8686
</li><li>Tablespaces
@@ -928,18 +928,22 @@ <h1><a name="section_19">Write-Ahead Log</a></h1>
928928
remove the 'fsync' parameter (which results in an an inconsistent
929929
database) in favor of this capability.
930930
</p>
931-
</li><li>Allow control over which tables are WAL-logged [<a href="http://momjian.postgresql.org/cgi-bin/pgtodo?walcontrol">walcontrol</a>]
931+
</li><li>Allow WAL logging to be turned off for a table, but the table
932+
might be dropped or truncated during crash recovery [<a href="http://momjian.postgresql.org/cgi-bin/pgtodo?walcontrol">walcontrol</a>]
932933
<p> Allow tables to bypass WAL writes and just fsync() dirty pages on
933-
commit. To do this, only a single writer can modify the table, and
934-
writes must happen only on new pages. Readers can continue accessing
935-
the table. This would affect COPY, and perhaps INSERT/UPDATE too.
936-
Another option is to avoid transaction logging entirely and truncate
937-
or drop the table on crash recovery. These should be implemented
938-
using ALTER TABLE, e.g. ALTER TABLE PERSISTENCE [ DROP | TRUNCATE |
939-
STABLE | DEFAULT ]. Tables using non-default logging should not use
940-
referential integrity with default-logging tables, and tables using
941-
stable logging probably can not have indexes. One complexity is
942-
the handling of indexes on TOAST tables.
934+
commit. This should be implemented using ALTER TABLE, e.g. ALTER
935+
TABLE PERSISTENCE [<a href="http://momjian.postgresql.org/cgi-bin/pgtodo? DROP | TRUNCATE | DEFAULT "> DROP | TRUNCATE | DEFAULT </a>]. Tables using
936+
non-default logging should not use referential integrity with
937+
default-logging tables. A table without dirty buffers during a
938+
crash could perhaps avoid the drop/truncate.
939+
</p>
940+
</li><li>Allow WAL logging to be turned off for a table, but the table would
941+
avoid being truncated/dropped [<a href="http://momjian.postgresql.org/cgi-bin/pgtodo?walcontrol">walcontrol</a>]
942+
<p> To do this, only a single writer can modify the table, and writes
943+
must happen only on new pages so the new pages can be removed during
944+
crash recovery. Readers can continue accessing the table. Such
945+
tables probably cannot have indexes. One complexity is the handling
946+
of indexes on TOAST tables.
943947
</p>
944948
</li></ul>
945949
<h1><a name="section_20">Optimizer / Executor</a></h1>

0 commit comments

Comments
 (0)