Click here to Skip to main content
15,868,141 members
Everything / Cache

Cache

cache

Great Reads

by Guirec
A pattern for an always available cache using asynchronous refresh.
by AlexCode
Handling different default AJAX caching definitions between browsers.
by Levente Kupás
If you have big reports which run slowly, you may use this T-SQL based engine to speed-up them.
by tugrulGtx
Accessing VRAM-cached nucleotide sequences in FASTA formatted files (*.fna, *.faa) by index

Latest Articles

by ToughDev
Fix high Windows memory usage caused by large metafile
by DiponRoy
How to run FTP, SFTP, SMTP, Cache, LDAP, SSO and other servers in Docker
by tugrulGtx
Direct mapped cache in front, LRU approximation behind, any LLC on back-end.
by tugrulGtx
CLOCK caching (LRU approximation) with O(1) cache hit, up to N asynchronous O(1) cache misses

All Articles

Sort by Score

Cache 

18 Apr 2013 by Guirec
A pattern for an always available cache using asynchronous refresh.
25 Jul 2011 by AlexCode
Handling different default AJAX caching definitions between browsers.
20 Jun 2013 by Levente Kupás
If you have big reports which run slowly, you may use this T-SQL based engine to speed-up them.
2 Mar 2021 by tugrulGtx
Accessing VRAM-cached nucleotide sequences in FASTA formatted files (*.fna, *.faa) by index
20 Jul 2017 by Fiyaz Hasan
This article shows you how to configure the ASP.NET Core 2.0 MVC File action result to write file to response with cache headers.
29 Sep 2021 by tugrulGtx
CLOCK caching (LRU approximation) with O(1) cache hit, up to N asynchronous O(1) cache misses
21 Apr 2013 by Markus Greuel
See how cache headers can help you to improve you page load times and how to implement them in ASP.NET Websites.
11 Oct 2013 by ASP.NET Community
CachingAuthor: Prakash Singh MehraIntroduction: It is a way to store the frequently used data into the server memory which can be retrieved very
5 Sep 2014 by OriginalGriff
No, you can't.L1, L2, L3 caches are typically inside the processor silicon in multicore processors: "normal" memory (which is what the System.Runtime.Caching namespace is concerned with) is external to the processor and is not a part of L1, L2, or L3...
5 Sep 2014 by Zoltán Zörgő
What???Do you know what CPU cache is? I doubt. At least read wikipedia: http://en.wikipedia.org/wiki/CPU_cache[^]It would be a disaster if one could modify those cache values. CPU cache and runtime cache is totally different things, on totally different level of functionality regarding...
17 Sep 2019 by Dave Kreskowiak
You want to cache 1,000,000 records on the client-side? One word: Don't. It sounds like you seriously need to re-think your design. The browser should be getting pages of data, only what the browser needs to show. Caching a million records when the client, typically, only needs to see or use a...
7 Apr 2013 by Matthew Faithfull
What you say may be completely correct but I believe the problem goes deeper than one of cache coherency. The issue I think is rather to do with the language specification and the current state of the art in optimising compilers.The C++ language specification does not, contrary to common...
7 Apr 2013 by H.Brydon
The professor was correct.The short answer to your question is that the code sequence illustrated needs to turn the operations into atomic operations which, amongst other things, will flush the cache and disable/workaround the instruction reordering as described.
6 Nov 2013 by Sergey Alexandrovich Kryukov
The data "from local disk" you mention is called Web cache. Please see: http://en.wikipedia.org/wiki/Web_cache[^].First of all, I would recommend this complete tutorial on cache control: http://www.mnot.net/cache_docs/[^].Some...
14 Jun 2016 by F-ES Sitecore
The server doesn't know when the user clears their cache so you can't react to it. You might have to do something like put a link to a handler on every page, and have it process the "If-Modified-Since" header. If that header is empty then this is the first time the user has requested the url...
24 Sep 2018 by Jeremy Hutchinson
Data driven layout in server-side Blazor
5 Nov 2019 by Kevin Mack
Hello all, It’s been a while since I did a blog post outside of the weekly updates. But I wanted to do one in terms of conversations that I’ve been having a lot lately and seems to be largely universal. High Availability.
17 Dec 2020 by IAmJoshChang
Today we are going to demonstrate how to use Top Down Dynamic Programming to solve the problem, Coin Change.
22 Mar 2011 by Wendelius
Every DBMS has a mechanism to store frequently used database pages and statements in-memory. But they do not cache results so this is usually the point why use an extra cache solution between the client application and the RDBMS. For example if contents of a web page is loaded from the DB,...
11 Apr 2011 by Henry Minute
I'm not sure this is a complete solution to your problem since you have not given enough information but have you looked at serialization?csharp-tutorial-serialize-objects-to-a-file[^].There are other serialization strategies in .Net:XML Serialization[^].General overview[^].
11 Apr 2011 by cechode
public static class FileBasedCahce { static Dictionary _FileMap; const string MAPFILENAME = "FileBasedCahceMAP.dat"; public static string DirectoryLocation = Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location); static...
12 Apr 2011 by Dave Kreskowiak
Reflector worked perfrectly fine for me after opening the System.Runtime.Caching.dll file. MemoryCache disassembles quite nicely.
12 Apr 2011 by Manfred Rudolf Bihy
Why use refractor if you can get Reflector from Red-Gate for about $35.The other thing is if your want to implement a custom cache why don't you just implement all the stuff that makes ObjectCache abstract?Another option is to use the MemoryCache type and derive from that.You could of...
12 Apr 2011 by Henry Minute
This[^] blog has an implementation that may help you. It should at least help to show the use of some of the properties/methods.
6 Oct 2011 by Not Active
A DataSet is a pretty "heavy" object and is not usually cached. Unless you have multiple DataTables within the DataSet there is no reason to use it. Creating an entity object or POCO may be a more efficient.
11 Nov 2011 by Alessandro Brito
I’m using Entity Framework 4.1 (Code-First) and SQL2008, and I have one question: Is it possible to include SqlDependency (Sytem.Runtime.Caching) to invalidate the cache when one or more tables are changing with EF 4.1??I’m trying to find any documentation about this, but I just found some...
10 Apr 2012 by Prasad_Kulkarni
Try this:
3 Jun 2012 by Ronen Rabinovitz
No need for complex settings, just create an object or a dictionary and let the helpers handle the cache.
6 Aug 2012 by Sergey Alexandrovich Kryukov
This exception is one of the easiest to nail down and fix. Almost always, it is related to unfinished recursion or mutual recursion:http://en.wikipedia.org/wiki/Recursion[^],http://en.wikipedia.org/wiki/Mutual_recursion[^].Use the debugger, put a breakpoint where the exception is thrown....
21 Aug 2012 by Sandip.Nascar
There is a way to do it automatically,In Assembly, set the version number.in code behind, get the assembly version protected string getversion() { return System.Reflection.Assembly.GetExecutingAssembly().GetName().Version.ToString(); }In...
5 Sep 2012 by Dylan Morley
What you really want to do is implement a decent paging solution. This will solve both your problems, you won't have slow binding times and you won't use lots of server memory by caching larges amounts of data.Humans can't handle 5000 records at once, it's too much information. Opinions...
22 Jul 2013 by vishnutejcj
i've resolved this by myself... window.onload = function () { if (!window.location.hash) { window.location = window.location + '#'; window.location.reload(true); } } ...
26 Nov 2013 by Binaya Acharya
I am working with winfrom application, for caching i have implemented Enterprise library caching. The definition of cache manager in app.config section is like this
31 Mar 2014 by Guruprasad.K.Basavaraju
Try Response.Redirect("View.aspx", false);I think the response.redirect ends the response. Response.End actually stops the execution of the page wherever it is using a ThreadAbortException. What happens really here is that the session token gets lost in the...
1 Jun 2014 by Peter Leow
Check these out:1. attribute-ng-app-is-not-valid-attribute.html[^]2. creating-html5-offline-web-applications-with-asp-net[^]
11 Apr 2015 by Micha C
This is about creating a single page web site using an ASP.NET Web API Service which stores the data via Cache Manager.
12 Sep 2016 by F-ES Sitecore
Assuming SessionID is the asp.net session ID, you are on the right tracks but there is a problem with your implementation. If you update the js file in the middle of someone's session then their id...
12 Sep 2016 by ZurdoDev
I do not think there is a perfect answer. We have some places where we tack on JavaScript new Date().getTime()to the end or our urls so that IE will think it is a page that has not been viewed before but we still have cache issues. It usually works but not all the time.The best option is...
31 Jul 2017 by Sharp Ninja
Caching doesn't have to be complicated.
14 Aug 2018 by Dave Ceddia
Frameworks like Vue have the notion of “computed properties” – a way to derive some new, possibly complex data based on something passed in. This post covers how to achieve the same result in React.
16 Apr 2019 by Dan Ionescu (USINESOFT)
LINQ extensions that allow to describe and to safely query cached data
17 Sep 2019 by Patrice T
Quote: What is the best method to browser cache 10 lac records from SQL database in ASP.NET? The best method is to not do it. Loading the phone directory of your country in a droplist is a bad idea. Even a rate of 1000 records per second makes it 20 minutes to load. Advice: look at web sites on...
29 Sep 2020 by OriginalGriff
No. Only the HTML is cached, it (generally) has no direct access to the data behind that. Think about it: to cache the whole site, it would need direct access to the DB server to cache a snapshot of the whole database which would be a massive...
29 Sep 2020 by OriginalGriff
This is just a guess, but ... it sounds like you are trying to use the past state of web site as a backup mechanism for a website, and that really isn't going to work. The wayback machine stores a static copy of the HTML for a site as I...
26 Jul 2010 by Gil Fink
The tip explains how to enable the local cache feature of Velocity (Microsoft Distributed Cache).
8 Nov 2010 by Martin Jarvis
How to apply output cache policies to a user control
30 Nov 2010 by Roman_wolf
Hi guys, I need your help with this scenario.In our application, we have a silverlight 4.0 xap that we use as a UserControl. This meaning, that several instances of the xap file can be hosted on the same page.When the xap is already cached, having several instances won't matter since all...
2 Dec 2010 by Roman_wolf
If anyone ever has a similar scenario, I got my answer on this threadAll it took was to enable application library caching.
28 Dec 2010 by Nguyễn Minh Phúc
Hi all,I use cache in ASPX but set expire can not excute. Pls look after:I inserted line: In code behide, in page load event: if (Cache["Test"] == null) { Cache["Test"] = 123; ...
28 Dec 2010 by Sandeep Mewara
Have a look at this part: VaryByParam="CID"Any idea what that means? Have a look at the details of Vary-by-param caching here: @ OutputCache[^]Caching Versions of a Page, Based on Parameters[^]You get back the value as 123 as caching is varied by 'CID' querystring value.More...
28 Dec 2010 by thatraja
Sandeep is right, you forgot the thing in the code. You must take a look at this article which is well written.Exploring Caching in ASP.NET[^]
11 Apr 2011 by Wendelius
Here's one possibility: Using Cache in Your WinForms Applications[^].Although the namespace is System.Web.Caching, you can use it other application types also.Of course you can also implement other kind of solutions, based on for example xml-files, data tables etc, but in the end I think...
12 Apr 2011 by apaka
I want to implement my custom cache that inherits from ObjectCache[^].Does anybody know how to do this or has source of MemoryCache because refractor doesn't show nothing. Thanks in advance.
21 Jun 2011 by My Tech World
I have a hosted a website Main associated with an app pool AppPoolMain. There is a virtual directory under this Main website named VD. VD has a separate app pool AppPoolVD.I want to write HttpCache within VD and read it from within Main and vice-versa.In other words, both VD and Main...
21 Jun 2011 by RakeshMeena
You might want to explore caching features of Windows Server AppFabric.
11 Jul 2011 by Christian Graus
One obvious benefit of a DB is that your data is not all in memory, it's on the DB server. One obvious benefit of caching data is that it's in memory already, as opposed to running SQL that needs to do joins and filtering, etc. However, in general, the benefits/costs depend on the nature of...
11 Jul 2011 by Member 8015046
What are the benefits and disadvantages to using HttpContext.Cache property. vs using a database? I had many post about database questions and such.
14 Jul 2011 by Member 8015046
HiI have a web service that puts named list of strings on to memory by using Context.Cache. I want to have the choice to save my list of strings if something goes wrong, like if the poster or the reader disconnects some how. So I am wondering if there is a way to put messages from cache and...
18 Jul 2011 by Shameel
I do not understand what you mean by HDD, does it mean storing the strings in a text file in the hard disk? If yes, SQL Server would be a far more superior, efficient and scalable option that using text files. You can write your own custom Cache class that stores its content in an SQL Server...
21 Jul 2011 by Al Moje
Hi,Your code you'd posted is incomplete. Where did you initialized the value of the following: 1. pageCount 2. PageNo 3. startPage 4. lastPage If I am not mistaken above variable was declared as public right?If I am not mistaken your application has a Master Page.If so,...
25 Jul 2011 by Al Moje
Hi,Try to modified your code as: into then in your click event: UpdatePanel1.Update();or if not work the...
23 Aug 2011 by arminamini
Hi every one.I cached my image folder in IIS(http headers).But i have 2 pics in this folder that in any time i should show one of them. and these pics are in a Gridview and i change their visible by Sqldata source.so i want 2 pics in this folder to not cached. so i dont set (Enable...
6 Oct 2011 by Patrick Skelton
Hi,I don't wish to seem that I am asking members on here to do my design work for me but I have a design-related question that I can't think how to evaluate without writing a load of code and doing some pretty detailed testing. I therefore wondered if I could run the basic idea past...
1 Nov 2011 by Fabio Di Peri
Hello to all!I need a thing that may seem strange: I need to get the url of some cached files in IE :DI've used a FileSystemWatcher to monitor the cache folder so it fires an event when certain files are created. This way I can have full file path, now I have to get their URLsBasically,...
1 Nov 2011 by Pandya Anil
you can generate URL of any file, if the file is inside your website directory (virtual directory). otherwise not,Example:My project Directory is.D:\ApplicationDir\MyWebiste1.root url is http://mywebsiteserver.com/index.aspx (the index.aspx page is inside MyWebsite1 folder, it means...
5 Nov 2011 by Fabio Di Peri
I used wininet.dll to get url of every entry in the cache and then searched for the file I was looking for
23 Nov 2011 by BVKrishna
I wanna access the users' cache information/browsing history so as to change the template fashion accordingly for the appealing effect on my website.Could you please guide me with a programmatic approach, am thinking to deploy crawlers, spiders., being a newbie in programming, i find it hard...
10 Jan 2012 by Naveen Karamchetti
The article attempts to explain when to use the value map caching pattern in BizTalk integrations
4 Feb 2012 by Adnan Masood
How to test and Ensure that AppFabric Service is up and running
26 Feb 2012 by Chi Aki
I have a custom RoleProvider and I want to remove the role cache on logout. The roles I have are "Administrator" and "Member", which are working accordingly to authorize every page/action I have in my application but when I try to change the role of the user within the same opened browser it's...
26 Feb 2012 by Chi Aki
Just resolved my problem.. I added Application_OnPostAuthenticateRequest on Global.asax.cs and assigned a new GenericPrincipal to HttpContext.Current.User. :)
23 Mar 2012 by tnitin55
HI All,I have developed a web application of around 20 pages i want to cache my my application for 15 minutes so that if user required to change there entries on any page they can change it and at the same time many user can access the application and tell me how can i use the caching for...
23 Mar 2012 by Rahul Rajat Singh
You might find this useful http://www.codeproject.com/Articles/334277/A-Beginner-s-Tutorial-on-Caching-in-ASP-NET
23 Mar 2012 by krumia
First of all, your question is not clear. What do you mean by "I want to cache my application"?1. If you mean "to cache the web pages containing forms, so your can re-submit his data", (in my opinion) it's a BAD idea. It would be a good idea if your application is stateless (i.e. given an...
10 Apr 2012 by NguyenVanDuc
Dear all, I want to turn off firefox caching, i have try : and Response.Cache.SetExpires(DateTime.UtcNow.AddMinutes(-1)) ...
10 Apr 2012 by sonu_coder
1. Opened up the FireFox browser 2. Typed about:config in the address bar 3. Typed ‘cache’ in the search bar, and looked for: network.http.use-cache. 4. Double clicked network.http.use-cache in order to set it to false. (BTW, Double clicking it again will set it to true and...
28 May 2012 by Member 8491154
I have a data set storing all continents with their respective countries. I am caching the data table:DataSet dset = new DataSet();string cacheKey = "CoverageDataTable";object cacheItem = Cache[cacheKey] as DataTable;if (cacheItem == null){ dset =...
8 Jun 2012 by thuanleminh
Hi all , how do i write an web cache program(javascript, node.js) that will be cached all websites visited ?thank !
14 Jun 2012 by TorstenH.
...I'm not familiar with the memcached - but I see connection problems there.Do you keep the connection to the server or do you make a new connection every time?
20 Jun 2012 by Alex Loddengaard
Here's some documentation with a working example. Note that you may not need to worry about authentication depending on your deployment.https://devcenter.heroku.com/articles/memcachier#java[^]
11 Jul 2012 by Member 8491154
In my project I want to implement this functionality:When a user logs out from the website and then presses the back button he does not navigate to the previous page where he was when he logged out.How do I do this?
12 Jul 2012 by Member 8491154
The solution is applicable to almost every common broewser used.Add the following script in the "" tag. window.history.forward(); function disableBackButton() { window.history.forward(); } ...
7 Aug 2012 by Member 8714829
public activityDetail instanceofActivitydetail { get; set;}and placed the following in the controller (before using the Cache class/property):Cache.CacheInstance.instanceofActivitydetail = new activityDetai();
13 Aug 2012 by Pavan Navule
Hi,I want to have application level client side caching in asp.netI have the following scenario. And doing the following currently:Works fine in my local machine.A master page and multiple content pages.In master page I have a dropdown to select States in a country.on the...
21 Aug 2012 by Tadit Dash (ତଡିତ୍ କୁମାର ଦାଶ)
Hi all,It is a very common practice for the testers while testing any issue to clear cache, temporary files, when any styling changes are updated on the website.And we can't expect the same action from the end users to see the changes.Currently we are facing this issue in our...
21 Aug 2012 by Christian Graus
If you really want end users to see the style changes quicker, change the name of the style sheet, so the browser knows it's a new one. Personally, once I release something, I expect that it works fine, and if end users look at the old style for a bit, I don't see a huge issue with...
21 Aug 2012 by Sandip.Nascar
The best technique is to use versioning to your css and js file.cheers
5 Sep 2012 by krunal25
Hello everyone,I need some kind of caching mechanism in sql or in asp.net for storing data (records) retrieved from sql stored procedure..Actual scenario :I have one stored procedure in sql which fetches 7 tables and gives the result , the result obtained is too huge i.e. around 5000...
5 Sep 2012 by Christian Amado
You will love this feature: SqlCacheDependency.http://msdn.microsoft.com/en-us/library/9dz445ks.aspx[^]Using SqlDependency for data change events[^]Hope it helps
5 Sep 2012 by Shriantlandge
You can use SQL paginiation techniq. PLease check below URL :http://shrikantlandge.blogspot.com/2009/05/pagination-with-mssql-server-2005.html[^]
24 Sep 2012 by thuanleminh
Hi,Is there any solutions for memcaching webpage with javascipt ?example : - check if webpage have never not cached : function check_cache() {} - add webpage to cache : function add_cache(){} - get from cache : function get_cache() {}my web page that i want to cached is contained...
10 Oct 2012 by reza_22
I designed admin panel and i have ckEditor that is hugely large size(think its about 500kb)then i wanted to use output cache for permanent time and i don now how to set duration permanent,this is first question and the thing is am i right to do this?is there a better way?
6 Nov 2012 by Deenuji
How to clear cache memory for login form? i created one login form but whenever i try to login i just click tat username textbox means it shows more than 20 names!!!! how to i clear that??????
6 Nov 2012 by n.podbielski
What you are describing is browser autosuggestion.Just add some guid like string to name of input tag. Browser remember forms inputs name attributes.Ofcourse you cannot use simply asp:Textbox because those have automatic names.Just copy this...
17 Mar 2013 by Coder93
I want some source for cache replacement policy such as • 1 Pseudo-LRU• 2 Random Replacement• 3 Segmented LRU• 4 Low Inter-reference Recency Set...can anyone help me?
17 Mar 2013 by Espen Harlinn
As always Google is your friend:Pseudo-LRU[^]Random Replacement[^]Segmented LRU[^]Low Inter-reference Recency Set[^]RegardsEspen Harlinn
18 Mar 2013 by greenbox64
Hi,iis 7 has output caching but i wanted to know whether it has something similar to data caching as in asp.net.Let me explain i want to store collection of values on the server. something like Cache[someCollection]The client is simple html pagesthanks
20 Mar 2013 by Stephen Hewison
Hi,I have a page which implements a cache manifest so it can be loaded offline.This page also executes a script which sends an AJAX request to the same server/domain the original page came from.On the first page the load, when loading from the server, the AJAX works as...
1 May 2013 by Advay Pandya
Hello,I am getting caching issue with the browser "Internet Explorer".My web application generates pdf files and I have a results page with links to those PDFs.If I refresh page then it deletes the old file and re-generate the new pdf file.But when I click on the link using...
22 May 2013 by Martin Stevens
HiI've got a Windows Forms Application which displays a listing of products derived from a dataset.I'm doing this without using gridviews instead all the controls (labels buttons, and panels) are generated on the fly and positioned in codeland as they are expanded or collapsed by clicking...