WillRy /
rabbitrun
| 1 | <?php |
||
| 2 | |||
| 3 | use PhpAmqpLib\Message\AMQPMessage; |
||
| 4 | |||
| 5 | class Process implements \WillRy\RabbitRun\PubSub\WorkerInterface |
||
|
0 ignored issues
–
show
|
|||
| 6 | { |
||
| 7 | |||
| 8 | public function handle(\WillRy\RabbitRun\PubSub\Task $data) |
||
|
0 ignored issues
–
show
The type
WillRy\RabbitRun\PubSub\Task was not found. Maybe you did not declare it correctly or list all dependencies?
The issue could also be caused by a filter entry in the build configuration.
If the path has been excluded in your configuration, e.g. filter:
dependency_paths: ["lib/*"]
For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths Loading history...
|
|||
| 9 | { |
||
| 10 | $body = $data->getData(); |
||
|
0 ignored issues
–
show
|
|||
| 11 | |||
| 12 | /** |
||
| 13 | * Fazer o processamento que for necessário |
||
| 14 | */ |
||
| 15 | |||
| 16 | //simulando um erro qualquer para exemplo |
||
| 17 | // $fakeException = rand() % 2 === 0; |
||
| 18 | // if ($fakeException) throw new \Exception("=== Erro ==="); |
||
| 19 | |||
| 20 | echo "Processado".PHP_EOL; |
||
| 21 | |||
| 22 | |||
| 23 | /** Marca o item como erro */ |
||
| 24 | //$data->nackError(); |
||
| 25 | |||
| 26 | /** Marca o item como cancelado */ |
||
| 27 | //$data->nackCancel(); |
||
| 28 | } |
||
| 29 | |||
| 30 | |||
| 31 | public function error(array $databaseData, Exception $error = null) |
||
| 32 | { |
||
| 33 | |||
| 34 | } |
||
| 35 | } |
||
| 36 |
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths