Which solution will meet these requirements?
Create an Application Load Balancer (ALB) and an Auto Scaling group for the MQTT broker. Use the Auto Scaling group as the target for the ALB. Update the DNS record in Route 53 to an alias record. Point the alias record to the ALB. Use the MQTT broker to store the data.
Set up AWS IoT Core to receive the sensor data. Create and configure a custom domain to connect to AWS IoT Core. Update the DNS record in Route 53 to point to the AWS IoT Core Data-ATS endpoint. Configure an AWS IoT rule to store the data.
Create a Network Load Balancer (NLB). Set the MQTT broker as the target. Create an AWS Global Accelerator accelerator. Set the NLB as the endpoint for the accelerator. Update the DNS record in Route 53 to a multivalue answer record. Set the Global Accelerator IP addresses as values. Use the MQTT broker to store the data.
Set up AWS IoT Greengrass to receive the sensor data. Update the DNS record in Route 53 to point to the AWS IoT Greengrass endpoint. Configure an AWS IoT rule to invoke an AWS Lambda function to store the data.
Explanations:
While using an Application Load Balancer (ALB) with an Auto Scaling group can help distribute the load among multiple instances of the MQTT broker, it does not address the core issue of message handling and data loss effectively. MQTT brokers are typically stateful and require specific configurations for scaling, which might not be efficiently handled by a generic ALB setup. Additionally, using a custom MQTT broker may still face issues with scaling under heavy loads compared to purpose-built services.
AWS IoT Core is a fully managed service specifically designed to handle large volumes of IoT messages securely and reliably. It provides automatic scaling, high availability, and features like message buffering, which would directly address the problem of data overload and loss from the MQTT broker. By creating a custom domain for AWS IoT Core and updating Route 53, the sensors can connect to a robust service designed for handling IoT data. AWS IoT rules can be configured to store data directly into DynamoDB, improving reliability and reducing the need for manual management of the MQTT broker.
Setting up a Network Load Balancer (NLB) for the MQTT broker might improve some aspects of connectivity, but it does not inherently solve the problem of handling large amounts of data and potential data loss. The NLB would simply distribute traffic without addressing the broker’s limitations. Moreover, integrating with AWS Global Accelerator adds complexity without directly enhancing the MQTT broker’s capacity to handle data, and still relies on the same broker architecture that has already proven to be unreliable.
AWS IoT Greengrass is designed for edge computing and may not be the best solution for handling large-scale data collection from millions of sensors. Although it allows local processing of data and can send data to AWS services, it does not address the core issue of scaling for millions of concurrent connections as efficiently as AWS IoT Core. Also, the need to configure AWS IoT rules and Lambda functions adds unnecessary complexity compared to the direct handling of messages by AWS IoT Core.