Amazon Simple Queue Service (Amazon SQS)

Tushar Joshi
4 min readJul 21, 2021

What is Cloud Computing ?

In the simplest terms, cloud computing means storing and accessing data and programs over the internet instead of your computer’s hard drive or to be specific, “hardware and software services from a provider on the internet.”

Amazon Simple Queue Service…

Amazon Web services hold many services in its package. These services are widely used around the globe to lessen the amount of burden caused due to managing them. One such managed service is SQS, lets get a know-how of the benefits it has to render us.

What is SQS?

  • SQS stands for Simple Queue Service.
  • SQS was the first service available in AWS.
  • Amazon SQS is a web service that gives you access to a message queue that can be used to store messages while waiting for a computer to process them.
  • Amazon SQS is a distributed queue system that enables web service applications to quickly and reliably queue messages that one component in the application generates to be consumed by another component where a queue is a temporary repository for messages that are awaiting processing.
  • With the help of SQS, you can send, store and receive messages between software components at any volume without losing messages.
  • Using Amazon SQS, you can separate the components of an application so that they can run independently, easing message management between components.
  • Any component of a distributed application can store the messages in the queue.
  • Messages can contain up to 256 KB of text in any format such as JSON, XML, etc.
  • Any component of an application can later retrieve the messages programmatically using the Amazon SQS API.
  • The queue acts as a buffer between the component producing and saving data, and the component receives the data for processing. This means that the queue resolves issues that arise if the producer is producing work faster than the consumer can process it, or if the producer or consumer is only intermittently connected to the network.
  • If you got two EC2 instances that are pulling the SQS Queue. You can configure the auto scaling group if a number of messages go over a certain limit. Suppose the number of messages exceeds 10, then you can add an additional EC2 instance to process the job faster. In this way, SQS provides elasticity.

Features of SQS:

Work Queues

Decouple components of a distributed application that may not all process the same amount of work simultaneously.

Buffer and Batch Operations

Add scalability and reliability to the architecture and smooth out temporary volume spikes without losing messages or increasing latency

Request Offloading

Move slow operations off of interactive request paths by enqueueing the request.

Fan-out

Combine SQS with SNS to send identical copies of a message to multiple queues parallel for simultaneous processing.

Auto Scaling

SQS queues can be used to determine the load on an application, and combined with Auto Scaling, the EC2 instances can be scaled in or out, depending on the volume of traffic

Benefits of SQS:

SQS is easy to set up without any overhead: Implementing SQS, there is no upfront cost or administrative cost. It is all configurable in AWS cloud and APIs.

SQL is reliable: Multiple copies of every message are stored redundantly across multiple availability zones so that they are available whenever needed.

SQS is secure: Amazon SQS exchange sensitive data between applications using server-side encryption (SSE) to encrypt each message body. Amazon SQS SSE integration with AWS Key Management Service (KMS).

SQS is scalable and cost-effective: Amazon SQS leverages the AWS cloud to dynamically scale based on demand. There is no limit to the number of messages per queue, and standard queues provide nearly unlimited throughput. Costs are based on usage.

SQS Use Cases:

1) BMW:

The BMW Group is using AWS for its connected car application that collects sensor data from BMW 7 Series cars to give drivers dynamically updated map information. BMW built its new car-as-a-sensor (CARASSO) service in only six months leveraging Amazon SQS, Amazon S3, Amazon DynamoDB, Amazon RDS, and AWS Elastic BeanStalk.

2) RedBus:

RedBus is expanding its AWS solution to include Amazon SQS and SNS for monitoring, alerts, and intercommunication. “Amazon SQS is an especially good solution for enabling messaging between external applications and our applications.”

— Charan Padmaraju, redBus CTO

Companies using SQS service:

Thank You for reading !!!

Keep Learning Keep Sharing !!!

--

--

Tushar Joshi

MLOPS Intern at Linux World || MLOPS 🧠 || DEVOPS(🐳☸👩🏻‍🍳)|| Ansible || Kubernetes|| AWS || ML || DL || Data Science || Jenkins|| Docker || RedHat Linux ||