TL;DR
The PostgreSQL module outputs instance_psc_attachment for the master instance but lacks a corresponding output for read replica PSC attachments, creating an inconsistency in the module's API.
Current Behavior
The module provides:
- ✅
instance_psc_attachment - PSC attachment for master instance
- ❌ Missing PSC attachment output for read replicas
Workaround
While users can technically extract PSC attachments from the replicas output:
# Current workaround
locals {
replica_psc_attachments = [for r in module.postgresql.replicas : r.psc_service_attachment_link]
}
This approach requires users to understand the internal structure of the replicas output
Terraform Resources
Detailed design
Additional information
No response