Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:128788 X-Original-To: internals@lists.php.net Delivered-To: internals@lists.php.net Received: from php-smtp4.php.net (php-smtp4.php.net [45.112.84.5]) by lists.php.net (Postfix) with ESMTPS id 69C981A00BC for ; Mon, 6 Oct 2025 15:28:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=php.net; s=mail; t=1759764442; bh=ptOu7ArWv0Jsd0jHrdVJckFsdmjkmdjzTtc3OA+60W8=; h=Date:From:To:In-Reply-To:References:Subject:From; b=TfOo6Eb8mVd/DeyRVb+bjuyY+Kj355vXuABDkuOJPrO3qfQ0mst5CWxP/deT1ioIl DmXR2kC0Pz6KsIf82uGtRTxvVTlLgtlBADQZE+OjlV5ODnnrp5eJwz+r5GlbhdqK9w 2Bgos80OA+YU7lw3j+We0IyrQ6e/EAY5il0xTgcHRwG7sgASidLF2Du+0kafQ3PeLa eF+B+AQSEOZvpoAHuG0wnxUFEYMxqqIxjBoROZpyftztGANW7qF30fZjhISS2FwrXl vz2EDNklwAtokSarvsAEZEQs0MyP8YwTf5NeMKAoZHhdqszGrL3p6XvEEzk3NR6Iv1 i79J8j6qQIvSA== Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 5D33418020B for ; Mon, 6 Oct 2025 15:27:21 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on php-smtp4.php.net X-Spam-Level: X-Spam-Status: No, score=-1.4 required=5.0 tests=BAYES_05,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,DMARC_MISSING,RCVD_IN_DNSWL_LOW, SPF_HELO_PASS,SPF_NONE autolearn=no autolearn_force=no version=4.0.1 X-Spam-Virus: No X-Envelope-From: Received: from fout-a1-smtp.messagingengine.com (fout-a1-smtp.messagingengine.com [103.168.172.144]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Mon, 6 Oct 2025 15:27:21 +0000 (UTC) Received: from phl-compute-10.internal (phl-compute-10.internal [10.202.2.50]) by mailfout.phl.internal (Postfix) with ESMTP id B0A8AEC0190 for ; Mon, 6 Oct 2025 11:28:36 -0400 (EDT) Received: from phl-imap-02 ([10.202.2.81]) by phl-compute-10.internal (MEProxy); Mon, 06 Oct 2025 11:28:36 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= garfieldtech.com; h=cc:content-transfer-encoding:content-type :content-type:date:date:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:subject:subject:to :to; s=fm2; t=1759764516; x=1759850916; bh=unYG64XMN1nt1p/pSXtQ+ VKI/fBDr1jI9tcntViHtL4=; b=Z5JOj7gWGw0YlYn6ZxpatKqAYJeJxI3kt0XPX eoDM4kji9i2sw3deMLXDfjvPnGyOchiOpgu9wr9tE+lTWQntg2/xjxOuZqgi/Seb JvYTVIgoiRmFHt2l+lC/8QLiYHGE8azMpP7JdrVaitvqonVEj3wKyAiwPhUSX1cP /znEW2uJToKXsKHV2Ak0LVtw5q/iFpiPB3IhXBMczXpAQZFPW/Nm/qd9ea0hBs5u yCQXQnjnGaxQjluPcAHKMTr3SdH9GAsyc92NtFOPD9KDN+FFlAz4ipEMK2Db8FPr sLU9qtaSooaSLbRIcOPnPpiqf6pILmMe0KYLXPczPGnus7XHg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :content-type:date:date:feedback-id:feedback-id:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:subject:subject:to:to:x-me-proxy:x-me-sender :x-me-sender:x-sasl-enc; s=fm2; t=1759764516; x=1759850916; bh=u nYG64XMN1nt1p/pSXtQ+VKI/fBDr1jI9tcntViHtL4=; b=WR8ToZaKEaBsXP+6s i9ZOFkhA0hqWw7PT7BkCMzuIWbJ0ZVDwhqP3l7K6CiiBHr+m9CPCxqRSCLjMpCOB DZQUVFGdMtzR80uoKCVAgXPoZoB41O9ze/dLqY6PcLKTrmR1UENjwhtBFfxyGR99 eXZFUrMgfqK+8aDX3B8imx096V10kmUQBtD1oYsJvV5YOuqaSaHj4UA6SzmtT6ir clAttYqzOh41wrM1Bm5BloekMeOjaepm5HXZcls5251EkTIlnhV+cT550iwdRmua GWPyi9uBpOYfWeMuRh+zoL6835zD7SuRz++qT6zQ/z399MpiGcjjsMeeJleS3eT6 sNmwg== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeeffedrtdeggdeljeeltdcutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpuffrtefokffrpgfnqfghnecuuegr ihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenucfjug hrpefoggffhffvkfgjfhfutgfgsehtqhertdertdejnecuhfhrohhmpedfnfgrrhhrhicu ifgrrhhfihgvlhgufdcuoehlrghrrhihsehgrghrfhhivghlughtvggthhdrtghomheqne cuggftrfgrthhtvghrnhepffeiiedvhfdvgedutddtgeetieeugeevhfetheeffeeftedu iedthedtgeejueeinecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilh hfrhhomheplhgrrhhrhiesghgrrhhfihgvlhguthgvtghhrdgtohhmpdhnsggprhgtphht thhopedupdhmohguvgepshhmthhpohhuthdprhgtphhtthhopehinhhtvghrnhgrlhhsse hlihhsthhsrdhphhhprdhnvght X-ME-Proxy: Feedback-ID: i8414410d:Fastmail Received: by mailuser.phl.internal (Postfix, from userid 501) id 4424A700069; Mon, 6 Oct 2025 11:28:36 -0400 (EDT) X-Mailer: MessagingEngine.com Webmail Interface Precedence: list list-help: list-post: List-Id: x-ms-reactions: disallow MIME-Version: 1.0 X-ThreadId: AejB4fewBc7J Date: Mon, 06 Oct 2025 10:28:07 -0500 To: "php internals" Message-ID: <14f591d4-aa1e-49dc-bc20-03cb493dc20c@app.fastmail.com> In-Reply-To: References: Subject: Re: [PHP-DEV] PHP True Async RFC Stage 4 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable From: larry@garfieldtech.com ("Larry Garfield") On Mon, Oct 6, 2025, at 12:34 AM, Edmond Dantes wrote: > Hello. > >> Just a quick question - other methods that tried to provide async/par= allel type functionality previously were only available via the CLI. > > TrueAsync itself is integrated into PHP in such a way that it is > always active. The scenario you described is technically possible (Of > course, this can also be useful for sending telemetry in a way that > doesn=E2=80=99t interfere with request processing.), but it=E2=80=99s = not particularly > relevant in the context of modern development. > > Why? > > Because client requests are usually processed sequentially, step by > step. Parallel tasks are rare.=20 This is simply not true. The example you're replying to is quite common. It's even more common for the database. WordPress, Drupal, and many oth= er such systems frequently run different DB queries to build different c= omponents of a page. (Blocks, widgets, components, the names differ.) = Being able to do those in parallel is a natural optimization that we wer= e thinking about in Drupal nearly 15 years ago, but it wasn't viable at = the time. > Therefore, from the server=E2=80=99s > perspective, the main benefit of concurrency is the ability to handle > multiple requests within a single process. That is *A benefit*. It is not the *only benefit*. Being able to compr= ess the time of each request in a shared-nothing model is absolutely val= uable. Remember, in the wild, PHP-FPM and mod_php are by orders of magnitude th= e most common ways PHP is executed. React, Swoole, etc. are rounding er= rors in most of the market. And the alternate runtime with the most mom= entum is FrankenPHP, which reuses processes but is still "one request in= a process at a time." > The same thing that Swoole, > AMPHP, and other modern backend solutions do. > > And this is one of the reasons why FPM is morally outdated and I am going to assume this is a translation issue, because "morally outda= ted" is the wrong term here. "Morally outdated" is how you'd describe "= racial segregation is good, actually." Not "this technology is slower t= han we need it to be." You probably mean "severely outdated" or somethi= ng along those lines. Which, as I explained above, is simply not true. PHP is going to be run= ning in a mostly shared-nothing environment for the foreseeable future. = Those use cases still would benefit from async support. --Larry Garfield