Invision Community 4: SEO, prepare for v5 and dormant account notifications By Matt Monday at 02:04 PM
Martin A. Posted April 8, 2019 Posted April 8, 2019 Hi, Just discovered that there is a call in IPS\cms\modules\front\database\records::manage.php(237) where you fetch the record image in order to get the image dimensions, This method call alone wastes more than 500ms on every article request that have a record image, which is all of them. We went from ~1.2s to ~550ms by removing this. We're storing our images in an S3 bucket, with CloudFlare as a CDN layer on top of that. getImageDimensions() ignores the CDN layer, and goes straight to the source, and that can cause an issue when the distance between the web server and S3 is far. Even the fact that the server needs to make an external request is enough to cause a noticeable delay. Since the image dimension is unlikely to change all the time, can't we store this information in the records table? AWS S3 users will have to pay extra for this too, as their CDN doesn't absorb these requests.
Recommended Posts
Archived
This topic is now archived and is closed to further replies.