I'm using Aurora PostgreSQL on RDS for a database cluster with one writer and one reader instance.
I have large analytical queries running on the reader every few minutes only and the writer has > 500 writes per minute.
I've tested my service both with db.t4g.medium and db.t4g.large instances.
- When using
db.t4g.medium, my writer goes into the burst mode and uses it's credit balance gradually, my reader never does and builds it up to the maximum in less time than the write uses it up. - When using
db.t4g.large, both writer and reader are doing fine.
I'm wondering if I could somehow use one of two strategies to manage this more cost effectively:
- Trigger a failover each time one of the instance has more than 2x the CPU credit balance of the other.
- Set up unbalanced instances one
db.t4g.mediumand the other onedb.t4g.largeand trigger a failover if the smaller instance ever ends up being the writer for an extended period.