Re: RFC proposal: worker mode primitives for SAPIs
| From: | Tim Düsterhus | Date: | Tue, 26 Dec 2023 19:16:31 +0000 |
| Subject: | Re: RFC proposal: worker mode primitives for SAPIs | ||
| References: | 1 2 3 4 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-122047@lists.php.net to get a copy of this message | ||
Hi
On 12/25/23 19:56, Jordan LeDoux wrote:
So you want to introduce a SAPI that doesn't work with any of the existing HTTP solutions people use that only supports HTTP requests? Or am I misunderstanding something? This sounds a bit like you want to merge in a tool that is designed for your personal product directly into core. FrankenPHP may be incredible and awesome, but the world runs on Apache and Nginx for HTTP requests.My understanding of the proposal in very simplified language is: A new function shall be added to be implemented by SAPIs that are capable of implementing the function correctly. This function effectively: 1. Flushes the pending headers (header() calls) and body (if any). 2. Blocks until a request arrives. 3. Sets the superglobals ($_GET, $_POST, ...) to the request's values. 4. Sets the php://input stream to that request's body. 5. Sets up default headers (e.g. x-powered-by, if enabled). Best regard Tim Düsterhus