Skip to content

Commit 1c0f553

Browse files
authored
Sort exceptions alphabetically (#1875)
1 parent dc282f2 commit 1c0f553

File tree

2 files changed

+12
-8
lines changed

2 files changed

+12
-8
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+
### Changed
6+
7+
- Sort exception alphabetically.
8+
59
## 2.1.1
610

711
### Changed

src/TimestreamQueryClient.php

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -44,19 +44,19 @@ class TimestreamQueryClient extends AbstractApi
4444
*
4545
* @throws AccessDeniedException
4646
* @throws InternalServerException
47+
* @throws InvalidEndpointException
4748
* @throws ThrottlingException
4849
* @throws ValidationException
49-
* @throws InvalidEndpointException
5050
*/
5151
public function cancelQuery($input): CancelQueryResponse
5252
{
5353
$input = CancelQueryRequest::create($input);
5454
$response = $this->getResponse($input->request(), new RequestContext(['operation' => 'CancelQuery', 'region' => $input->getRegion(), 'exceptionMapping' => [
5555
'AccessDeniedException' => AccessDeniedException::class,
5656
'InternalServerException' => InternalServerException::class,
57+
'InvalidEndpointException' => InvalidEndpointException::class,
5758
'ThrottlingException' => ThrottlingException::class,
5859
'ValidationException' => ValidationException::class,
59-
'InvalidEndpointException' => InvalidEndpointException::class,
6060
], 'requiresEndpointDiscovery' => true, 'usesEndpointDiscovery' => true]));
6161

6262
return new CancelQueryResponse($response);
@@ -87,16 +87,16 @@ public function cancelQuery($input): CancelQueryResponse
8787
* }|DescribeEndpointsRequest $input
8888
*
8989
* @throws InternalServerException
90-
* @throws ValidationException
9190
* @throws ThrottlingException
91+
* @throws ValidationException
9292
*/
9393
public function describeEndpoints($input = []): DescribeEndpointsResponse
9494
{
9595
$input = DescribeEndpointsRequest::create($input);
9696
$response = $this->getResponse($input->request(), new RequestContext(['operation' => 'DescribeEndpoints', 'region' => $input->getRegion(), 'exceptionMapping' => [
9797
'InternalServerException' => InternalServerException::class,
98-
'ValidationException' => ValidationException::class,
9998
'ThrottlingException' => ThrottlingException::class,
99+
'ValidationException' => ValidationException::class,
100100
]]));
101101

102102
return new DescribeEndpointsResponse($response);
@@ -117,19 +117,19 @@ public function describeEndpoints($input = []): DescribeEndpointsResponse
117117
*
118118
* @throws AccessDeniedException
119119
* @throws InternalServerException
120+
* @throws InvalidEndpointException
120121
* @throws ThrottlingException
121122
* @throws ValidationException
122-
* @throws InvalidEndpointException
123123
*/
124124
public function prepareQuery($input): PrepareQueryResponse
125125
{
126126
$input = PrepareQueryRequest::create($input);
127127
$response = $this->getResponse($input->request(), new RequestContext(['operation' => 'PrepareQuery', 'region' => $input->getRegion(), 'exceptionMapping' => [
128128
'AccessDeniedException' => AccessDeniedException::class,
129129
'InternalServerException' => InternalServerException::class,
130+
'InvalidEndpointException' => InvalidEndpointException::class,
130131
'ThrottlingException' => ThrottlingException::class,
131132
'ValidationException' => ValidationException::class,
132-
'InvalidEndpointException' => InvalidEndpointException::class,
133133
], 'requiresEndpointDiscovery' => true, 'usesEndpointDiscovery' => true]));
134134

135135
return new PrepareQueryResponse($response);
@@ -179,10 +179,10 @@ public function prepareQuery($input): PrepareQueryResponse
179179
* @throws AccessDeniedException
180180
* @throws ConflictException
181181
* @throws InternalServerException
182+
* @throws InvalidEndpointException
182183
* @throws QueryExecutionException
183184
* @throws ThrottlingException
184185
* @throws ValidationException
185-
* @throws InvalidEndpointException
186186
*/
187187
public function query($input): QueryResponse
188188
{
@@ -191,10 +191,10 @@ public function query($input): QueryResponse
191191
'AccessDeniedException' => AccessDeniedException::class,
192192
'ConflictException' => ConflictException::class,
193193
'InternalServerException' => InternalServerException::class,
194+
'InvalidEndpointException' => InvalidEndpointException::class,
194195
'QueryExecutionException' => QueryExecutionException::class,
195196
'ThrottlingException' => ThrottlingException::class,
196197
'ValidationException' => ValidationException::class,
197-
'InvalidEndpointException' => InvalidEndpointException::class,
198198
], 'requiresEndpointDiscovery' => true, 'usesEndpointDiscovery' => true]));
199199

200200
return new QueryResponse($response, $this, $input);

0 commit comments

Comments
 (0)