Simple Message Queue (SMQ, formerly MNS) has become the preferred message transmission channel for many Alibaba Cloud products due to its simple queue-based messaging model, lightweight protocol, and pay-as-you-go billing model. Additionally, its lossless publishing capability and high availability in multi-zone ensure reliable message transmission between cloud products and between cloud products and user applications. This topic introduces typical scenarios where SMQ acts as a message channel between cloud products.
Scenario 1: Use cloud product events subscribed by queues and asynchronous task execution results to process subsequent businesses
Scenario | Description |
After Object Storage Service (OSS) events are pushed to an SMQ queue or topic, the developer service consumes the messages for subsequent business processing. | |
After alert events are written to an SMQ queue or topic, consumer applications consume these messages to implement automated processing based on business logic. | |
After scaling group dynamics are written to an SMQ queue or topic, consumer applications consume these messages to implement automated processing based on business logic. | |
After the callback content is written to an SMQ queue, obtain the progress and status of the task by consuming SMQ queue messages. |
Scenario 2: Trigger task or function execution through messages
Scenario | Description |
Use the queue or topic of SMQ as the event source for triggering function execution. The message that meets the rules defined by the trigger will automatically invoke the function associated with the trigger. | |
You can use the queue of SMQ as the event source for the event stream to trigger the execution of the event stream. |
Scenario 3: Message communication between user applications and cloud products
Scenario | Description |
When complex or fine-grained processing of device data is required, user applications send device messages to SMQ for consumption, and IoT Platform consume queue messages to obtain device event information. | |
After the data or result data during function execution is delivered to an SMQ queue, user applications consume the queue messages to implement automated processing based on business logic. |