Re: [BUG] temporary file usage report with extended protocol and unnamed portals
Sami Imseih <samimseih@gmail.com>
From: Sami Imseih <samimseih@gmail.com>
To: Michael Paquier <michael@paquier.xyz>
Cc: Mircea Cadariu <cadariu.mircea@gmail.com>, Frédéric Yhuel <frederic.yhuel@dalibo.com>, Tom Lane <tgl@sss.pgh.pa.us>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>, Benoit Lobréau <benoit.lobreau@dalibo.com>, Guillaume Lelarge <guillaume.lelarge@dalibo.com>, Pierrick Chovelon <pierrick.chovelon@dalibo.com>
Date: 2025-09-16T19:13:39Z
Lists: pgsql-hackers
Attachments
- v11-0001-Fix-temp-file-log-blame-for-unnamed-portals.patch (application/octet-stream) patch v11-0001
- v11-0002-Add-tests-for-temp-table-logging.patch (application/octet-stream) patch v11-0002
> Just my 2c while looking at this particular part of the thread. Now
> to the main patch proposed, v8 or v10..
I have been thinking about whether test coverage is worth it for temp
file logging. I think it is, but others may disagree. However, I also
don't think the current tests are correct.
For example, this is not true. We should now always log the correct query.
```
ok(0, "The wrong query has been logged");
```
Also, the tests should be checking that we are logging "temporary file: "
before the next statement is logged.
I split up the actual fix and the corrected tests into separate patches.
They can be committed together if there is agreement that tests are worth it.
--
Sami
Commits
-
Drop unnamed portal immediately after execution to completion
- 1fd981f05369 19 (unreleased) landed
-
Override log_error_verbosity to "default" in test 009_log_temp_files
- 02c171f63fca 19 (unreleased) landed
-
Add tests for logging of temporary file removal and statement
- 76bba033128a 19 (unreleased) landed