mirror of
https://github.com/wallabag/wallabag.git
synced 2025-01-09 00:15:27 +00:00
AMPQ -> AMQP
This commit is contained in:
parent
a622fbc444
commit
ac87e0db2a
4 changed files with 18 additions and 18 deletions
|
@ -254,7 +254,7 @@ old_sound_rabbit_mq:
|
|||
type: topic
|
||||
queue_options:
|
||||
name: 'wallabag.import.pocket'
|
||||
callback: wallabag_import.consumer.ampq.pocket
|
||||
callback: wallabag_import.consumer.amqp.pocket
|
||||
import_readability:
|
||||
connection: default
|
||||
exchange_options:
|
||||
|
@ -262,7 +262,7 @@ old_sound_rabbit_mq:
|
|||
type: topic
|
||||
queue_options:
|
||||
name: 'wallabag.import.readability'
|
||||
callback: wallabag_import.consumer.ampq.readability
|
||||
callback: wallabag_import.consumer.amqp.readability
|
||||
import_wallabag_v1:
|
||||
connection: default
|
||||
exchange_options:
|
||||
|
@ -270,7 +270,7 @@ old_sound_rabbit_mq:
|
|||
type: topic
|
||||
queue_options:
|
||||
name: 'wallabag.import.wallabag_v1'
|
||||
callback: wallabag_import.consumer.ampq.wallabag_v1
|
||||
callback: wallabag_import.consumer.amqp.wallabag_v1
|
||||
import_wallabag_v2:
|
||||
connection: default
|
||||
exchange_options:
|
||||
|
@ -278,4 +278,4 @@ old_sound_rabbit_mq:
|
|||
type: topic
|
||||
queue_options:
|
||||
name: 'wallabag.import.wallabag_v2'
|
||||
callback: wallabag_import.consumer.ampq.wallabag_v2
|
||||
callback: wallabag_import.consumer.amqp.wallabag_v2
|
||||
|
|
|
@ -5,7 +5,7 @@ namespace Wallabag\ImportBundle\Consumer;
|
|||
use OldSound\RabbitMqBundle\RabbitMq\ConsumerInterface;
|
||||
use PhpAmqpLib\Message\AMQPMessage;
|
||||
|
||||
class AMPQEntryConsumer extends AbstractConsumer implements ConsumerInterface
|
||||
class AMQPEntryConsumer extends AbstractConsumer implements ConsumerInterface
|
||||
{
|
||||
/**
|
||||
* {@inheritdoc}
|
|
@ -1,28 +1,28 @@
|
|||
# RabbitMQ stuff
|
||||
services:
|
||||
wallabag_import.consumer.ampq.pocket:
|
||||
class: Wallabag\ImportBundle\Consumer\AMPQEntryConsumer
|
||||
wallabag_import.consumer.amqp.pocket:
|
||||
class: Wallabag\ImportBundle\Consumer\AMQPEntryConsumer
|
||||
arguments:
|
||||
- "@doctrine.orm.entity_manager"
|
||||
- "@wallabag_user.user_repository"
|
||||
- "@wallabag_import.pocket.import"
|
||||
- "@logger"
|
||||
wallabag_import.consumer.ampq.readability:
|
||||
class: Wallabag\ImportBundle\Consumer\AMPQEntryConsumer
|
||||
wallabag_import.consumer.amqp.readability:
|
||||
class: Wallabag\ImportBundle\Consumer\AMQPEntryConsumer
|
||||
arguments:
|
||||
- "@doctrine.orm.entity_manager"
|
||||
- "@wallabag_user.user_repository"
|
||||
- "@wallabag_import.readability.import"
|
||||
- "@logger"
|
||||
wallabag_import.consumer.ampq.wallabag_v1:
|
||||
class: Wallabag\ImportBundle\Consumer\AMPQEntryConsumer
|
||||
wallabag_import.consumer.amqp.wallabag_v1:
|
||||
class: Wallabag\ImportBundle\Consumer\AMQPEntryConsumer
|
||||
arguments:
|
||||
- "@doctrine.orm.entity_manager"
|
||||
- "@wallabag_user.user_repository"
|
||||
- "@wallabag_import.wallabag_v1.import"
|
||||
- "@logger"
|
||||
wallabag_import.consumer.ampq.wallabag_v2:
|
||||
class: Wallabag\ImportBundle\Consumer\AMPQEntryConsumer
|
||||
wallabag_import.consumer.amqp.wallabag_v2:
|
||||
class: Wallabag\ImportBundle\Consumer\AMQPEntryConsumer
|
||||
arguments:
|
||||
- "@doctrine.orm.entity_manager"
|
||||
- "@wallabag_user.user_repository"
|
||||
|
|
|
@ -2,12 +2,12 @@
|
|||
|
||||
namespace Tests\Wallabag\ImportBundle\Consumer\AMQP;
|
||||
|
||||
use Wallabag\ImportBundle\Consumer\AMPQEntryConsumer;
|
||||
use Wallabag\ImportBundle\Consumer\AMQPEntryConsumer;
|
||||
use PhpAmqpLib\Message\AMQPMessage;
|
||||
use Wallabag\UserBundle\Entity\User;
|
||||
use Wallabag\CoreBundle\Entity\Entry;
|
||||
|
||||
class AMPQEntryConsumerTest extends \PHPUnit_Framework_TestCase
|
||||
class AMQPEntryConsumerTest extends \PHPUnit_Framework_TestCase
|
||||
{
|
||||
public function testMessageOk()
|
||||
{
|
||||
|
@ -112,7 +112,7 @@ JSON;
|
|||
->with(json_decode($body, true))
|
||||
->willReturn($entry);
|
||||
|
||||
$consumer = new AMPQEntryConsumer(
|
||||
$consumer = new AMQPEntryConsumer(
|
||||
$em,
|
||||
$userRepository,
|
||||
$import
|
||||
|
@ -157,7 +157,7 @@ JSON;
|
|||
->disableOriginalConstructor()
|
||||
->getMock();
|
||||
|
||||
$consumer = new AMPQEntryConsumer(
|
||||
$consumer = new AMQPEntryConsumer(
|
||||
$em,
|
||||
$userRepository,
|
||||
$import
|
||||
|
@ -212,7 +212,7 @@ JSON;
|
|||
->with(json_decode($body, true))
|
||||
->willReturn(null);
|
||||
|
||||
$consumer = new AMPQEntryConsumer(
|
||||
$consumer = new AMQPEntryConsumer(
|
||||
$em,
|
||||
$userRepository,
|
||||
$import
|
Loading…
Reference in a new issue