@@ -32,7 +32,7 @@ final class SendMessageRequest extends Input
32
32
* ! `#x9` | `#xA` | `#xD` | `#x20` to `#xD7FF` | `#xE000` to `#xFFFD` | `#x10000` to `#x10FFFF`
33
33
* !
34
34
* ! Amazon SQS does not throw an exception or completely reject the message if it contains invalid characters. Instead,
35
- * ! it replaces those invalid characters with ` U+FFFD` before storing the message in the queue, as long as the message
35
+ * ! it replaces those invalid characters with U+FFFD before storing the message in the queue, as long as the message
36
36
* ! body contains at least one valid character.
37
37
*
38
38
* [^1]: http://www.w3.org/TR/REC-xml/#charsets
@@ -123,27 +123,37 @@ final class SendMessageRequest extends Input
123
123
private $ messageDeduplicationId ;
124
124
125
125
/**
126
- * This parameter applies only to FIFO (first-in-first-out) queues.
126
+ * `MessageGroupId` is an attribute used in Amazon SQS FIFO (First-In-First-Out) and standard queues. In FIFO queues,
127
+ * `MessageGroupId` organizes messages into distinct groups. Messages within the same message group are always processed
128
+ * one at a time, in strict order, ensuring that no two messages from the same group are processed simultaneously. In
129
+ * standard queues, using `MessageGroupId` enables fair queues. It is used to identify the tenant a message belongs to,
130
+ * helping maintain consistent message dwell time across all tenants during noisy neighbor events. Unlike FIFO queues,
131
+ * messages with the same `MessageGroupId` can be processed in parallel, maintaining the high throughput of standard
132
+ * queues.
133
+ *
134
+ * - **FIFO queues:**`MessageGroupId` acts as the tag that specifies that a message belongs to a specific message group.
135
+ * Messages that belong to the same message group are processed in a FIFO manner (however, messages in different
136
+ * message groups might be processed out of order). To interleave multiple ordered streams within a single queue, use
137
+ * `MessageGroupId` values (for example, session data for multiple users). In this scenario, multiple consumers can
138
+ * process the queue, but the session data of each user is processed in a FIFO fashion.
127
139
*
128
- * The tag that specifies that a message belongs to a specific message group. Messages that belong to the same message
129
- * group are processed in a FIFO manner (however, messages in different message groups might be processed out of order).
130
- * To interleave multiple ordered streams within a single queue, use `MessageGroupId` values (for example, session data
131
- * for multiple users). In this scenario, multiple consumers can process the queue, but the session data of each user is
132
- * processed in a FIFO fashion.
140
+ * If you do not provide a `MessageGroupId` when sending a message to a FIFO queue, the action fails.
133
141
*
134
- * - You must associate a non-empty `MessageGroupId` with a message. If you don't provide a `MessageGroupId`, the action
135
- * fails.
136
- * - `ReceiveMessage` might return messages with multiple `MessageGroupId` values. For each `MessageGroupId`, the
137
- * messages are sorted by time sent. The caller can't specify a `MessageGroupId`.
142
+ * `ReceiveMessage` might return messages with multiple `MessageGroupId` values. For each `MessageGroupId`, the
143
+ * messages are sorted by time sent.
144
+ * - **Standard queues:**Use `MessageGroupId` in standard queues to enable fair queues. The `MessageGroupId` identifies
145
+ * the tenant a message belongs to. A tenant can be any entity that shares a queue with others, such as your customer,
146
+ * a client application, or a request type. When one tenant sends a disproportionately large volume of messages or has
147
+ * messages that require longer processing time, fair queues ensure other tenants' messages maintain low dwell time.
148
+ * This preserves quality of service for all tenants while maintaining the scalability and throughput of standard
149
+ * queues. We recommend that you include a `MessageGroupId` in all messages when using fair queues.
138
150
*
139
- * The maximum length of `MessageGroupId` is 128 characters. Valid values: alphanumeric characters and punctuation
151
+ * The length of `MessageGroupId` is 128 characters. Valid values: alphanumeric characters and punctuation
140
152
* `(!"#$%&'()*+,-./:;<=>?@[\]^_`{|}~)`.
141
153
*
142
154
* For best practices of using `MessageGroupId`, see Using the MessageGroupId Property [^1] in the *Amazon SQS Developer
143
155
* Guide*.
144
156
*
145
- * ! `MessageGroupId` is required for FIFO queues. You can't use it for Standard queues.
146
- *
147
157
* [^1]: https://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/using-messagegroupid-property.html
148
158
*
149
159
* @var string|null
0 commit comments