Need advice about which tool to choose?Ask the StackShare community!
Amazon MQ vs MQTT: What are the differences?
Introduction
Amazon MQ is a fully managed message broker service that makes it easy to set up and operate message brokers in the cloud. MQTT (Message Queuing Telemetry Transport) is a lightweight messaging protocol designed for IoT devices to communicate over unreliable networks.
- Message Broker vs Protocol: Amazon MQ is a message broker service that provides a fully managed solution for handling messages, while MQTT is a messaging protocol that ensures reliable, low-bandwidth communication between IoT devices.
- Protocol Support: Amazon MQ supports various messaging protocols, including MQTT, while MQTT is specifically designed for lightweight, publish-subscribe messaging scenarios.
- Message Persistence: Amazon MQ stores messages durably by default, ensuring that messages are not lost in case of failures, while MQTT does not guarantee message persistence unless a reliable messaging infrastructure is implemented by the client.
- Scalability: Amazon MQ is a fully managed service that automatically scales resources to handle message traffic, while MQTT requires manual configuration and monitoring to scale efficiently.
- Security: Amazon MQ provides built-in security features, such as authentication, authorization, and encryption, to protect messages and ensure secure communication, while MQTT requires additional security measures to be implemented by the client, such as SSL/TLS encryption and authentication.
- Integration with Other Services: Amazon MQ can easily integrate with other AWS services, such as Amazon SNS, Amazon SQS, and AWS Lambda, providing a comprehensive messaging solution, whereas MQTT integration with other services may require additional middleware or custom development.
In Summary, Amazon MQ is a managed message broker service that supports various messaging protocols, including MQTT, while MQTT is a lightweight messaging protocol specifically designed for IoT devices, with additional considerations needed for scalability and security.
I want to schedule a message. Amazon SQS provides a delay of 15 minutes, but I want it in some hours.
Example: Let's say a Message1 is consumed by a consumer A but somehow it failed inside the consumer. I would want to put it in a queue and retry after 4hrs. Can I do this in Amazon MQ? I have seen in some Amazon MQ videos saying scheduling messages can be done. But, I'm not sure how.
Mithiridi, I believe you are talking about two different things. 1. If you need to process messages with delays of more 15m or at specific times, it's not a good idea to use queues, independently of tool SQM, Rabbit or Amazon MQ. you should considerer another approach using a scheduled job. 2. For dead queues and policy retries RabbitMQ, for example, doesn't support your use case. https://medium.com/@kiennguyen88/rabbitmq-delay-retry-schedule-with-dead-letter-exchange-31fb25a440fc I'm not sure if that is possible SNS/SQS support, they have a maximum delay for delivery (maxDelayTarget) in seconds but it's not clear the number. You can check this out: https://docs.aws.amazon.com/sns/latest/dg/sns-message-delivery-retries.html
Pros of Amazon MQ
- Supports low IQ developers7
- Supports existing protocols (JMS, NMS, AMQP, STOMP, …)3
- Easy to migrate existing messaging service2
Pros of MQTT
- Varying levels of Quality of Service to fit a range of3
- Lightweight with a relatively small data footprint2
- Very easy to configure and use with open source tools2
Sign up to add or upvote prosMake informed product decisions
Cons of Amazon MQ
- Slow AF4
Cons of MQTT
- Easy to configure in an unsecure manner1