Hi Support Team,
My requirement is to generate a Report request with 100 evaluation Ids each. Report request is submitted to generate 100 Reports in PDF format or Word Format. Most of the Reports generated are about 1000 to 1300 pages each.
I have implemented ProofOfConcept on DistributedCache feature on Report data output stream for generating the Report and I was able to achieve the result. I have used this DistributedCache mechanisim to improve performance i.e. to avoid re-processing of the same Report data again when there is no change in the Report data for a certain period of time.
Also, I did test behavior of AbsoluteExpiration vs SlidingExpiration in DistributedCacheEntryOptions. I am planning to use AbsoluteExpiration option.
var cacheEntryOptions = new DistributedCacheEntryOptions
{
//AbsoluteExpiration = DateTime.Now.AddMinutes(60), //AbsoluteExpirationRelativeToNow = TimeSpan.FromMinutes(60) SlidingExpiration = TimeSpan.FromMinutes(60)
};
Deployed the DistributedCache feature ProofOfConcept code to AppService in Azure cloud DEV environment. Below are the stats:
PDF Report:
Reportrequest submitted first time with 100 evaluation Ids in Pdf format - 100 reports processing - it takes around 28 mins.
When the Report request is again submitted with same 100 evaluation Ids in Pdf format - same 100 reports are served from Cache - it takes around 12 mins.
Word Report:
Reportrequest submitted first time with 100 evaluation Ids in Word format - 100 reports processing- it takes around 14 mins.
When the Report request is again submitted with same 100 evaluation Ids in Word format - same 100 reports are served from Cache - it takes around 1 Minute..
I was reading about Distributed Cache. 
Refer the screenshot above. I was analyzing on the below use case scenarios, Need inputs and best approach to avoid any memory leak issues in the Azure environment using DistributedCache?
Example:
ReportRequest1 : generate Report request with evaluationids 1-100
ReportRequest2 : generate Report request with evaluationids 101-200
ReportRequest3 : generate Report request with evaluationids 201-300
ReportRequest4 : generate Report request with evaluationids 301-400
ReportRequest5 : generate Report request with evaluationids 401-500
ReportRequest6 : generate Report request with evaluationids 501-600
ReportRequest7 : generate Report request with evaluationids 601-700
ReportRequest8 : generate Report request with evaluationids 701-800
ReportRequest9 : generate Report request with evaluationids 801-900
ReportRequest10 : generate Report request with evaluationids 901-1000
If we do all above Report requests in span of 60 mins time, This will end up storing 1000 Reports data in the cache store.
Need inputs and best approach to handle to avoid any memory leak issues in the Azure AppService by using DistributedCache?
Thank you
Vam