Releases: reactphp-parallel/reactphp-parallel
Releases ยท reactphp-parallel/reactphp-parallel
2.1.0
2.1.0
- Total issues resolved: 0
- Total pull requests resolved: 1
- Total contributors: 1
Dependencies ๐ฆ
- 60: [2.x] Drop PHP 8.1 thanks to @WyriHaximus
2.0.0
Fully reworked the public facing API to utilize fibers:
From:
<?php
use PackageVersions\Versions;
use React๏ฟฝventLoop\Factory;
use ReactParallel\Factory as ParallelFactory;
use ReactParallel\ObjectProxy\Generated\Proxies\WyriHaximus\Metrics\Registry as RegistryProxy;
use WyriHaximus\Metrics\Label;
use function React\Promise๏ฟฝll;
use WyriHaximus\React\Parallel\Finite;
use function WyriHaximus\iteratorOrArrayToArray;
use WyriHaximus\React\Parallel\ReturnThread;
use WyriHaximus\React\Parallel\FiniteWorker;
$options = getopt(
'',
[
'iterations:',
'delay::',
],
);
require dirname(__DIR__) . DIRECTORY_SEPARATOR . 'vendor' . DIRECTORY_SEPARATOR . 'autoload.php';
$loop = Factory::create();
echo 'Loop: ', get_class($loop), PHP_EOL;
$parallelFactory = new ParallelFactory($loop);
$pool = $parallelFactory->lowLevelPool();
$loop->futureTick(static function () use ($pool, $options): void {
foreach (range(0, 7) as $i) {
$pool->run(static function (int $index, int $iterations, bool $delay): int {
for ($i = 0; $i < $iterations; $i++) {
if ($delay) {
usleep($i * 3.3);
}
echo "๏ฟฝ[" . (30 + $index) . ";" . (40 + $index) . "m.๏ฟฝ[0m";
}
return true;
}, [$i, (int)$options['iterations'], isset($options['delay'])]);
}
});
echo PHP_EOL, 'Loop::run()', PHP_EOL;
$loop->run();
echo PHP_EOL, 'Loop::done()', PHP_EOL;To:
<?php
declare(strict_types=1);
use React๏ฟฝventLoop\Loop;
use ReactParallel\Factory as ParallelFactory;
use function React\Async๏ฟฝsync;
$options = getopt(
'',
[
'iterations:',
'delay::',
],
);
require dirname(__DIR__) . DIRECTORY_SEPARATOR . 'vendor' . DIRECTORY_SEPARATOR . 'autoload.php';
echo 'Loop: ', Loop::get()::class, PHP_EOL;
$parallelFactory = new ParallelFactory();
$pool = $parallelFactory->lowLevelPool();
foreach (range(0, 7) as $i) {
Loop::futureTick(async(static function () use ($i, $pool, $options): void {
$pool->run(static function (int $index, int $iterations, bool $delay): bool {
for ($i = 0; $i < $iterations; $i++) {
if ($delay) {
usleep((int) ($i * 0.3));
}
echo "๏ฟฝ[" . (30 + $index) . ";" . (40 + $index) . "m.๏ฟฝ[0m";
}
return true;
}, [$i, (int)$options['iterations'], isset($options['delay'])]);
}));
}
echo PHP_EOL, 'Loop::run()', PHP_EOL;2.0.0
- Total issues resolved: 0
- Total pull requests resolved: 28
- Total contributors: 3
Dependencies ๐ฆ,Feature ๐
- 56: Template types thanks to @WyriHaximus
Dependencies ๐ฆ,Enhancement โจ
- 54: Down bump to PHP 8.1 thanks to @WyriHaximus
Dependencies ๐ฆ
- 50: Bump composer/composer from 2.6.6 to 2.7.0 thanks to @dependabot[bot]
- 49: PHP 8.2+ thanks to @WyriHaximus
- 48: Update dependency react/http to v1.9.0 [SECURITY] - autoclosed thanks to @renovate[bot]
- 47: Update dependency react/http to v1.9.0 [SECURITY] thanks to @renovate[bot]
- 46: Update github/super-linter Docker tag to v5 - autoclosed thanks to @renovate[bot]
- 44: Update actions/cache action to v3 - autoclosed thanks to @renovate[bot]
- 43: Update JasonEtco/is-sponsor-label-action action to v2 - autoclosed thanks to @renovate[bot]
- 42: Update github/super-linter Docker tag to v2.2.2 - autoclosed thanks to @renovate[bot]
- 41: Update dependency wyrihaximus/metrics to v2 - autoclosed thanks to @renovate[bot]
- 40: Update dependency wyrihaximus/async-test-utilities to v7 - autoclosed thanks to @renovate[bot]
- 39: Update dependency react/promise to v3 - autoclosed thanks to @renovate[bot]
- 38: Update dependency ocramius/package-versions to v2 - autoclosed thanks to @renovate[bot]
- 37: Update dependency moneyphp/money to v4 - autoclosed thanks to @renovate[bot]
- 35: Update dependency react/http to v1.9.0 [SECURITY] thanks to @renovate[bot]
- 33: Update dependency ancarda/psr7-string-stream to v1.3.1 - autoclosed thanks to @renovate[bot]
- 32: Update dependency react/http to v1.9.0 [SECURITY] - autoclosed thanks to @renovate[bot]
- 27: Bump react/http from 1.2.0 to 1.3.0 thanks to @dependabot[bot]
- 25: Bump react-parallel/limited-pool from 1.0.0 to 1.0.1 thanks to @dependabot[bot]
- 24: Bump wyrihaximus/async-test-utilities from 3.3.2 to 3.3.3 thanks to @dependabot[bot]
- 23: Bump wyrihaximus/async-test-utilities from 3.3.1 to 3.3.2 thanks to @dependabot[bot]
- 22: Bump react-parallel/event-loop from 1.1.0 to 1.2.0 thanks to @dependabot[bot]
- 21: Bump wyrihaximus/async-test-utilities from 3.2.0 to 3.3.1 thanks to @dependabot[bot]
- 20: Bump react-parallel/infinite-pool from 2.1.0 to 2.1.2 thanks to @dependabot[bot]
- 19: Bump react/http from 1.1.0 to 1.2.0 thanks to @dependabot[bot]
Enhancement โจ
1.1.0
Metrics
This release adds supports for metrics through wyrihaximus/metrics:
use React๏ฟฝventLoop\Factory as EventLoopFactory;
use ReactParallel\Factory;
use ReactParallel\Metrics;
use WyriHaximus\Metrics\Configuration;
use WyriHaximus\Metrics\InMemory\Registry;
$loop = EventLoopFactory::create();
$registry = new Registry(Configuration::create());
$factory = (new Factory($loop))->withMetrics(Metrics::create($registry));1.1.0
- Total issues resolved: 0
- Total pull requests resolved: 4
- Total contributors: 2
Dependencies ๐ฆ,JSON ๐จโ๐ผ,PHP ๐
- 17: Update to test utilities v3 thanks to @WyriHaximus
Dependencies ๐ฆ,PHP ๐
Dependencies ๐ฆ,Documentation ๐,JSON ๐จโ๐ผ,PHP ๐
- 15: Add HTTP example thanks to @WyriHaximus
Dependencies ๐ฆ,Documentation ๐,JSON ๐จโ๐ผ,MarkDown ๐,PHP ๐,Source ๐ฎ,Tests ๐งช
- 14: Add Metrics thanks to @WyriHaximus
1.0.0
1.0.0
- Total issues resolved: 0
- Total pull requests resolved: 10
- Total contributors: 1
Documentation ๐,MarkDown ๐
- 13: Add documentation thanks to @WyriHaximus
Dependencies ๐ฆ,JSON ๐จโ๐ผ,PHP ๐
- 12: Update to stable streams thanks to @WyriHaximus
Dependencies ๐ฆ,JSON ๐จโ๐ผ,PHP ๐,Source ๐ฎ
Dependencies ๐ฆ,JSON ๐จโ๐ผ,PHP ๐,Source ๐ฎ,Tests ๐งช
PHP ๐,Source ๐ฎ,Tests ๐งช
- 9: Add event loop getter thanks to @WyriHaximus
CI ๐ง,Configuration โ,YAML ๐
- 8: Sync Makefile improvements from wyrihaximus/test-utilities thanks to @WyriHaximus
- 5: Github Workflows thanks to @WyriHaximus
Dependencies ๐ฆ,JSON ๐จโ๐ผ,NEON ๐ฆนโโ๏ธ,PHP ๐,Source ๐ฎ,Tests ๐งช
-
7: Update all the things thanks to @WyriHaximus
-
4: Github configuration thanks to @WyriHaximus
-
3: Make factory instanciable thanks to @WyriHaximus