Suppose I have a WCF service that is not session or singleton based and is set up as per call. The service needs some information from a file, but this information does not change and only needs to be read once. I don’t want every call opening and reading the contents of the file for performance reasons. I would like to cache this data.
How can I make make per call instance WCF service cache this information to avoid opening and reading the file with every call?
Do I need a separate caching service/component? We are using .Net 4.
One thing I have looked at is the possibility of using the AppFabric caching service, but maybe there is something simplier.
You could use the caching that is used in ASP.NET and is also available in other .NET applications