I have 6 web servers which are giving me problems due to cache inconsistency. I am thinking of building a cache invalidation service such that there is a topic on which all the servers can publish a message to invalidate an object. I am considering using the Amazon SNS for the making the topic.
Now for the servers to receive the invalidation messages, I am confused between the following:
- Should I be using the SQS queues for the servers to receive messages.
- Should I be using HTTP endpoints and then build an api on that route that invalidates the cache. Could you please highlight the pros and cons of both of these approaches or any other approach that might benefit me.