0 Replies Latest reply on Feb 11, 2015 12:26 PM by npa npa

    RestEasy flush cache under a cluster of nodes.

    npa npa Newbie

      We have a restful webservice which uses RestEasy. We are using JaxRs's CacheControl to cache the response xml for a GET endpoint.

      ex: GET - https://api.apiway.com/v1/users/12345

       

      To Clear the cache, I need to hit the same endpoint but with a PUT(Instead of a GET) and the cache will be cleared for that endpoint.

      ex: PUT - https://api.apiway.com/v1/users/12345

       

       

      This works fine when I run it in my local where I only have 1 websphere instance running. But our QA environment has 2 webphere instances running behind a load balancer. So, when I call the PUT endpoint to refresh the cache, it will only clear the cache on 1 websphere instance where as the other websphere instance will send respond with outdated data.

       

      How to I use cacheControl to refresh cache from multiple instances that are behind a load balancer?