Posted By: PerfectPhase | Jul 18th, 2007 @ 7:46 AM
page 1 of 1
Comments: 10 | Views: 2550
PerfectPhase
PerfectPhase
"This is not war, this is pest control!" - Dalek to Cyberman
I've been playing with a small sample that shows how to do ajax style progress bars for long running tasks on the server and found a really strange problem that I hope someone can explain to me.

The source is here if anyone wants to play.

The idea is that when an update panel is posted back to the server I hook into this via the PageRequestManager BeginRequest and start a second callback going that can query the state of the original task.

This all works fine until you add a Global.ascx file to the project.  At this point all the out of band callbacks that are meant to update the progress bar seem to be defered until after the first callback completes.

To see what I mean, grab the sample above run it then 'add a new item->Global Application Class' and run it again and the progress bar will fail to update.   If you put a break point on GetCurrentStatus in UpdateProgressPage class you see that all the request come in after the first callback completes!

Can anyone can explain this to me, I'm at a loss!!

BTW i've only tried this on two machines so far, I'd be intreasted to know if anyone else has the problem.

Thanks,

Stephen.
I have the same issue. Did you find a fix to the problem?
thank you very, very, very, very much !!!! Big Smile

Federico
Big thanks, i wasted f..n day to find whats wrong with PageMethods. To be honest MS could mentiond about such behaviour in ajax docs. I would save some time.
DAC
DAC
Hi,

Do we have any fix from microsoft? or anybody konws workaround.

Please let me know. I have the same issue.

Thanks,
DAC
DAC
DAC
Hi,

In my case I see that there are some limitation for the threads to fire async. I can see in IE 2 threads are firing async where as same page in safari fires 4 threads async at one time.

does anyone has the same issue?

--DAC

Hi !

 

Although, this thread is stone-old, may be, it is read. I am struggling with the same problem, which hinders me to use WCF, hosted by IIS. There seems to be no way to configure the session-mode with WCF.

 

A normal page can have "EnableSessionState="readonly", WCF not. But I need the session and a readonly access would be enough. But you cannot configure it with WCF.  The same with webservices [asmx]. I tried to compile both with the interface "IReadOnlySessionState".

But it does not help. This lows down many of my ajax requests and I ask me, if I have to change the service side stack - to apache or soemthing java based. Don't know. The ajax performance is very, very poor!

 

Any help would be great!

 

br--mabra

 

figuerres
figuerres
???

mabra:  in general web services should *ALWAYS* be state-less, there are many reasons for this.

but what does WCF have to do with ajax ?

are you calling a WCF service from inside an ajax page?

 

why does the server need the clients session?

 

in general i would make the service not need that session state on the server.

 

page 1 of 1
Comments: 10 | Views: 2550
Microsoft Communities