Add PostgreSQL 19 compatibility#654
Conversation
PG19 introduces several API changes that break the build: - planner_hook gains an ExplainState *es parameter - QueryDesc->totaltime renamed to QueryDesc->query_instr with executor-managed instrumentation lifecycle (query_instr_options) - LWLockNewTrancheId() now requires a name argument - ShmemInitHash() drops the max_size parameter (5->4 args) - post_parse_analyze_hook JumbleState parameter is now const-qualified - escape_string_warning removed from core_yy_extra_type - storage/shmem.h, storage/proc.h, utils/tuplestore.h no longer transitively included All changes are guarded with #if PG_VERSION_NUM >= 190000 and have zero impact on PG 14-18. Tested against PG 19devel with all 22 regression tests and 34 TAP tests passing.
|
To add to this, I'd encourage the extension authors to also look at this commit https://git.postgresql.org/gitweb/?p=postgresql.git;a=commitdiff;h=49cc0d41488b92a1d547e278b459c3b224393c8f;hp=51098839cfb40dc496bb48fe4ea14d19170099ac That commit made (I also had a separate commit for other PG19 fixes, which is very similar to this PR, FWIW: lfittl@77f6ec1) |
|
Thanks for the pull request and sorry for the late response, but I think adding PG 19 support is a bit more than this. For example I would want some tests to make sure for example PGQ is supported. And I also wonder if we should not move to the new API for hashes in shared memory. |
Description:
PG19 introduces several API changes that break the build. This PR adds
C code changes (pg_stat_monitor.c, hash_query.c, pg_stat_monitor.h):
executor-managed instrumentation lifecycle (query_instr_options)
Test changes:
All changes use #if PG_VERSION_NUM >= 190000 / #else / #endif guards.
Tested against PG 19devel — all 22 regression tests and 34 TAP tests pass.
Links:
Related PostgreSQL 19 commits:
Upstream CI only tests PG 14-18: