The Dynamic Duo? | Scaling Postgres 419

Scaling Postgres15mMay 31, 2026
AI-Generated Summary

PostgreSQL's lack of built-in transparent data encryption (TDE) isn't due to technical inability but a long-standing community disagreement over scope and requirements—leaving users to rely on workarounds like disk encryption, cloud provider tools, or application-level encryption. This episode dives deep into practical, real-world strategies for managing data security and performance in complex Postgres environments. From using foreign tables and materialized views together to optimize analytics across heterogeneous data sources, to avoiding the catastrophic cascade caused by long-running transactions in job queues, the host highlights critical anti-patterns and solutions. The discussion also covers emerging challenges like running AI workloads directly in the database, the risks of parallel HNSW index builds in PG Vector, and the hidden dangers of locking behaviors—especially invisible deadlocks from foreign key constraints and vacuum lock conflicts. These insights reveal that Postgres’s power lies not in its defaults, but in how carefully engineers manage its trade-offs.

Key Takeaways
1

Combine foreign tables with materialized views to turn slow, remote datasets into locally indexed, high-performance analytical structures.

2

Long-running transactions in job queues can block vacuum and cause CPU saturation—use lock timeouts during migrations to prevent cascading failures.

3

PostgreSQL lacks native TDE, but encryption at rest can be achieved via file system encryption (ZFS, Ceph), cloud provider tools (AWS EBS), or application-level encryption.

4

Running LLM calls within database transactions creates 30-second bottlenecks—move AI work to the application layer to avoid transaction timeouts.

5

Use jittered retries and avoid synchronous AI calls in transactions to prevent retry storms and performance degradation.

…and 3 more takeaways available in PodZeus

Chapters
0:00
3 min

The Dynamic Duo: Foreign Tables + Materialized Views

Now we've turned a slow remote dataset into a locally optimized analytical structure.

Highlight
3:12
2 min

The Cascade of Long Transactions

The database had a snapshot as it was doing this copy, so the auto vacuum could not remove dead rows because of that current copy snapshot.

Highlight
5:04
2 min

Why PostgreSQL Lacks Transparent Data Encryption

It is possible to have encryption at rest today without adopting a proprietary fork.

Highlight
7:28
2 min

AI in the Database: Performance Pitfalls

Running LLM calls inside Postgres transactions creates 30-second external dependencies that block entire transactions—better to handle AI work in the app layer.

9:46
1 min

PG Vector 0.8.2 and the HNSW CVE

A critical CVE in PG Vector 0.8.2 affects parallel HNSW index builds—users must upgrade immediately to avoid security risks.

High-Impact Quotes
So as a quote here, now we've turned a slow remote dataset into a locally optimized analytical structure.
Host2:18
Because the database had a snapshot as it was doing this copy, so the auto vacuum could not remove dead rows because of that current copy snapshot.
Host4:23
And he says it is possible to have encryption at rest today without adopting a proprietary fork.
Host6:55
Speakers

Host

Host Name
Topics Discussed
foreign tables90%materialized views90%long-running transactions88%transparent data encryption85%PostgreSQL locking85%job queue performance82%PG Vector CVE80%application-level encryption78%
People & Brands

PostgreSQL

other

25xNeutral

PG Vector

other

4xNeutral

refent

other

2xNeutral

Apache Age

other

2xNeutral

Toast

other

2xNeutral

ZFS

other

1xNeutral

Ceph

other

1xNeutral

Snowflake

organization

1xNeutral

PGEdge

organization

1xNeutral

PGConDev2026

other

1xNeutral

Start discovering podcast insights today

Start with a 7-day trial and explore a growing catalog of popular podcasts. No credit card required.

No credit card required • 7-day trial • Cancel anytime