I did a little preliminary research today on how to measure postgres performance, including on AWS.
Postgres can be configured to log query-related data.
These logs can be exported to tools like pgbadger or hosted tools like pganalyze. Datadog seems to have some options, too.
With postgres on AWS RDS, you need to do some extra configuration.
- pganalyze AWS setup steps: https://pganalyze.com/docs/install/amazon_rds
- how to consume AWS log format with pgbadger: https://forums.aws.amazon.com/thread.jspa?threadID=145342
- AWS setup notes on SO: https://stackoverflow.com/questions/31330740/how-do-you-enable-the-logging-of-all-queries-to-postgresql-aws-rds-instance
- pgbadger howto: http://www.pateldenish.com/2015/10/pgbadger-log-analysis-for-postgres-rds-instances.html
Currently / by default, Mozilla's datadog install has instance-level data about RDS instances (machine stats like CPU or IOPS usage):
- https://app.datadoghq.com/screen/integration/aws_rds
- https://app.datadoghq.com/dash/integration/aws_rds_enhanced_metrics?live=true&page=0&is_auto=false&from_ts=1502212868530&to_ts=1502216468530&tile_size=m
- https://app.datadoghq.com/dash/270730/screenshots?live=true&page=0&is_auto=false&from_ts=1499622574171&to_ts=1502214574171&tile_size=m