werkspot / message-bus-werkspot-message-queue-adapter
This package is abandoned and no longer maintained.
No replacement package was suggested.
The adapter that allows for werkspot/message-queue to be used with werkspot/message-bus.
dev-master / 1.0.x-dev
2017-10-09 13:38 UTC
Requires
- php: ^7.1
- roave/security-advisories: dev-master
- werkspot/message-bus: dev-master
- werkspot/message-queue: dev-master
Requires (Dev)
- friendsofphp/php-cs-fixer: ^2.0
- mockery/mockery: v1.0.0-alpha1
- phpunit/phpunit: ^5.7
This package is auto-updated.
Last update: 2020-10-21 07:22:22 UTC
README
This is an adapter around Werkspot\MessageQueue, so Werkspot\MessageBus can use it and still be decoupled.
Usage
The MessageDispatcher
is the entry point to the message bus. There are already a few middlewares provided with
this library, which you can find in src/Bus/DeliveryChain
.
use Werkspot\MessageBus\MessageQueue\WerkspotMessageQueue\MessageQueueService; use Werkspot\MessageQueue\MessageQueueService as WerkspotMessageQueueService; $message = new AsynchronousMessage('payload', 'destination', ['metadata']); $messageQueueService = new MessageQueueService(new WerkspotMessageQueueService(/* ... */)); $messageQueueService->enqueueMessage($message);
Installation
To install the library, run the command below and you will get the latest version:
composer require werkspot/message-bus-werkspot-message-queue-adapter
Tests
To execute the tests run:
make test
Coverage
To generate the test coverage run:
make test_with_coverage
Code standards
To fix the code standards run:
make cs-fix