Caching / Global Assembly Cache?

R

Rob Meade

Hi all,

I put a small site together recently using asp.net - having attended a MS
..Net course a little while back we were told that the first time a .net
application is run it'll take a little longer than usual - which I have
noticed to be the case - thats fine - after that it always seems as I'd
expect - however, whilst playing recently I noticed that if I browsed to the
site for the first time the following day it would also take a little longer
than you'd expect - no where near as long as the first time since being
built, but still a few seconds....it seems now that it doesn't just have to
be the following day, indeed a return within an hour or so would give the
same results.

I mentioned this in passing to a colleague who suggested that it would be no
longer stored in the Global Assembly Cache, if this is the case, what can I
do to make this 'not overly popular' website load quickly each time...my
concern is that until the clients business grows their website may not
indeed be that popular, thus it could well be just them popping by to have a
look at it (as we all do) - if so - each time they visit it'll seem unfairly
slow - my codes not that bad! :eek:)

Any help or information regarding this would be appreciated,

Kind regards

Rob
 
P

Patrice

IMO rather in relation with starting the application. You could see if you
does elengthy things when starting or to change the session timeout to try
to run abit longer...

Patrice
 
M

Marina

The issue is that asp.net apps shut down after being idle for some time.
When a request comes in, the app restarts - hence the delay. The idle
timeout can be set in machine.config.
 
R

Rob Meade

Thanks both of you for your replies, I assume you are both talking about the
session timeout at this point...

If so...its currently set to 20 minutes, I had *assumed* that this was only
relevant when setting session variables though - something that I do not use
in this application.

I have about 5 user controls which build up the page.

About 10 functions in total perhaps, one works out what page the user is on,
one display and image based on that, one changes hex to dec for colour codes
(see my other thread entitled - Setting table cell colors) - the others are
primarily for building tables dynamically.

Some add rows, some add cells...thats about it....

hmm....still a bit unsure what might be causing it now....its currently
still in 'debug' mode - I've not done a 'release' mode version yet - could
that be anything to do with it?

Thanks again for any help.

Regards

Rob
 
B

bruce barker

when you first hit an asp.net site, loads a new appdomain, then loads the
asp.net dll for that page (one per page). if the dll does not exist it
compiles it first.

if site has had no activity for a given amount of time (idle - see
machine.config), the app domain is unloaded, and the next hit causes the
above to repeat.

-- bruce (sqlwork.com)
 
P

Patrice

AFAIK, in ASP classic, the application shutdown when the last session
terminates (and the last session terminates once the timeout is reached
without any request from the user). Check also Marina adivces as ASP.NET
could perhaps provides another setting that make the application still waits
an aditional amount of time before shuting down...

Note also that the application is also restarted when the application is
updated...

I'm not sure how the user contrrols are related to this. Are you talking
about the same problm ? If a separate problem you may want to open another
discussion thread...

Patrice
 
M

Marina

No, nothing to do with sessions. This is a timeout on the asp applications -
the amount of time no one makes any requests.
 
J

John Timney \(Microsoft MVP\)

The idleTimeout setting in the processModel section within machine config
controls the time an application will wait with no requests before releasing
its resources back to the system. The default is infinite, so it should not
recycle unless this default setting for the server has been changed.

If your getting strange behaviour, an easy workaround is to create a very
small windows service that polls the asp.net application every couple of
minutes for a pointless web request, thus acting as a keepalive.

--
Regards

John Timney
Microsoft Regional Director
Microsoft MVP
 
R

Rob Meade

This is the row I believe you have all mentioned (thanks by the way)..

<processModel enable="true" timeout="Infinite" idleTimeout="Infinite"
shutdownTimeout="0:00:05" requestLimit="Infinite" requestQueueLimit="5000"
restartQueueLimit="10" memoryLimit="60" webGarden="false"
cpuMask="0xffffffff" userName="machine" password="AutoGenerate"
logLevel="Errors" clientConnectedCheck="0:00:05"
comAuthenticationLevel="Connect" comImpersonationLevel="Impersonate"
responseDeadlockInterval="00:03:00" maxWorkerThreads="20"
maxIoThreads="20"/>


I would certainly not have edited this by hand, is there anyway to have
changed it using a GUI? Does the above look like the norm?

Thanks again for further help

Regards

Rob
 
P

Patrice

Marina,

I'm a bit confused by this value.

How does it behave compared with the session timeout ? Does it restart using
this value (shutdown possibly session even if the session timeout value is
greater) or is this some additional amount of time ?

I suppose ASP.NET still ends the app when there is no more sessions (even
when this value is infinite) ???

Thanks in advance for any pointers (so far the doc I've saw is not crystal
clear)

Patrice
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,581
Members
45,057
Latest member
KetoBeezACVGummies

Latest Threads

Top