Re: WAL usage calculation patch
Julien Rouhaud <rjuju123@gmail.com>
Commits
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Change the display of WAL usage statistics in Explain.
- 69bfaf2e1de4 13.0 landed
-
Cosmetic fixups for WAL usage work.
- ef08ca113fe3 13.0 landed
-
Allow parallel create index to accumulate buffer usage stats.
- 5c71362174eb 13.0 landed
- f179e9f01b65 11.8 landed
- 13823ad3b012 12.3 landed
-
Allow autovacuum to log WAL usage statistics.
- b7ce6de93b59 13.0 landed
-
Add the option to report WAL usage in EXPLAIN and auto_explain.
- 33e05f89c53e 13.0 landed
-
Allow pg_stat_statements to track WAL usage statistics.
- 6b466bf5f2be 13.0 landed
-
Add infrastructure to track WAL usage.
- df3b181499b4 13.0 landed
-
Include information on buffer usage during planning phase, in EXPLAIN output, take two.
- ce77abe63cfc 13.0 cited
-
Include information on buffer usage during planning phase, in EXPLAIN output.
- ed7a5095716e 13.0 cited
-
Allow parallel vacuum to accumulate buffer usage.
- 3a5e22138a8d 13.0 landed
-
Allow pg_stat_statements to track planning statistics.
- 17e03282241c 13.0 cited
Attachments
- v5-0001-Track-WAL-usage.patch (text/plain)
On Wed, Mar 18, 2020 at 09:02:58AM +0300, Kirill Bychik wrote: > > There is a higher-level Instrumentation API that can be used with > INSTRUMENT_WAL flag to collect the wal usage information. I believe > the instrumentation is widely used in the executor code, so it should > not be a problem to colelct instrumentation information on autovacuum > worker level. > > Just a recommendation/chat, though. I am happy with the way the data > is collected now. If you commit this variant, please add a TODO to > rework wal usage to common instr API. The instrumentation is somewhat intended to be used with executor nodes, not backend commands. I don't see real technical reason that would prevent that, but I prefer to keep things as-is for now, as it sound less controversial. This is for the 3rd patch, which may not even be considered for this CF anyway. > > > As for the tests, please get somebody else to review this. I strongly > > > believe checking full page writes here could be a source of > > > instability. > > > > > > I'm also a little bit dubious about it. The initial checkpoint should make > > things stable (of course unless full_page_writes is disabled), and Cfbot also > > seems happy about it. At least keeping it for the temporary tables test > > shouldn't be a problem. > > Temp tables should show zero FPI WAL records, true :) > > I have no objections to the patch. I'm attaching a v5 with fp records only for temp tables, so there's no risk of instability. As I previously said I'm fine with your two patches, so unless you have objections on the fpi test for temp tables or the documentation changes, I believe those should be ready for committer.