Table of contents
AWS SNS-SQS guidelines
Instances of SNS and SQS
Filtering between SNS and SQS
DON’T create filters when subscribing an SQS Queue to an SNS Topic. No filtering is currently allowed on our Cloud infrastructure (message attributes, message payload).
AWS Objects naming
SNS Topic Name
[PlatformSolution]-[Application]-[Domain]-[Entity]-[Event]-[Environment]
SQS Queue Name
[PlatformSolution]-[Application]-[ConsumerService]-[Entity]-[Event]-[Environment]
Variables details
-
[PlatformSolution]: The name and progressive number of the Solution within NextGen Platform (e.g.:s000001). -
[Application]: The name of the application that publishes events to a topic or subscribes to a queue (e.g.:fsm, geo, fsm-water). -
[Domain]: The Domain to which the entity belongs (see NextGen APIs - Domains and Subdomains). -
[Entity]: The name of the REST resource to which the event is referring. If no REST resource exists, please use the name of the underlyingBusinessObject,DTO, of the best human-readable functional name available (e.g.:agenda-outcome). -
[Event]: Which operation has been done in the system, usuallycreated,updated,deleted. -
[Environment]: The type of environment, usuallydev,test,prod. -
[ConsumerService]: Domain or Subdomain that will handle the event listened by the SQS queue (see NextGen APIs - Domains and Subdomains). Alternatively, the best representation of the objective of the SQS queue, it could be external system integration, internal data alignment, a customization, etc.
Example
-
Platform Solution:
s000001 -
Platform Application name:
fsm1 -
Domain:
work-orders -
Entity:
work-orders -
Event:
updated -
Consumer 1:
sap-intgr(an integration service sending data to SAP) -
Consumer 2:
messages(subdomain, in this case a service sending push messages to technicians)
|
Environment |
Resource Type |
Resource Name |
|
DEV |
SNS Topic |
|
|
|
SQS Queue (1) |
|
|
|
SQS Queue (2) |
|
|
|
DLQ (1) |
|
|
TEST |
SNS Topic |
|
|
|
SQS Queue (1) |
|
|
|
SQS Queue (2) |
|
|
PROD |
SNS Topic |
|
|
|
SQS Queue (1) |
|
|
|
SQS Queue (2) |
|