Questions regarding cache algorithms by applications and implementations of information caching by database engines and other information repository and presentation applications.

learn more… | top users | synonyms (1)

1
vote
1answer
1k views

Caching Business Objects in MVC application

I figured this was more of an architectural question, so I chose to post it here rather than Stack Overflow. So I'm building an MVC web application and have just finished writing the code that wraps ...
1
vote
0answers
48 views

Difference between application cache and object cache

I'm reading Martin L. Abbott, Michael T. Fisher's Scalability rules: 50 principles for scaling Web sites, and in rules 24 and 25 they talk about Application Caches and Object Caches respectively. My ...
1
vote
0answers
99 views

Saving and retrieving multiple cached json/txt data files

I am working on some numerical programming and need to generate the results for a model given a variety of input parameters. Since the model takes a while to run, I was planning to save the data to ...
1
vote
0answers
94 views

Using a distributed system as an alternative to disk storage

So, one of the differences between "main memory" and disk storage is durability -- the data on hard disks will stay accessible and unaffected even if the host machine crashes or loses power. One can ...
1
vote
1answer
79 views

Cache policy categorization

From what I search online, there are 2 most common policies used in cache access: Cache aside Read through + Write through But there are some other policies like: For write hit case: Write ...
1
vote
0answers
119 views

Why does the EF query plan cache eviction algorithm reduce the cache to its cleanup trigger size, causing a perpetual cleanup?

The cache eviction algorithm for query plan caching in Entity Framework is described in section 3.2.2 as this: Once the cache contains a set number of entries (800), we start a timer that ...
1
vote
1answer
156 views

Running an algorithm against a large dataset

We have a python application which does a DFS search against data in a database. Right now, that data is small so I can hold everything in a python container but the data is going to grow and there ...
1
vote
0answers
47 views

efficient caching with complex user rights

I am currently learning about memcached/redis, and I am trying to figure out how could I use this kind of technology at work. Now I understand that you should mostly cache data which is common to ...
1
vote
2answers
97 views

What to call objects that may delete cached data to meet memory constraints?

I'm developing some cross-platform software which is intended to run on mobile devices. Both iOS and Android provide low memory warnings. I plan to make a wrapper class that will free cached resources ...
1
vote
0answers
68 views

Built-in Context-and-Input-to-Output-Hashing in Compilers

Why doesn't (open source) compilers contain builtin funtionality for (shared) caching and reuse-fetching (using SHA1-hash of compiler-version, build-flags, target-platform and inputs) of executable ...
1
vote
1answer
226 views

Is using dynamically generated code as cache a good idea?

I have a web search interface that can compare products in a table. This data set changes a few times a week. I have been storing a "DISTINCT" list (used for parametric selection) in a cache table. ...
0
votes
2answers
222 views

Image caching when rendering the same images on different pages [closed]

I'm told to think about caching of images that will be displayed on the page. The images will be repeated throughout the website on different pages and I'm told to figure out the best way to cache ...
0
votes
1answer
145 views

Why are the test values the same for FIFO and LRU? [closed]

I had a computer science assignment where we compared FIFO, LRU and random policy for a cache memory. FIFO and LRU were equally good as improvements to a random policy. Why? Is it just a coincidence? ...
0
votes
2answers
490 views

Intel Nehalem/SB/IB/Haswell CPUs, cache vs TLB

On the Nehalem+ architecture Intel CPUs what is the interaction between the L1 cache, L2 cache, L1 DTLB and L2 DTLB? On all the images I have found there isnt a clear explanation whether the CPU looks ...
0
votes
1answer
448 views

Python - Cache function and decorator

I am playing with cache functions using decorators. First, I use a generic function def memorize(func): cache = {} print "printing cache" print cache print "cache printed" ...
0
votes
1answer
200 views

Can I use a timestamp parameter for cache invalidation?

I am considering a scheme for passing a timestamp value in a cached response, and then sending it back to the service to perform cache invalidation. I'm wondering if that's a valid approach. Is that a ...
0
votes
1answer
487 views

Improving performance with caching of files in C# [closed]

EDIT: You were right, the problem is not checking if a file with the same name exists but the connection. I made a mistake measuring the time with StopWatch and included a part which used the network ...
0
votes
1answer
98 views

Redis for caching

I've heard a lot of positive about Redis but have not used it myself. Now I want to add a cache layer for my web app to reduce the DB load, and I suppose Redis is fine for this. But I don't clearly ...
0
votes
2answers
589 views

Pattern for caching DAOs: strategy or decorator?

I'm building a php system with the Services/DAOs/Domain Models pattern, and now is the time to implement a caching system for the DAOs. Would you use a decorator pattern, or maybe the strategy ...
0
votes
1answer
256 views

design for buffering or queuing data streams to replace database

We have a system (ms stack, .net, sql) that receives data from thousands of remote devices (several independent readings/min). We currently save all the data to a db as it arrives and a second service ...
0
votes
1answer
308 views

Are there any concerns with using a static read-only unit of work so that it behaves like a cache?

Related question: How do I cache data that rarely changes? I'm making an ASP.NET MVC4 application. On every request the security details about the user will need to be checked with the area/...
0
votes
2answers
1k views

Idea to develop a caching server between IIS and SQL Server

I work on a few high traffic websites that all share the same database and that are all heavily database driven. Our SQL server is max-ed out and, although we have already implemented many changes ...
0
votes
2answers
1k views

Syncing objects to a remote server, and caching on local storage

What's the best method of sycing objects (as JSON) to a remote server, with local caching? I have some objects that will pretty much just be plain-text with some extra meta-data. I was thinking of ...
0
votes
1answer
135 views

Optimizing and caching frequently accessed but rarely updated Tables

My app has some tables that will be rarely updated, probably just once in the beginning and at the system setup. Despite that, they will be frequently accessed. Almost every operation depends on ...
0
votes
3answers
561 views

Best practices for caching search queries

I am trying to improve performance of my ASP.net Web Api by adding a data cache but I am not sure how exactly to go about it as it seems to be more complex than most caching scenarios. An example is I ...
0
votes
1answer
86 views

Mail Server Caching

I'm currently working on a web mail client. When a user logs in, I'm fetching all the mails from the INBOX from the beginning of time. As expected this is pretty darn slow. I'm planning to implement ...
0
votes
1answer
182 views

Running entire frontend of a system on a flatfile cache

I'm in the middle of moving away from PyroCMS to a custom solution built on Laravel. Wont go into the details as to why here, but it is a necessity. I'm toying with the idea of caching things like ...
0
votes
2answers
840 views

How to store cache?

The data in my website is stored in many different tables(friends,relatives,etc) and every-time I have to query each and every table. But all this data is subject centric. E.g. data for a person is of ...
0
votes
1answer
23 views

Request Caching for Symfony 3 application with > 1 million combination of query parameters

We have a REST Webservice build with Symfony3 and PHP7. The application is served via Nginx and PHP-FPM. The Webservice returns a list of products. Products inside the list are filtered by attributes....
0
votes
1answer
63 views

Cache invalidation on multiple servers

I have 6 web servers which are giving me problems due to cache inconsistency. I am thinking of building a cache invalidation service such that there is a topic on which all the servers can publish a ...
0
votes
0answers
52 views

Clearing Laravel cache on REST web service and front-end

Our REST web service and front-end are both on the Laravel Framework. The REST service and the front-end share a memcached server. The endpoint response and the data received on the front-end are ...
0
votes
0answers
67 views

What is the design pattern name for a class that handles 2nd level caching? [duplicate]

I have a system where I want to start introducing some 2nd level caching. I want to abstract data access a bit and allow some type of other class to do the dirty work of fetching a DTO; it will check ...
0
votes
0answers
34 views

Cache Memory Vs Main Memory [duplicate]

Why is the access time of the cache memory lesser than the access time of the main memory? I have tried looking at the sites as - tutorialspoint.com, education-portal.com etc. I know that the ...
0
votes
0answers
1k views

Understand how the TLB (Translation Lookaside buffer) works and interacts with pagetable and addresses

So I am trying to understand this TLB (Translation Lookaside Buffer). But I am having a hard time grasping it. in context of having two streams of addresses, tlb and pagetable. I don't understand ...
0
votes
3answers
545 views

How do I handle 3rd party search result data (via cache)

I have a search function on my site and it is taking data from 6 different 3rd party resources. The problem is, it takes too long requesting the data over and over again on the results page. I've ...
0
votes
3answers
459 views

Forcing Cache Refresh

I'm updating an existing tomcat web application to read certain resources from a REST API. Currently the application reads them from flat files. Since the application is very critical, I added a ...
-4
votes
2answers
54 views

Cache repository violating the SRP [closed]

interface IRepository { Data getData(); } class BaseRepository implements IRepository { public Data getData() { ... } } class CacheRepository implements IRepository { private final ...