ONE process at a time

  • Thread starter Thread starter Alan Wang
  • Start date Start date
A

Alan Wang

Hi there,

I am having a web application which has OpenOffice running as backend. The
whole web application runs great if there is only one request at a time. The
web application will mess up if there are more than one requests at same
time. My question is what should I do to only allow one process at same
time for my web application. In another words, The second request will wait
until the first one has finished if there are more than one request at same
time.

Thanks in advanced

Alan
 
Aside from it being a pretty terrible idea you should look at the waithandle
classes in the System.Threading namespace, particuarly at the ManualReset
event. I only mention because you could do it but obviously it won't scale.
 
Like Duncan said you can uses the waithandle namespaces, which are like
mutex's.
It won't scale, and it's poor design. Better find out what resource(s) are
not able to handle multiple requests.

Cheers,
Mark
 
How about using synchronized method?

Alan
Mark said:
Like Duncan said you can uses the waithandle namespaces, which are like
mutex's.
It won't scale, and it's poor design. Better find out what resource(s) are
not able to handle multiple requests.

Cheers,
Mark
 

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

Back
Top