I have an Application which requires data from Service2, which will return the same answer for a given request, forever, unless its backing database is updated. The database is updated very rarely, let's say twice per year.
I would like to design a solution so that the Application caches the answers from Service2, but to externally provide a feature so as to invalidate the cache of Application. I thought of exposing a RESTful webservice from the Application, but I am confused on how to design it correctly.
/application/cache/invalidate
is a non RESTful URL - I was thinking about /application/cache/
to be called with HTTP POST. However, it looks to me that for a proper RESTful design, when POST is used to update a resource, the content to update should be contained in the body of the request.
What is the right way to design a "InvalidateCache" restful webservice?