| From: | Andres Freund <andres(at)anarazel(dot)de> | 
|---|---|
| To: | Daniel Gustafsson <daniel(at)yesql(dot)se> | 
| Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Thomas Munro <thomas(dot)munro(at)gmail(dot)com>, Robert Haas <robertmhaas(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org> | 
| Subject: | Re: initdb caching during tests | 
| Date: | 2023-08-23 01:17:45 | 
| Message-ID: | 20230823011745.jjj3fvo6njubifn4@awork3.anarazel.de | 
| Views: | Whole Thread | Raw Message | Download mbox | Resend email | 
| Thread: | |
| Lists: | pgsql-hackers | 
Hi,
On 2023-08-22 23:47:24 +0200, Daniel Gustafsson wrote:
> I had a look at this today and have been running a lot of tests with it without
> finding anything that breaks.
Thanks!
> The duplicated code is unfortunate, but after playing around with some
> options I agree that it's likely the best option.
Good and bad to hear :)
> While looking I did venture down the rabbithole of making it support extra
> params as well, but I don't think moving the goalposts there is doing us any
> favors, it's clearly chasing diminishing returns.
Agreed. I also went down that rabbithole, but it quickly gets a lot more code
and complexity - and there just aren't that many tests using non-default
options.
> My only small gripe is that I keep thinking about template databases for CREATE
> DATABASE when reading the error messages in this patch, which is clearly not
> related to what this does.
> 
> +   note("initializing database system by copying initdb template");
> 
> I personally would've used cache instead of template in the user facing parts
> to keep concepts separated, but thats personal taste.
I am going back and forth on that one (as one can notice with $subject). It
doesn't quite seem like a cache, as it's not "created" on demand and only
usable when the exactly same parameters are used repeatedly. But template is
overloaded as you say...
> All in all, I think this is committable as is.
Cool. Planning to do that tomorrow. We can easily extend / adjust this later,
it just affects testing infrastructure.
Greetings,
Andres Freund
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Andy Fan | 2023-08-23 01:19:34 | Re: Support run-time partition pruning for hash join | 
| Previous Message | Imseih (AWS), Sami | 2023-08-23 00:55:51 | False "pg_serial": apparent wraparound” in logs |