473,225 Members | 1,311 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,225 software developers and data experts.

ASP.NET application load time after some change

Hi:
We developed a set of ASP.NET Web Applications that never runs in
stand-alone mode, but always inside a portal (Rainbow Portal). All modules
are copied on that portal.
My question is: load time takes, sometimes, three or four of minutes in
a medium-level machine (a PIII 1.5 Ghz), when the binary contents are
changed, or if the time of last modification of the web.config file is
changed.
An application that runs in "stand-alone" mode take no more than a few
seconds to be loaded after this kind of change.

What determines how much time will be spended on the process of loading
a page after some change? The number of DLL's in the bin folder, the
complexity of web.config file?
Is there some possible configuration in machine.config (or even
web.config) that can increase or decrease load time?
I suppose that a DLL compiled in DEBUG mode takes more time to load than
a DLL that was compiled in release mode. But this time is not the double or
the triple of the time spended in a release DLL, is it?

Thanks for your support. I am looking at google too, but I can't find
the right words to perform the search...

--
Ravi Wallau
no****@nospam.org
Feb 10 '06 #1
4 2184
I am not an expert on calculating these things, but here are a few points to
keep in mind:

1. When the application uses multiple dll's, the server has more work to do,
therefore slightly increasing the time required
2. The server does cache some pieces of information, sometimes more
depending on the application. Therefore, this cache must be recreated if any
dll's or the web.config file is modified, increasing the time when the
application is run the first time.
3. The speed can also be affected by how much stuff is in viewstate. And
take note that if you have viewstate enabled for a large number of objects,
viewstate can become quite large after a couple postbacks of the same page.
Therefore, it is a good idea to remember to set viewstate to False for
anything reasonable, since it is set to True by default. Many controls such
as Labels or Controls who have their value set in the Load event have no
need for viewstate, when I saw the difference between my pages when I
started remembering to do this it was a big difference in efficiency.
4. Sometimes it is better not to use ASP.NET Controls. For example, if you
have an image that is "just there" and is always the same, just use a plain
HTML img tag for it, this is less code because it does not get declared as a
Control (even if you never reference a Control, Visual Studio .NET
automatically adds the declaration for WebControls, but it does not
automatically add declarations for HtmlControls), therefore creating less
work for the server.
5. Anywhere possible, use subprocedures and/or functions. Even if the
subprocedure/function is only used 2 or 3 times, it is less compiled code
because the compiler only needs to compile it once.

There may be other things you can do, but I am not sure what they might be.
Please don't be offended if I mentioned anything that sounds "common sense",
I remember how much I knew when I first started ASP.NET, and sometimes
simple things aren't simple until someone has told you about them. There are
things that I spent almost a year doing the hard way because I didn't know
there was a better way. Good Luck!
--
Nathan Sokalski
nj********@hotmail.com
http://www.nathansokalski.com/

"Ravi Ambros Wallau" <no****@nospam.com> wrote in message
news:eI**************@TK2MSFTNGP11.phx.gbl...
Hi:
We developed a set of ASP.NET Web Applications that never runs in
stand-alone mode, but always inside a portal (Rainbow Portal). All modules
are copied on that portal.
My question is: load time takes, sometimes, three or four of minutes in
a medium-level machine (a PIII 1.5 Ghz), when the binary contents are
changed, or if the time of last modification of the web.config file is
changed.
An application that runs in "stand-alone" mode take no more than a few
seconds to be loaded after this kind of change.

What determines how much time will be spended on the process of loading
a page after some change? The number of DLL's in the bin folder, the
complexity of web.config file?
Is there some possible configuration in machine.config (or even
web.config) that can increase or decrease load time?
I suppose that a DLL compiled in DEBUG mode takes more time to load
than a DLL that was compiled in release mode. But this time is not the
double or the triple of the time spended in a release DLL, is it?

Thanks for your support. I am looking at google too, but I can't find
the right words to perform the search...

--
Ravi Wallau
no****@nospam.org

Feb 11 '06 #2
Nathan:
Thanks for your response.
I believe that's the problem is the large number of DLL's that I have on
my bin folder...
There's nothing else that I can do... Probally .Net indexes all DLL's
before loading the application. Tks

"Nathan Sokalski" <nj********@hotmail.com> wrote in message
news:ea**************@TK2MSFTNGP11.phx.gbl...
I am not an expert on calculating these things, but here are a few points
to keep in mind:

1. When the application uses multiple dll's, the server has more work to
do, therefore slightly increasing the time required
2. The server does cache some pieces of information, sometimes more
depending on the application. Therefore, this cache must be recreated if
any dll's or the web.config file is modified, increasing the time when the
application is run the first time.
3. The speed can also be affected by how much stuff is in viewstate. And
take note that if you have viewstate enabled for a large number of
objects, viewstate can become quite large after a couple postbacks of the
same page. Therefore, it is a good idea to remember to set viewstate to
False for anything reasonable, since it is set to True by default. Many
controls such as Labels or Controls who have their value set in the Load
event have no need for viewstate, when I saw the difference between my
pages when I started remembering to do this it was a big difference in
efficiency.
4. Sometimes it is better not to use ASP.NET Controls. For example, if you
have an image that is "just there" and is always the same, just use a
plain HTML img tag for it, this is less code because it does not get
declared as a Control (even if you never reference a Control, Visual
Studio .NET automatically adds the declaration for WebControls, but it
does not automatically add declarations for HtmlControls), therefore
creating less work for the server.
5. Anywhere possible, use subprocedures and/or functions. Even if the
subprocedure/function is only used 2 or 3 times, it is less compiled code
because the compiler only needs to compile it once.

There may be other things you can do, but I am not sure what they might
be. Please don't be offended if I mentioned anything that sounds "common
sense", I remember how much I knew when I first started ASP.NET, and
sometimes simple things aren't simple until someone has told you about
them. There are things that I spent almost a year doing the hard way
because I didn't know there was a better way. Good Luck!
--
Nathan Sokalski
nj********@hotmail.com
http://www.nathansokalski.com/

"Ravi Ambros Wallau" <no****@nospam.com> wrote in message
news:eI**************@TK2MSFTNGP11.phx.gbl...
Hi:
We developed a set of ASP.NET Web Applications that never runs in
stand-alone mode, but always inside a portal (Rainbow Portal). All
modules are copied on that portal.
My question is: load time takes, sometimes, three or four of minutes
in a medium-level machine (a PIII 1.5 Ghz), when the binary contents are
changed, or if the time of last modification of the web.config file is
changed.
An application that runs in "stand-alone" mode take no more than a few
seconds to be loaded after this kind of change.

What determines how much time will be spended on the process of
loading a page after some change? The number of DLL's in the bin folder,
the complexity of web.config file?
Is there some possible configuration in machine.config (or even
web.config) that can increase or decrease load time?
I suppose that a DLL compiled in DEBUG mode takes more time to load
than a DLL that was compiled in release mode. But this time is not the
double or the triple of the time spended in a release DLL, is it?

Thanks for your support. I am looking at google too, but I can't find
the right words to perform the search...

--
Ravi Wallau
no****@nospam.org


Feb 14 '06 #3
I am not sure if it will actually speed up your application, but if you have
*.dll's that you rarely or never modify/replace (perhaps dll's from
third-parties, such as Oracle's database dll), you can try out a utility
called ILMerge. This utility combines multiple .NET dll's into one dll file.
I have never actually used it, because I have never had the opportunity to
write an application that uses more than one dll, but it sounds nice and for
some people quite useful. Here is the URL to download it:

http://www.microsoft.com/downloads/d...displaylang=en

I think I mentioned all my other ideas, so if your application really seems
too slow and your server is working correctly, you may want to try to work
on improving code efficiency (please don't take that as an insult, almost
any code can be improved in some way or another, even that written by the
best). Anyway, Good Luck!
--
Nathan Sokalski
nj********@hotmail.com
http://www.nathansokalski.com/

"Ravi Ambros Wallau" <no****@nospam.com> wrote in message
news:es**************@TK2MSFTNGP10.phx.gbl...
Nathan:
Thanks for your response.
I believe that's the problem is the large number of DLL's that I have
on my bin folder...
There's nothing else that I can do... Probally .Net indexes all DLL's
before loading the application. Tks

"Nathan Sokalski" <nj********@hotmail.com> wrote in message
news:ea**************@TK2MSFTNGP11.phx.gbl...
I am not an expert on calculating these things, but here are a few points
to keep in mind:

1. When the application uses multiple dll's, the server has more work to
do, therefore slightly increasing the time required
2. The server does cache some pieces of information, sometimes more
depending on the application. Therefore, this cache must be recreated if
any dll's or the web.config file is modified, increasing the time when
the application is run the first time.
3. The speed can also be affected by how much stuff is in viewstate. And
take note that if you have viewstate enabled for a large number of
objects, viewstate can become quite large after a couple postbacks of the
same page. Therefore, it is a good idea to remember to set viewstate to
False for anything reasonable, since it is set to True by default. Many
controls such as Labels or Controls who have their value set in the Load
event have no need for viewstate, when I saw the difference between my
pages when I started remembering to do this it was a big difference in
efficiency.
4. Sometimes it is better not to use ASP.NET Controls. For example, if
you have an image that is "just there" and is always the same, just use a
plain HTML img tag for it, this is less code because it does not get
declared as a Control (even if you never reference a Control, Visual
Studio .NET automatically adds the declaration for WebControls, but it
does not automatically add declarations for HtmlControls), therefore
creating less work for the server.
5. Anywhere possible, use subprocedures and/or functions. Even if the
subprocedure/function is only used 2 or 3 times, it is less compiled code
because the compiler only needs to compile it once.

There may be other things you can do, but I am not sure what they might
be. Please don't be offended if I mentioned anything that sounds "common
sense", I remember how much I knew when I first started ASP.NET, and
sometimes simple things aren't simple until someone has told you about
them. There are things that I spent almost a year doing the hard way
because I didn't know there was a better way. Good Luck!
--
Nathan Sokalski
nj********@hotmail.com
http://www.nathansokalski.com/

"Ravi Ambros Wallau" <no****@nospam.com> wrote in message
news:eI**************@TK2MSFTNGP11.phx.gbl...
Hi:
We developed a set of ASP.NET Web Applications that never runs in
stand-alone mode, but always inside a portal (Rainbow Portal). All
modules are copied on that portal.
My question is: load time takes, sometimes, three or four of minutes
in a medium-level machine (a PIII 1.5 Ghz), when the binary contents are
changed, or if the time of last modification of the web.config file is
changed.
An application that runs in "stand-alone" mode take no more than a
few seconds to be loaded after this kind of change.

What determines how much time will be spended on the process of
loading a page after some change? The number of DLL's in the bin folder,
the complexity of web.config file?
Is there some possible configuration in machine.config (or even
web.config) that can increase or decrease load time?
I suppose that a DLL compiled in DEBUG mode takes more time to load
than a DLL that was compiled in release mode. But this time is not the
double or the triple of the time spended in a release DLL, is it?

Thanks for your support. I am looking at google too, but I can't find
the right words to perform the search...

--
Ravi Wallau
no****@nospam.org



Feb 15 '06 #4
Thanks for your support, and I'm not offended... As an experienced
programmer, I know exactly what you are talking about...
I've made some testes and have some interesting results:
- After modifying web.config file, load time of first page takes about 15
seconds...
- If I only run iisreset.exe, load time is about 4 or 5 seconds...
- If I run iisreset.exe _and_ delete the contents of Temporary ASP.NET
Files, load time is about 16 seconds...

But what took my atention is that ASP.NET makes a copy of all DLL's in a
folder 770de4ce\9a480d92\assembly\dll2, each DLL with it's own directory
(and a AssemblyInfo.ini file)...
I don't know why this happens... It's not a good behavior for me, but I
think it's related with some "never stop the server" feature...
I think that create 370 directories and copy 370 files (and create 370
ini's) is a heavy thing to do...

I'll use ILMerge and test to see what happens...
Thanks!

I've note
"Nathan Sokalski" <nj********@hotmail.com> wrote in message
news:%2****************@TK2MSFTNGP12.phx.gbl...
I am not sure if it will actually speed up your application, but if you
have *.dll's that you rarely or never modify/replace (perhaps dll's from
third-parties, such as Oracle's database dll), you can try out a utility
called ILMerge. This utility combines multiple .NET dll's into one dll
file. I have never actually used it, because I have never had the
opportunity to write an application that uses more than one dll, but it
sounds nice and for some people quite useful. Here is the URL to download
it:

http://www.microsoft.com/downloads/d...displaylang=en

I think I mentioned all my other ideas, so if your application really
seems too slow and your server is working correctly, you may want to try
to work on improving code efficiency (please don't take that as an insult,
almost any code can be improved in some way or another, even that written
by the best). Anyway, Good Luck!
--
Nathan Sokalski
nj********@hotmail.com
http://www.nathansokalski.com/

"Ravi Ambros Wallau" <no****@nospam.com> wrote in message
news:es**************@TK2MSFTNGP10.phx.gbl...
Nathan:
Thanks for your response.
I believe that's the problem is the large number of DLL's that I have
on my bin folder...
There's nothing else that I can do... Probally .Net indexes all DLL's
before loading the application. Tks

"Nathan Sokalski" <nj********@hotmail.com> wrote in message
news:ea**************@TK2MSFTNGP11.phx.gbl...
I am not an expert on calculating these things, but here are a few points
to keep in mind:

1. When the application uses multiple dll's, the server has more work to
do, therefore slightly increasing the time required
2. The server does cache some pieces of information, sometimes more
depending on the application. Therefore, this cache must be recreated if
any dll's or the web.config file is modified, increasing the time when
the application is run the first time.
3. The speed can also be affected by how much stuff is in viewstate. And
take note that if you have viewstate enabled for a large number of
objects, viewstate can become quite large after a couple postbacks of
the same page. Therefore, it is a good idea to remember to set viewstate
to False for anything reasonable, since it is set to True by default.
Many controls such as Labels or Controls who have their value set in the
Load event have no need for viewstate, when I saw the difference between
my pages when I started remembering to do this it was a big difference
in efficiency.
4. Sometimes it is better not to use ASP.NET Controls. For example, if
you have an image that is "just there" and is always the same, just use
a plain HTML img tag for it, this is less code because it does not get
declared as a Control (even if you never reference a Control, Visual
Studio .NET automatically adds the declaration for WebControls, but it
does not automatically add declarations for HtmlControls), therefore
creating less work for the server.
5. Anywhere possible, use subprocedures and/or functions. Even if the
subprocedure/function is only used 2 or 3 times, it is less compiled
code because the compiler only needs to compile it once.

There may be other things you can do, but I am not sure what they might
be. Please don't be offended if I mentioned anything that sounds "common
sense", I remember how much I knew when I first started ASP.NET, and
sometimes simple things aren't simple until someone has told you about
them. There are things that I spent almost a year doing the hard way
because I didn't know there was a better way. Good Luck!
--
Nathan Sokalski
nj********@hotmail.com
http://www.nathansokalski.com/

"Ravi Ambros Wallau" <no****@nospam.com> wrote in message
news:eI**************@TK2MSFTNGP11.phx.gbl...
Hi:
We developed a set of ASP.NET Web Applications that never runs in
stand-alone mode, but always inside a portal (Rainbow Portal). All
modules are copied on that portal.
My question is: load time takes, sometimes, three or four of minutes
in a medium-level machine (a PIII 1.5 Ghz), when the binary contents
are changed, or if the time of last modification of the web.config file
is changed.
An application that runs in "stand-alone" mode take no more than a
few seconds to be loaded after this kind of change.

What determines how much time will be spended on the process of
loading a page after some change? The number of DLL's in the bin
folder, the complexity of web.config file?
Is there some possible configuration in machine.config (or even
web.config) that can increase or decrease load time?
I suppose that a DLL compiled in DEBUG mode takes more time to load
than a DLL that was compiled in release mode. But this time is not the
double or the triple of the time spended in a release DLL, is it?

Thanks for your support. I am looking at google too, but I can't
find the right words to perform the search...

--
Ravi Wallau
no****@nospam.org



Feb 15 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Sivakumar Shanmugam | last post by:
Group.. We are running on db2 UDF V8 on Sun solaris platform. I created an UDF which calles a C-routine(SQL_API_FN). This C-routine in turn calls an external C-function. The C-function is provided...
4
by: John Tyce | last post by:
The problem that I am now having, involves refreshing controls. I have allot of text boxes, several combo boxes and grids. These controls are showing live data from an Oracle database. I have dates...
1
by: Keith | last post by:
All, I have been told this is an ASP.NET issue and not an IIS issue, so I am posting this here. I have a problem with ASP.NET returning an HTTP 500 error when trying to run ASPX pages on...
5
by: Loane Sharp | last post by:
Hi there I've got a hang of a problem ... I'm running the .NET framework (2.0.40903), SQL Server 2000 and SQL Express 2005 on Windows XP Pro on a pretty good and new IBM Thinkpad X41. Some...
11
by: Jason | last post by:
Hi I have a "problem" i have got a ASP.NET application. in this application i have included logging. in the logging i have logged how many seconds it takes for this application to fully load....
7
by: ddd | last post by:
Hi, I am having problems with using the DrawToDC of the MSHTML.iHTMLElementRender in a VB.net application. For some reason I am getting a "catastrophic error". I am basing the code on c#...
5
by: Ravi Ambros Wallau | last post by:
Dear friends: This is my third question on this news in three days... Sorry for this spam behavior :-) I've a lot of problems on "first page load" after some change on web.config or even in the...
2
by: jphelan | last post by:
Ever since I successfully applied some techniques for increasing the speed of my 17 meg. Application; it has only made me hunger for more. First, let me list what I have done so far: 1. Split...
11
by: Don | last post by:
I have a WPF application in VB in VSTS 2008 RTM. I am trying to "blink" (momentarily clear) a field of data if the data is reloaded from the database to give the user some visual indication of the...
1
isladogs
by: isladogs | last post by:
The next online meeting of the Access Europe User Group will be on Wednesday 6 Dec 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, Mike...
0
by: veera ravala | last post by:
ServiceNow is a powerful cloud-based platform that offers a wide range of services to help organizations manage their workflows, operations, and IT services more efficiently. At its core, ServiceNow...
3
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 3 Jan 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). For other local times, please check World Time Buddy In...
0
by: mar23 | last post by:
Here's the situation. I have a form called frmDiceInventory with subform called subfrmDice. The subform's control source is linked to a query called qryDiceInventory. I've been trying to pick up the...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 7 Feb 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:30 (7.30PM). In this month's session, the creator of the excellent VBE...
0
by: fareedcanada | last post by:
Hello I am trying to split number on their count. suppose i have 121314151617 (12cnt) then number should be split like 12,13,14,15,16,17 and if 11314151617 (11cnt) then should be split like...
0
by: stefan129 | last post by:
Hey forum members, I'm exploring options for SSL certificates for multiple domains. Has anyone had experience with multi-domain SSL certificates? Any recommendations on reliable providers or specific...
1
by: davi5007 | last post by:
Hi, Basically, I am trying to automate a field named TraceabilityNo into a web page from an access form. I've got the serial held in the variable strSearchString. How can I get this into the...
0
by: MeoLessi9 | last post by:
I have VirtualBox installed on Windows 11 and now I would like to install Kali on a virtual machine. However, on the official website, I see two options: "Installer images" and "Virtual machines"....

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.