Questions tagged [caching]

A cache is a mechanism for temporarily storing (caching) data locally in order to reduce access time to data stored far away. For CPU/disk/web browsing please use relevant tags (cpu-cache, diskcache,...)

A cache is a mechanism that involves temporarily storing data in places that are faster to access than the original storage location. can be machine code instructions, images, documents, or web pages, for example. The purpose of a cache is to reduce access time, bandwidth usage, server load, and perceived lag.

Different applications where cache mechanisms are used include:

Useful Links

35446 questions
10
votes
2 answers

IIS7 Web.Config Caching - what are the differences here, and how does it all come together?

In IIS7 I've got the ability to set caching options. These options are added to my web.config as such...
Chase Florell
  • 42,985
  • 56
  • 169
  • 364
10
votes
3 answers

ASP.Net Core 2.0 - ResponseCaching Middleware - Not Caching on Server

I want to use server-side response caching (output cache) with asp.net core 2.0 and found out about Response Caching Middleware and wanted to give it a try with a brand new asp.core mvc project. Here is the description from the link above which…
Engin
  • 355
  • 1
  • 3
  • 13
10
votes
1 answer

Trigger hard cache refresh when index.html changes in create-react-app deployment

I'm currently building and deploying my create-react-app site using "react-scripts build", and then copying the contents of the build directory to an apache web directory. The web directory contains an index.html file, which points to the compiled…
Dan
  • 1,015
  • 10
  • 20
10
votes
1 answer

Caching reverse proxy for dynamic content

I was thinking about asking on Software Recommendations, but then I've found out that it may be a too strange request and it needs some clarification first. My points are: Each response contains an etag which is a hash of the content and which is…
maaartinus
  • 40,991
  • 25
  • 130
  • 292
10
votes
3 answers

EF Core 2.0.0 Query Filter is Caching TenantId (Updated for 2.0.1+)

I'm building a multi-tenant application, and am running into difficulties with what I think is EF Core caching the tenant id across requests. The only thing that seems to help is constantly rebuilding the application as I sign in and out of…
Gup3rSuR4c
  • 8,497
  • 10
  • 59
  • 116
10
votes
0 answers

Why does calling cache take a long time on a Spark Dataset?

I'm loading large datasets and then caching them for reference throughout my code. The code looks something like this: val conversations = sqlContext.read .format("com.databricks.spark.redshift") .option("url", jdbcUrl) .option("tempdir",…
Josiah Yoder
  • 2,380
  • 4
  • 29
  • 46
10
votes
2 answers

How Force browser to reload cached static file with versioning?

After deploying a new version of a website the browser loads everything from its cache from the old webpage until a hard, force refresh is done. In ASP.NET MVC if the file becomes in Bundle, it handled by Optimization framework. a version added to…
Hamed Moghadasi
  • 1,651
  • 1
  • 14
  • 31
10
votes
6 answers

What's the difference between L1 and L2 caches in web-applications with Hibernate as ORM mechanism?

I just want some general info about standard purpose of using L1 cache and L2 cache. I'm curious because I'm investigating the system with terracotta as 2nd level cache and I've found that it also has 1st-level cache.
Roman
  • 59,060
  • 84
  • 230
  • 322
10
votes
2 answers

Multiple key pointing to single value in Redis (Cache) with java

I want to store multiple keys with single value using jedis (Redis cache) with java. I have three keys like user_1, driver_10, admin_5 and value = this is user, and I want to get value by using any one key among those three.
user3864113
  • 147
  • 1
  • 1
  • 7
10
votes
1 answer

Lighthouse & Polymer: start_url in manifest is not cached by Service Worker

I'm testing my Polymer application and I get a pretty good score on Lighthouse. However, I still have a small problem. I have a manifest.json file containing everything so the app can be added to the home screen, but Lighthouse still gives a failure…
10
votes
3 answers

How to cache images only in disk using Kingfisher?

I am using Kingfisher library for downloading and caching images. I am facing some issues in the implementation: Are the images cached in both memory and disk? Is there any provision to cache images only on disk? I have already read multiple posts…
PGDev
  • 20,976
  • 5
  • 29
  • 68
10
votes
1 answer

How To Cache Images in React?

Suppose I have a list of url's like so : [ '/images/1', '/images/2', ... ] And I want to prefetch n of those so that transitioning between images is faster. What I am doing now in componentWillMount is the following: componentWillMount() { …
Tim Roberts
  • 928
  • 2
  • 7
  • 21
10
votes
2 answers

Default browser cache expiration period for text/html

In case there's no cache expiration related headers (except Date, Last-Modified and ETag) in an HTTP response what would be the expiration period for a resource if its Content-Type is text/html? Does it depend on the browser?
axk
  • 4,947
  • 11
  • 53
  • 88
10
votes
4 answers

jQuery: setInterval

I want to make a slideshow on my site, but the problem is that the setInterval works only one time. It loads my file only one time end then stops. Heres the code: main.html