473,408 Members | 1,871 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,408 software developers and data experts.

ASP.NET application and first time load

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.
i have placed these timing loggings in the Load and Init events on a typical
aspx page. i.e. first line of code in Page_Load is
DateTime dtStart = DateTime.Now;
and the last lines of code are
DateTime dtEnd = DateTime.Now;
TimeSpan timeTaken = dtStart - dtEnd;
// log result to log files;
according to my log files, for the first load, it takes 2 seconds for the
application to fully load. every subsequent access to that application takes
1 second or less to fully load. yet, when i manually count the seconds
between clicking "Go" and the time the application is fully loaded, it is
about 17 seconds.

NOTE: the above is a first time load (restarting the web server, or
restarting IIS). every load (from "Go" to "finish") after that, takes 2
seconds or less. Restarting IIS service will then mean the application will,
again, take 17 seconds to load, but only 2 of those seconds are used by the
application.

Are their events i am missing that i should be timing?
is it really IIS that is actually taking up all the time?
what can i do about this first time hit?

Thanks.
Hope i have made sense, if not, lemme know so i can clarify
Jason
Nov 19 '05 #1
11 2338
The first time lag you experience is ASP reloading the worker process for
your application. This includes any recompilations needed. This happens
outside the scopr of the application. So there is a delay, then your app
runs and logs its load time.

MattC
"Jason" <c_*******@mighty.co.za> wrote in message
news:Of*************@TK2MSFTNGP14.phx.gbl...
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.
i have placed these timing loggings in the Load and Init events on a
typical
aspx page. i.e. first line of code in Page_Load is
DateTime dtStart = DateTime.Now;
and the last lines of code are
DateTime dtEnd = DateTime.Now;
TimeSpan timeTaken = dtStart - dtEnd;
// log result to log files;
according to my log files, for the first load, it takes 2 seconds for the
application to fully load. every subsequent access to that application
takes
1 second or less to fully load. yet, when i manually count the seconds
between clicking "Go" and the time the application is fully loaded, it is
about 17 seconds.

NOTE: the above is a first time load (restarting the web server, or
restarting IIS). every load (from "Go" to "finish") after that, takes 2
seconds or less. Restarting IIS service will then mean the application
will,
again, take 17 seconds to load, but only 2 of those seconds are used by
the
application.

Are their events i am missing that i should be timing?
is it really IIS that is actually taking up all the time?
what can i do about this first time hit?

Thanks.
Hope i have made sense, if not, lemme know so i can clarify
Jason

Nov 19 '05 #2
thanks
any documentation where i can read up on these recompilations?

thanks again
any other suggestions?

"MattC" <m@m.com> wrote in message
news:uU**************@TK2MSFTNGP12.phx.gbl...
The first time lag you experience is ASP reloading the worker process for
your application. This includes any recompilations needed. This happens
outside the scopr of the application. So there is a delay, then your app
runs and logs its load time.

MattC
"Jason" <c_*******@mighty.co.za> wrote in message
news:Of*************@TK2MSFTNGP14.phx.gbl...
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.
i have placed these timing loggings in the Load and Init events on a
typical
aspx page. i.e. first line of code in Page_Load is
DateTime dtStart = DateTime.Now;
and the last lines of code are
DateTime dtEnd = DateTime.Now;
TimeSpan timeTaken = dtStart - dtEnd;
// log result to log files;
according to my log files, for the first load, it takes 2 seconds for the application to fully load. every subsequent access to that application
takes
1 second or less to fully load. yet, when i manually count the seconds
between clicking "Go" and the time the application is fully loaded, it is about 17 seconds.

NOTE: the above is a first time load (restarting the web server, or
restarting IIS). every load (from "Go" to "finish") after that, takes 2
seconds or less. Restarting IIS service will then mean the application
will,
again, take 17 seconds to load, but only 2 of those seconds are used by
the
application.

Are their events i am missing that i should be timing?
is it really IIS that is actually taking up all the time?
what can i do about this first time hit?

Thanks.
Hope i have made sense, if not, lemme know so i can clarify
Jason


Nov 19 '05 #3
Hey Jason,

The first time a ASP.NET application runs it has to compile the MSIL code
into Native code for execution and then start responding to request made by
the client (browser).
and any other request made after the first one (the one that starts the
application)
the native code is already present with the framework it need not recompile
the MSIL code to native code.
Hence, anytime you access your application for the first time it is much
slower than any subsequent access.

************************************
Hope this helps,
Shaun
http://blogs.wwwcoder.com/shaunakp
************************************

"Jason" wrote:
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.
i have placed these timing loggings in the Load and Init events on a typical
aspx page. i.e. first line of code in Page_Load is
DateTime dtStart = DateTime.Now;
and the last lines of code are
DateTime dtEnd = DateTime.Now;
TimeSpan timeTaken = dtStart - dtEnd;
// log result to log files;
according to my log files, for the first load, it takes 2 seconds for the
application to fully load. every subsequent access to that application takes
1 second or less to fully load. yet, when i manually count the seconds
between clicking "Go" and the time the application is fully loaded, it is
about 17 seconds.

NOTE: the above is a first time load (restarting the web server, or
restarting IIS). every load (from "Go" to "finish") after that, takes 2
seconds or less. Restarting IIS service will then mean the application will,
again, take 17 seconds to load, but only 2 of those seconds are used by the
application.

Are their events i am missing that i should be timing?
is it really IIS that is actually taking up all the time?
what can i do about this first time hit?

Thanks.
Hope i have made sense, if not, lemme know so i can clarify
Jason

Nov 19 '05 #4
excellent, thanks.
so not much i can do about it?
is there a website i can read regarding this?
"S h a u n" <Sh***@discussions.microsoft.com> wrote in message
news:AA**********************************@microsof t.com...
Hey Jason,

The first time a ASP.NET application runs it has to compile the MSIL code
into Native code for execution and then start responding to request made by the client (browser).
and any other request made after the first one (the one that starts the
application)
the native code is already present with the framework it need not recompile the MSIL code to native code.
Hence, anytime you access your application for the first time it is much
slower than any subsequent access.

************************************
Hope this helps,
Shaun
http://blogs.wwwcoder.com/shaunakp
************************************

"Jason" wrote:
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.
i have placed these timing loggings in the Load and Init events on a typical aspx page. i.e. first line of code in Page_Load is
DateTime dtStart = DateTime.Now;
and the last lines of code are
DateTime dtEnd = DateTime.Now;
TimeSpan timeTaken = dtStart - dtEnd;
// log result to log files;
according to my log files, for the first load, it takes 2 seconds for the application to fully load. every subsequent access to that application takes 1 second or less to fully load. yet, when i manually count the seconds
between clicking "Go" and the time the application is fully loaded, it is about 17 seconds.

NOTE: the above is a first time load (restarting the web server, or
restarting IIS). every load (from "Go" to "finish") after that, takes 2
seconds or less. Restarting IIS service will then mean the application will, again, take 17 seconds to load, but only 2 of those seconds are used by the application.

Are their events i am missing that i should be timing?
is it really IIS that is actually taking up all the time?
what can i do about this first time hit?

Thanks.
Hope i have made sense, if not, lemme know so i can clarify
Jason

Nov 19 '05 #5
Hey Jason,

As far as my understanding goes nothing can be done about it , but i fail to
see the problem since this will just happen the very first time the
application is started it wont affect much.

well dont know abt sites, but i am sure this will be documented on MSDN site
, google a bit on this, or have a look at MS Press 70-320

under the section

Chapter 1 : Understanding the .NET Framework -
Lesson 2: Understanding the Common Language
Runtime
******************************
Hope this helps,
Shaun (M.C.P)

http://blogs.wwwcoder.com/shaunakp
******************************

"Jason" wrote:
excellent, thanks.
so not much i can do about it?
is there a website i can read regarding this?
"S h a u n" <Sh***@discussions.microsoft.com> wrote in message
news:AA**********************************@microsof t.com...
Hey Jason,

The first time a ASP.NET application runs it has to compile the MSIL code
into Native code for execution and then start responding to request made

by
the client (browser).
and any other request made after the first one (the one that starts the
application)
the native code is already present with the framework it need not

recompile
the MSIL code to native code.
Hence, anytime you access your application for the first time it is much
slower than any subsequent access.

************************************
Hope this helps,
Shaun
http://blogs.wwwcoder.com/shaunakp
************************************

"Jason" wrote:
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.
i have placed these timing loggings in the Load and Init events on a typical aspx page. i.e. first line of code in Page_Load is
DateTime dtStart = DateTime.Now;
and the last lines of code are
DateTime dtEnd = DateTime.Now;
TimeSpan timeTaken = dtStart - dtEnd;
// log result to log files;
according to my log files, for the first load, it takes 2 seconds for the application to fully load. every subsequent access to that application takes 1 second or less to fully load. yet, when i manually count the seconds
between clicking "Go" and the time the application is fully loaded, it is about 17 seconds.

NOTE: the above is a first time load (restarting the web server, or
restarting IIS). every load (from "Go" to "finish") after that, takes 2
seconds or less. Restarting IIS service will then mean the application will, again, take 17 seconds to load, but only 2 of those seconds are used by the application.

Are their events i am missing that i should be timing?
is it really IIS that is actually taking up all the time?
what can i do about this first time hit?

Thanks.
Hope i have made sense, if not, lemme know so i can clarify
Jason


Nov 19 '05 #6
Thanks

I also dont see it as a problem. but clients can be a pain in the butt. and
the customer is always right. sigh
Thanks for the help

"S h a u n" <Sh***@discussions.microsoft.com> wrote in message
news:B6**********************************@microsof t.com...
Hey Jason,

As far as my understanding goes nothing can be done about it , but i fail to see the problem since this will just happen the very first time the
application is started it wont affect much.

well dont know abt sites, but i am sure this will be documented on MSDN site , google a bit on this, or have a look at MS Press 70-320

under the section

Chapter 1 : Understanding the .NET Framework -
Lesson 2: Understanding the Common Language
Runtime
******************************
Hope this helps,
Shaun (M.C.P)

http://blogs.wwwcoder.com/shaunakp
******************************

"Jason" wrote:
excellent, thanks.
so not much i can do about it?
is there a website i can read regarding this?
"S h a u n" <Sh***@discussions.microsoft.com> wrote in message
news:AA**********************************@microsof t.com...
Hey Jason,

The first time a ASP.NET application runs it has to compile the MSIL code into Native code for execution and then start responding to request made
by
the client (browser).
and any other request made after the first one (the one that starts
the application)
the native code is already present with the framework it need not

recompile
the MSIL code to native code.
Hence, anytime you access your application for the first time it is much slower than any subsequent access.

************************************
Hope this helps,
Shaun
http://blogs.wwwcoder.com/shaunakp
************************************

"Jason" wrote:

> 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.
> i have placed these timing loggings in the Load and Init events on a

typical
> aspx page. i.e. first line of code in Page_Load is
> DateTime dtStart = DateTime.Now;
> and the last lines of code are
> DateTime dtEnd = DateTime.Now;
> TimeSpan timeTaken = dtStart - dtEnd;
> // log result to log files;
> according to my log files, for the first load, it takes 2 seconds for the
> application to fully load. every subsequent access to that
application takes
> 1 second or less to fully load. yet, when i manually count the
seconds > between clicking "Go" and the time the application is fully loaded, it is
> about 17 seconds.
>
> NOTE: the above is a first time load (restarting the web server, or
> restarting IIS). every load (from "Go" to "finish") after that,
takes 2 > seconds or less. Restarting IIS service will then mean the

application will,
> again, take 17 seconds to load, but only 2 of those seconds are used
by the
> application.
>
> Are their events i am missing that i should be timing?
> is it really IIS that is actually taking up all the time?
> what can i do about this first time hit?
>
> Thanks.
> Hope i have made sense, if not, lemme know so i can clarify
> Jason
>
>
>


Nov 19 '05 #7
hahaha
Yup , clients are the tough ones to convince :) best of luck in that front

*********************************
Hope this helps,
Shaun (M.C.P)

http://blogs.wwwcoder.com/shaunakp
*********************************

"Jason" wrote:
Thanks

I also dont see it as a problem. but clients can be a pain in the butt. and
the customer is always right. sigh
Thanks for the help

"S h a u n" <Sh***@discussions.microsoft.com> wrote in message
news:B6**********************************@microsof t.com...
Hey Jason,

As far as my understanding goes nothing can be done about it , but i fail

to
see the problem since this will just happen the very first time the
application is started it wont affect much.

well dont know abt sites, but i am sure this will be documented on MSDN

site
, google a bit on this, or have a look at MS Press 70-320

under the section

Chapter 1 : Understanding the .NET Framework -
Lesson 2: Understanding the Common Language
Runtime
******************************
Hope this helps,
Shaun (M.C.P)

http://blogs.wwwcoder.com/shaunakp
******************************

"Jason" wrote:
excellent, thanks.
so not much i can do about it?
is there a website i can read regarding this?
"S h a u n" <Sh***@discussions.microsoft.com> wrote in message
news:AA**********************************@microsof t.com...
> Hey Jason,
>
> The first time a ASP.NET application runs it has to compile the MSIL code > into Native code for execution and then start responding to request made by
> the client (browser).
> and any other request made after the first one (the one that starts the > application)
> the native code is already present with the framework it need not
recompile
> the MSIL code to native code.
> Hence, anytime you access your application for the first time it is much > slower than any subsequent access.
>
> ************************************
> Hope this helps,
> Shaun
> http://blogs.wwwcoder.com/shaunakp
> ************************************
>
> "Jason" wrote:
>
> > 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.
> > i have placed these timing loggings in the Load and Init events on a
typical
> > aspx page. i.e. first line of code in Page_Load is
> > DateTime dtStart = DateTime.Now;
> > and the last lines of code are
> > DateTime dtEnd = DateTime.Now;
> > TimeSpan timeTaken = dtStart - dtEnd;
> > // log result to log files;
> > according to my log files, for the first load, it takes 2 seconds for the
> > application to fully load. every subsequent access to that application takes
> > 1 second or less to fully load. yet, when i manually count the seconds > > between clicking "Go" and the time the application is fully loaded, it is
> > about 17 seconds.
> >
> > NOTE: the above is a first time load (restarting the web server, or
> > restarting IIS). every load (from "Go" to "finish") after that, takes 2 > > seconds or less. Restarting IIS service will then mean the application will,
> > again, take 17 seconds to load, but only 2 of those seconds are used by the
> > application.
> >
> > Are their events i am missing that i should be timing?
> > is it really IIS that is actually taking up all the time?
> > what can i do about this first time hit?
> >
> > Thanks.
> > Hope i have made sense, if not, lemme know so i can clarify
> > Jason
> >
> >
> >


Nov 19 '05 #8
luckily we have a windows service supporting the ASP.NET applications. from
there we can do WebClient.OpenReads to the various pages, effectively
"firing" that compilation.
one more step.

is it possible to determine if the IIS Admin service was just started? are
their events we can subscribe to perhaps??

"S h a u n" <Sh***@discussions.microsoft.com> wrote in message
news:A6**********************************@microsof t.com...
hahaha
Yup , clients are the tough ones to convince :) best of luck in that front

*********************************
Hope this helps,
Shaun (M.C.P)

http://blogs.wwwcoder.com/shaunakp
*********************************

"Jason" wrote:
Thanks

I also dont see it as a problem. but clients can be a pain in the butt. and the customer is always right. sigh
Thanks for the help

"S h a u n" <Sh***@discussions.microsoft.com> wrote in message
news:B6**********************************@microsof t.com...
Hey Jason,

As far as my understanding goes nothing can be done about it , but i fail
to
see the problem since this will just happen the very first time the
application is started it wont affect much.

well dont know abt sites, but i am sure this will be documented on
MSDN site
, google a bit on this, or have a look at MS Press 70-320

under the section

Chapter 1 : Understanding the .NET Framework -
Lesson 2: Understanding the Common
Language Runtime
******************************
Hope this helps,
Shaun (M.C.P)

http://blogs.wwwcoder.com/shaunakp
******************************

"Jason" wrote:

> excellent, thanks.
> so not much i can do about it?
> is there a website i can read regarding this?
> "S h a u n" <Sh***@discussions.microsoft.com> wrote in message
> news:AA**********************************@microsof t.com...
> > Hey Jason,
> >
> > The first time a ASP.NET application runs it has to compile the MSIL code
> > into Native code for execution and then start responding to
request made
> by
> > the client (browser).
> > and any other request made after the first one (the one that
starts the
> > application)
> > the native code is already present with the framework it need not
> recompile
> > the MSIL code to native code.
> > Hence, anytime you access your application for the first time it
is much
> > slower than any subsequent access.
> >
> > ************************************
> > Hope this helps,
> > Shaun
> > http://blogs.wwwcoder.com/shaunakp
> > ************************************
> >
> > "Jason" wrote:
> >
> > > 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.
> > > i have placed these timing loggings in the Load and Init events
on a > typical
> > > aspx page. i.e. first line of code in Page_Load is
> > > DateTime dtStart = DateTime.Now;
> > > and the last lines of code are
> > > DateTime dtEnd = DateTime.Now;
> > > TimeSpan timeTaken = dtStart - dtEnd;
> > > // log result to log files;
> > > according to my log files, for the first load, it takes 2 seconds for
> the
> > > application to fully load. every subsequent access to that

application
> takes
> > > 1 second or less to fully load. yet, when i manually count the

seconds
> > > between clicking "Go" and the time the application is fully
loaded, it
> is
> > > about 17 seconds.
> > >
> > > NOTE: the above is a first time load (restarting the web server,
or > > > restarting IIS). every load (from "Go" to "finish") after that,

takes 2
> > > seconds or less. Restarting IIS service will then mean the

application
> will,
> > > again, take 17 seconds to load, but only 2 of those seconds are

used by
> the
> > > application.
> > >
> > > Are their events i am missing that i should be timing?
> > > is it really IIS that is actually taking up all the time?
> > > what can i do about this first time hit?
> > >
> > > Thanks.
> > > Hope i have made sense, if not, lemme know so i can clarify
> > > Jason
> > >
> > >
> > >
>
>
>


Nov 19 '05 #9
hey
am not understanding the problem exactly could you elaborate on it please
********************************
Hope this helps,
Shaun (M.C.P)

http://blogs.wwwcoder.com/shaunakp
*********************************

"Jason" wrote:
luckily we have a windows service supporting the ASP.NET applications. from
there we can do WebClient.OpenReads to the various pages, effectively
"firing" that compilation.
one more step.

is it possible to determine if the IIS Admin service was just started? are
their events we can subscribe to perhaps??

"S h a u n" <Sh***@discussions.microsoft.com> wrote in message
news:A6**********************************@microsof t.com...
hahaha
Yup , clients are the tough ones to convince :) best of luck in that front

*********************************
Hope this helps,
Shaun (M.C.P)

http://blogs.wwwcoder.com/shaunakp
*********************************

"Jason" wrote:
Thanks

I also dont see it as a problem. but clients can be a pain in the butt. and the customer is always right. sigh
Thanks for the help

"S h a u n" <Sh***@discussions.microsoft.com> wrote in message
news:B6**********************************@microsof t.com...
> Hey Jason,
>
> As far as my understanding goes nothing can be done about it , but i fail to
> see the problem since this will just happen the very first time the
> application is started it wont affect much.
>
> well dont know abt sites, but i am sure this will be documented on MSDN site
> , google a bit on this, or have a look at MS Press 70-320
>
> under the section
>
> Chapter 1 : Understanding the .NET Framework -
> Lesson 2: Understanding the Common Language > Runtime
>
>
> ******************************
> Hope this helps,
> Shaun (M.C.P)
>
> http://blogs.wwwcoder.com/shaunakp
> ******************************
>
> "Jason" wrote:
>
> > excellent, thanks.
> > so not much i can do about it?
> > is there a website i can read regarding this?
> > "S h a u n" <Sh***@discussions.microsoft.com> wrote in message
> > news:AA**********************************@microsof t.com...
> > > Hey Jason,
> > >
> > > The first time a ASP.NET application runs it has to compile the MSIL code
> > > into Native code for execution and then start responding to request made
> > by
> > > the client (browser).
> > > and any other request made after the first one (the one that starts the
> > > application)
> > > the native code is already present with the framework it need not
> > recompile
> > > the MSIL code to native code.
> > > Hence, anytime you access your application for the first time it is much
> > > slower than any subsequent access.
> > >
> > > ************************************
> > > Hope this helps,
> > > Shaun
> > > http://blogs.wwwcoder.com/shaunakp
> > > ************************************
> > >
> > > "Jason" wrote:
> > >
> > > > 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.
> > > > i have placed these timing loggings in the Load and Init events on a > > typical
> > > > aspx page. i.e. first line of code in Page_Load is
> > > > DateTime dtStart = DateTime.Now;
> > > > and the last lines of code are
> > > > DateTime dtEnd = DateTime.Now;
> > > > TimeSpan timeTaken = dtStart - dtEnd;
> > > > // log result to log files;
> > > > according to my log files, for the first load, it takes 2 seconds for
> > the
> > > > application to fully load. every subsequent access to that
application
> > takes
> > > > 1 second or less to fully load. yet, when i manually count the
seconds
> > > > between clicking "Go" and the time the application is fully loaded, it
> > is
> > > > about 17 seconds.
> > > >
> > > > NOTE: the above is a first time load (restarting the web server, or > > > > restarting IIS). every load (from "Go" to "finish") after that,
takes 2
> > > > seconds or less. Restarting IIS service will then mean the
application
> > will,
> > > > again, take 17 seconds to load, but only 2 of those seconds are used by
> > the
> > > > application.
> > > >
> > > > Are their events i am missing that i should be timing?
> > > > is it really IIS that is actually taking up all the time?
> > > > what can i do about this first time hit?
> > > >
> > > > Thanks.
> > > > Hope i have made sense, if not, lemme know so i can clarify
> > > > Jason
> > > >
> > > >
> > > >
> >
> >
> >


Nov 19 '05 #10
how would i programmatically know that the IIS Admin service was just
started?
i.e. the administrator of that particular web server went and stopped the
IIS Admin service, then started it up again. is there a way of knowing that
the service was just started?

not sure how else i can ask this....

"S h a u n" <Sh***@discussions.microsoft.com> wrote in message
news:CC**********************************@microsof t.com...
hey
am not understanding the problem exactly could you elaborate on it please
********************************
Hope this helps,
Shaun (M.C.P)

http://blogs.wwwcoder.com/shaunakp
*********************************

"Jason" wrote:
luckily we have a windows service supporting the ASP.NET applications. from there we can do WebClient.OpenReads to the various pages, effectively
"firing" that compilation.
one more step.

is it possible to determine if the IIS Admin service was just started? are their events we can subscribe to perhaps??

"S h a u n" <Sh***@discussions.microsoft.com> wrote in message
news:A6**********************************@microsof t.com...
hahaha
Yup , clients are the tough ones to convince :) best of luck in that front
*********************************
Hope this helps,
Shaun (M.C.P)

http://blogs.wwwcoder.com/shaunakp
*********************************

"Jason" wrote:

> Thanks
>
> I also dont see it as a problem. but clients can be a pain in the butt.
and
> the customer is always right. sigh
> Thanks for the help
>
> "S h a u n" <Sh***@discussions.microsoft.com> wrote in message
> news:B6**********************************@microsof t.com...
> > Hey Jason,
> >
> > As far as my understanding goes nothing can be done about it , but
i fail
> to
> > see the problem since this will just happen the very first time th
e > > application is started it wont affect much.
> >
> > well dont know abt sites, but i am sure this will be documented on

MSDN
> site
> > , google a bit on this, or have a look at MS Press 70-320
> >
> > under the section
> >
> > Chapter 1 : Understanding the .NET Framework -
> > Lesson 2: Understanding the Common

Language
> > Runtime
> >
> >
> > ******************************
> > Hope this helps,
> > Shaun (M.C.P)
> >
> > http://blogs.wwwcoder.com/shaunakp
> > ******************************
> >
> > "Jason" wrote:
> >
> > > excellent, thanks.
> > > so not much i can do about it?
> > > is there a website i can read regarding this?
> > > "S h a u n" <Sh***@discussions.microsoft.com> wrote in message
> > > news:AA**********************************@microsof t.com...
> > > > Hey Jason,
> > > >
> > > > The first time a ASP.NET application runs it has to compile the MSIL
> code
> > > > into Native code for execution and then start responding to

request
> made
> > > by
> > > > the client (browser).
> > > > and any other request made after the first one (the one that

starts
> the
> > > > application)
> > > > the native code is already present with the framework it need
not > > > recompile
> > > > the MSIL code to native code.
> > > > Hence, anytime you access your application for the first time it is
> much
> > > > slower than any subsequent access.
> > > >
> > > > ************************************
> > > > Hope this helps,
> > > > Shaun
> > > > http://blogs.wwwcoder.com/shaunakp
> > > > ************************************
> > > >
> > > > "Jason" wrote:
> > > >
> > > > > 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.
> > > > > i have placed these timing loggings in the Load and Init
events on a
> > > typical
> > > > > aspx page. i.e. first line of code in Page_Load is
> > > > > DateTime dtStart = DateTime.Now;
> > > > > and the last lines of code are
> > > > > DateTime dtEnd = DateTime.Now;
> > > > > TimeSpan timeTaken = dtStart - dtEnd;
> > > > > // log result to log files;
> > > > > according to my log files, for the first load, it takes 2

seconds
> for
> > > the
> > > > > application to fully load. every subsequent access to that
> application
> > > takes
> > > > > 1 second or less to fully load. yet, when i manually count
the > seconds
> > > > > between clicking "Go" and the time the application is fully

loaded,
> it
> > > is
> > > > > about 17 seconds.
> > > > >
> > > > > NOTE: the above is a first time load (restarting the web server, or
> > > > > restarting IIS). every load (from "Go" to "finish") after
that, > takes 2
> > > > > seconds or less. Restarting IIS service will then mean the
> application
> > > will,
> > > > > again, take 17 seconds to load, but only 2 of those seconds

are used
> by
> > > the
> > > > > application.
> > > > >
> > > > > Are their events i am missing that i should be timing?
> > > > > is it really IIS that is actually taking up all the time?
> > > > > what can i do about this first time hit?
> > > > >
> > > > > Thanks.
> > > > > Hope i have made sense, if not, lemme know so i can clarify
> > > > > Jason
> > > > >
> > > > >
> > > > >
> > >
> > >
> > >
>
>
>


Nov 19 '05 #11
Not sure if i understood your qts correctly but
you can build a Windows service inheriting from Service Controll Manager
class or something (not sure about the exact name) using which you can
monitor services running on the machine and inturn fire and event to your
custom service using Custom Commands whenever the IIS service event that you
want to trap is fired.

e.g

the Custom service that you inherit from SCM will monitor IIS Service and
fire a custom command to the service to take some action whenever the IIS
service is shut down or fired up

Let me know if this helps

********************************
Hope this helps,
Shaun (M.C.P)

http://blogs.wwwcoder.com/shaunakp
*********************************

"Jason" wrote:
how would i programmatically know that the IIS Admin service was just
started?
i.e. the administrator of that particular web server went and stopped the
IIS Admin service, then started it up again. is there a way of knowing that
the service was just started?

not sure how else i can ask this....

"S h a u n" <Sh***@discussions.microsoft.com> wrote in message
news:CC**********************************@microsof t.com...
hey
am not understanding the problem exactly could you elaborate on it please
********************************
Hope this helps,
Shaun (M.C.P)

http://blogs.wwwcoder.com/shaunakp
*********************************

"Jason" wrote:
luckily we have a windows service supporting the ASP.NET applications. from there we can do WebClient.OpenReads to the various pages, effectively
"firing" that compilation.
one more step.

is it possible to determine if the IIS Admin service was just started? are their events we can subscribe to perhaps??

"S h a u n" <Sh***@discussions.microsoft.com> wrote in message
news:A6**********************************@microsof t.com...
> hahaha
> Yup , clients are the tough ones to convince :) best of luck in that front >
> *********************************
> Hope this helps,
> Shaun (M.C.P)
>
> http://blogs.wwwcoder.com/shaunakp
> *********************************
>
> "Jason" wrote:
>
> > Thanks
> >
> > I also dont see it as a problem. but clients can be a pain in the butt. and
> > the customer is always right. sigh
> > Thanks for the help
> >
> > "S h a u n" <Sh***@discussions.microsoft.com> wrote in message
> > news:B6**********************************@microsof t.com...
> > > Hey Jason,
> > >
> > > As far as my understanding goes nothing can be done about it , but i fail
> > to
> > > see the problem since this will just happen the very first time th e > > > application is started it wont affect much.
> > >
> > > well dont know abt sites, but i am sure this will be documented on
MSDN
> > site
> > > , google a bit on this, or have a look at MS Press 70-320
> > >
> > > under the section
> > >
> > > Chapter 1 : Understanding the .NET Framework -
> > > Lesson 2: Understanding the Common
Language
> > > Runtime
> > >
> > >
> > > ******************************
> > > Hope this helps,
> > > Shaun (M.C.P)
> > >
> > > http://blogs.wwwcoder.com/shaunakp
> > > ******************************
> > >
> > > "Jason" wrote:
> > >
> > > > excellent, thanks.
> > > > so not much i can do about it?
> > > > is there a website i can read regarding this?
> > > > "S h a u n" <Sh***@discussions.microsoft.com> wrote in message
> > > > news:AA**********************************@microsof t.com...
> > > > > Hey Jason,
> > > > >
> > > > > The first time a ASP.NET application runs it has to compile the MSIL
> > code
> > > > > into Native code for execution and then start responding to
request
> > made
> > > > by
> > > > > the client (browser).
> > > > > and any other request made after the first one (the one that
starts
> > the
> > > > > application)
> > > > > the native code is already present with the framework it need not > > > > recompile
> > > > > the MSIL code to native code.
> > > > > Hence, anytime you access your application for the first time it is
> > much
> > > > > slower than any subsequent access.
> > > > >
> > > > > ************************************
> > > > > Hope this helps,
> > > > > Shaun
> > > > > http://blogs.wwwcoder.com/shaunakp
> > > > > ************************************
> > > > >
> > > > > "Jason" wrote:
> > > > >
> > > > > > 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.
> > > > > > i have placed these timing loggings in the Load and Init events on a
> > > > typical
> > > > > > aspx page. i.e. first line of code in Page_Load is
> > > > > > DateTime dtStart = DateTime.Now;
> > > > > > and the last lines of code are
> > > > > > DateTime dtEnd = DateTime.Now;
> > > > > > TimeSpan timeTaken = dtStart - dtEnd;
> > > > > > // log result to log files;
> > > > > > according to my log files, for the first load, it takes 2
seconds
> > for
> > > > the
> > > > > > application to fully load. every subsequent access to that
> > application
> > > > takes
> > > > > > 1 second or less to fully load. yet, when i manually count the > > seconds
> > > > > > between clicking "Go" and the time the application is fully
loaded,
> > it
> > > > is
> > > > > > about 17 seconds.
> > > > > >
> > > > > > NOTE: the above is a first time load (restarting the web server, or
> > > > > > restarting IIS). every load (from "Go" to "finish") after that, > > takes 2
> > > > > > seconds or less. Restarting IIS service will then mean the
> > application
> > > > will,
> > > > > > again, take 17 seconds to load, but only 2 of those seconds are used
> > by
> > > > the
> > > > > > application.
> > > > > >
> > > > > > Are their events i am missing that i should be timing?
> > > > > > is it really IIS that is actually taking up all the time?
> > > > > > what can i do about this first time hit?
> > > > > >
> > > > > > Thanks.
> > > > > > Hope i have made sense, if not, lemme know so i can clarify
> > > > > > Jason
> > > > > >
> > > > > >
> > > > > >
> > > >
> > > >
> > > >
> >
> >
> >


Nov 19 '05 #12

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

Similar topics

6
by: orekin | last post by:
Hi There I have been trying to come to grips with Application.Run(), Application.Exit() and the Message Pump and I would really appreciate some feedback on the following questions .. There are...
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...
6
by: B B | last post by:
Okay, here is what's happening: I have a reasonably fast laptop (1.4 GHz Mobile M, so comparable to 2.5GHz P4) doing .net development. Running Windows XP pro, SP2 IIS is installed and running...
7
by: Ralf Gedrat | last post by:
Hello! I have some Vb.Net applications, which are terminated at indefinite times without message. If I call in the program regulated system.GC.Collect, then the program is terminated here...
4
by: Ravi Ambros Wallau | last post by:
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...
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...
9
by: jeff | last post by:
Hi All. I realize that when my Deployed winforms application starts, Windows needs to load the .net 2 framework before control is given to my application.... Is there anyway to either ... -...
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...
1
by: davidmurray1 | last post by:
I have a C++ app on my flash drive that i am running, but often times, i must take the flash drive out of the computer and use it elsewhere while the executable continues to run. however, the...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

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.