Re: [Lazarus] fpWeb long process progress

2012-08-15 Thread Henry Vermaak
On 15 August 2012 09:28, Michael Schnell wrote: > On 08/15/2012 12:14 AM, Leonardo M. Ramé wrote: >> >> in my case, I know in advance the process wouldn't take more than one >> minute, > > I feel that (without some special configuration) a normal web server will > kill a standard CGI process that

Re: [Lazarus] fpWeb long process progress

2012-08-15 Thread Michael Schnell
On 08/15/2012 12:14 AM, Leonardo M. Ramé wrote: in my case, I know in advance the process wouldn't take more than one minute, I feel that (without some special configuration) a normal web server will kill a standard CGI process that takes more than just a few seconds before returning. Please

Re: [Lazarus] fpWeb long process progress

2012-08-15 Thread Michael Van Canneyt
On Tue, 14 Aug 2012, Leonardo M. Ramé wrote: On 2012-08-14 11:47:41 -0300, Marcos Douglas wrote: IMHO, maybe is better to use CGI gateway to capture the requests and, for each one them, start a process -- this method will use a file to write the log of process, as Leonardo and Michael said.

Re: [Lazarus] fpWeb long process progress

2012-08-14 Thread Leonardo M . Ramé
On 2012-08-14 11:47:41 -0300, Marcos Douglas wrote: > IMHO, maybe is better to use CGI gateway to capture the requests and, > for each one them, start a process -- this method will use a file to > write the log of process, as Leonardo and Michael said. > Yes, in my case, I know in advance the pro

Re: [Lazarus] fpWeb long process progress

2012-08-14 Thread Marcos Douglas
On Tue, Aug 14, 2012 at 11:34 AM, Michael Schnell wrote: > On 08/14/2012 04:27 PM, Leonardo M. Ramé wrote: >> >> 2) With the TaskId generated by the server, the client calls a CGI method >> called runLongTask(myTaskId). > > I don't know if it's a goad idea to allow a standard CGI to do a long

Re: [Lazarus] fpWeb long process progress

2012-08-14 Thread Michael Schnell
On 08/14/2012 04:27 PM, Leonardo M. Ramé wrote: 2) With the TaskId generated by the server, the client calls a CGI method called runLongTask(myTaskId). I don't know if it's a goad idea to allow a standard CGI to do a long action before returning top the WebServer. At least the WebServer mi

Re: [Lazarus] fpWeb long process progress

2012-08-14 Thread michael . vancanneyt
On Tue, 14 Aug 2012, Leonardo M. Ramé wrote: I have code which does exactly that. It's used in production. It's unix-only, however (it relies on fork and exec). If you're interested, I can send you the code. Michael. Yes please, send me the code. Sent in private mail. Michael.-- __

Re: [Lazarus] fpWeb long process progress

2012-08-14 Thread michael . vancanneyt
On Tue, 14 Aug 2012, Leonardo M. Ramé wrote: On 2012-08-14 09:47:41 +0200, Michael Schnell wrote: 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

Re: [Lazarus] fpWeb long process progress

2012-08-14 Thread Leonardo M . Ramé
On 2012-08-14 09:06:20 +0200, michael.vancann...@wisa.be wrote: > > > On Mon, 13 Aug 2012, Leonardo M. Ramé wrote: > > >On 2012-08-13 15:15:56 -0700, leledumbo wrote: > >>>How can I send responses by intervals? > >> > >>AFAIK that's not the way web application works. It's the client that should

Re: [Lazarus] fpWeb long process progress

2012-08-14 Thread Leonardo M . Ramé
On 2012-08-14 09:47:41 +0200, Michael Schnell wrote: > 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 app

Re: [Lazarus] fpWeb long process progress

2012-08-14 Thread Michael Schnell
On 08/14/2012 09:06 AM, michael.vancann...@wisa.be wrote: I have code which does exactly that. It's used in production. It's unix-only, however (it relies on fork and exec). GREAT ! It would be great if this would be integrated in the Lazarus distribution (as a special "Application") or i

Re: [Lazarus] fpWeb long process progress

2012-08-14 Thread Michael Schnell
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 a

Re: [Lazarus] fpWeb long process progress

2012-08-14 Thread michael . vancanneyt
On Mon, 13 Aug 2012, Leonardo M. Ramé wrote: On 2012-08-13 15:15:56 -0700, leledumbo wrote: How can I send responses by intervals? AFAIK that's not the way web application works. It's the client that should be querying the server in a regular interval (using AJAX request perhaps). The serve

Re: [Lazarus] fpWeb long process progress

2012-08-13 Thread Marcos Douglas
On Mon, Aug 13, 2012 at 7:31 PM, Leonardo M. Ramé wrote: > > On 2012-08-13 15:15:56 -0700, leledumbo wrote: > > > How can I send responses by intervals? > > > > AFAIK that's not the way web application works. It's the client that > > should > > be querying the server in a regular interval (using A

Re: [Lazarus] fpWeb long process progress

2012-08-13 Thread Leonardo M . Ramé
On 2012-08-13 15:15:56 -0700, leledumbo wrote: > > How can I send responses by intervals? > > AFAIK that's not the way web application works. It's the client that should > be querying the server in a regular interval (using AJAX request perhaps). > The server can track current progress status and

Re: [Lazarus] fpWeb long process progress

2012-08-13 Thread leledumbo
> How can I send responses by intervals? AFAIK that's not the way web application works. It's the client that should be querying the server in a regular interval (using AJAX request perhaps). The server can track current progress status and return that right away when asked. -- View this messag