SlideShare a Scribd company logo
1 of 11
MQTT meets AMQP
for reliable messaging
By Haci Murat Yaman 25/6/2023
https://www.linkedin.com/in/muratyaman/
MQTT: Message Queuing Telemetry Transport
“... lightweight messaging protocol designed for efficient communication between
devices in constrained networks”
It is a Pub/Sub protocol.
It is not a message queue.
MQTT: Advantages
● Lightweight and Efficient in terms of bandwidth & processing power
● Persistent Sessions:
○ Clients can maintain their subscriptions and message queues even if they temporarily disconnect from the
broker; this feature ensures message delivery to clients that were offline during a period of unreliable
connectivity. This is misleading!
● Publish/Subscribe Model:
○ Publishers send messages to a broker; subscribers receive messages from the broker.
● Asynchronous Communication:
○ The sender does not need to wait for an immediate response from the receiver.
● Quality of Service (QoS) Levels: This is very misleading!
○ 0 (At most once): Messages are delivered once but may be lost or duplicated.
○ 1 (At least once): Messages are guaranteed to be delivered at least once, but duplicates may occur.
○ 2 (Exactly once): Messages are ensured to be delivered exactly once by using a two-step handshake
process.
● Scalability and Flexibility: a broker handle many devices → suitable for IoT
MQTT: Disadvantages
● Increased Network Overhead:
○ esp. in extremely constrained networks or when dealing with a large number of small messages
● Lack of Built-in Security:
○ Even though it can work over TLS; MQTT applications should implement authentication.
● Potential Message Loss:
○ While higher QoS levels (such as QoS 1 and QoS 2) provide reliability, they can introduce additional
overhead and latency, impacting the overall efficiency of the communication.
● Lack of Standardized Support for Request-Response Communication:
○ Its pub/sub model is primarily designed for asynchronous communication.
● Limited Broker Features:
○ Brokers typically focus on message routing and delivery.
○ Advanced features like message persistence depends on implementation.
● Bandwidth Consumption:
○ In scenarios with extremely low-bandwidth or high-cost data connections, the continuous
transmission of MQTT control packets, keep-alive messages, and subscription updates can impact
the overall data consumption.
AMQP: Advanced Message Queuing Protocol
“... a messaging protocol that provides a reliable and flexible means of
communication between applications or components in a distributed system.”
AMQP: Advantages
● Reliable Message Delivery:
○ It uses acknowledgments and delivery confirmations.
● Interoperability:
○ It provides a standard way of exchanging messages
● Scalability:
○ It supports distributed and scalable messaging architectures.
○ We can add more instances of the message broker or message queues.
● Message Routing and Filtering:
○ It provides flexible mechanisms for routing messages such as header-based, topic-based, content-based.
● Security:
○ It includes built-in security features like authentication and authorization mechanisms
● Vendor Neutrality:
○ It is an open and standardized protocol.
● Message Persistence:
○ It supports durable message queues.
● Monitoring and Management:
○ It includes mechanisms for tracking message rates, queue sizes, and other metrics
AMQP: Disadvantages
● Complexity:
○ It can be complex to set up and configure.
○ Learning Curve for Developers: Effort is required to implement message producers and consumers correctly.
○ Operational Complexity: It requires configuring queues, setting up routing rules, monitoring message flows,
and ensuring high availability and fault tolerance.
● Performance Overhead:
○ Robustness and reliability features come with performance overhead; i.e. due to acknowledgments,
confirmations, and message persistence
● Protocol Compatibility:
○ Implementations of senders and receivers may not be compatible.
● Limited Real-Time Messaging:
○ Even though it is capable of handling real-time messaging, it may not be the optimal choice for extremely low-
latency, high-frequency messaging scenarios.
● Scalability Challenges:
○ Managing large-scale deployments with high message volumes requires careful planning, monitoring, and
load balancing to ensure efficient resource utilization and avoid bottlenecks.
● Potential Vendor Lock-In:
○ There is possibility of vendor lock-in if you heavily rely on proprietary extensions or features.
Devices are connected.
Network is stable.
Unstable network
Unstable network
Conclusion
The proof of concept works!
Code repository: https://github.com/muratyaman/mqtt-meets-amqp
But more testing is needed esp. under heavy load.
Could this stack of MQTT & AMQP work better than MQTT or AMQP alone?

More Related Content

Similar to MQTT meets AMQP

IBM MQ: Managing Workloads, Scaling and Availability with MQ Clusters
IBM MQ: Managing Workloads, Scaling and Availability with MQ ClustersIBM MQ: Managing Workloads, Scaling and Availability with MQ Clusters
IBM MQ: Managing Workloads, Scaling and Availability with MQ ClustersDavid Ware
 
Introduction to MQ Telemetry Transport (MQTT)
Introduction to MQ Telemetry Transport (MQTT)Introduction to MQ Telemetry Transport (MQTT)
Introduction to MQ Telemetry Transport (MQTT)Amarjeetsingh Thakur
 
SOA Pattern-Asynchronous Queuing
SOA Pattern-Asynchronous QueuingSOA Pattern-Asynchronous Queuing
SOA Pattern-Asynchronous QueuingWSO2
 
Where next for MQTT?
Where next for MQTT?Where next for MQTT?
Where next for MQTT?Ian Craggs
 
Transport Layer In Computer Network
Transport Layer In Computer NetworkTransport Layer In Computer Network
Transport Layer In Computer NetworkDestro Destro
 
Application Layer Protocols for the IoT
Application Layer Protocols for the IoTApplication Layer Protocols for the IoT
Application Layer Protocols for the IoTDamien Magoni
 
Towards Improved Data Dissemination of Publish-Subscribe Systems
Towards Improved Data Dissemination of Publish-Subscribe SystemsTowards Improved Data Dissemination of Publish-Subscribe Systems
Towards Improved Data Dissemination of Publish-Subscribe SystemsSrinath Perera
 
Low Latency Mobile Messaging using MQTT
Low Latency Mobile Messaging using MQTTLow Latency Mobile Messaging using MQTT
Low Latency Mobile Messaging using MQTTHenrik Sjöstrand
 
IAB-5039 : MQTT: A Protocol for the Internet of Things (InterConnect 2015)
IAB-5039 : MQTT: A Protocol for the Internet of Things (InterConnect 2015)IAB-5039 : MQTT: A Protocol for the Internet of Things (InterConnect 2015)
IAB-5039 : MQTT: A Protocol for the Internet of Things (InterConnect 2015)PeterNiblett
 
Enterprise messaging with jms
Enterprise messaging with jmsEnterprise messaging with jms
Enterprise messaging with jmsSridhar Reddy
 
Choosing the Right Firewall for Your Business.pdf
Choosing the Right Firewall for Your Business.pdfChoosing the Right Firewall for Your Business.pdf
Choosing the Right Firewall for Your Business.pdfInfoRIPRASAITSolutio
 
Ranker jms implementation
Ranker jms implementationRanker jms implementation
Ranker jms implementationEosSoftware
 
mqtt intro short
mqtt intro shortmqtt intro short
mqtt intro shortMahmutERKEN
 
Mqtt(Message queue telemetry protocol) presentation
Mqtt(Message queue telemetry protocol) presentation Mqtt(Message queue telemetry protocol) presentation
Mqtt(Message queue telemetry protocol) presentation Piyush Rathi
 
Introduction to EMQ X Enterprise
Introduction to EMQ X EnterpriseIntroduction to EMQ X Enterprise
Introduction to EMQ X EnterpriseEMQ
 

Similar to MQTT meets AMQP (20)

MODULE-4_CCN.pptx
MODULE-4_CCN.pptxMODULE-4_CCN.pptx
MODULE-4_CCN.pptx
 
AMQP.pdf
AMQP.pdfAMQP.pdf
AMQP.pdf
 
IBM MQ: Managing Workloads, Scaling and Availability with MQ Clusters
IBM MQ: Managing Workloads, Scaling and Availability with MQ ClustersIBM MQ: Managing Workloads, Scaling and Availability with MQ Clusters
IBM MQ: Managing Workloads, Scaling and Availability with MQ Clusters
 
Mqtt
MqttMqtt
Mqtt
 
Introduction to MQ Telemetry Transport (MQTT)
Introduction to MQ Telemetry Transport (MQTT)Introduction to MQ Telemetry Transport (MQTT)
Introduction to MQ Telemetry Transport (MQTT)
 
SOA Pattern-Asynchronous Queuing
SOA Pattern-Asynchronous QueuingSOA Pattern-Asynchronous Queuing
SOA Pattern-Asynchronous Queuing
 
Where next for MQTT?
Where next for MQTT?Where next for MQTT?
Where next for MQTT?
 
AMQP with RabbitMQ
AMQP with RabbitMQAMQP with RabbitMQ
AMQP with RabbitMQ
 
Transport Layer In Computer Network
Transport Layer In Computer NetworkTransport Layer In Computer Network
Transport Layer In Computer Network
 
Application Layer Protocols for the IoT
Application Layer Protocols for the IoTApplication Layer Protocols for the IoT
Application Layer Protocols for the IoT
 
Towards Improved Data Dissemination of Publish-Subscribe Systems
Towards Improved Data Dissemination of Publish-Subscribe SystemsTowards Improved Data Dissemination of Publish-Subscribe Systems
Towards Improved Data Dissemination of Publish-Subscribe Systems
 
Low Latency Mobile Messaging using MQTT
Low Latency Mobile Messaging using MQTTLow Latency Mobile Messaging using MQTT
Low Latency Mobile Messaging using MQTT
 
IAB-5039 : MQTT: A Protocol for the Internet of Things (InterConnect 2015)
IAB-5039 : MQTT: A Protocol for the Internet of Things (InterConnect 2015)IAB-5039 : MQTT: A Protocol for the Internet of Things (InterConnect 2015)
IAB-5039 : MQTT: A Protocol for the Internet of Things (InterConnect 2015)
 
Enterprise messaging with jms
Enterprise messaging with jmsEnterprise messaging with jms
Enterprise messaging with jms
 
Choosing the Right Firewall for Your Business.pdf
Choosing the Right Firewall for Your Business.pdfChoosing the Right Firewall for Your Business.pdf
Choosing the Right Firewall for Your Business.pdf
 
Ranker jms implementation
Ranker jms implementationRanker jms implementation
Ranker jms implementation
 
mqtt intro short
mqtt intro shortmqtt intro short
mqtt intro short
 
RabbitMq
RabbitMqRabbitMq
RabbitMq
 
Mqtt(Message queue telemetry protocol) presentation
Mqtt(Message queue telemetry protocol) presentation Mqtt(Message queue telemetry protocol) presentation
Mqtt(Message queue telemetry protocol) presentation
 
Introduction to EMQ X Enterprise
Introduction to EMQ X EnterpriseIntroduction to EMQ X Enterprise
Introduction to EMQ X Enterprise
 

More from Haci Murat Yaman

The API Journey: GraphQL Specification and Implementation
The API Journey: GraphQL Specification and ImplementationThe API Journey: GraphQL Specification and Implementation
The API Journey: GraphQL Specification and ImplementationHaci Murat Yaman
 
The API Journey: from REST to GraphQL
The API Journey: from REST to GraphQLThe API Journey: from REST to GraphQL
The API Journey: from REST to GraphQLHaci Murat Yaman
 
Node.js System: The Landing
Node.js System: The LandingNode.js System: The Landing
Node.js System: The LandingHaci Murat Yaman
 
Node.js System: The Approach
Node.js System: The ApproachNode.js System: The Approach
Node.js System: The ApproachHaci Murat Yaman
 
The Saga of JavaScript and TypeScript: Part 1
The Saga of JavaScript and TypeScript: Part 1The Saga of JavaScript and TypeScript: Part 1
The Saga of JavaScript and TypeScript: Part 1Haci Murat Yaman
 
The Saga of JavaScript and Typescript: in Deno land
The Saga of JavaScript and Typescript: in Deno landThe Saga of JavaScript and Typescript: in Deno land
The Saga of JavaScript and Typescript: in Deno landHaci Murat Yaman
 

More from Haci Murat Yaman (6)

The API Journey: GraphQL Specification and Implementation
The API Journey: GraphQL Specification and ImplementationThe API Journey: GraphQL Specification and Implementation
The API Journey: GraphQL Specification and Implementation
 
The API Journey: from REST to GraphQL
The API Journey: from REST to GraphQLThe API Journey: from REST to GraphQL
The API Journey: from REST to GraphQL
 
Node.js System: The Landing
Node.js System: The LandingNode.js System: The Landing
Node.js System: The Landing
 
Node.js System: The Approach
Node.js System: The ApproachNode.js System: The Approach
Node.js System: The Approach
 
The Saga of JavaScript and TypeScript: Part 1
The Saga of JavaScript and TypeScript: Part 1The Saga of JavaScript and TypeScript: Part 1
The Saga of JavaScript and TypeScript: Part 1
 
The Saga of JavaScript and Typescript: in Deno land
The Saga of JavaScript and Typescript: in Deno landThe Saga of JavaScript and Typescript: in Deno land
The Saga of JavaScript and Typescript: in Deno land
 

Recently uploaded

Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Igalia
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersThousandEyes
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
Google AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAGGoogle AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAGSujit Pal
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxOnBoard
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Alan Dix
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...HostedbyConfluent
 

Recently uploaded (20)

Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Google AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAGGoogle AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAG
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptx
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
 

MQTT meets AMQP

  • 1. MQTT meets AMQP for reliable messaging By Haci Murat Yaman 25/6/2023 https://www.linkedin.com/in/muratyaman/
  • 2. MQTT: Message Queuing Telemetry Transport “... lightweight messaging protocol designed for efficient communication between devices in constrained networks” It is a Pub/Sub protocol. It is not a message queue.
  • 3. MQTT: Advantages ● Lightweight and Efficient in terms of bandwidth & processing power ● Persistent Sessions: ○ Clients can maintain their subscriptions and message queues even if they temporarily disconnect from the broker; this feature ensures message delivery to clients that were offline during a period of unreliable connectivity. This is misleading! ● Publish/Subscribe Model: ○ Publishers send messages to a broker; subscribers receive messages from the broker. ● Asynchronous Communication: ○ The sender does not need to wait for an immediate response from the receiver. ● Quality of Service (QoS) Levels: This is very misleading! ○ 0 (At most once): Messages are delivered once but may be lost or duplicated. ○ 1 (At least once): Messages are guaranteed to be delivered at least once, but duplicates may occur. ○ 2 (Exactly once): Messages are ensured to be delivered exactly once by using a two-step handshake process. ● Scalability and Flexibility: a broker handle many devices → suitable for IoT
  • 4. MQTT: Disadvantages ● Increased Network Overhead: ○ esp. in extremely constrained networks or when dealing with a large number of small messages ● Lack of Built-in Security: ○ Even though it can work over TLS; MQTT applications should implement authentication. ● Potential Message Loss: ○ While higher QoS levels (such as QoS 1 and QoS 2) provide reliability, they can introduce additional overhead and latency, impacting the overall efficiency of the communication. ● Lack of Standardized Support for Request-Response Communication: ○ Its pub/sub model is primarily designed for asynchronous communication. ● Limited Broker Features: ○ Brokers typically focus on message routing and delivery. ○ Advanced features like message persistence depends on implementation. ● Bandwidth Consumption: ○ In scenarios with extremely low-bandwidth or high-cost data connections, the continuous transmission of MQTT control packets, keep-alive messages, and subscription updates can impact the overall data consumption.
  • 5. AMQP: Advanced Message Queuing Protocol “... a messaging protocol that provides a reliable and flexible means of communication between applications or components in a distributed system.”
  • 6. AMQP: Advantages ● Reliable Message Delivery: ○ It uses acknowledgments and delivery confirmations. ● Interoperability: ○ It provides a standard way of exchanging messages ● Scalability: ○ It supports distributed and scalable messaging architectures. ○ We can add more instances of the message broker or message queues. ● Message Routing and Filtering: ○ It provides flexible mechanisms for routing messages such as header-based, topic-based, content-based. ● Security: ○ It includes built-in security features like authentication and authorization mechanisms ● Vendor Neutrality: ○ It is an open and standardized protocol. ● Message Persistence: ○ It supports durable message queues. ● Monitoring and Management: ○ It includes mechanisms for tracking message rates, queue sizes, and other metrics
  • 7. AMQP: Disadvantages ● Complexity: ○ It can be complex to set up and configure. ○ Learning Curve for Developers: Effort is required to implement message producers and consumers correctly. ○ Operational Complexity: It requires configuring queues, setting up routing rules, monitoring message flows, and ensuring high availability and fault tolerance. ● Performance Overhead: ○ Robustness and reliability features come with performance overhead; i.e. due to acknowledgments, confirmations, and message persistence ● Protocol Compatibility: ○ Implementations of senders and receivers may not be compatible. ● Limited Real-Time Messaging: ○ Even though it is capable of handling real-time messaging, it may not be the optimal choice for extremely low- latency, high-frequency messaging scenarios. ● Scalability Challenges: ○ Managing large-scale deployments with high message volumes requires careful planning, monitoring, and load balancing to ensure efficient resource utilization and avoid bottlenecks. ● Potential Vendor Lock-In: ○ There is possibility of vendor lock-in if you heavily rely on proprietary extensions or features.
  • 11. Conclusion The proof of concept works! Code repository: https://github.com/muratyaman/mqtt-meets-amqp But more testing is needed esp. under heavy load. Could this stack of MQTT & AMQP work better than MQTT or AMQP alone?