You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Declarative (SDL) rollout fails on Spilo/postgres-operator databases: type "pg_stat_statements" does not exist (SQLSTATE 42704) #21241
Hey again, thanks for the incredible support in regards to my previous issue #20434 !!
I'd like to report one more problem relative to one of my previous bugs, which came after the fixes.
Apparently the "metric_helpers" error came from Zalando's Spilo Wrapper, in which they have a function called pg_stat_statements as stated below. metric_helpers.sql :
CREATE EXTENSION pg_stat_statements;
CREATESCHEMAmetric_helpers;
CREATEFUNCTIONmetric_helpers.pg_stat_statements(showtext boolean)
RETURNS SETOF public.pg_stat_statements
LANGUAGE sql IMMUTABLE STRICT SECURITY DEFINER
AS $$ SELECT*FROMpublic.pg_stat_statements(showtext) $$;
Steps to reproduce
Trying to create a rollout with a bootstrapped postgres out of the box Zalando Spilo's postgres-operator will reproduce the error.
Expected behavior
SDL to work properly for DDL
Provide the database you are using
PostgreSQL v16 LTS
Additional context
I've run this problem through Claude and it's suggested solution goes like this:
Add pg_stat_statements to the bundled extensionScripts map with a minimal script
declaring the pg_stat_statements view (a superset column list across extension versions
is sufficient for DDL semantic analysis), like the existing bundles for
citext/hstore/pg_trgm/vector. pg_stat_kcache and pg_auth_mon (also installed by Spilo
by default) may deserve the same treatment.
Activity
zchpeter commentedon Sep 3, 2026
Hi @chriskovaios , thanks for flagging this issue, we have filed an internal ticket BYT-10142.