Skip to content

Commit 3b2a484

Browse files
author
awstools
committed
feat(client-drs): New fields were added to reflect availability zone data in source server and recovery instance description commands responses, as well as source server launch status.
1 parent 287cd60 commit 3b2a484

File tree

4 files changed

+478
-1057
lines changed

4 files changed

+478
-1057
lines changed

clients/client-drs/src/endpoint/ruleset.ts

+18-17
Original file line numberDiff line numberDiff line change
@@ -6,24 +6,25 @@ import { RuleSetObject } from "@aws-sdk/util-endpoints";
66
or see "smithy.rules#endpointRuleSet"
77
in codegen/sdk-codegen/aws-models/drs.json */
88

9-
const p="required",
10-
q="fn",
11-
r="argv",
12-
s="ref";
13-
const a="PartitionResult",
9+
const q="required",
10+
r="fn",
11+
s="argv",
12+
t="ref";
13+
const a="isSet",
1414
b="tree",
1515
c="error",
1616
d="endpoint",
17-
e={[p]:false,"type":"String"},
18-
f={[p]:true,"default":false,"type":"Boolean"},
19-
g={[s]:"Endpoint"},
20-
h={[q]:"booleanEquals",[r]:[{[s]:"UseFIPS"},true]},
21-
i={[q]:"booleanEquals",[r]:[{[s]:"UseDualStack"},true]},
22-
j={},
23-
k={[q]:"booleanEquals",[r]:[true,{[q]:"getAttr",[r]:[{[s]:a},"supportsFIPS"]}]},
24-
l={[q]:"booleanEquals",[r]:[true,{[q]:"getAttr",[r]:[{[s]:a},"supportsDualStack"]}]},
25-
m=[g],
26-
n=[h],
27-
o=[i];
28-
const _data={version:"1.0",parameters:{Region:e,UseDualStack:f,UseFIPS:f,Endpoint:e},rules:[{conditions:[{[q]:"aws.partition",[r]:[{[s]:"Region"}],assign:a}],type:b,rules:[{conditions:[{[q]:"isSet",[r]:m},{[q]:"parseURL",[r]:m,assign:"url"}],type:b,rules:[{conditions:n,error:"Invalid Configuration: FIPS and custom endpoint are not supported",type:c},{type:b,rules:[{conditions:o,error:"Invalid Configuration: Dualstack and custom endpoint are not supported",type:c},{endpoint:{url:g,properties:j,headers:j},type:d}]}]},{conditions:[h,i],type:b,rules:[{conditions:[k,l],type:b,rules:[{endpoint:{url:"https://drs-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:j,headers:j},type:d}]},{error:"FIPS and DualStack are enabled, but this partition does not support one or both",type:c}]},{conditions:n,type:b,rules:[{conditions:[k],type:b,rules:[{type:b,rules:[{endpoint:{url:"https://drs-fips.{Region}.{PartitionResult#dnsSuffix}",properties:j,headers:j},type:d}]}]},{error:"FIPS is enabled but this partition does not support FIPS",type:c}]},{conditions:o,type:b,rules:[{conditions:[l],type:b,rules:[{endpoint:{url:"https://drs.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:j,headers:j},type:d}]},{error:"DualStack is enabled but this partition does not support DualStack",type:c}]},{endpoint:{url:"https://drs.{Region}.{PartitionResult#dnsSuffix}",properties:j,headers:j},type:d}]}]};
17+
e="PartitionResult",
18+
f={[q]:false,"type":"String"},
19+
g={[q]:true,"default":false,"type":"Boolean"},
20+
h={[t]:"Endpoint"},
21+
i={[r]:"booleanEquals",[s]:[{[t]:"UseFIPS"},true]},
22+
j={[r]:"booleanEquals",[s]:[{[t]:"UseDualStack"},true]},
23+
k={},
24+
l={[r]:"booleanEquals",[s]:[true,{[r]:"getAttr",[s]:[{[t]:e},"supportsFIPS"]}]},
25+
m={[r]:"booleanEquals",[s]:[true,{[r]:"getAttr",[s]:[{[t]:e},"supportsDualStack"]}]},
26+
n=[i],
27+
o=[j],
28+
p=[{[t]:"Region"}];
29+
const _data={version:"1.0",parameters:{Region:f,UseDualStack:g,UseFIPS:g,Endpoint:f},rules:[{conditions:[{[r]:a,[s]:[h]}],type:b,rules:[{conditions:n,error:"Invalid Configuration: FIPS and custom endpoint are not supported",type:c},{type:b,rules:[{conditions:o,error:"Invalid Configuration: Dualstack and custom endpoint are not supported",type:c},{endpoint:{url:h,properties:k,headers:k},type:d}]}]},{type:b,rules:[{conditions:[{[r]:a,[s]:p}],type:b,rules:[{conditions:[{[r]:"aws.partition",[s]:p,assign:e}],type:b,rules:[{conditions:[i,j],type:b,rules:[{conditions:[l,m],type:b,rules:[{type:b,rules:[{endpoint:{url:"https://drs-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:k,headers:k},type:d}]}]},{error:"FIPS and DualStack are enabled, but this partition does not support one or both",type:c}]},{conditions:n,type:b,rules:[{conditions:[l],type:b,rules:[{type:b,rules:[{endpoint:{url:"https://drs-fips.{Region}.{PartitionResult#dnsSuffix}",properties:k,headers:k},type:d}]}]},{error:"FIPS is enabled but this partition does not support FIPS",type:c}]},{conditions:o,type:b,rules:[{conditions:[m],type:b,rules:[{type:b,rules:[{endpoint:{url:"https://drs.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:k,headers:k},type:d}]}]},{error:"DualStack is enabled but this partition does not support DualStack",type:c}]},{type:b,rules:[{endpoint:{url:"https://drs.{Region}.{PartitionResult#dnsSuffix}",properties:k,headers:k},type:d}]}]}]},{error:"Invalid Configuration: Missing Region",type:c}]}]};
2930
export const ruleSet: RuleSetObject = _data;

clients/client-drs/src/models/models_0.ts

+30-10
Original file line numberDiff line numberDiff line change
@@ -289,6 +289,11 @@ export interface DataReplicationInfo {
289289
* <p>Error in data replication.</p>
290290
*/
291291
dataReplicationError?: DataReplicationError;
292+
293+
/**
294+
* <p>AWS Availability zone into which data is being replicated.</p>
295+
*/
296+
stagingAvailabilityZone?: string;
292297
}
293298

294299
export enum LastLaunchResult {
@@ -323,6 +328,14 @@ export interface LifeCycleLastLaunchInitiated {
323328
type?: LastLaunchType | string;
324329
}
325330

331+
export enum LaunchStatus {
332+
FAILED = "FAILED",
333+
IN_PROGRESS = "IN_PROGRESS",
334+
LAUNCHED = "LAUNCHED",
335+
PENDING = "PENDING",
336+
TERMINATED = "TERMINATED",
337+
}
338+
326339
/**
327340
* <p>An object containing information regarding the last launch of a Source Server.</p>
328341
*/
@@ -331,6 +344,11 @@ export interface LifeCycleLastLaunch {
331344
* <p>An object containing information regarding the initiation of the last launch of a Source Server.</p>
332345
*/
333346
initiated?: LifeCycleLastLaunchInitiated;
347+
348+
/**
349+
* <p>Status of Source Server's last launch.</p>
350+
*/
351+
status?: LaunchStatus | string;
334352
}
335353

336354
/**
@@ -1208,14 +1226,6 @@ export enum InitiatedBy {
12081226
TERMINATE_RECOVERY_INSTANCES = "TERMINATE_RECOVERY_INSTANCES",
12091227
}
12101228

1211-
export enum LaunchStatus {
1212-
FAILED = "FAILED",
1213-
IN_PROGRESS = "IN_PROGRESS",
1214-
LAUNCHED = "LAUNCHED",
1215-
PENDING = "PENDING",
1216-
TERMINATED = "TERMINATED",
1217-
}
1218-
12191229
/**
12201230
* <p>Represents a server participating in an asynchronous Job.</p>
12211231
*/
@@ -1518,6 +1528,11 @@ export interface RecoveryInstanceDataReplicationInfo {
15181528
* <p>Information about Data Replication</p>
15191529
*/
15201530
dataReplicationError?: RecoveryInstanceDataReplicationError;
1531+
1532+
/**
1533+
* <p>AWS Availability zone into which data is being replicated.</p>
1534+
*/
1535+
stagingAvailabilityZone?: string;
15211536
}
15221537

15231538
export enum EC2InstanceState {
@@ -1730,9 +1745,14 @@ export interface RecoveryInstance {
17301745
isDrill?: boolean;
17311746

17321747
/**
1733-
* <p>Environment (On Premises / AWS) of the instance that the recovery instance originated from. </p>
1748+
* <p>Environment (On Premises / AWS) of the instance that the recovery instance originated from.</p>
17341749
*/
17351750
originEnvironment?: OriginEnvironment | string;
1751+
1752+
/**
1753+
* <p>AWS availability zone associated with the recovery instance.</p>
1754+
*/
1755+
originAvailabilityZone?: string;
17361756
}
17371757

17381758
export interface DescribeRecoveryInstancesResponse {
@@ -2317,7 +2337,7 @@ export interface ReplicationConfigurationReplicatedDisk {
23172337
throughput?: number;
23182338

23192339
/**
2320-
* <p>When <code>stagingDiskType</code> is set to Auto, this field shows the current staging disk EBS volume type as it is constantly updated by the service. This is a read-only field.</p>
2340+
* <p>The Staging Disk EBS volume type to be used during replication when <code>stagingDiskType</code> is set to Auto. This is a read-only field.</p>
23212341
*/
23222342
optimizedStagingDiskType?: ReplicationConfigurationReplicatedDiskStagingDiskType | string;
23232343
}

clients/client-drs/src/protocols/Aws_restJson1.ts

+4
Original file line numberDiff line numberDiff line change
@@ -3850,6 +3850,7 @@ const deserializeAws_restJson1DataReplicationInfo = (output: any, context: __Ser
38503850
output.replicatedDisks != null
38513851
? deserializeAws_restJson1DataReplicationInfoReplicatedDisks(output.replicatedDisks, context)
38523852
: undefined,
3853+
stagingAvailabilityZone: __expectString(output.stagingAvailabilityZone),
38533854
} as any;
38543855
};
38553856

@@ -4071,6 +4072,7 @@ const deserializeAws_restJson1LifeCycleLastLaunch = (output: any, context: __Ser
40714072
output.initiated != null
40724073
? deserializeAws_restJson1LifeCycleLastLaunchInitiated(output.initiated, context)
40734074
: undefined,
4075+
status: __expectString(output.status),
40744076
} as any;
40754077
};
40764078

@@ -4166,6 +4168,7 @@ const deserializeAws_restJson1RecoveryInstance = (output: any, context: __SerdeC
41664168
output.failback != null ? deserializeAws_restJson1RecoveryInstanceFailback(output.failback, context) : undefined,
41674169
isDrill: __expectBoolean(output.isDrill),
41684170
jobID: __expectString(output.jobID),
4171+
originAvailabilityZone: __expectString(output.originAvailabilityZone),
41694172
originEnvironment: __expectString(output.originEnvironment),
41704173
pointInTimeSnapshotDateTime: __expectString(output.pointInTimeSnapshotDateTime),
41714174
recoveryInstanceID: __expectString(output.recoveryInstanceID),
@@ -4208,6 +4211,7 @@ const deserializeAws_restJson1RecoveryInstanceDataReplicationInfo = (
42084211
output.replicatedDisks != null
42094212
? deserializeAws_restJson1RecoveryInstanceDataReplicationInfoReplicatedDisks(output.replicatedDisks, context)
42104213
: undefined,
4214+
stagingAvailabilityZone: __expectString(output.stagingAvailabilityZone),
42114215
} as any;
42124216
};
42134217

0 commit comments

Comments
 (0)