Skip to content

Commit ebfe9c4

Browse files
Update generated code (#1449)
* update generated code * Update src/Service/Lambda/CHANGELOG.md --------- Co-authored-by: Jérémy Derussé <[email protected]>
1 parent 69e8d79 commit ebfe9c4

File tree

4 files changed

+41
-1
lines changed

4 files changed

+41
-1
lines changed

manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"variables": {
3-
"${LATEST}": "3.273.2"
3+
"${LATEST}": "3.273.4"
44
},
55
"endpoints": "https://raw.githubusercontent.com/aws/aws-sdk-php/${LATEST}/src/data/endpoints.json",
66
"services": {

src/Service/Lambda/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 api-change: This release adds RecursiveInvocationException to the Invoke API and InvokeWithResponseStream API.
8+
59
## 1.9.0
610

711
### Added
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
<?php
2+
3+
namespace AsyncAws\Lambda\Exception;
4+
5+
use AsyncAws\Core\Exception\Http\ClientException;
6+
use Symfony\Contracts\HttpClient\ResponseInterface;
7+
8+
/**
9+
* Lambda has detected your function being invoked in a recursive loop with other Amazon Web Services resources and
10+
* stopped your function's invocation.
11+
*/
12+
final class RecursiveInvocationException extends ClientException
13+
{
14+
/**
15+
* The exception type.
16+
*/
17+
private $type;
18+
19+
public function getType(): ?string
20+
{
21+
return $this->type;
22+
}
23+
24+
protected function populateResult(ResponseInterface $response): void
25+
{
26+
$data = $response->toArray(false);
27+
28+
$this->type = isset($data['Type']) ? (string) $data['Type'] : null;
29+
if (null !== $v = (isset($data['message']) ? (string) $data['message'] : null)) {
30+
$this->message = $v;
31+
}
32+
}
33+
}

src/Service/Lambda/src/LambdaClient.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@
3535
use AsyncAws\Lambda\Exception\KMSNotFoundException;
3636
use AsyncAws\Lambda\Exception\PolicyLengthExceededException;
3737
use AsyncAws\Lambda\Exception\PreconditionFailedException;
38+
use AsyncAws\Lambda\Exception\RecursiveInvocationException;
3839
use AsyncAws\Lambda\Exception\RequestTooLargeException;
3940
use AsyncAws\Lambda\Exception\ResourceConflictException;
4041
use AsyncAws\Lambda\Exception\ResourceNotFoundException;
@@ -232,6 +233,7 @@ public function deleteFunction($input): Result
232233
* @throws InvalidRuntimeException
233234
* @throws ResourceConflictException
234235
* @throws ResourceNotReadyException
236+
* @throws RecursiveInvocationException
235237
*/
236238
public function invoke($input): InvocationResponse
237239
{
@@ -266,6 +268,7 @@ public function invoke($input): InvocationResponse
266268
'InvalidRuntimeException' => InvalidRuntimeException::class,
267269
'ResourceConflictException' => ResourceConflictException::class,
268270
'ResourceNotReadyException' => ResourceNotReadyException::class,
271+
'RecursiveInvocationException' => RecursiveInvocationException::class,
269272
]]));
270273

271274
return new InvocationResponse($response);

0 commit comments

Comments
 (0)