@@ -43,24 +43,22 @@ much any API that already uses Promises.
4343* [ Tests] ( #tests )
4444* [ License] ( #license )
4545
46- > Note: This project is in an early alpha stage! Feel free to report any issues you encounter.
47-
4846## Quickstart example
4947
5048Once [ installed] ( #install ) , you can use the following code to access an
5149HTTP webserver and send a large number of HTTP GET requests:
5250
5351``` php
5452$loop = React\EventLoop\Factory::create();
55- $client = new Clue\React\Buzz\Browser($loop);
53+ $browser = new Clue\React\Buzz\Browser($loop);
5654
5755// load a huge array of URLs to fetch
5856$urls = file('urls.txt');
5957
6058// each job should use the browser to GET a certain URL
6159// limit number of concurrent jobs here
62- $q = new Queue(3, null, function ($url) use ($client ) {
63- return $client ->get($url);
60+ $q = new Queue(3, null, function ($url) use ($browser ) {
61+ return $browser ->get($url);
6462});
6563
6664foreach ($urls as $url) {
@@ -88,12 +86,12 @@ If you add a job to the queue and it still below the limit, it will be executed
8886immediately. If you keep adding new jobs to the queue and its concurrency limit
8987is reached, it will not start a new operation and instead queue this for future
9088execution. Once one of the pending operations complete, it will pick the next
91- job from the qeueue and execute this operation.
89+ job from the queue and execute this operation.
9290
9391The ` new Queue(int $concurrency, ?int $limit, callable $handler) ` call
9492can be used to create a new queue instance.
9593You can create any number of queues, for example when you want to apply
96- different limits to different kind of operations.
94+ different limits to different kinds of operations.
9795
9896The ` $concurrency ` parameter sets a new soft limit for the maximum number
9997of jobs to handle concurrently. Finding a good concurrency limit depends
@@ -332,12 +330,15 @@ for more details.
332330The recommended way to install this library is [ through Composer] ( https://getcomposer.org ) .
333331[ New to Composer?] ( https://getcomposer.org/doc/00-intro.md )
334332
333+ This project follows [ SemVer] ( http://semver.org/ ) .
335334This will install the latest supported version:
336335
337336``` bash
338- $ composer require clue/mq-react:dev-master
337+ $ composer require clue/mq-react:^1.0
339338```
340339
340+ See also the [ CHANGELOG] ( CHANGELOG.md ) for details about version upgrades.
341+
341342This project aims to run on any platform and thus does not require any PHP
342343extensions and supports running on legacy PHP 5.3 through current PHP 7+ and
343344HHVM.
@@ -360,4 +361,13 @@ $ php vendor/bin/phpunit
360361
361362## License
362363
363- MIT
364+ This project is released under the permissive [ MIT license] ( LICENSE ) .
365+
366+ I'd like to thank [ Bergfreunde GmbH] ( https://www.bergfreunde.de/ ) , a German
367+ online retailer for Outdoor Gear & Clothing, for sponsoring the first release! 🎉
368+ Thanks to sponsors like this, who understand the importance of open source
369+ development, I can justify spending time and focus on open source development
370+ instead of traditional paid work.
371+
372+ > Did you know that I offer custom development services and issuing invoices for
373+ sponsorships of releases and for contributions? Contact me (@clue ) for details.
0 commit comments