I have a WCF RESTful web service, I have implemented cache mechanism using HashTable. but the problem is it is getting flushes/count=0 automatically after 20 mins if its kept in idle state or no connection is made to it.
Can u please suggest what could be the possible solution to it
I even tried using httpruntime.cache to achieve the same and removed hashtable but the outcome was same
by some R&D i found this thing could solve the issue but it didnt
[ServiceBehavior(InstanceContextMode = InstanceContextMode.Single, ConcurrencyMode = ConcurrencyMode.Multiple)]
Sounds very much like you’re hosting in IIS and did not configure Idle Timeout settings, which means your application pool will be automatically shut down after (default) 20 minutes of idle time.