[Lazarus] fpWeb long process progress
Michael Schnell
mschnell at lumino.de
Tue Aug 14 09:47:41 CEST 2012
AFAIK, a web application uses the plain old standard mechanism, a web
server uses to work with a CGI application. it start the application and
when same ends, the web server retrieves its output and sends it to the
browser. So the web application just does not live long to be able to
wait for anything.
To create a longer living web enabled process it takes a lot more effort.
You can try several approaches:
- purely propriety: Use a second process (a long living daemon) and
have the web application communicate with same (e.g. via TCP/IP or Pipe)
- fast CGI: here the (Apache) Web Server does exactly this
communication on it's own account
- ISAPI: here a (Microsoft) Web server communicates with a DLL
My colleagues do a combination of (1) and (3) with one of their (Delphi)
project very successfully:
They created a very simple ISAPI DLL (using RemObjects to do the ISAPI
communication)
They created a Windows service and used RemObjects (using the "Windows
Message" transport) to have the ISAPI DLL communicate with the service.
(RemObjects is a commercial product that is specified to work as well
with Delphi as with FreePascal.)
-Michael
More information about the Lazarus
mailing list