I have a C# service which is not an ASP.NET application, but uses a singleton instance of of class HttpRuntime to cache items in its cache member. The singleton is created like this:
static private System.Web.HttpRuntime _httpRuntime = new HttpRuntime();
I want to set its maximum memory usage so I have the following in the app's confi...
I am developing a small intranet based web application. I have YSlow installed and it suggests I do several things but they don't seem relevant for me.
e.g I do not need a CDN.
My application is slow so I want to reduce the bandwidth of requests.
What rules of YSlow should I adhere to?
Are there alternative tools for smaller sites?
Wh...
I am creating a portal where many sites will run of the same MVC application. I have a list of Sites stored in the HttpRuntime.Cache. Is it wrong to access the cache via a static method? Should I instead be passing this on view data?
For example, is this wrong on the view:
<%= SiteHelper.CurrentSite %>
Where the code for SiteHelper is...
I'm trying to implement some kind of caching in a PHP script that will go out to many different clients/sites, which will be deployed by fairly non-technical users, using a variety of web hosts. Due to the non-technical nature of the users, I'd like to avoid asking them to tweak file permissions. The caching needs to be across session...
How can you use ModRewrite to check if a cache file exists, and if it does, rewrite to the cache file and otherwise rewrite to a dynamic file.
For example I have the following folder structure:
pages.php
cache/
pages/
1.html
2.html
textToo.html
etc.
How would you setup the RewriteRules for this so request can be send ...
Some time ago I wrote a little piece of code to ask about on interviews and see how people understand concepts of cache and memory:
#include "stdafx.h"
#include <stdlib.h>
#include <windows.h>
#include <iostream>
#define TOTAL 0x20000000
using namespace std;
__int64 count(int INNER, int OUTER)
{
int a = 0;
int* arr = (int*) H...
Can someone post any simple explanation of cache aware algorithms? There are lot of links available but the reading material in those sites is academic in nature and time consuming to read and comprehend.
...
I have a statistics page which has a meta refresh tag on it.
<meta http-equiv="refresh" content="10" />
How do I stop it forcing a refresh of the images in the page too? I've tried setting Cache control but the browser (IE7) still refreshes the 50+ images in the page.
Response.Cache.AppendCacheExtension("post-check=900,pre-check=3600...
what happens if an user trying to read HttpContext.Current.Cache[key] while the other one trying to remove object HttpContext.Current.Cache.Remove(key) at the same time?
Just think about hundreds of users reading from cache and trying to clean some cache objects at the same time. What happens and is it thread safe?
Is it possible to c...
What tools are available to either completely clear, or selectively remove cached information about file and directory contents?
The application that I'm developing is a specialised compression utility, and is expected to do a lot of work reading and writing files that the operating system hasn't touched recently, and whose disk blocks ...
hi,
i have two applications - one is an asp.net website and the other is a windows service.
both applications are referencing my business layer (library project), which itself is referencing my data access layer (library project) that itself uses the enterprise library data application block to receive the data form a sql server 2005 d...
I am using the Asp.net OutputCache on a page containing a usercontrol that in certain circumstances when the usercontrol is edited i want to be able to expire the page cache and reload the page with fresh data.
Is there any way i can do this from within the usercontrol?
If not, what are some other methods of caching the page that will ...
Since there is no concept of sessions in ASP.Net MVC and each request is independent of each other would I ever make use of the Cache object to internally cache data in order to minimize db access? The output caching functionality is great for caching view data but if I wanted to cache something like a user profile which should be shared...
I'm having a strange problem here...
I have an ASP.NET 3.5 application that has a GridView and a SqlDataSource on the Default.aspx. The GridView is databound to the SqlDataSource. The GridView has a button for each row called "View" that sends the user to a separate page where the row can be edited.
I have two installations of this a...
I have an HttpWebRequest that I've set the CachePolicy to CacheIfAvailable, and I've set AllowAutoRedirect to false.
Now when there is a cache hit, the HttpWebResponse.Status == NotModified, and there is no response stream. I need to know what the cached response is!
If I set the CachePolicy to BypassCache it works just fine. But I ne...
As part of a system I am working on we have put a layer of caching in a proxy which calls another system. The key to this cache is built up of the key value pairs which are used in the proxy call. So if the proxy is called with the same values the item will be retrieved from the cache rather than from the other service. This works and is...
Hi,
I have a dataset that contains around 500 records with 7 columns in each record. I would like to use objectdatasource and caching. I am sure that the data doesn't change. But there will be lots of users accessing the data. My question is whether it would be a good idea to cache the data that has 500 records. is it optimal or not? I ...
i try to put a lock to a static string object to access to cache,, the lock() block executes in my local,but whenever i deploy it to the server, it locks forever. i write every single step to event log to see the process and lock(object) just causes the deadlock on the server. The command right after lock() is never executed as the i do...
I'm building an application with multiple server involved. (4 servers where each one has a database and a webserver. 1 master database and 3 slaves + one load balancer)
There is several approach to enable caching. Right now it's fairly simple and not efficient at all.
All the caching is done on an NFS partition share between all servers...
If I plan to use data caching do I have to worry about conflicts when also using deferred loading? It seems that with linq i am losing control of my data.
...