Forum Index > Suggestion Box > Suggestion for reducing server load.
Page 1
Author
Thread Post
Krazykat1980
Level 21
Joined: 2/13/2013
Threads: 1
Posts: 3
Posted: 12/9/2015 at 8:17 AM
Post #1
Add Last Modified Date and etags to pet image headers (and allow if-modified-since and if-none-match requests).
Then the whole file will only get downloaded if it's actually been changed (and if it hasn't been changed you'll only send a 304 not modified instead of the whole file).
The pet image urls look like:
image_builder_pet.php?species=sylvorpa&breed=sylesti
A lot of caches won't store files with '?' in the url, regardless of max-age... and, if you're generating each pet image every time it's viewed instead of once when the pet is created (that's what it looks like you're doing), that uses a lot of server resources...
Also, Vary: User-Agent can cause cache inefficiency. (Does the image actually look different if you're using Chrome instead of Firefox? That's not only on the pet images but also on the logout button image among others.)
Does the logout button image change often enough to warrant a max age of only 7 days especially since the pet images have a max age of 14 days and they're more likely to change? Although you at least have that set to accept if-modified-since and if-none-match, but if the image isn't likely to change that's still unnecessary traffic. That image last changed 2 years 101 days ago.
For cpu and ram usage, look at your keep-alive settings (I don't remember which way it goes, but using keep-alive raises one and lowers the other). Also, Max=500 seems a bit high. (Although I'm iffy on this part - keep-alive is managing to majorly confuse me).
Confirm Action
Are you sure you wish to delete this post?
Confirm Action
Are you sure you wish to restore this post?
Confirm Action
Are you sure you wish to report this post?
Go to Top
This Page loaded in 0.007 seconds.
Terms of Service | Privacy Policy | Contact Us | Credits | Job Opportunities