38,348 questions
1 vote
2 answers
2k views
Get the source image file from img tag
I have an img tag with src="www.example.com/pic1.jpeg". The image file has already loaded fully. Now I want to save the image file. I can download it by using the link in the src attribute. But I ...
6 votes
3 answers
5k views
Injecting and using Spring Security UserCache
Spring Boot here. I am implementing my own UserDetailsService impl and need to reference/use the Spring-provided UserCache: package myorg.myapp; import org.springframework.security.core.userdetails....
14 votes
2 answers
5k views
How to get functools.lru_cache to return new instances?
I use Python's lru_cache on a function which returns a mutable object, like so: import functools @functools.lru_cache() def f(): x = [0, 1, 2] # Stand-in for some long computation return x ...
0 votes
1 answer
44 views
DevExpress ASPxGridView reloads data on every group row expand - how to cache/prevent?
My DevExpress ASPxGridView reloads the entire dataset every time I expand a grouped row, causing performance issues. The LoadGeneralSearch() method fires on each expand, re-executing the SQL query. ...
1 vote
1 answer
52 views
How to prevent Azure front door caching a SPA index.html
I have an Azure front door (afd) with a route and rule set to serve a SPA, as is quite normal, I don't want the index.html cached but do want all the other files cached. I created a rule-set and rules ...
8 votes
2 answers
9k views
Recognize HTTP 304 in service worker / fetch()
I build a service worker which always responds with data from the cache and then, in the background, sends a request to the server. If the server responds with HTTP 304 - not modified everything is ...
2 votes
0 answers
395 views
Can I remove vscode's Webstorage/CacheStorage
I use vscode on Windows11. Today I found spaces of C:/ worn out. I used WizTree and found out that Code/Webstorage/xx/CacheStorage had taken ~20GB spaces. The "cache" in their name let me ...
0 votes
0 answers
21 views
Accessing fonts via etc.clientlibs have cache-control [closed]
While accessing fonts from etc.clientlibs cache-control header is added for 24 hrs in publisher, is it comes with OOTB? Please advise.
3 votes
1 answer
195 views
Why does sequential array access have a high cache miss rate?
I have the following C code that I am testing to understand perf and caching. It sequentially accesses an array of doubles. // test.c #include <stdio.h> #include <stdlib.h> #include <...
0 votes
0 answers
15 views
Swagger Caching Authentication parameters
I have an ASP.NET Core Web API. I am using Swagger, so when I run my app in debug mode, the Swagger page appears and I can test my endpoints. I also have authentication, and crucially, I'm ...
2 votes
1 answer
2k views
Mobile image cache size limitations?
Is anyone familiar with a comprehensive list of mobile devices and their browser's cache limits for images? I found one reference for iPhone: http://www.niallkennedy.com/blog/2008/02/iphone-cache-...
Advice
0 votes
1 replies
28 views
Cloudfront Cache policy headers vs Vary header
Why can we set which request headers should make up the cache key in a cloudfront distribution behaviour? If the origin responds with a Vary header, shouldn't the cache just use the headers in there ...
-4 votes
0 answers
61 views
How to get Firefox to save the images currently shown on a page [closed]
When saving a page in Firefox with Ctrl-S and choosing "Web Page, complete", it redownloads (some) images and, if they were changed in the meantime, it saves other images than the ones that ...
0 votes
1 answer
42 views
Revoking Connected Devices: How to Invalidate IMemoryCache Immediately to Prevent 2-Minute Access Window?
Hey i was building a DeviceService to know Connected Devices to an account after i builded every thing now i got issue with revoking device Main Confusion : that i decided to use IMemoryCache to ...
1 vote
3 answers
9k views
Error: Predis\Connection\ConnectionException: `SELECT` failed: ERR value is not an integer or out of range [tcp://redis:6379] in file
I have redis problem in laravel, I'm using laradock to upload my containers, but I don't know why it's not working. When I ran the command redis-server in the terminal inside the bash of redis I saw ...