简体   繁体   中英

ShieldUI Caching application data for browser access

This is an ASP.Net MVC5 aplication.

We have a document archive for our customers. Some customers have a rather large archive, up to 15,000 documents. The data is retrieved from a web service and converted to JSON for use in our grid display.

I am using ShieldUI Grid for displaying the list of documents. I would like to somehow retrieve all their document, in the background and load the grid from that data store vs. having to load from our web service for each page.

This makes the grid much easier to filter and sort because I don't have to make a round-trip to the server for the data. Besides, the filtering only works with the current page, anyway.

The data for the customer with the largest number of documents, returned in JSON format is about 5.76MB (JSON string length approx 6,048,120 chars). Any thoughts on what to use to handle this type caching? Is 6MB too much to have the client handle the caching?

You can pre-fetch any amount of data and bind the grid to it. For example, you can assign the fetched data to a variable and bind the grid widget to it. In this example: http://demos.shieldui.com/web/grid-general/basic-usage the control is bound to a js file, but you can do the same to a local variable as well. However, please keep in mind that this may not be the best option performance-wise - if there are too many records, it may be best to use remote databinding, for example, to improve the responsiveness of the component and the application.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM