![]() Private readonly IDistributedCache _distributedCache Otherwise generate (and cache) a new forecast: public class WeatherForecastModel : PageModel Then in the page model you can use the injected IDistributedCache instance to load the cached forecast if it exists. Then in your Program.cs, call AddAWSDynamoDBDistributedCache on the WebApplicationBuilder.Services collection, and configure it with an existing DynamoDB table to store the cached data: (options => To get started, first install the package from. Generating the forecast may be computationally expensive relative to rendering the page, so we want to cache the current forecast for 24 hours, as well as share the cached forecast across the multiple servers hosting our application. Using the Distributed Cache ProviderĬonsider a hypothetical ASP.NET Core web application that displays a local weather forecast. NET Framework applications and not with ASP.NET Core. Initially released in 2012, the session state provider library is only compatible with. ![]() NET Distributed Cache Provider for DynamoDB is the successor to the AWS DynamoDB Session State Provider. A cache can improve the performance of an application an external cache allows the data to be shared across application servers and helps to avoid cache misses when the application is restarted or redeployed. This library enables Amazon DynamoDB to be used as the storage for ASP.NET Core’s distributed cache framework. NET Distributed Cache Provider for DynamoDB. ![]() We are happy to announce the preview release of the AWS. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |