summaryrefslogtreecommitdiff
path: root/plugins/jobs/oooold/tests/consumer.php
blob: ed56edffe4facd6321c9d866d4be2a8f7728f74d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
<?php

/**
 * Spiral Framework.
 *
 * @license   MIT
 * @author    Anton Titov (Wolfy-J)
 */

declare(strict_types=1);

use Spiral\Core\Container;
use Spiral\Goridge;
use Spiral\Jobs;
use Spiral\RoadRunner;

require 'bootstrap.php';

$rr = new RoadRunner\Worker(new Goridge\StreamRelay(STDIN, STDOUT));

$consumer = new Jobs\Consumer(new Jobs\Registry\ContainerRegistry(new Container()));
$consumer->serve($rr);