ICallbackEventHandler - bottleneck?

I

Ian

Question: Is there a way to multi-thread ICallbackEventHandler using
delegates?

Problem: I'm executing client-side calls to my page, which implements
ICallbackEventHandler. I need to implement ICallbackEventHandler in
order to access the state of various 3rd party controls I'm working
with.

I have one method in particular which takes a long time to process,
roughly 30 seconds or so. My goal is to allow other methods to be
processed while this runs in the background. What I've found so far,
though, is that any calls executed after the lengthy one seem to queue
up, and none of their callbacks are executed until the 1st method is
completed.

I am not familiar enough with the ICallbackEventHandler life-cycle
model nor async delegates to dig very far into it, so I might be
missing something obvious.

I haven't had much luck finding discussions of this issue. The best
resource I found so far is:
http://www.eggheadcafe.com/articles/20060918.asp, which states in part:
"Page class lifecycle completion is halted pending the return of all
async method calls"

Thanks,

Ian
 
B

bruce barker

in general the browser only allows 2 (unless you make a change in the
registry) concurrent connections to the server. so, this may cause blocking.

asp.net if you use session queues requests also (1 at a time), so this
will cause blocking (and is probably what is causing your behavior).

you should not make a 30 second call, as this will lead to instablilty.
you should change the long call to two. one to starts the request (on a
seperate thread). and a second that polls for completion.


-- bruce (sqlwork.com)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top