title: Can Memcached be used as second layer caching for Entity Framework 6?
body: <p>I have an application that is written in ASP.NET MVC 5. This generate lots of database transactions.</p>
  
  <p>I don't have server slave to dedicate for reporting so I need to use a second level caching in Entity framework to cache all the queries that are generated by the reports.</p>
  
  <p>The idea here is to reduce the amount of the queries that have to hit the database especially when multiple users are trying to view the same report. so if I have 5 people that want to view a dashboard, only one will hit the database and the rest will read the data set stored in the cache. This should improve the reports performance, reduce the database locks and improve my application performance.</p>
  
  <p>Is it possible to use <a href="http://memcached.org/" rel="nofollow">Memcached</a> or <a href="http://redis.io/" rel="nofollow">Redis</a> with Entity framework where the data set is cached after the query is executed for a set amount of time. And of course before the query is executed, the cache will be checked for existing dataset before a hard inquiry is executed at the server.</p>
  
  <p>I came across <a href="http://www.alachisoft.com/ncache/" rel="nofollow">NCache</a> which seems to be exactly what I am trying to accomplish but unfortunately it is pricey.</p>