I'd like to resurrect this thread in the sense that, despite my best efforts (and disabling all extensions other than those in core), my average TTFB is between 450-600ms ! I spend a day on this yesterday trying out various configuration changes - to the point of even breaking the server altogether at one stage and needing to recover from snapshot π.
My server isn't the issue. A standard HTML page renders within 200ms. I have two Flarum instances currently (a third is in the works for my Rabbit Sanctuary) - https://metabullet.com (the busiest one) and https://hostrisk.com (mostly automated, but still highly active).
At this point, I'm looking for suggestions. I run NGINX (v1.2.0 with Brotli, Opcache, etc), REDIS (via blomstra/flarum-redis
). It's not SSL/TLS, DNS, etc, as these all respond in around 20ms or less. This leads me to the Flarum front door (I have a NodeBB install I use for testing [not currently up, but can be if required] and this has a TTFB of 200ms). Whilst this isn't necessarily a show stopper in terms of TTFB, it's highly unusual for it to be at this level even with just the core extensions.
I thought perhaps it may be something in the database, although I see the same with hostrisk.com - this is a stable build from scratch (it does have a lot of extensions, but it's the same if these are all stripped back to just core). I've experienced this across three VPS providers too.