Simple Notification Service (SNS) / Simple Queue Service (SQS) Flashcards
- Amazon SNS supports encrypted topics. When you publish messages to encrypted topics Amazon SNS uses “…this service…” to encrypt your messages
Customer master keys (CMK), powered by AWS KMS
True or False, with SNS the subscriber decides what format they get the message in
True
In SNS, What are some common endpoints for subscriptions?
- “HTTPs and HTTPs”: create webhooks into your web-application
- “Email”: good for internal email notifications (only supports plain text)
- “Amazon SQS”: place SNS message into SQS queue
- “Email-JSON”: sends you json via email
- “AWS Lambda”: triggers a lambda function
- “SMS”: send a text message
- “Platform application endpoints”: Mobile Push
How many topics can each subscription subscribe to?
1
Sending push notifications directly to apps on mobile devices is known as what
Application As Subscriber
This is a fully managed pub/sub messaging service
Simple Notification Service (SNS)
Publishers use the AWS API via ___ or ___ to push messages to a topic. Many AWS services integrate with SNS and act as publishers.
AWS CLI or SDK
Is SQS Push or Pull based?
Pull based
You publish messages to SQS using this AWS component
AWS SDK
When using the Extended Java Client Library what is the maximum message size?
2GB
What is the minimum size of a message?
1 byte
In SQS What are the 2 available types of queues?
- FIFO Queues
- Standard Queue
Which queue type supports multiple ordered message groups within a single queue?
FIFO Queue
AWS SQS First-In-First-Out queues support multiple ordered message groups within a single queue. Limited to 300 transactions per second. SWS FIFO queues have all the same capabilities of a Standard Queue
SQS message queues guarantee a message will be delivered how many times
kjuz ˌgɛrənˈti
“at least” once
Queue type that supports multiple ordered message groups within a single queue
FIFO Queue
SQS
What is the maximum visibility timeout period you can set?
(ˌvɪzəˈbɪlɪti)
12 Hours
SQS
How long is the default visibility timeout period?
0 Seconds
30 Seconds (Default)
12 Hours
Visibility timeout sets the length of time that a message received from a queue (by one consumer) will not be visible to the other message consumers.
SQS
The minimum visibility timeout period possible for messages
Amazon SQS doesn’t automatically delete the message. Because Amazon SQS is a distributed system, there’s no guarantee that the consumer actually receives the message (for example, due to a connectivity issue, or due to an issue in the consumer application). Thus, the consumer must delete the message
0 seconds
To prevent other consumers from processing the message again, Amazon SQS sets a visibility timeout, a period of time during which Amazon SQS prevents other consumers from receiving and processing the message. The default visibility timeout for a message is 30 seconds. The minimum is 0 seconds. The maximum is 12 hours.
SQS
Which polling method should you use if you need a message right away (immediately)?
Short polling
SQS
Which polling method will help you to reduce costs?
Long Polling
SQS
What is the default polling method?
Short polling
SQS
What type of polling returns messages immediately, even if the message queue being polled is empty?
Short polling
SQS
What type of polling waits until a message arrives in the queue before polling?
Long Polling
SQS can retain messages from ___ to ___ and by default is ___
Amazon SQS automatically deletes messages that have been in a queue for more than the maximum message retention period. You can set the message retention period using the SetQueueAttributes action.
- 1m
- 4 days (Default)
- 14 days
What is SQS?
What are its 5 elements?
- It’s a message queuing service that enables you to decouple and scale microservices, distributed systems, and serverless applications for application integration
- Types of Queues (Standard and First-In-First-Out)
- Polling types (Short and Long)
- Visibility time-out (0, 30s*, 12h)
- Retaining time (1m, 4d*, 14d)
- Message size (1b - 256kb) with JAVA (2 Gb)
What is SNS?
What are its 5 elements?
- It’s apub/sub messaging service for application integration
- Topics
- Publishers
- Subscriptions
- Protocols (HTTP,Email, SQS, Lambda, SMS)
- Application as subscriber (Send push notifications)