magento / architecture

A place where Magento architectural discussions happen
275 stars 153 forks source link

feat(message-queue): adds design for first-class queue configuration #432

Closed damienwebdev closed 4 years ago

damienwebdev commented 4 years ago

Problem

Solution

This proposal exposes a first class "queue" object in queue_topology.xml and provides backwards compatability for prior versions of Magento before this change.

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework-message-queue:etc/topology.xsd">
    <exchange name="inbox.mdc" type="topic" connection="amqp">
        <binding id="someBinding"
                 topic="some.topic.name"
                 destinationType="queue"
                 destination="some-queue"/>
    </exchange>
    <queue name="some-queue" connection="amqp">
        <arguments>
           <argument name="x-message-ttl" xsi:type="string">arg-value</argument>
           <argument name="x-dead-letter-exchange" xsi:type="string">my-dlx</argument>
       </arguments>
    </queue>
</config>

Requested Reviewers

@paliarush @maghamed @nuzil

nrkapoor commented 4 years ago

@mslabko @kandy @maghamed

paliarush commented 4 years ago

Presented on Dev Guild, no objections or comments.