Install
In the App Store, choose PostgreSQL and fill in:
The first install asks you to run a short script that creates the identity PostgreSQL writes its backups with. Until you run it and click Verify, nothing is created.
Connect a service
inframan.yaml
DATABASE_URL receives a URL of the form:
Backups
- Continuous: every change is archived as it’s written, through PostgreSQL’s write-ahead log.
- Daily: a full base backup at the backup hour you chose.
- Retention: 7 days on non-production infrastructures.
- On demand: click Back up now on the Backups tab.
Restore
A restore never overwrites your database. It creates a new PostgreSQL instance on the same infrastructure, so the original stays exactly as it was until you decide what to do with it.- Open the instance and select the Backups tab.
- Choose to restore, then pick what to Recover to: a backup, or a Point in time within the retention window.
- Name the new instance and create it.
- Point your services at the new instance by changing their connection, for example
DATABASE_URL: postgres/main-restored, and deploy.
Monitoring
The instance’s Monitoring tab charts capacity, persistence, throughput, connections and resources. The Overview tab runs health checks for:- The database being down.
- Connections close to the limit.
- Transaction ID wraparound risk.
connections, cache_hit_rate, database_size, deadlocks, replication_lag and longest_transaction.
Limits
- One tier, Basic: a single PostgreSQL instance.
- On Google Cloud the database gets its own node pool, which uses Spot nodes. When a node is reclaimed, the database restarts on a new one from its persistent volume.
- Importing an existing database from a dump isn’t available on AWS.