caching

Same connection even though the ODBC data source has changed

I have a .Net service that has a list of strings containing ODBC connections and I use these in a loop to check multiple databases for tasks to process (eg. polling). However if i change where an ODBC connection points to..by changing its default database for some reason, even though i'm only storing the string name of the ODBC connecti...

EHCache + Hibernate Error: Cached Item Was Locked

I have been trying to figure out this problem for a month or so now, and it has been driving me crazy. Basically I want to keep this from happening: FINEST: Cached item was locked: com.cache.dataobject.Part.parts#0 FINE: select parts0_.mainPart_id as mainPart3_1_, parts0_.id as id1_, parts0_.id as id182_0_, parts0_.mainPart_id as mai...

Django caching for subdomains

I'm using subdomains in django for user pages via a middleware hack in a similar way to what is described here: stackoverflow.com/questions/624827/in-a-django-web-application-how-do-you-give-users-their-own-subdomain Now, I have the default django cache turned on for all pages for not-logged-in users. I had to disable the cache implicit...

Selective Cache clearing across load balanced servers (ASP.Net)

We have a website that runs on two load balanced servers. We use the ASP.Net caching to help improve performance by caching high usage data. BUT, occasionally that data changes. When it does, we need to clear the relevant cache items on BOTH the load balanced servers. Does anyone have some easy to implement suggestions for how this c...

asp.net CacheDuration Attribute and Exception scenario

I am planning on using the CacheDuration Attribute with my WebMethods. I have the webmethod code wrapped in a try/catch and the exceptions are logged to the database. after handling the exception, i return the error message in the response object (lets call it ABCResponseInfo), so the calling client can know about the error. this instanc...

Is there a good book on web application performance tuning?

I would like to read how to use caching effectively, optimize my database schema and queries, apply partitioning and load balancing. There are pretty much resources on optimizing code and low-level stuff but not the other. I've read Building Scalable Web Sites by Cal Henderson and besides a single chapter actually on scaling, which bar...

C# with ajax update panel and Cache object causing re-authentication

Hi, I have a web application that uses an update panel to display a grid of patient data. That grid is updated every 5 seconds using an asp:Timer control. For authentication I use windows with impersonate="false" (in the web.config file). Also IIS 6 has been configured with no anonymous access and windows authentication. The grid data is...

Confirming HTTP caching with Fiddler

How can I use Fiddler to confirm that HTTP caching is working? Is there another better way? ...

How do you make your Java application memory efficient?

How do you optimize the heap size usage of an application that has a lot (millions) of long-lived objects? (big cache, loading lots of records from a db) Use the right data type Avoid java.lang.String to represent other data types Avoid duplicated objects Use enums if the values are known in advance Use object pools String.intern() ...

Caching best practices

Hi, everyone. Can someone share some links on articles about back end caching and fragment caching in ASP MVC applications, best cache architectures, etc. Any useful advices also will be very appreciated. ...

how to configure memory size for asp.net inproc cache

I do not want asp.net to take decision on when the items in the cache should be invalidated, rather the business logic should trigger the cache clean up. Asp.net automatically invalidates some items from the cache when the cache usage reaches a particular threshold value (inbuilt optimization in the framework). As of now the virtual m...

How to denormalize a heavily normalized database system?

I'm looking to introduce some database denormalization to a heavily normalized system. I have a large set of databases that have evolved over ten years and are under increasing amounts of load so I'm looking to improve PERFORMANCE and possibly reduce the complexity of some queries. It is not uncommon to do 10 joins to accomplish any ...

Should we not use the System.Web.Caching.Cache class in a WinForms app?

I've seen several articles/blog posts that advocate the use of the System.Web.Caching.Cache in applications that are not for the Web, however, the MSDN documentation quite clearly states that The Cache class is not intended for use outside of ASP.NET applications. It was designed and tested for use in ASP.NET to provide caching for ...

Programmatically get the cache line size?

Just want to document the answer to this specific question... a similar question (with potential answers was asked here) All platforms welcome, please specify the platform for your answer. ...

how do i cache FileContentResult for performance?

Presently i have the following action to return files (images, PDF's, etc) from my DB: // // GET: /FileManager/GetFile/ID [OutputCache(Duration = 600, VaryByParam = "ID")] public ActionResult GetFile(int ID) { FileService svc = new FileService(new SqlFileRepository(base.ConnectionString)); KsisOnline...

Django caching - can it be done pre-emptively?

I have a Django view, which receives part of its data from an external website, which I parse using urllib2/BeautifulSoup. This operation is rather expensive so I cache it using the low-level cache API, for ~5 minutes. However, each user which accesses the site after the cached data expires will receive a significant delay of a few seco...

How can I create a hibernate collection that will be re-read every time I request it?

I have an entity that has a state table associated with it. The state table is managed by another process, and contains a list of objects that my business logic must process. I would like to get a new snapshot of the state table each time I reload the entity. How can I ensure that no part of Hibernate or its support libraries ever cac...

Possible to make Flash cache large sound assets?

I have written a game in Flash (AS3/Flex SDK/MXMLC) that streams music and sound files from my server. I'm concerned about bandwidth - the audio components are nearly 3MB, and if the game becomes popular it will really rack up the bandwidth charges. Is there any way to make Flash cache the audio components once they've been downloaded,...

.Net caching tool

Why would you use third party caching tool and which one would you rcommend for ASP.net? ...

Is passing a big structure pointer to a function cache effective?

Hello, If one has a big structure, having lot of member variables. Some function needs to access 4-5 elements in the structure for its working, so which of the below scenario could be cache effective(less cache misses)- 1.) Pass the pointer to the structure as argument to the function, Which in turn will access the needed elements.(Ass...