Server Caching Is a Hard Job
In a typical SOA web application, we have a web server that gathers data from many backend services and generates HTML output for the user’s browser.
Chances are that some services are performing too slow and you are thinking about adding a caching mechanism to them. The Spring Framework has the cache abstraction out of the box and Hibernate has the second-level cache that can help you to improve the performance of services. But hold on! Caching on the service layer is not as easy as you might think. From our experience, there are two burdens that can make you regret deciding to do so.