> For the complete documentation index, see [llms.txt](https://mamawhocode.gitbook.io/aws/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://mamawhocode.gitbook.io/aws/services/integration/mq.md).

# MQ

message broker service

[Document](https://docs.aws.amazon.com/amazon-mq/index.html?nc2=type_a) | [Migration guide](https://docs.aws.amazon.com/amazon-mq/latest/migration-guide/concept-chapter-about.html)

## Overview

* managed message broker service for
  * RabbitMQ
  * ActiveMQ
  * IBM MQ
* It replaces natvie SNS and SQS, so have both feature: queue & topic

### Why MQ?

* SNS and SQS are cloud-native
* On-premises using: MQTT, AMQP, STOMP, Openwire, WSS
* when migrate to the cloud, instead of re-engineering the app to use SNS or SQS, we can use Amazon MQ

### Draw back

* Does not scale as much as SNS/SQS
* Amazon MQ run on servers, can run Multi-AZ for failover

## Fail-over

* Set up Multi-AZ for fail-over, using a Standby server & Amazon EFS for storage.&#x20;

  <figure><img src="https://2259236002-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fuh9xZDZ53qGqmMCM44PU%2Fuploads%2Fgit-blob-dc19e126267633d988a96fd11a266fd259232dbe%2Ffigure_20230506142905.png?alt=media" alt=""><figcaption></figcaption></figure>
