Cache is somewhat abstract, there are several optimizations you can do on a system that fit well into this word, such as:
- Static page cache
- Database query cache
- Service replies cache
- Opcodes cache
I think in most cases, so much concern for optimization is unnecessary, although some are part of good programming practice.
It all depends on the load on your system. If you're having performance issues (lots of bandwidth usage, processing, memory, disk space, etc.), start optimizing your system from the simplest to the most complicated ones.
There are some generic tips and easy to implement such as:
- Always watch out for the two biggest performance villains: network access and disk access.
- Some techniques such as caching static files in the client browser using headers can alleviate your problems with bandwidth usage.
- Importing common libraries of third party CDNs can also help with bandwidth (Example: link )
- Avoiding the use of
SELECT *
or adopting ARCHIVE or MEMORY tables on a MySQL-based system can expedite queries.
And so on ...