Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion manifest.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"variables": {
"${LATEST}": "3.283.8"
"${LATEST}": "3.283.13"
},
"endpoints": "https://raw.githubusercontent.com/aws/aws-sdk-php/${LATEST}/src/data/endpoints.json",
"services": {
Expand Down
1 change: 1 addition & 0 deletions src/Service/Sns/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
### Added

- AWS api-change: Remove `ValidationException`
- AWS api-change: Message Archiving and Replay is now supported in Amazon SNS for FIFO topics.

### Changed

Expand Down
12 changes: 12 additions & 0 deletions src/Service/Sns/src/Exception/InvalidStateException.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<?php

namespace AsyncAws\Sns\Exception;

use AsyncAws\Core\Exception\Http\ClientException;

/**
* Indicates that the specified state is not a valid state for an event source.
*/
final class InvalidStateException extends ClientException
{
}
2 changes: 1 addition & 1 deletion src/Service/Sns/src/Exception/KMSDisabledException.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
use AsyncAws\Core\Exception\Http\ClientException;

/**
* The request was rejected because the specified customer master key (CMK) isn't enabled.
* The request was rejected because the specified Amazon Web Services KMS key isn't enabled.
*/
final class KMSDisabledException extends ClientException
{
Expand Down
3 changes: 1 addition & 2 deletions src/Service/Sns/src/Exception/KMSInvalidStateException.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,7 @@

/**
* The request was rejected because the state of the specified resource isn't valid for this request. For more
* information, see How Key State Affects Use of a Customer Master Key [^1] in the *Key Management Service Developer
* Guide*.
* information, see Key states of Amazon Web Services KMS keys [^1] in the *Key Management Service Developer Guide*.
*
* [^1]: https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html
*/
Expand Down
12 changes: 12 additions & 0 deletions src/Service/Sns/src/Exception/ReplayLimitExceededException.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<?php

namespace AsyncAws\Sns\Exception;

use AsyncAws\Core\Exception\Http\ClientException;

/**
* Indicates that the request parameter has exceeded the maximum number of concurrent message replays.
*/
final class ReplayLimitExceededException extends ClientException
{
}
6 changes: 5 additions & 1 deletion src/Service/Sns/src/Input/CreateTopicInput.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,11 @@ final class CreateTopicInput extends Input
*
* The following attributes apply only to FIFO topics [^4]:
*
* - `FifoTopic` – When this is set to `true`, a FIFO topic is created.
* - `ArchivePolicy` – Adds or updates an inline policy document to archive messages stored in the specified Amazon
* SNS topic.
* - `BeginningArchiveTime` – The earliest starting point at which a message in the topic’s archive can be replayed
* from. This point in time is based on the configured message retention period set by the topic’s message archiving
* policy.
* - `ContentBasedDeduplication` – Enables content-based deduplication for FIFO topics.
*
* - By default, `ContentBasedDeduplication` is set to `false`. If you create a FIFO topic and this attribute is
Expand Down
14 changes: 14 additions & 0 deletions src/Service/Sns/src/Input/SubscribeInput.php
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,21 @@ final class SubscribeInput extends Input
* Specifying a valid ARN for this attribute is required for Kinesis Data Firehose delivery stream subscriptions. For
* more information, see Fanout to Kinesis Data Firehose delivery streams [^1] in the *Amazon SNS Developer Guide*.
*
* The following attributes apply only to FIFO topics [^2]:
*
* - `ReplayPolicy` – Adds or updates an inline policy document for a subscription to replay messages stored in the
* specified Amazon SNS topic.
* - `ReplayStatus` – Retrieves the status of the subscription message replay, which can be one of the following:
*
* - `Completed` – The replay has successfully redelivered all messages, and is now delivering newly published
* messages. If an ending point was specified in the `ReplayPolicy` then the subscription will no longer receive
* newly published messages.
* - `In progress` – The replay is currently replaying the selected messages.
* - `Failed` – The replay was unable to complete.
* - `Pending` – The default state while the replay initiates.
*
* [^1]: https://docs.aws.amazon.com/sns/latest/dg/sns-firehose-as-subscriber.html
* [^2]: https://docs.aws.amazon.com/sns/latest/dg/sns-fifo-topics.html
*
* @var array<string, string>|null
*/
Expand Down
10 changes: 9 additions & 1 deletion src/Service/Sns/src/SnsClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
use AsyncAws\Sns\Exception\InvalidParameterException;
use AsyncAws\Sns\Exception\InvalidParameterValueException;
use AsyncAws\Sns\Exception\InvalidSecurityException;
use AsyncAws\Sns\Exception\InvalidStateException;
use AsyncAws\Sns\Exception\KMSAccessDeniedException;
use AsyncAws\Sns\Exception\KMSDisabledException;
use AsyncAws\Sns\Exception\KMSInvalidStateException;
Expand All @@ -28,6 +29,7 @@
use AsyncAws\Sns\Exception\KMSThrottlingException;
use AsyncAws\Sns\Exception\NotFoundException;
use AsyncAws\Sns\Exception\PlatformApplicationDisabledException;
use AsyncAws\Sns\Exception\ReplayLimitExceededException;
use AsyncAws\Sns\Exception\StaleTagException;
use AsyncAws\Sns\Exception\SubscriptionLimitExceededException;
use AsyncAws\Sns\Exception\TagLimitExceededException;
Expand Down Expand Up @@ -195,6 +197,7 @@ public function deleteEndpoint($input): Result
* }|DeleteTopicInput $input
*
* @throws InvalidParameterException
* @throws InvalidStateException
* @throws InternalErrorException
* @throws AuthorizationErrorException
* @throws NotFoundException
Expand All @@ -207,6 +210,7 @@ public function deleteTopic($input): Result
$input = DeleteTopicInput::create($input);
$response = $this->getResponse($input->request(), new RequestContext(['operation' => 'DeleteTopic', 'region' => $input->getRegion(), 'exceptionMapping' => [
'InvalidParameter' => InvalidParameterException::class,
'InvalidState' => InvalidStateException::class,
'InternalError' => InternalErrorException::class,
'AuthorizationError' => AuthorizationErrorException::class,
'NotFound' => NotFoundException::class,
Expand Down Expand Up @@ -412,6 +416,7 @@ public function publish($input): PublishResponse
* @throws KMSThrottlingException
* @throws KMSAccessDeniedException
* @throws InvalidSecurityException
* @throws ValidationException
*/
public function publishBatch($input): PublishBatchResponse
{
Expand All @@ -436,6 +441,7 @@ public function publishBatch($input): PublishBatchResponse
'KMSThrottling' => KMSThrottlingException::class,
'KMSAccessDenied' => KMSAccessDeniedException::class,
'InvalidSecurity' => InvalidSecurityException::class,
'ValidationException' => ValidationException::class,
]]));

return new PublishBatchResponse($response);
Expand All @@ -447,7 +453,7 @@ public function publishBatch($input): PublishBatchResponse
* to confirm the subscription.
*
* You call the `ConfirmSubscription` action with the token from the subscription response. Confirmation tokens are
* valid for three days.
* valid for two days.
*
* This action is throttled at 100 transactions per second (TPS).
*
Expand All @@ -465,6 +471,7 @@ public function publishBatch($input): PublishBatchResponse
*
* @throws SubscriptionLimitExceededException
* @throws FilterPolicyLimitExceededException
* @throws ReplayLimitExceededException
* @throws InvalidParameterException
* @throws InternalErrorException
* @throws NotFoundException
Expand All @@ -477,6 +484,7 @@ public function subscribe($input): SubscribeResponse
$response = $this->getResponse($input->request(), new RequestContext(['operation' => 'Subscribe', 'region' => $input->getRegion(), 'exceptionMapping' => [
'SubscriptionLimitExceeded' => SubscriptionLimitExceededException::class,
'FilterPolicyLimitExceeded' => FilterPolicyLimitExceededException::class,
'ReplayLimitExceeded' => ReplayLimitExceededException::class,
'InvalidParameter' => InvalidParameterException::class,
'InternalError' => InternalErrorException::class,
'NotFound' => NotFoundException::class,
Expand Down