IIS Recycle Vs ASP Cache

Nov 15, 2010

does scheduled recycling an application pool affects HttpContext.Application / Cache? I can't find reference for that.I guess yes, as it causes worker process to restart, I want to make sure. I'm talking about iis 6.0 (w3wp.exe).

View 3 Replies


Similar Messages:

C# - Implement System.Web.Caching.Cache Object In A Controller To Cache Specific Query?

Mar 29, 2010

Is it correct to implement my caching object like this in my controller :

[code]....

And I Use it like this :

[code]....

View 1 Replies

Recycle Web Application In Production Server?

Sep 1, 2010

I have made changes to my global.asax file so i want to recycle my web application to make the changes work. How to safely recycle my asp.net web application in production server?

View 3 Replies

Architecture :: Cache The Full List Of Objects In Http Cache On The Service Tier And Page In Memory?

Feb 25, 2011

We have a wfc layer that wraps the business classes and database access and use a client that lives on the database layer. Amongst our group we are attempting to form standards. Some want to have the client call the web method and pass the page they are requesting and the page size. Pass that to the database and then page in SQL Server use RowNum.Some want to cache the full list of objects in http cache on the service tier and page in memory. They concern here is memory use on the server.

Which would be best for a medium number of users with potentially large number of records to manage (say 30K) Is it better to cache them all in memory and work from there or page at the database as the application scales?

View 1 Replies

New-Cache Parameters For AppFabric Cache When Storing.NET Session State

Jul 28, 2010

What are the "optimal" parameters for creating an AppFabric cache when you will be storing session state in the cache? MSDN Cache-Related Commands

Powershell command line:

New-Cache [-CacheName] <String> [-Eviction <String>] [-Expirable <String>] [-Force [<SwitchParameter>]] [-NotificationsEnabled <String>] [-Secondaries <Int32>] [-TimeToLive <Int64>]

[code]...

Since I don't want my sessions to be removed unless the session has been abandoned either via code or Session Timeout...For eviction, I would think "None" and for expireable, I would think False.I have tested and calling Session.Abandon does remove the object from the cache. I have also tested to see if by extending my session, the session object in cache is also extended. This does seem to work the "correct" way.

View 1 Replies

Data Cache Support Background Population Of Cache Entries?

Aug 1, 2010

We have a data driven ASP.NET website which has been written using the standard pattern for data caching (adapted here from MSDN):

public DataTable GetData()
{
string key = "DataTable";
object item = Cache[key] as DataTable;

[code]...

The trouble with this is that the call to GetDataFromSQL() is expensive and the use of the site is fairly high. So every five minutes, when the cache drops, the site becomes very 'sticky' while a lot of requests are waiting for the new data to be retrieved.

What we really want to happen is for the old data to remain current while new data is periodically reloaded in the background. (The fact that someone might therefore see data that is six minutes old isn't a big issue - the data isn't that time sensitive). This is something that I can write myself, but it would be useful to know if any alternative caching engines (I know names like Velocity, memcache) support this kind of scenario. Or am I missing some obvious trick with the standard ASP.NET data cache?

View 3 Replies

C# - Maximum Length Of Cache Keys In HttpRuntime.Cache Object?

Feb 24, 2010

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=somevalue6... etc...

we have so many parameters that the cache key is several hundred characters long. is there a limit to the length of these cache keys? Internally, it is using a dictionary, so theoretically the lookup time should be constant. However, I wonder if we have potential to run into some performance/memory problem.

View 1 Replies

ADO.NET :: Use HttpContext.Current.Cache (system.web) For Cache Data Something In Project

Sep 13, 2010

I have use Nhibernate in my MVC Project by me known, Nhibernate have cache on Session and Object. now, I want use HttpContext.Current.Cache (system.web) for cache data something in project. my code same that have problem, haven't it. and that's right or wrong.

View 2 Replies

Architecture :: Distributed Caching / Keeping Cache In Sync Between Multiple Webservers Or Even Better Farm Cache Management To Another Server?

Feb 26, 2010

I've got a web application that runs of a state server. It looks like soon it may need to distributed and there will be two web servers behind a load balancer.

This works great for session state but my next challenge is Cache

My application leverages heavily of cache. I understand ASP.Net 4.0 will be offering more here but nothing much has been said about the how too.

There are two challenges that I face

1). Each webserver will have its own copy of cache whereas it would be more efficient to put this to a third server the same as session state is put to state server.

2). The real challenge is keeping cache in sync if a simple dataset derived from the database is changed my code dumps that cache item and reloads the cache. That's all well on one webserver but webserver number two wont know to drop that particular cache item and reload it. This could cause some unexpected problems in the application.

For scenario number 2 I could attempt to do some smart coding so server number two knows to dump the cache and reload it.

My guess is someone else has already been here before and there's probably a better implementation approach rather than writing extra code.

Does anyone know how I could achieve the goal of keeping Cache in sync between multiple webservers or even better farm Cache management to another server?

View 2 Replies

Is Page Output Cache Stored In.NET Cache Object?

Nov 2, 2010

I need to enable caching in my asp.net application, but I do not want to use the webserver's memory for holding cache objects. If I add the page directive for output caching will the page be stored in the asp.net cache object?

View 2 Replies

C# - Application_End() Cannot Access Cache Through HttpContext.Current.Cache

Dec 12, 2010

I want to be able to maintain certain objects between application restarts.

To do that, I want to write specific cached items out to disk in Global.asax Application_End() function and re-load them back on Application_Start().

I currently have a cache helper class, which uses the following method to return the cached value:

return HttpContext.Current.Cache[key];

Problem: during Application_End(), HttpContext.Current is null since there is no web request (it's an automated cleanup procedure) - therefore, I cannot access .Cache[] to retrieve any of the items to save to disk.

Question: how can I access the cache items during Application_End()?

View 4 Replies

Log IIS Application Pool Startup / Shutdown And Recycle?

Dec 9, 2010

My application is running in a shared hosting environment. I do have a dedicated App Pool for my app. I've been doing some testing with 1st visits and precompile performance and have been tracking when my application starts up and shuts down.

In my Global.asax I have some logging code in Application_Start and Application_End. I can see from my logs generally when the application is idle and shuts down, then someone visits and it starts back up.

But, I also see cases where a shutdown is logged and then followed by another shutdown about 13 minutes later; without a startup in the middle.

I also see instances where there are two Startups in a row. I'm guessing these might be a recycle, but why wouldn't there be a shutdown log entry?

What I'd really like to know if there is a better way to track when my application starts, when it shuts down and if it is shutdown due to an idle pool, or from a recycle. I don't have access to the Windows Event Log so I need to do this from my app if possible.

View 1 Replies

Session - Why Does Application Recycle When Delete A Folder

Sep 27, 2010

I have a Silverlight application using a WCF service hosted in IIS. I make use of some aspects of ASP.NET. I have the following folder structure for my application:

inetput
wwwroot
myapp
reports
{user-guid-folders}
report1.pdf
report2.pdf
App_Data (folder)
bin (folder)
Client_Bin (folder)
(various .aspx files, plus web.config, etc.)

The application dynamically generates reports and puts them in a folder with a GUID for the name which is unique to the user. This all works fine. However, when the user logs out I was cleaning up and deleting the PDF files in their folder, then deleting their GUID folder.

Deleting the files works fine, but if I delete the folder, the application recycles (which then removes all other users' sessions - I get a Session_OnEnd event for every user's session, and an Application_OnEnd event. The next user request causes the whole application to restart. So, while I can fix this by not deleting the GUID folder (which my application itself created), what is the reason for this? Is there any way I can prevent this from happening?

View 1 Replies

Iis7 - Should Set .NET Application Pool To Auto-recycle

Mar 3, 2011

I have a number of ASP.NET (4.0) web applications that appear to leak (a small amount) of memory during each request. It is such a small amount, that for most use-cases, it will not grow to become a problem for weeks or even months at a time. I generally try to be good with closing any connections managed by the application, avoiding state-variables (or instance variables for my singleton), etc. My question is this - is this normal behavior for ASP.NET applications? I had turned off the default (IIS 7) behavior of recycling the app pool after 20 minutes of being idle. I do this since the application takes a few minutes to build its internal cache, and I want to avoid negatively impacting the user experience (and having them wait for the application to start when they issue the request).

View 1 Replies

.net - Memory Increase On Application Pool Recycle?

Dec 14, 2010

I'd like to describe strange issue I've noticed while analyzing my asp.net application in production and ask for some advice or opinion on the following matter.Application usually runs with some 80-90 MB of memory footprint. This seems stable since no memory leaks have been detected so far - no slight increase in memory usage over time. Yet, problem occurs when application pool recycles (I'm using shared hosting and judging by logs it occurs either when app is idle for 20 mins or every ~30 hours - something like that). The issue is that used memory almost doubles for some period on recycle - it goes to some 160-170 MBs without any explanation. This is confusing, since it is common claim that recycling should purge the memory and all other resources - at least I get it that way. System holds this amount of memory for some 7-8 hours and then memory usage drops to it's usual level of 90-100 MB, again, with no apparent reason (at least not know to me).

View 1 Replies

Appdomain Recycle Settings On Mod_mono & Apache?

Apr 30, 2010

How does one control the application recycle settings for an ASP.NET application runnin on mod_mono & Apache ?

On IIS6 & 7 there was an option to specify either a time period, a number of requests, etc. when the AppDomain would be recycled and the application would basically do an Application_End() / Application_Start().

I am seeing the same behaviour on mod_mono & Apache ,but I can't find where to change the settings.

View 2 Replies

Memory Limits And Application Pool Recycle?

Jun 22, 2010

my web applications app pool configuration is
PeriodicRestartMemory : 512000
PeriodicRestartPrivateMemory : 196608

although the virtual memory limit is higher than private memory, app pool is recycled with virtual memory limits exceeded errors in the event log (instead of private memory).

what is the reason for this? how could it exceed virtual memory limits before exceeding private memory limits? it seems that systems other allocations in virtual memory cause limits exceeded before applications private allocations exceed the limits, but what are those allocations of the system? or what is the root cause of this.

View 1 Replies

IIS7 ASP.NET In-proc Session NOT Being Lost After App Recycle?

Aug 23, 2010

I've got an ASP.NET MVC app running under IIS7. It's using the default in-proc session management, which, according to all that I read, should lose the users' session after an app pool recycle.It doesn't seem to be losing it though. Even an IIS reset doesn't lose the session.Has something changed in IIS7 that keeps the session alive?

View 1 Replies

DataSource Controls :: Item To Be Moved To A 'recycle Bin'?

Jun 25, 2010

I'm building a Content Management website which will also include other features. When an admin member deletes an item through the admin panel, I would like this item to be moved to a 'recycle bin' for 30 days (then automatically deleted).What is the best way of implementing this feature? One idea I had was to have a 'Deleted' bit column in my table, then only show records [Code].... However this would mean having to remember to put this condition in place everytime I [Code].... from the table.

Another Idea I had was to have a second table where the records would be moved to when deleted. However I have many tables being used in my website, so this would mean doubling the amount of tables, and having duplicate table structures (which could cause consistency issues in the future).Ideally I would like to have a 'RecycleBin' table which all the records are moved to, but this could contain 100s of columns to be able to store data from all the different tables.

View 2 Replies

Configuration :: Worker Process Recycle, Every 60 Seconds?

Jul 13, 2010

We recently had to enable Memory Recycling on a 2.0 app pool (IIS6). We checked both boxes, leaving in the default values of 500 MB for virtual memory and 192 MB for used memory. Here's where it gets interesting. Every 60 seconds, on the dot, the worker process is forced to recycle.Our tests were spamming the site with concurrent users trying to get the virtual memory up to 500MB, but we never could (as viewed in task manager). However, that didn't matter. We tested it by simply recycling the pool and hitting one page, once, and seeing around 30MB allocated and then just waiting 60 seconds and watching the process die in task manager (and a new one start up).We've increased the value for maximum virtual memory to 768MB and the issue *appears* to have gone away, but just arbitrarily accepting a fix isn't how we like to do things. I haven't found any officially reported bugs, kb articles, or solutions on blogs that point to what is causing this. To me, this means either it's some crazy environmental issue or the answer is really obvious and we just can't see it.

View 1 Replies

Is It Possible To Recycle IIS Application Pools Without Losing User Sessions

Nov 25, 2010

We're currently deploying code to live pretty reguarly at the moment, but the down side is destroying user session data.

Is there a way of being able to recycle IIS without loosing session data, or is persisiting session state in SQL server or alike the only way?

View 2 Replies

Visual Studio :: The Files Delete In The Recycle Bin That A App_offline.htm?

Mar 2, 2011

have been using the Publish Web Site option VS 2005, and all of a sudden it quick working correctly and do not get an error message. Also, compiling the web site does not take as long as it did before. Now Pubish Web site only puts the bin folder and PrecompileApp.config file in the C:InetpubwwwrootOIAEmailMaint. Because I am working and testing this website sometimes I delete any previous files that was in the folder C:InetpubwwwrootOIAEmailMaint before Publish Web Site. I did notice when I was looking at the files I delete in the Recycle Bin that a app_offline.htm. Apparently I changed some kind of option by accident by I do not have a clue what.

View 1 Replies

Cast Object Of Type' Error - Resolved By IIS Recycle?

Sep 8, 2010

3rd party ASP.Net web site and web service installed. The code appears not to log errors to server log or custom error log.

User receives the following critical untrapped error message:

"System.Web.Services.Protocols.SoapException: Unable to cast object of type 'System.Security.Principal.WindowsIdentity' to type 'Library.Security.Identity'. at ....."

Of course I understand the type cast issue but why would a IIS recycle resolve the issue?

View 1 Replies

ASMX :: WCF Service Is Not Restarting After Application Pool Recycle?

Nov 18, 2010

My WCF Service isnt restarting after the app pool recycles. I have no control over how often the pool is recycled (shared hosting) .How do I get the wcf service to restart on pool-recycle ?

View 1 Replies

Recycle Application Mod_Mono 2.8 / Getting A 404 Not Found Error Page?

Dec 14, 2010

I have a CentOS 5.x server running Mono 2.8.1 and mod_mono 2.8 with apache2.

Every time I deploy a site from visual studio 2010 to my server by ftp, and navigate to the site, I get a 404 not found error page.

Sites in other subdomains (virtual hosts) are not affected.

Performing a restart of httpd using /etc/init.d/httpd restart fixes the problem, and I can view my ASP site again. Obviously restarting the entire httpd process is less than adequate.

My guess is that this is similar to application domains in IIS. Is there a way to 'recycle' and app domain in mod_mono? Can I set this to happen on deployment?

View 2 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved