[fpc-pascal] CGI/FastCGI and WS request with a max time response
leledumbo_cool at yahoo.co.id
Fri Jan 5 01:33:21 CET 2018
> The problem is that the WS could take so long time that the entire request
will broke with a "time out".
I suggest making the request handling asynchronous instead. So request will
only register and return some unique id to the requester, then do call to
the WS in background thread. An endpoint shall be provided that when given a
unique id will check whether the corresponding thread has finished executing
or not, returning 200 + response data when done, and 202 if still in
progress. This endpoint shall be called in regular interval by the
requester, until it finishes processing or your server dies (500).
Sent from: http://free-pascal-general.1045716.n5.nabble.com/
More information about the fpc-pascal