If the purposes are to maintain caches in-sync then the easiest solution is to use a distributed cache, i.e. every cache provider except for In Memory Cache.
Generally for communicating between load-balanced servers I’d prefer to use a loosely-coupled pub/sub solution like Redis Pub/Sub or Redis Server Events which utilizes Redis Pub/Sub behind-the-scenes, although since all App Servers would need access to Redis you may as well consider using a Redis Distributed Cache in that case.
Otherwise for point-to-point communications, communicating between server-to-server is no different than client-to-server where you’d just use a Service Client to send Service requests to the other server.
I’m currently using a Redis Distributed Cache and it works well, but I wanted to improve the performance of the cache by eliminating the round-trip to Redis. Keeping the cache in-memory would be beneficial for performance in heavy cached operations, but it has the syncronization problem.
So you would suggest to have a channel dedicated to the servers, to use as a “cache sync”, that each web app subscribe at launch, right? We already have Redis Server Events working, so it would be trivial to implement.
ok so if you’re already using Redis Server Events than you can just send a message to a custom “appserver” channel (which each AppServer subscribes to) with a custom “delete cache” notification which includes a list of keys which you can then forward to your local instances Cache.RemoveAll(keys).