Slow Response for ASP.NET page

  • Thread starter Ramkumar T via DotNetMonster.com
  • Start date
R

Ramkumar T via DotNetMonster.com

Hi
I am experiencing performance issues with my simple web application. (which
contains pretty simple and straight forward web pages).The app's home page
takes well over 15 seconds to run under ASP.NET for the first time. Well I
agree that the initial page load takes a while becos of the JIT compilation.

However,after first load the delay goes away, but it returns after some idle
time.

Any Suggestions so as to improve the performance?

Please help!
 
M

Mark Fitzpatrick

This is exactly how it should be. After a period of idle time the web server
is recovering unused resources including the compiled ASP.Net code. This is
just part of the garbage collection and memory management of the web server
and helps to keep the web server healthy. It should take about 20 minutes
after the last page request before the web server unloads the application.

Hope this helps,
Mark Fitzpatrick
Microsoft MVP - FrontPage
 
L

Lucas Tam

This is exactly how it should be. After a period of idle time the web
server is recovering unused resources including the compiled ASP.Net
code. This is just part of the garbage collection and memory
management of the web server and helps to keep the web server healthy.
It should take about 20 minutes after the last page request before the
web server unloads the application.

Too bad the server can't keep an application alive without any hacks : (
 
B

Ben

Would you really want to run an application that isn't being used? Remeber
for a web application all static and cache items etc are retained in
physical memory. The server simply says, hey my last session has timed out,
I'm not being used, so I'll shut down for memory conservations sake. I do
think it would be cool to have a flag somewhere at the application level to
indicate that you want to keep the application running at all times.

HTH,
Ben
 
L

Lucas Tam

Would you really want to run an application that isn't being used?

Some applications are used only during business hours... or perhaps
they're low-usage. This does not mean the application is not used, just
not continiously.

Thus, when the application is uncached, the user has to wait a long
period of time to wait for the applicaiton to be started.

It would be nice if Microsoft allowed the application to remain in
memory (i.e. Force Keep Alive).
The server simply says, hey my last
session has timed out, I'm not being used, so I'll shut down for
memory conservations sake. I do think it would be cool to have a flag
somewhere at the application level to indicate that you want to keep
the application running at all times.

Why not? Memory is cheap. Hardware is cheap. And if the administrator
wants the app to stay alive, what's wrong with that?
 
B

Ben

Jim,

That's very interesting information. I didn't realize the setting was at
the application pool level. This leaves me wondering (strictly curious, I
personally never use sessions), what happens to sessions that are set to
expire after the application pool recycle time?

E.g. Session Timeout = 60 (just hypothetical) & App pool recycle = 20

20 minutes go by, the app pool is recycled, 20 more minutes go by, (we're at
40 minutes since the last request), the user sends a request. What happens
now? The application is started up? This seems to indicate that since the
application went down any session state was lost. Seems like bad things
could happen because of this.

Am I missing something? Are we supposed to configure application pool
recycling to coinside with their application session timeouts? Ouch!

Ben
 
J

JIMCO Software

Ben said:
Jim,

That's very interesting information. I didn't realize the setting
was at the application pool level. This leaves me wondering
(strictly curious, I personally never use sessions), what happens to
sessions that are set to expire after the application pool recycle
time?
E.g. Session Timeout = 60 (just hypothetical) & App pool recycle = 20

20 minutes go by, the app pool is recycled, 20 more minutes go by,
(we're at 40 minutes since the last request), the user sends a
request. What happens now? The application is started up? This
seems to indicate that since the application went down any session
state was lost. Seems like bad things could happen because of this.

Am I missing something? Are we supposed to configure application pool
recycling to coinside with their application session timeouts? Ouch!

Hi Ben,

The default (on Windows Server 2003) is a recycle after 20 minutes of
inactivity. If there are active Sessions, you don't have inactivity.

--
Jim Cheshire
JIMCO Software
http://www.jimcosoftware.com

FrontPage add-ins for FrontPage 2000 - 2003
 
B

Ben

I knew I was missing something. Thanks.

JIMCO Software said:
Hi Ben,

The default (on Windows Server 2003) is a recycle after 20 minutes of
inactivity. If there are active Sessions, you don't have inactivity.

--
Jim Cheshire
JIMCO Software
http://www.jimcosoftware.com

FrontPage add-ins for FrontPage 2000 - 2003
 

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

Top