Skip to content

Commit e9f03fc

Browse files
authored
Sort exceptions alphabetically (#1875)
1 parent 5eca392 commit e9f03fc

File tree

2 files changed

+33
-29
lines changed

2 files changed

+33
-29
lines changed

CHANGELOG.md

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

77
- AWS api-change: Added us-gov-east-1 and us-gov-west-1 as valid Latency Based Routing regions for change-resource-record-sets.
88

9+
### Changed
10+
11+
- Sort exception alphabetically.
12+
913
## 2.8.0
1014

1115
### Added

src/Route53Client.php

Lines changed: 29 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -122,20 +122,20 @@ class Route53Client extends AbstractApi
122122
* '@region'?: string|null,
123123
* }|ChangeResourceRecordSetsRequest $input
124124
*
125-
* @throws NoSuchHostedZoneException
126-
* @throws NoSuchHealthCheckException
127125
* @throws InvalidChangeBatchException
128126
* @throws InvalidInputException
127+
* @throws NoSuchHealthCheckException
128+
* @throws NoSuchHostedZoneException
129129
* @throws PriorRequestNotCompleteException
130130
*/
131131
public function changeResourceRecordSets($input): ChangeResourceRecordSetsResponse
132132
{
133133
$input = ChangeResourceRecordSetsRequest::create($input);
134134
$response = $this->getResponse($input->request(), new RequestContext(['operation' => 'ChangeResourceRecordSets', 'region' => $input->getRegion(), 'exceptionMapping' => [
135-
'NoSuchHostedZone' => NoSuchHostedZoneException::class,
136-
'NoSuchHealthCheck' => NoSuchHealthCheckException::class,
137135
'InvalidChangeBatch' => InvalidChangeBatchException::class,
138136
'InvalidInput' => InvalidInputException::class,
137+
'NoSuchHealthCheck' => NoSuchHealthCheckException::class,
138+
'NoSuchHostedZone' => NoSuchHostedZoneException::class,
139139
'PriorRequestNotComplete' => PriorRequestNotCompleteException::class,
140140
]]));
141141

@@ -201,29 +201,29 @@ public function changeResourceRecordSets($input): ChangeResourceRecordSetsRespon
201201
* '@region'?: string|null,
202202
* }|CreateHostedZoneRequest $input
203203
*
204-
* @throws InvalidDomainNameException
204+
* @throws ConflictingDomainExistsException
205+
* @throws DelegationSetNotAvailableException
206+
* @throws DelegationSetNotReusableException
205207
* @throws HostedZoneAlreadyExistsException
206-
* @throws TooManyHostedZonesException
207-
* @throws InvalidVPCIdException
208+
* @throws InvalidDomainNameException
208209
* @throws InvalidInputException
209-
* @throws DelegationSetNotAvailableException
210-
* @throws ConflictingDomainExistsException
210+
* @throws InvalidVPCIdException
211211
* @throws NoSuchDelegationSetException
212-
* @throws DelegationSetNotReusableException
212+
* @throws TooManyHostedZonesException
213213
*/
214214
public function createHostedZone($input): CreateHostedZoneResponse
215215
{
216216
$input = CreateHostedZoneRequest::create($input);
217217
$response = $this->getResponse($input->request(), new RequestContext(['operation' => 'CreateHostedZone', 'region' => $input->getRegion(), 'exceptionMapping' => [
218-
'InvalidDomainName' => InvalidDomainNameException::class,
218+
'ConflictingDomainExists' => ConflictingDomainExistsException::class,
219+
'DelegationSetNotAvailable' => DelegationSetNotAvailableException::class,
220+
'DelegationSetNotReusable' => DelegationSetNotReusableException::class,
219221
'HostedZoneAlreadyExists' => HostedZoneAlreadyExistsException::class,
220-
'TooManyHostedZones' => TooManyHostedZonesException::class,
221-
'InvalidVPCId' => InvalidVPCIdException::class,
222+
'InvalidDomainName' => InvalidDomainNameException::class,
222223
'InvalidInput' => InvalidInputException::class,
223-
'DelegationSetNotAvailable' => DelegationSetNotAvailableException::class,
224-
'ConflictingDomainExists' => ConflictingDomainExistsException::class,
224+
'InvalidVPCId' => InvalidVPCIdException::class,
225225
'NoSuchDelegationSet' => NoSuchDelegationSetException::class,
226-
'DelegationSetNotReusable' => DelegationSetNotReusableException::class,
226+
'TooManyHostedZones' => TooManyHostedZonesException::class,
227227
]]));
228228

229229
return new CreateHostedZoneResponse($response);
@@ -277,21 +277,21 @@ public function createHostedZone($input): CreateHostedZoneResponse
277277
* '@region'?: string|null,
278278
* }|DeleteHostedZoneRequest $input
279279
*
280-
* @throws NoSuchHostedZoneException
281280
* @throws HostedZoneNotEmptyException
282-
* @throws PriorRequestNotCompleteException
283-
* @throws InvalidInputException
284281
* @throws InvalidDomainNameException
282+
* @throws InvalidInputException
283+
* @throws NoSuchHostedZoneException
284+
* @throws PriorRequestNotCompleteException
285285
*/
286286
public function deleteHostedZone($input): DeleteHostedZoneResponse
287287
{
288288
$input = DeleteHostedZoneRequest::create($input);
289289
$response = $this->getResponse($input->request(), new RequestContext(['operation' => 'DeleteHostedZone', 'region' => $input->getRegion(), 'exceptionMapping' => [
290-
'NoSuchHostedZone' => NoSuchHostedZoneException::class,
291290
'HostedZoneNotEmpty' => HostedZoneNotEmptyException::class,
292-
'PriorRequestNotComplete' => PriorRequestNotCompleteException::class,
293-
'InvalidInput' => InvalidInputException::class,
294291
'InvalidDomainName' => InvalidDomainNameException::class,
292+
'InvalidInput' => InvalidInputException::class,
293+
'NoSuchHostedZone' => NoSuchHostedZoneException::class,
294+
'PriorRequestNotComplete' => PriorRequestNotCompleteException::class,
295295
]]));
296296

297297
return new DeleteHostedZoneResponse($response);
@@ -315,17 +315,17 @@ public function deleteHostedZone($input): DeleteHostedZoneResponse
315315
* '@region'?: string|null,
316316
* }|ListHostedZonesRequest $input
317317
*
318+
* @throws DelegationSetNotReusableException
318319
* @throws InvalidInputException
319320
* @throws NoSuchDelegationSetException
320-
* @throws DelegationSetNotReusableException
321321
*/
322322
public function listHostedZones($input = []): ListHostedZonesResponse
323323
{
324324
$input = ListHostedZonesRequest::create($input);
325325
$response = $this->getResponse($input->request(), new RequestContext(['operation' => 'ListHostedZones', 'region' => $input->getRegion(), 'exceptionMapping' => [
326+
'DelegationSetNotReusable' => DelegationSetNotReusableException::class,
326327
'InvalidInput' => InvalidInputException::class,
327328
'NoSuchDelegationSet' => NoSuchDelegationSetException::class,
328-
'DelegationSetNotReusable' => DelegationSetNotReusableException::class,
329329
]]));
330330

331331
return new ListHostedZonesResponse($response, $this, $input);
@@ -382,15 +382,15 @@ public function listHostedZones($input = []): ListHostedZonesResponse
382382
* '@region'?: string|null,
383383
* }|ListHostedZonesByNameRequest $input
384384
*
385-
* @throws InvalidInputException
386385
* @throws InvalidDomainNameException
386+
* @throws InvalidInputException
387387
*/
388388
public function listHostedZonesByName($input = []): ListHostedZonesByNameResponse
389389
{
390390
$input = ListHostedZonesByNameRequest::create($input);
391391
$response = $this->getResponse($input->request(), new RequestContext(['operation' => 'ListHostedZonesByName', 'region' => $input->getRegion(), 'exceptionMapping' => [
392-
'InvalidInput' => InvalidInputException::class,
393392
'InvalidDomainName' => InvalidDomainNameException::class,
393+
'InvalidInput' => InvalidInputException::class,
394394
]]));
395395

396396
return new ListHostedZonesByNameResponse($response);
@@ -465,15 +465,15 @@ public function listHostedZonesByName($input = []): ListHostedZonesByNameRespons
465465
* '@region'?: string|null,
466466
* }|ListResourceRecordSetsRequest $input
467467
*
468-
* @throws NoSuchHostedZoneException
469468
* @throws InvalidInputException
469+
* @throws NoSuchHostedZoneException
470470
*/
471471
public function listResourceRecordSets($input): ListResourceRecordSetsResponse
472472
{
473473
$input = ListResourceRecordSetsRequest::create($input);
474474
$response = $this->getResponse($input->request(), new RequestContext(['operation' => 'ListResourceRecordSets', 'region' => $input->getRegion(), 'exceptionMapping' => [
475-
'NoSuchHostedZone' => NoSuchHostedZoneException::class,
476475
'InvalidInput' => InvalidInputException::class,
476+
'NoSuchHostedZone' => NoSuchHostedZoneException::class,
477477
]]));
478478

479479
return new ListResourceRecordSetsResponse($response, $this, $input);
@@ -491,8 +491,8 @@ public function resourceRecordSetsChanged($input): ResourceRecordSetsChangedWait
491491
{
492492
$input = GetChangeRequest::create($input);
493493
$response = $this->getResponse($input->request(), new RequestContext(['operation' => 'GetChange', 'region' => $input->getRegion(), 'exceptionMapping' => [
494-
'NoSuchChange' => NoSuchChangeException::class,
495494
'InvalidInput' => InvalidInputException::class,
495+
'NoSuchChange' => NoSuchChangeException::class,
496496
]]));
497497

498498
return new ResourceRecordSetsChangedWaiter($response, $this, $input);

0 commit comments

Comments
 (0)