supabase / benchmarks

https://supabase.com
43 stars 2 forks source link

Postgres Benchmark #7

Open kiwicopple opened 3 years ago

kiwicopple commented 3 years ago

Chore

As part of our move from Alpha to Beta, we will want to be clear about the limitations and performance of our Postgres offering (free tier).

In this benchmark just the Postgres database.

We need to do 3 things:

kiwicopple commented 3 years ago

From Angelico:

Online resources (eg.) seem to point towards using pgbench and its resultant metric transactions per second or tps.

Should be a helpful decider between t3a.nano & t3a.micro for the DB instance

steve-chavez commented 2 years ago

Edit: As noted below the previous methodology here was wrong. This is now corrected.

pgbench tests for some of the m5a instances(tuned according to pgtune).

# steps taken from https://www.cloudbees.com/blog/tuning-postgresql-with-pgbench

createdb example
pgbench example -i -s 50 --foreign-keys

# Ran the following command 3 times on all the instance types
# This was run on a different machine with 8 cores(t3a.2xlarge)
pgbench -c 100 -j 8 -M prepared -T 30 example 
type run1 run2 run3
m5a.large 1509.766608 1685.471195 1791.559195
m5a.xlarge 3081.890468 3799.897694 3836.188151
m5a.2xlarge 4753.743995 7775.855491 7836.620631
m5a.4xlarge 5702.618662 11688.693390 11828.751758
m5a.8xlarge 5854.134383 12403.998820 12550.028498
darora commented 2 years ago

(Just a note for any observers; there are some flaws with the methodology used for the above numbers, we'll be updating them soon)