[RFC] True native async implementations
Personne n'a encore pris cette issue.
- Langage dominant
- C
- Étoiles
- 40.4k
- Forks
- 8.2k
- Merge moyen
- 2 j 15 h
- PR mergées (30 j)
- 103
Description
Highlights
🏅 Top 1 performance in synthetic benchmark
⚡ 30,000% faster latency in Laravel
RFC: https://wiki.php.net/rfc/true_async
Source: https://github.com/true-async/php-src/tree/true-async-stable
True Async Author: @EdmondDantes
Interests
There is also quite a bit of interest in true async as the exchanges here https://externals.io/message/129690#129944 and here https://github.com/orgs/true-async/discussions/9
Description
It was demonstrated that PHP-based framework can beat many frameworks with async, see here:
https://www.http-arena.com/leaderboard/#v=composite&res=mem
It should be noted in the past, during techempower benchmark, actix is among the top contenders in web performance, but in httparena, php async framework scored higher with async/coroutine. While php is not entirely a framework, native async/coroutine is a promising potential
In other works, it also demonstrated massive performance improvement in average latency in Laravel from 4000 ms to 13ms for the same workload.
Misconceptions
-
Myth 1
Myth: Native async will mess up ALL of existing synchronous PHP code and projects globally!
Truth: Actually no, you have to explicitly define a function/class/namespace to have an async property, otherwise all synchronous codes and projects will happily run as usual as if there is no native async.
-
Myth 2
Myth: Great, now I have to think async when coding new project
Truth: Actually no, just DON'T define your functions/class/namespace as async then you will be happy with your old php self
Guide de contribution
Ouvrir le guide de contribution
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Piste de recherche
Commencez par le PHP RFC lié et la branche de code source true-async-stable, puis examinez les discussions référencées et le contexte des benchmarks. L’issue ne définit pas de fichiers spécifiques, de tests, de limites d’implémentation ni de critères d’acceptation ; sa réalisation nécessiterait donc d’abord de convenir d’une conception et d’un périmètre.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Évaluation
- Stack technique
- c, php
- Domaine
- backend
- Type d'issue
- Fonctionnalité
- Difficulté
- 5/5
- Temps estimé
- Plus d'une semaine
- Activité
- Calme
- Clarté
- À clarifier
- Accessibilité débutants
- 20/100