NetTalk Central
NetTalk Web Server => Web Server - Ask For Help => Topic started by: Robert Iliuta on November 30, 2009, 07:14:35 AM
-
Hallo,
I have a web server and this web server receive files from a web client. I need to know when this web server is in process of receiving a file and when he finish and is not busy anymore.
Thank you ,
Regards,
Robert Iliuta
-
Hi Robert,
I guess the easiest way is to keep a thread counter in WebHandler.
ie at the start of WebHandler increment a global thread counter, and at the end of it decrement the counter. If the counter > 0 then there are threads currently processing requests.
Cheers
Bruce
-
Hallo Bruce,
Where is the WebHandler start and close ? Can you point me on the right direction ? Also if this global variable is threaded , how can I use this in WebServer procedure? I need a flag when is busy or not .... In WebServer I have a prompt updated: BUSY or NOT BUSY based on that flag.
Thank you,
Robert
-
Hi Robert,
>> Where is the WebHandler start and close ? Can you point me on the right direction ?
The WebHandler is a normal Clarion procedure. See attached picture.
>> Also if this global variable is threaded , how can I use this in WebServer procedure?
It's not supposed to be Threaded. It's supposed to be non threaded. (That's kinda the point).
>> I need a flag when is busy or not
If the counter >0 then it's busy. If it's = 0 then it's not busy.
Cheers
Bruce
[attachment deleted by admin]
-
Hallo Bruce,
YOU are the BEST !
It works wonderful .
Thank you very much for help.
Regards,
Robert