Conversation
4803f35 to
9b5bd80
Compare
| if (!$this->repository) { | ||
| return; | ||
| } | ||
| return $this->repository; |
There was a problem hiding this comment.
Line break before the return statement
|
Hey @talisman-innovations! I added a couple minor CS type comments, otherwise, this is looking pretty good. |
|
Hi @kmfk - no problem - I think I got them all, plus added an implementation of the create function for good measure. Regards Steve |
|
For a use case we have I'm thinking of implementing a function to allow for redelivery of a message. As the messages sit in the DB it's trivial to implement. Any issues with adding that? Tt could go in the AbstractProvider if other providers offer that feature. |
…ations/qpush-bundle into doctrine-provider
|
The inspection completed: 5 new issues, 31 updated code elements |
|
@talisman-innovations I have no memory of why this would still be open for so long. Looking it over, this looks good to me, but wanted to confirm with you before merging. |
|
Hi - yes feel free to merge. Thanks. |
|
Will do. Currently need to fix an issue with PHPUnit and Symfony ^3.2 to fix the failing builds. Will get this in afterward. |
|
This provider is not documented. unless |
Hi
As discussed a while ago here's an implementation of a Doctrine provider for qpush. The idea is to have a table 'uecode_qpush_message' that holds all the messages for all the queues for the provider. Each message has a queue_name and a boolean to mark it as delivered or not. The message gets serialised by doctrine and then stored/retrieved from the table. Messages are not deleted from the table apart from when the destroy method is called. So the message table has a history of all the message sent along with created and updated times.
To use - examples
config.yml
You can optionally pass in an entity manager for doctrine. Otherwise it defaults to doctrine.orm.default_entity_manager
entity_manager: my.entity.manager
Add this to composer.json
To create the table use console doctrine:schema:update
Other than that usage is as per the other providers.