Skip to content

Commit f2a7df0

Browse files
Update generated code (#1823)
* update generated code * Update src/Service/Comprehend/CHANGELOG.md --------- Co-authored-by: Jérémy Derussé <[email protected]>
1 parent c1255c7 commit f2a7df0

10 files changed

+81
-46
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
## NOT RELEASED
44

5+
### Added
6+
7+
- AWS enhancement: In-flight message typo fix from 20k to 120k.
8+
59
## 2.2.1
610

711
### Changed

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
},
2929
"extra": {
3030
"branch-alias": {
31-
"dev-master": "2.2-dev"
31+
"dev-master": "2.3-dev"
3232
}
3333
}
3434
}

src/Exception/InvalidAddressException.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
use AsyncAws\Core\Exception\Http\ClientException;
66

77
/**
8-
* The `accountId` is invalid.
8+
* The specified ID is invalid.
99
*/
1010
final class InvalidAddressException extends ClientException
1111
{

src/Exception/InvalidSecurityException.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
use AsyncAws\Core\Exception\Http\ClientException;
66

77
/**
8-
* When the request to a queue is not HTTPS and SigV4.
8+
* The request was not made over HTTPS or did not use SigV4 for signing.
99
*/
1010
final class InvalidSecurityException extends ClientException
1111
{

src/Exception/QueueDoesNotExistException.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
use AsyncAws\Core\Exception\Http\ClientException;
66

77
/**
8-
* The specified queue doesn't exist.
8+
* Ensure that the `QueueUrl` is correct and that the queue has not been deleted.
99
*/
1010
final class QueueDoesNotExistException extends ClientException
1111
{

src/Exception/RequestThrottledException.php

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,11 @@
77
/**
88
* The request was denied due to request throttling.
99
*
10-
* - The rate of requests per second exceeds the Amazon Web Services KMS request quota for an account and Region.
11-
* - A burst or sustained high rate of requests to change the state of the same KMS key. This condition is often known
12-
* as a "hot key."
13-
* - Requests for operations on KMS keys in a Amazon Web Services CloudHSM key store might be throttled at a
14-
* lower-than-expected rate when the Amazon Web Services CloudHSM cluster associated with the Amazon Web Services
15-
* CloudHSM key store is processing numerous commands, including those unrelated to the Amazon Web Services CloudHSM
16-
* key store.
10+
* - Exceeds the permitted request rate for the queue or for the recipient of the request.
11+
* - Ensure that the request rate is within the Amazon SQS limits for sending messages. For more information, see Amazon
12+
* SQS quotas [^1] in the *Amazon SQS Developer Guide*.
13+
*
14+
* [^1]: https://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/sqs-quotas.html#quotas-requests
1715
*/
1816
final class RequestThrottledException extends ClientException
1917
{

src/Exception/TooManyEntriesInBatchRequestException.php

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,13 @@
55
use AsyncAws\Core\Exception\Http\ClientException;
66

77
/**
8-
* The batch request contains more entries than permissible.
8+
* The batch request contains more entries than permissible. For Amazon SQS, the maximum number of entries you can
9+
* include in a single SendMessageBatch [^1], DeleteMessageBatch [^2], or ChangeMessageVisibilityBatch [^3] request is
10+
* 10.
11+
*
12+
* [^1]: https://docs.aws.amazon.com/AWSSimpleQueueService/latest/APIReference/API_SendMessageBatch.html
13+
* [^2]: https://docs.aws.amazon.com/AWSSimpleQueueService/latest/APIReference/API_DeleteMessageBatch.html
14+
* [^3]: https://docs.aws.amazon.com/AWSSimpleQueueService/latest/APIReference/API_ChangeMessageVisibilityBatch.html
915
*/
1016
final class TooManyEntriesInBatchRequestException extends ClientException
1117
{

src/Input/GetQueueUrlRequest.php

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,14 @@
77
use AsyncAws\Core\Request;
88
use AsyncAws\Core\Stream\StreamFactory;
99

10+
/**
11+
* Retrieves the URL of an existing queue based on its name and, optionally, the Amazon Web Services account ID.
12+
*/
1013
final class GetQueueUrlRequest extends Input
1114
{
1215
/**
13-
* The name of the queue whose URL must be fetched. Maximum 80 characters. Valid values: alphanumeric characters,
14-
* hyphens (`-`), and underscores (`_`).
15-
*
16-
* Queue URLs and names are case-sensitive.
16+
* (Required) The name of the queue for which you want to fetch the URL. The name can be up to 80 characters long and
17+
* can include alphanumeric characters, hyphens (-), and underscores (_). Queue URLs and names are case-sensitive.
1718
*
1819
* @required
1920
*
@@ -22,7 +23,8 @@ final class GetQueueUrlRequest extends Input
2223
private $queueName;
2324

2425
/**
25-
* The Amazon Web Services account ID of the account that created the queue.
26+
* (Optional) The Amazon Web Services account ID of the account that created the queue. This is only required when you
27+
* are attempting to access a queue owned by another Amazon Web Services account.
2628
*
2729
* @var string|null
2830
*/

src/Input/ReceiveMessageRequest.php

Lines changed: 26 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@
88
use AsyncAws\Core\Stream\StreamFactory;
99
use AsyncAws\Sqs\Enum\MessageSystemAttributeName;
1010

11+
/**
12+
* Retrieves one or more messages from a specified queue.
13+
*/
1114
final class ReceiveMessageRequest extends Input
1215
{
1316
/**
@@ -84,7 +87,27 @@ final class ReceiveMessageRequest extends Input
8487

8588
/**
8689
* The duration (in seconds) that the received messages are hidden from subsequent retrieve requests after being
87-
* retrieved by a `ReceiveMessage` request.
90+
* retrieved by a `ReceiveMessage` request. If not specified, the default visibility timeout for the queue is used,
91+
* which is 30 seconds.
92+
*
93+
* Understanding `VisibilityTimeout`:
94+
*
95+
* - When a message is received from a queue, it becomes temporarily invisible to other consumers for the duration of
96+
* the visibility timeout. This prevents multiple consumers from processing the same message simultaneously. If the
97+
* message is not deleted or its visibility timeout is not extended before the timeout expires, it becomes visible
98+
* again and can be retrieved by other consumers.
99+
* - Setting an appropriate visibility timeout is crucial. If it's too short, the message might become visible again
100+
* before processing is complete, leading to duplicate processing. If it's too long, it delays the reprocessing of
101+
* messages if the initial processing fails.
102+
* - You can adjust the visibility timeout using the `--visibility-timeout` parameter in the `receive-message` command
103+
* to match the processing time required by your application.
104+
* - A message that isn't deleted or a message whose visibility isn't extended before the visibility timeout expires
105+
* counts as a failed receive. Depending on the configuration of the queue, the message might be sent to the
106+
* dead-letter queue.
107+
*
108+
* For more information, see Visibility Timeout [^1] in the *Amazon SQS Developer Guide*.
109+
*
110+
* [^1]: https://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/sqs-visibility-timeout.html
88111
*
89112
* @var int|null
90113
*/
@@ -93,7 +116,8 @@ final class ReceiveMessageRequest extends Input
93116
/**
94117
* The duration (in seconds) for which the call waits for a message to arrive in the queue before returning. If a
95118
* message is available, the call returns sooner than `WaitTimeSeconds`. If no messages are available and the wait time
96-
* expires, the call does not return a message list.
119+
* expires, the call does not return a message list. If you are using the Java SDK, it returns a
120+
* `ReceiveMessageResponse` object, which has a empty list instead of a Null object.
97121
*
98122
* ! To avoid HTTP errors, ensure that the HTTP response timeout for `ReceiveMessage` requests is longer than the
99123
* ! `WaitTimeSeconds` parameter. For example, with the Java SDK, you can set HTTP transport settings using the

src/SqsClient.php

Lines changed: 28 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ public function addPermission($input): Result
157157
* from the queue after they're processed. You can also increase the number of queues you use to process your messages.
158158
* To request a limit increase, file a support request [^2].
159159
*
160-
* For FIFO queues, there can be a maximum of 20,000 in flight messages (received from a queue by a consumer, but not
160+
* For FIFO queues, there can be a maximum of 120,000 in flight messages (received from a queue by a consumer, but not
161161
* yet deleted from the queue). If you reach this limit, Amazon SQS returns no error messages.
162162
*
163163
* ! If you attempt to set the `VisibilityTimeout` to a value greater than the maximum time left, Amazon SQS returns an
@@ -268,20 +268,25 @@ public function changeMessageVisibilityBatch($input): ChangeMessageVisibilityBat
268268
*
269269
* > After you create a queue, you must wait at least one second after the queue is created to be able to use the queue.
270270
*
271-
* To get the queue URL, use the `GetQueueUrl` action. `GetQueueUrl` requires only the `QueueName` parameter. be aware
272-
* of existing queue names:
271+
* To retrieve the URL of a queue, use the `GetQueueUrl` [^3] action. This action only requires the `QueueName` [^4]
272+
* parameter.
273273
*
274-
* - If you provide the name of an existing queue along with the exact names and values of all the queue's attributes,
275-
* `CreateQueue` returns the queue URL for the existing queue.
276-
* - If the queue name, attribute names, or attribute values don't match an existing queue, `CreateQueue` returns an
277-
* error.
274+
* When creating queues, keep the following points in mind:
275+
*
276+
* - If you specify the name of an existing queue and provide the exact same names and values for all its attributes,
277+
* the `CreateQueue` [^5] action will return the URL of the existing queue instead of creating a new one.
278+
* - If you attempt to create a queue with a name that already exists but with different attribute names or values, the
279+
* `CreateQueue` action will return an error. This ensures that existing queues are not inadvertently altered.
278280
*
279281
* > Cross-account permissions don't apply to this action. For more information, see Grant cross-account permissions to
280-
* > a role and a username [^3] in the *Amazon SQS Developer Guide*.
282+
* > a role and a username [^6] in the *Amazon SQS Developer Guide*.
281283
*
282284
* [^1]: https://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/FIFO-queues.html#FIFO-queues-moving
283285
* [^2]: https://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/limits-queues.html
284-
* [^3]: https://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/sqs-customer-managed-policy-examples.html#grant-cross-account-permissions-to-role-and-user-name
286+
* [^3]: https://docs.aws.amazon.com/AWSSimpleQueueService/latest/APIReference/API_GetQueueUrl.html
287+
* [^4]: https://docs.aws.amazon.com/AWSSimpleQueueService/latest/APIReference/API_CreateQueue.html#API_CreateQueue_RequestSyntax
288+
* [^5]: https://docs.aws.amazon.com/AWSSimpleQueueService/latest/APIReference/API_CreateQueue.html
289+
* [^6]: https://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/sqs-customer-managed-policy-examples.html#grant-cross-account-permissions-to-role-and-user-name
285290
*
286291
* @see https://docs.aws.amazon.com/AWSSimpleQueueService/latest/APIReference/API_CreateQueue.html
287292
* @see https://docs.aws.amazon.com/aws-sdk-php/v3/api/api-sqs-2012-11-05.html#createqueue
@@ -325,10 +330,11 @@ public function createQueue($input): CreateQueueResult
325330
* a queue even if a visibility timeout setting causes the message to be locked by another consumer. Amazon SQS
326331
* automatically deletes messages left in a queue longer than the retention period configured for the queue.
327332
*
328-
* > The `ReceiptHandle` is associated with a *specific instance* of receiving a message. If you receive a message more
329-
* > than once, the `ReceiptHandle` is different each time you receive a message. When you use the `DeleteMessage`
330-
* > action, you must provide the most recently received `ReceiptHandle` for the message (otherwise, the request
331-
* > succeeds, but the message will not be deleted).
333+
* > Each time you receive a message, meaning when a consumer retrieves a message from the queue, it comes with a unique
334+
* > `ReceiptHandle`. If you receive the same message more than once, you will get a different `ReceiptHandle` each
335+
* > time. When you want to delete a message using the `DeleteMessage` action, you must use the `ReceiptHandle` from the
336+
* > most recent time you received the message. If you use an old `ReceiptHandle`, the request will succeed, but the
337+
* > message might not be deleted.
332338
* >
333339
* > For standard queues, it is possible to receive a message even after you delete it. This might happen on rare
334340
* > occasions if one of the servers which stores a copy of the message is unavailable when you send the request to
@@ -499,12 +505,13 @@ public function getQueueAttributes($input): GetQueueAttributesResult
499505
}
500506

501507
/**
502-
* Returns the URL of an existing Amazon SQS queue.
508+
* The `GetQueueUrl` API returns the URL of an existing Amazon SQS queue. This is useful when you know the queue's name
509+
* but need to retrieve its URL for further operations.
503510
*
504-
* To access a queue that belongs to another AWS account, use the `QueueOwnerAWSAccountId` parameter to specify the
505-
* account ID of the queue's owner. The queue's owner must grant you permission to access the queue. For more
506-
* information about shared queue access, see `AddPermission` or see Allow Developers to Write Messages to a Shared
507-
* Queue [^1] in the *Amazon SQS Developer Guide*.
511+
* To access a queue owned by another Amazon Web Services account, use the `QueueOwnerAWSAccountId` parameter to specify
512+
* the account ID of the queue's owner. Note that the queue owner must grant you the necessary permissions to access the
513+
* queue. For more information about accessing shared queues, see the `AddPermission` API or Allow developers to write
514+
* messages to a shared queue [^1] in the *Amazon SQS Developer Guide*.
508515
*
509516
* [^1]: https://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/sqs-writing-an-sqs-policy.html#write-messages-to-shared-queue
510517
*
@@ -650,8 +657,8 @@ public function queueExists($input): QueueExistsWaiter
650657
* long-poll support. For more information, see Amazon SQS Long Polling [^1] in the *Amazon SQS Developer Guide*.
651658
*
652659
* Short poll is the default behavior where a weighted random set of machines is sampled on a `ReceiveMessage` call.
653-
* Thus, only the messages on the sampled machines are returned. If the number of messages in the queue is small (fewer
654-
* than 1,000), you most likely get fewer messages than you requested per `ReceiveMessage` call. If the number of
660+
* Therefore, only the messages on the sampled machines are returned. If the number of messages in the queue is small
661+
* (fewer than 1,000), you most likely get fewer messages than you requested per `ReceiveMessage` call. If the number of
655662
* messages in the queue is extremely small, you might not receive any messages in a particular `ReceiveMessage`
656663
* response. If this happens, repeat the request.
657664
*
@@ -669,20 +676,14 @@ public function queueExists($input): QueueExistsWaiter
669676
*
670677
* You can provide the `VisibilityTimeout` parameter in your request. The parameter is applied to the messages that
671678
* Amazon SQS returns in the response. If you don't include the parameter, the overall visibility timeout for the queue
672-
* is used for the returned messages. For more information, see Visibility Timeout [^4] in the *Amazon SQS Developer
673-
* Guide*.
674-
*
675-
* A message that isn't deleted or a message whose visibility isn't extended before the visibility timeout expires
676-
* counts as a failed receive. Depending on the configuration of the queue, the message might be sent to the dead-letter
677-
* queue.
679+
* is used for the returned messages. The default visibility timeout for a queue is 30 seconds.
678680
*
679681
* > In the future, new attributes might be added. If you write code that calls this action, we recommend that you
680682
* > structure your code so that it can handle new attributes gracefully.
681683
*
682684
* [^1]: https://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/sqs-long-polling.html
683685
* [^2]: https://www.ietf.org/rfc/rfc1321.txt
684686
* [^3]: https://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/sqs-queue-message-identifiers.html
685-
* [^4]: https://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/sqs-visibility-timeout.html
686687
*
687688
* @see https://docs.aws.amazon.com/AWSSimpleQueueService/latest/APIReference/API_ReceiveMessage.html
688689
* @see https://docs.aws.amazon.com/aws-sdk-php/v3/api/api-sqs-2012-11-05.html#receivemessage

0 commit comments

Comments
 (0)