Matching supply and demand - Connected Mobility Lens

Matching supply and demand

CMCOST_4: How do you optimize cost by matching backend resources with demand?

Connected vehicle solutions generate a massive amount of data and events, which can quickly become overwhelming for traditional, request-response-based architectures. Event-driven architectures allow for a more scalable solution, as events are processed asynchronously, allowing for faster and more efficient handling of large volumes of events and consume resources only when and if events occur.

[CMCOST_BP4.1] Implement event driven architectures for your backend systems.

Evaluate and select your compute type depending on events processed by your backend systems.

  • Consider using AWS Lambda for events that can be processed asynchronously with one or a cascade of processing steps short lived time (up to 15 minutes) that can be orchestrated with AWS Step Functions. As an example, Lambda are suitable for an API based service such subscription management for a service. Use AWS Step Functions to coordinate serverless workflows. It helps manage and control the execution order of your Lambda functions and other services, reducing the time and resources needed for complex tasks.

  • Consider using containers through Amazon Elastic Kubernetes Service (Amazon EKS) or Amazon Elastic Container Service (Amazon ECS) when you need near real time event processing of large-scale number of events or require more processing time. Both Amazon EKS and Amazon ECS offer AWS Fargate that run your containers serverless without any underlying infrastructure to maintain.

  • As an example, containers are suitable for large number of MQTT messaging based events that needs near real time processing such vehicle diagnose data collection and processing after a defect being detected.

  • Amazon EC2 Spot Instances: For non-critical workloads, consider using EC2 Spot Instances. Spot Instances are available at significantly lower prices compared to On-Demand instances but can be interrupted with short notice when the Spot price exceeds your bid. Use Spot Instances to handle non-time-sensitive tasks and save costs.

  • AWS Cost Explorer and AWS Budgets: Utilize AWS Cost Explorer and AWS Budgets to monitor and analyze your AWS costs. These tools provide insights into spending patterns and can help you identify opportunities for optimization.

  • Finally, for large batch processing AWS Batch that helps you to run batch computing workloads on the AWS Cloud.