Solved

"Please Wait" - Under Load

Posted on 2004-09-13
8
445 Views
Last Modified: 2010-04-15
Hi All,

Ok I realize that the title is a bit cryptic so let me explain.

I have an C# web application that generates a few pages on the fly. Basically the ASPX file is empty and I generate everything using Response.Write()

I am now doing stress tests on my server and ak experiencing a problem.

When the server is under stress and I load a page in the app ... the page opens up but except for the title bar everything is just a blank white page ( it's busy loading) ... as this is not very appealing and the user might think that the app has hung I would like to put a "please wait" on the page while the main stuff is loading ... the main data loads from oracle and then writes to the page.

I have tried adding a 'Please wait" to the ASPX page to let it display before the page is regenerated, I have also added a Response.Write("Please Wait");Response.End(); to the Page_Load ... so it shoows it while the real data loads ...

in both cases there is no joy. The page still stays white for a few seconds and once it's done it just displays my data (I'm guessing that my "Please wait" flashes just before my data is displayed) ...

Can anybody help here

Txs
Peter
0
Comment
Question by:Pete2003
  • 4
  • 3
8 Comments
 
LVL 5

Expert Comment

by:Kelmen
ID: 12042143
At the approriate event (eg, PageLoad), after you render the text "Please wait"...., use Response.Flush to force this text pass to browser.
0
 
LVL 14

Accepted Solution

by:
AvonWyss earned 500 total points
ID: 12042300
Kelmen's suggestion might work (or might not, depending on whether the browser will already display the message before the page has been fully loaded), and you'll always have the "please wait" message staying on top of the message after the results have been returned.

My suggestion would be to generate two requests: one to a page with only a "Please Wait" message, which inclused a refresh-metatag in the head: <META HTTP-EQUIV=Refresh CONTENT="0; URL=UrlOfPage">

This should make thre browser load the given URL after the page, while still displaying the "please wait" message until the page has loaded.
0
 

Author Comment

by:Pete2003
ID: 12042641
AvonWyss: I hav tried your approach and it does help when the Oracle stuff is loading but it also introduces another wait period ...

as I'm stressing both the oracle and the IIS server, I get a blank page when I load my 'loader page' , then the 'please wait ' appears on my loader page then the real page loads ... granted that the wait period for the 'load page' is much shorter then the 'real page' however there is still a wait period for the 'load page' and there is the extra delay of when the 'load page' loads my 'real page' ... since it's an extra trip to an already busy IIS server ...

Txs
Peter
0
 
LVL 14

Expert Comment

by:AvonWyss
ID: 12042697
The delay should be quite short, if you pay attention not do do things in the load page (escpecially be aware of things that might be done in the global.asax file for each request). The extra trip is not very expensive, since the HTTP connects will stay open after the please-wait-request.
0
Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

 

Author Comment

by:Pete2003
ID: 12042905
Ok here is my load page ... "reportLoad.html"

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title></title>
<META HTTP-EQUIV=Refresh CONTENT="0; URL=reportMain.aspx">

<meta name="GENERATOR" content="Microsoft Visual Studio .NET 7.1">
<meta name=ProgId content=VisualStudio.HTML>
<meta name=Originator content="Microsoft Visual Studio .NET 7.1">
</head>
<body>
Please Wait ...


</body>
</html>

Is that as 'streamline' as I will get ?
0
 
LVL 14

Expert Comment

by:AvonWyss
ID: 12042911
Assuming that the IIS server does not have a script mapping on HTML pages, so that this page is serves as static content, I think that this is about the best you can get...
0
 

Author Comment

by:Pete2003
ID: 12042949
Ok txs ...
0
 
LVL 14

Expert Comment

by:AvonWyss
ID: 12042968
Thanks for the points!

Note that the refresh-URL can also be an url on another server if you put in a fully-qualified url (http://...), so that you could have a second server as "back-end" if you really get into performance troubles. But I doubt that the effort and costs of a second server could be worth the little decrease in serving time.
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

In order to hide the "ugly" records selectors (triangles) in the rowheaders, here are some suggestions. Microsoft doesn't have a direct method/property to do it. You can only hide the rowheader column. First solution, the easy way The first sol…
Entity Framework is a powerful tool to help you interact with the DataBase but still doesn't help much when we have a Stored Procedure that returns more than one resultset. The solution takes some of out-of-the-box thinking; read on!
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now