Simple Queue Service (SQS)
Learn how SQS, SNS, and Kenesis work in general and together.
What is SQS?
SQS is a web service that gives you access to a message queue that can be used to store messages while waiting for the messages to process them. It is a distributed queue system that enables web service applications to quickly and reliably queue messages that one component in the application generates and another consumes.
In other words, a queue is a temporary repository for messages that are awaiting process.
You can also think of SQS as a buffer between two components, producing data and a component consuming data. This means that a queue consumes data. This means that a queue could potentially resolve issues that come about when a producer is producing at a larger rate than what the consumer can handle.
Queues types
There are two types of queues:
- Standard (default)
- FIFO
Standard queues
Standard queues let you have nearly an unlimited number of transactions per second. Standard queues guarantee that a message is delivered at least once. They also provide best-effort ordering which ensures that messages are gradually delivered in the same order as they are received.
FIFO queues
The most important feature of the FIFO (First In First Out) queue is the first in first out delivery coupled with exactly-once processing.
The order in which messages are sent and received are strictly preserved and a message is delivered once and remains available until a consumer processes it and deletes it.
SQS – is a pull-based queue
The below outlines the parts of a distributed messaging system and explains the lifecycle of an Amazon SQS message.
Create a free account to view this lesson.
Continue your learning journey with a 14-day free trial.
By signing up, you agree to Educative's Terms of Service and Privacy Policy