| From: | Jacob Champion <jacob(dot)champion(at)enterprisedb(dot)com> |
|---|---|
| To: | PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
| Cc: | Andres Freund <andres(at)anarazel(dot)de>, Nazir Bilal Yavuz <byavuz81(at)gmail(dot)com> |
| Subject: | [PATCH] CI: Add a CPAN cache on Windows |
| Date: | 2026-06-05 18:05:08 |
| Message-ID: | CAOYmi+mC8_ZW3A1vGZHMDiW+vCMHQNga4jb9jawHn=LauwL6xQ@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
Based on the conversation at [1].
This caches the Perl site directory after we've installed IPC::Run.
After consulting with Christoph Berg and David Wheeler on the Discord,
I've set up the cache to key on the output of `perl -V`, so that we'll
rebuild it after any change to Perl underneath us.
I went back and forth on doing the bare minimum (just save off the
CPAN source+build caches, then run CPAN each time) vs the more
involved strategy presented here (don't use CPAN at all on a cache
hit). The simpler approach only saved us about half of the up-to-60s
installation delay, because I can't seem to get CPAN to skip the
installation if IPC::Run is already installed.
So this patch is more code, but it's a lot faster once the cache is
warm. (The cache is also much smaller, as a minor bonus, but it was
only ~3MB to start with.)
--Jacob
[1] https://postgr.es/m/CAOYmi%2BkyuJHC7NTJWbzLBX25QnCsMVDbYWmv5tveSveNUyBAUw%40mail.gmail.com
| Attachment | Content-Type | Size |
|---|---|---|
| 0001-ci-Cache-the-CPAN-installation-on-Windows-runners.patch | application/octet-stream | 7.2 KB |
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Bruce Momjian | 2026-06-05 18:14:21 | Re: First draft of PG 19 release notes |
| Previous Message | Corey Huinker | 2026-06-05 17:52:01 | Re: postgres_fdw: Emit message when batch_size is reduced |