Solved

"Please Wait" - Under Load

Posted on 2004-09-13
8
447 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
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 

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

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
creating a flowchart from an algorithm 5 30
Chat Room 1 43
XML & .net 5 40
How to write a select year(max(datefield) in EntitySQL in  c# entity framework 12 27
This article describes a simple method to resize a control at runtime.  It includes ready-to-use source code and a complete sample demonstration application.  We'll also talk about C# Extension Methods. Introduction In one of my applications…
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…
Delivering innovative fully-managed cloud services for mission-critical applications requires expertise in multiple areas plus vision and commitment. Meet a few of the people behind the quality services of Concerto.

932 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

14 Experts available now in Live!

Get 1:1 Help Now