Web Cache (DataTable)

OverView : C# WebService 3.5 이상 에서 Db DataTable Cache 화 하기

Controller.HttpContext.Cache 속성을 통해 이 클래스의 인스턴스를 가져올 수 있으며
싱글톤 HttpContext.Current.Cache를 통해 가져올 수도 있습니다.
이 클래스는 내부적으로 할당된 다른 캐싱 엔진을 사용하기 때문에 명시적으로 생성될 것으로 예상되지 않습니다.
코드를 작동시키는 가장 간단한 방법은 다음을 수행하는 것입니다.

1.Simple Source

2.HttpContext.Cache

3.DB

4.Insert Query

링크 : https://github.com/iammukeshm/RepositoryPatternWithCachingAndHangfire/blob/master/SampleCustomers.sql

5.WebService Call

6.Cache Insert

7.화면

8.Result

9.접속 화면 수가 많아지면 메모리 사용도 올라 간다. (10화면) => 접속 종류 되면 원래대로 된다.

source  : https://stackoverflow.com/questions/41684213/looking-for-a-very-simple-cache-example?utm_medium=organic&utm_source=google_rich_qa&utm_campaign=google_rich_qa