ASP.NET 5 System.Runtime.Caching

I am converting an existing .Net 4.5 MVC 5 project to a new ASP.NET 5 project. One of my files refers to the System.Runtime.Caching namespace, but when moving this file to a new project this namespace cannot be found.

I added System.Runtime as a dependency in the new project, but apparently this .Caching bit is missing. Has anyone experienced a similar problem?

+4
source share
2 answers

To use a namespace System.Runtime.Cachingin an ASP.NET application, you must add a namespace reference.

To add a link to the Website

  • -, .
  • .NET, System.Runtime.Caching, OK.

: https://msdn.microsoft.com/en-us/library/ff477235(v=vs.110).aspx#Anchor_2

+1

"Microsoft.Extensions.Caching.Memory", JSON.

"dependencies": {
    "Microsoft.Extensions.Caching.Memory": "1.0.0"
  }

.

https://docs.asp.net/en/latest/performance/caching/memory.html

+3

Source: https://habr.com/ru/post/1624284/


All Articles