caching

Is something wrong with the dynamic keyword in C# 4.0 ?

There is some strange behavior with the C# 4.0 dynamic usage: using System; class Program { public void Baz() { Console.WriteLine("Baz1"); } static void CallBaz(dynamic x) { x.Baz(); } static void Main(string[] args) { dynamic a = new Program(); dynamic b = new { Baz = new Action(() => Console.WriteLine("Baz2")) }; ...

When is OpenAFS cache cleared?

Let's say I have a bunch of users who all access the same set of files, that have permission system:anyuser. User1 logs in and accesses some files, and then logs out. When User2 logs in and tries to access the same files, will the cache serve the files, or will it be cleared between users? Thanks in advance. ...

How do I read the cache of Chrome and Firefox programmatically on the Mac?

Background I want to access the cache of Chrome and Firefox in my Cocoa application. I need to get the HTML for pages accessed recently. Safari is a piece of cake - all this information is available in SQLite data stores, but not so in Chrome and Firefox. The Problem For Firefox, the cache is in /Library/Caches/Firefox/Profiles/xxx.de...

cache - flush and invaildate operation

I have some questions on Cache synchronization operations. Invalidate - before cpu tries to read a portion of memory updated by a device, the corresponding memory needs to be invalidated. Flush - Before the device read a portion of memory updated by CPU, CPU must flush(write back is also correct? ) the contents from cache to memory. ...

Cache problems when updating an object from another model

I have a problem with making changes to an object from within another model as well as within the object's model. I have the following models: class Foo < ActiveRecord::Base has_many :bars def do_something self.value -= 1 # Complicated code doing other things to this Foo bars[0].do_other save! end end class Bar...

wanting a good memory + disk caching solution

I'm currently storing generated HTML pages in a memcached in-memory cache. This works great, however I am wanting to increase the storage capacity of the cache beyond available memory. What I would really like is: memcached semantics (i.e. not reliable, just a cache) memcached api preferred (but not required) large in-memory first leve...

Selected event not raised for ObjectDatasource when enable-caching is true

I've a Gridview control using an ODS(ObjectDataSource) to fetch data. For the best performance and efficiency, I've turned-off the view state of Gridview (i.e. EnableViewstate = "false". And I've also enabled caching in the associated Objectdatasource. This eliminates as much as 50-60% performance optimization because it eliminates the ...

How to perform caching in MVC.

Hi, I want to perform caching of data for 1 day. In my MVC model I am getting the data from the database and the using it on my View. I want to add the data in cache if not there.If it is already in cache then getting the result directly form there. In my model I have a function result() in that I have used caching as if (HttpContext....

Disabling price cache in UberCart?

How do you disable the caching of selling price in UberCart? ...

Are ASP.NET Cache values scoped equally or more narrowly than a static variable?

In order to synchronise access to a Dictionary object in the ASP.NET cache, it is recommended that a synchroniser object be used. Dino Esposito recommends a static variable as the target for locking (See http://www.drdobbs.com/cpp/184406369). However, this will only work if the ASP.NET Cache values have the same scope (or narrower scope...

An efficient cache in Delphi

I'm creating a cache which is going to contain records in Delphi 2007. Each record contains a String, 2 Dates and a value. Type MyRecord = Record Location : String; Date1 : TDateTime; Date2 : TDateTime; Value : Double; End; There are no guarantees on what the maximum size of the cache will be. It is highly likely tha...

Forcing cache expiration from a JavaScript file

I have an old version of a JS file cached on users' browsers, with expiration set to 10 years (since then, I have learned how to set expires headers correctly on my web server). I have made updates to the JS file, and I want my users to benefit from them. Is there any way my web server can force users' browsers to clear the cache for t...

rails will_paginate and sorting with page caching

Hi! I have a website where in the category 'show' action a list of products is shown. I successfully paginate with the will_paginate plugin and made this work with page caching by configuring my routes like Sean Behan does: http://seanbehan.com/ruby-on-rails/how-to-use-pretty-urls-with-rails-will_paginate-plugin/. But I would love to ...

Cakephp cache only caching one file per action

Hi, I have a songs controller. Within the songs controller i have a 'view' action which get's passed an id, eg /songs/view/1 /songs/view/5 /songs/view/500 When a user visits /songs/view/1, the file is cached correctly and saved as 'songs_view_1.php' Now for the problem, when a user hit's a different song, eg /songs/view/2, the 'so...

Need a cache which is shared between C++, Java and .Net Applications

Is there a caching solution which works with C++, .Net and Java all accessing and populating same data in cache? (Data is composed of simple strings only) Longer version: I have 4 applications which work on different areas of a problem. Two of them are developed in C++, one is a java desktop application, and another is a C# application...

Is file_get_contents slower than include?

have a file caching system for a php 5 library i use often. when the request is made i check for a cached file, if there is one i render it and exit. $contents = file_get_contents( self::_cacheFile() ); echo $contents; exit(); i have to do file_get_contents instead of just include because of cached xml files with the pesky `<?x...

How to Cache Elements in iPhone

Hello iPhone Gurus, I wrote a RSS based application that will fetch some XML files, parse them and throw them into a table view. I'm using the NSURLConnection and the NSXMLParser in order to connect and parse the XML content. I would like to cache those results so that once the user connected once to the application he could disconnec...

Thread-safe cache libraries for .NET

Background: I maintain several Winforms apps and class libraries that either could or already do benefit from caching. I'm also aware of the Caching Application Block and the System.Web.Caching namespace (which, from what I've gathered, is perfectly OK to use outside ASP.NET). I've found that, although both of the above classes are te...

Maximum length of cache keys in HttpRuntime.Cache object?

We are using HttpRuntime.Cache API in an ASP.NET to cache data retrieved from a database. For this particular application, our database queries feature a LOT of parameters, so our cache keys look something like this: table=table1;param1=somevalue1;param2=somevalue2;param3=somevalue3;param4=somevalue4;param5=somevalue5;param6=someval...

Does running IIS7 in classic mode affect MVC output caching?

I have a need to run an application in classic mode for backwards compatibility with a specific application, and am trying to understand what kind of impact that will have on the performance of an MVC application that is running on the site. If we put a few static file maps (for .js, .css, .png, etc) above the ASP.NET wildcard map to re...