<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Fri, Jan 30, 2015 at 4:46 AM, Michael Van Canneyt <span dir="ltr"><<a href="mailto:michael@freepascal.org" target="_blank">michael@freepascal.org</a>></span> wrote:<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><span>
On Thu, 29 Jan 2015, silvioprog wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
Hello,<br>
<br>
Using the TCustomHTTPApplication class, I just set the "Threaded" property to true, and my application works in threaded mode. But,<br>
how to do the same in TCustomFCgiApplication class?<br>
</blockquote>
<br></span>
This is currently not supported.<br>
<br>
If you use fastcgi in classical environment, the Apache webserver will start as many instances of the fastcgi executable as it considers necessary to handle the load.<br>
<br>
Only if you use proxy fastcgi (i.e. a separately running binary listening on a fixed port, not started in Apache), then threading may be useful.<br></blockquote><div><br></div><div>Perfect.</div><div><br></div><div>Do you know if FastCGI proxy accepts a multi-thread structure? I got this question after I did a test on nginx and Apache. I put a processing in a thread, and even then the server was waiting for the end of the first processing. =/</div><div><br></div><div>It's interesting we check it, because if they do not support multi-threaded implementations, we would have unnecessary work.</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
To support threading requires a major rework of the fastcgi implementation, and probably also changes to fpweb (which is not thread-safe).<br>
<br>
This is on my todo list, but you are free to try and supply a patch.<br>
<br>
Michael.</blockquote></div><div><br></div><div>I'll test my drafts this weekend. I'm very interested in this feature, so now it is priority in my test list. =)</div><div><br></div>-- <br><div>Silvio Clécio<br>My public projects - <a href="http://github.com/silvioprog" target="_blank">github.com/silvioprog</a></div>
</div></div>