Skip to content

Commit 9d932c3

Browse files
author
awstools
committed
feat(client-emr-serverless): Added support for enabling disk encryption using customer managed AWS KMS keys to CreateApplication, UpdateApplication and StartJobRun APIs.
1 parent 3fa6ead commit 9d932c3

10 files changed

Lines changed: 174 additions & 8 deletions

File tree

clients/client-emr-serverless/src/commands/CreateApplicationCommand.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -127,6 +127,12 @@ export interface CreateApplicationCommandOutput extends CreateApplicationRespons
127127
* remoteWriteUrl: "STRING_VALUE",
128128
* },
129129
* },
130+
* diskEncryptionConfiguration: { // DiskEncryptionConfiguration
131+
* encryptionContext: { // EncryptionContext
132+
* "<keys>": "STRING_VALUE",
133+
* },
134+
* encryptionKeyArn: "STRING_VALUE",
135+
* },
130136
* interactiveConfiguration: { // InteractiveConfiguration
131137
* studioEnabled: true || false,
132138
* livyEndpointEnabled: true || false,

clients/client-emr-serverless/src/commands/GetApplicationCommand.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,12 @@ export interface GetApplicationCommandOutput extends GetApplicationResponse, __M
140140
* // remoteWriteUrl: "STRING_VALUE",
141141
* // },
142142
* // },
143+
* // diskEncryptionConfiguration: { // DiskEncryptionConfiguration
144+
* // encryptionContext: { // EncryptionContext
145+
* // "<keys>": "STRING_VALUE",
146+
* // },
147+
* // encryptionKeyArn: "STRING_VALUE",
148+
* // },
143149
* // interactiveConfiguration: { // InteractiveConfiguration
144150
* // studioEnabled: true || false,
145151
* // livyEndpointEnabled: true || false,

clients/client-emr-serverless/src/commands/GetJobRunCommand.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,12 @@ export interface GetJobRunCommandOutput extends GetJobRunResponse, __MetadataBea
104104
* // remoteWriteUrl: "STRING_VALUE",
105105
* // },
106106
* // },
107+
* // diskEncryptionConfiguration: { // DiskEncryptionConfiguration
108+
* // encryptionContext: { // EncryptionContext
109+
* // "<keys>": "STRING_VALUE",
110+
* // },
111+
* // encryptionKeyArn: "STRING_VALUE",
112+
* // },
107113
* // },
108114
* // jobDriver: { // JobDriver Union: only one key present
109115
* // sparkSubmit: { // SparkSubmit

clients/client-emr-serverless/src/commands/StartJobRunCommand.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,12 @@ export interface StartJobRunCommandOutput extends StartJobRunResponse, __Metadat
102102
* remoteWriteUrl: "STRING_VALUE",
103103
* },
104104
* },
105+
* diskEncryptionConfiguration: { // DiskEncryptionConfiguration
106+
* encryptionContext: { // EncryptionContext
107+
* "<keys>": "STRING_VALUE",
108+
* },
109+
* encryptionKeyArn: "STRING_VALUE",
110+
* },
105111
* },
106112
* tags: { // TagMap
107113
* "<keys>": "STRING_VALUE",

clients/client-emr-serverless/src/commands/UpdateApplicationCommand.ts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -127,6 +127,12 @@ export interface UpdateApplicationCommandOutput extends UpdateApplicationRespons
127127
* remoteWriteUrl: "STRING_VALUE",
128128
* },
129129
* },
130+
* diskEncryptionConfiguration: { // DiskEncryptionConfiguration
131+
* encryptionContext: { // EncryptionContext
132+
* "<keys>": "STRING_VALUE",
133+
* },
134+
* encryptionKeyArn: "STRING_VALUE",
135+
* },
130136
* schedulerConfiguration: { // SchedulerConfiguration
131137
* queueTimeoutMinutes: Number("int"),
132138
* maxConcurrentRuns: Number("int"),
@@ -240,6 +246,12 @@ export interface UpdateApplicationCommandOutput extends UpdateApplicationRespons
240246
* // remoteWriteUrl: "STRING_VALUE",
241247
* // },
242248
* // },
249+
* // diskEncryptionConfiguration: { // DiskEncryptionConfiguration
250+
* // encryptionContext: { // EncryptionContext
251+
* // "<keys>": "STRING_VALUE",
252+
* // },
253+
* // encryptionKeyArn: "STRING_VALUE",
254+
* // },
243255
* // interactiveConfiguration: { // InteractiveConfiguration
244256
* // studioEnabled: true || false,
245257
* // livyEndpointEnabled: true || false,

clients/client-emr-serverless/src/models/models_0.ts

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,24 @@ export interface AutoStopConfig {
3131
idleTimeoutMinutes?: number | undefined;
3232
}
3333

34+
/**
35+
* <p>The configuration object that allows encrypting local disks.</p>
36+
* @public
37+
*/
38+
export interface DiskEncryptionConfiguration {
39+
/**
40+
* <p>Specifies the optional encryption context that will be used when encrypting the data. An encryption context is a collection of non-secret key-value pairs that represent additional authenticated data. </p>
41+
* @public
42+
*/
43+
encryptionContext?: Record<string, string> | undefined;
44+
45+
/**
46+
* <p>The KMS key ARN to encrypt local disks.</p>
47+
* @public
48+
*/
49+
encryptionKeyArn?: string | undefined;
50+
}
51+
3452
/**
3553
* <p>The IAM Identity Center Configuration accepts the Identity Center instance parameter required to enable trusted identity propagation. This configuration allows identity propagation between integrated services and the Identity Center instance.</p>
3654
* @public
@@ -1401,6 +1419,12 @@ export interface Application {
14011419
*/
14021420
monitoringConfiguration?: MonitoringConfiguration | undefined;
14031421

1422+
/**
1423+
* <p>The configuration object that allows encrypting local disks.</p>
1424+
* @public
1425+
*/
1426+
diskEncryptionConfiguration?: DiskEncryptionConfiguration | undefined;
1427+
14041428
/**
14051429
* <p>The interactive configuration object that enables the interactive use cases for an application.</p>
14061430
* @public
@@ -1442,6 +1466,12 @@ export interface ConfigurationOverrides {
14421466
* @public
14431467
*/
14441468
monitoringConfiguration?: MonitoringConfiguration | undefined;
1469+
1470+
/**
1471+
* <p>The override configuration to encrypt local disks.</p>
1472+
* @public
1473+
*/
1474+
diskEncryptionConfiguration?: DiskEncryptionConfiguration | undefined;
14451475
}
14461476

14471477
/**
@@ -1538,6 +1568,12 @@ export interface CreateApplicationRequest {
15381568
*/
15391569
monitoringConfiguration?: MonitoringConfiguration | undefined;
15401570

1571+
/**
1572+
* <p>The configuration object that allows encrypting local disks.</p>
1573+
* @public
1574+
*/
1575+
diskEncryptionConfiguration?: DiskEncryptionConfiguration | undefined;
1576+
15411577
/**
15421578
* <p>The interactive configuration object that enables the interactive use cases to use when running an application.</p>
15431579
* @public
@@ -1651,6 +1687,12 @@ export interface UpdateApplicationRequest {
16511687
*/
16521688
monitoringConfiguration?: MonitoringConfiguration | undefined;
16531689

1690+
/**
1691+
* <p>The configuration object that allows encrypting local disks.</p>
1692+
* @public
1693+
*/
1694+
diskEncryptionConfiguration?: DiskEncryptionConfiguration | undefined;
1695+
16541696
/**
16551697
* <p>The scheduler configuration for batch and streaming jobs running on this application. Supported with release labels emr-7.0.0 and above.</p>
16561698
* @public

clients/client-emr-serverless/src/schemas/schemas_0.ts

Lines changed: 17 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ const _CWLC = "CloudWatchLoggingConfiguration";
1717
const _DA = "DeleteApplication";
1818
const _DAR = "DeleteApplicationRequest";
1919
const _DARe = "DeleteApplicationResponse";
20+
const _DEC = "DiskEncryptionConfiguration";
2021
const _EPA = "EntryPointArgument";
2122
const _EPAn = "EntryPointArguments";
2223
const _EPP = "EntryPointPath";
@@ -126,9 +127,11 @@ const _cl = "client";
126127
const _co = "configurations";
127128
const _cp = "cpu";
128129
const _d = "disk";
130+
const _dEC = "diskEncryptionConfiguration";
129131
const _dT = "diskType";
130132
const _e = "enabled";
131133
const _eA = "endedAt";
134+
const _eC = "encryptionContext";
132135
const _eIP = "executionIamPolicy";
133136
const _eKA = "encryptionKeyArn";
134137
const _eP = "entryPoint";
@@ -250,8 +253,8 @@ var Query: StaticSimpleSchema = [0, n0, _Q, 8, 0];
250253
var SparkSubmitParameters: StaticSimpleSchema = [0, n0, _SSP, 8, 0];
251254
export var Application$: StaticStructureSchema = [3, n0, _A,
252255
0,
253-
[_aI, _n, _a, _rL, _t, _s, _sD, _iC, _mC, _cA, _uA, _ta, _aSC, _aSCu, _nC, _ar, _iCm, _wTS, _rC, _mCo, _iCn, _sC, _iCC, _jLCAC],
254-
[0, 0, 0, 0, 0, 0, 0, () => InitialCapacityConfigMap, () => MaximumAllowedResources$, 4, 4, 128 | 0, () => AutoStartConfig$, () => AutoStopConfig$, () => NetworkConfiguration$, 0, () => ImageConfiguration$, () => WorkerTypeSpecificationMap, [() => ConfigurationList, 0], () => MonitoringConfiguration$, () => InteractiveConfiguration$, () => SchedulerConfiguration$, () => IdentityCenterConfiguration$, () => JobLevelCostAllocationConfiguration$]
256+
[_aI, _n, _a, _rL, _t, _s, _sD, _iC, _mC, _cA, _uA, _ta, _aSC, _aSCu, _nC, _ar, _iCm, _wTS, _rC, _mCo, _dEC, _iCn, _sC, _iCC, _jLCAC],
257+
[0, 0, 0, 0, 0, 0, 0, () => InitialCapacityConfigMap, () => MaximumAllowedResources$, 4, 4, 128 | 0, () => AutoStartConfig$, () => AutoStopConfig$, () => NetworkConfiguration$, 0, () => ImageConfiguration$, () => WorkerTypeSpecificationMap, [() => ConfigurationList, 0], () => MonitoringConfiguration$, () => DiskEncryptionConfiguration$, () => InteractiveConfiguration$, () => SchedulerConfiguration$, () => IdentityCenterConfiguration$, () => JobLevelCostAllocationConfiguration$]
255258
];
256259
export var ApplicationSummary$: StaticStructureSchema = [3, n0, _AS,
257260
0,
@@ -290,8 +293,8 @@ export var Configuration$: StaticStructureSchema = [3, n0, _C,
290293
];
291294
export var ConfigurationOverrides$: StaticStructureSchema = [3, n0, _CO,
292295
0,
293-
[_aC, _mCo],
294-
[[() => ConfigurationList, 0], () => MonitoringConfiguration$]
296+
[_aC, _mCo, _dEC],
297+
[[() => ConfigurationList, 0], () => MonitoringConfiguration$, () => DiskEncryptionConfiguration$]
295298
];
296299
export var ConflictException$: StaticErrorSchema = [-3, n0, _CE,
297300
{ [_er]: _cl, [_hE]: 409 },
@@ -301,8 +304,8 @@ export var ConflictException$: StaticErrorSchema = [-3, n0, _CE,
301304
TypeRegistry.for(n0).registerError(ConflictException$, ConflictException);
302305
export var CreateApplicationRequest$: StaticStructureSchema = [3, n0, _CAR,
303306
0,
304-
[_n, _rL, _t, _cT, _iC, _mC, _ta, _aSC, _aSCu, _nC, _ar, _iCm, _wTS, _rC, _mCo, _iCn, _sC, _iCC, _jLCAC],
305-
[0, 0, 0, [0, 4], () => InitialCapacityConfigMap, () => MaximumAllowedResources$, 128 | 0, () => AutoStartConfig$, () => AutoStopConfig$, () => NetworkConfiguration$, 0, () => ImageConfigurationInput$, () => WorkerTypeSpecificationInputMap, [() => ConfigurationList, 0], () => MonitoringConfiguration$, () => InteractiveConfiguration$, () => SchedulerConfiguration$, () => IdentityCenterConfigurationInput$, () => JobLevelCostAllocationConfiguration$]
307+
[_n, _rL, _t, _cT, _iC, _mC, _ta, _aSC, _aSCu, _nC, _ar, _iCm, _wTS, _rC, _mCo, _dEC, _iCn, _sC, _iCC, _jLCAC],
308+
[0, 0, 0, [0, 4], () => InitialCapacityConfigMap, () => MaximumAllowedResources$, 128 | 0, () => AutoStartConfig$, () => AutoStopConfig$, () => NetworkConfiguration$, 0, () => ImageConfigurationInput$, () => WorkerTypeSpecificationInputMap, [() => ConfigurationList, 0], () => MonitoringConfiguration$, () => DiskEncryptionConfiguration$, () => InteractiveConfiguration$, () => SchedulerConfiguration$, () => IdentityCenterConfigurationInput$, () => JobLevelCostAllocationConfiguration$]
306309
];
307310
export var CreateApplicationResponse$: StaticStructureSchema = [3, n0, _CARr,
308311
0,
@@ -319,6 +322,11 @@ export var DeleteApplicationResponse$: StaticStructureSchema = [3, n0, _DARe,
319322
[],
320323
[]
321324
];
325+
export var DiskEncryptionConfiguration$: StaticStructureSchema = [3, n0, _DEC,
326+
0,
327+
[_eC, _eKA],
328+
[128 | 0, 0]
329+
];
322330
export var GetApplicationRequest$: StaticStructureSchema = [3, n0, _GAR,
323331
0,
324332
[_aI],
@@ -574,8 +582,8 @@ export var UntagResourceResponse$: StaticStructureSchema = [3, n0, _URRn,
574582
];
575583
export var UpdateApplicationRequest$: StaticStructureSchema = [3, n0, _UAR,
576584
0,
577-
[_aI, _cT, _iC, _mC, _aSC, _aSCu, _nC, _ar, _iCm, _wTS, _iCn, _rL, _rC, _mCo, _sC, _iCC, _jLCAC],
578-
[[0, 1], [0, 4], () => InitialCapacityConfigMap, () => MaximumAllowedResources$, () => AutoStartConfig$, () => AutoStopConfig$, () => NetworkConfiguration$, 0, () => ImageConfigurationInput$, () => WorkerTypeSpecificationInputMap, () => InteractiveConfiguration$, 0, [() => ConfigurationList, 0], () => MonitoringConfiguration$, () => SchedulerConfiguration$, () => IdentityCenterConfigurationInput$, () => JobLevelCostAllocationConfiguration$]
585+
[_aI, _cT, _iC, _mC, _aSC, _aSCu, _nC, _ar, _iCm, _wTS, _iCn, _rL, _rC, _mCo, _dEC, _sC, _iCC, _jLCAC],
586+
[[0, 1], [0, 4], () => InitialCapacityConfigMap, () => MaximumAllowedResources$, () => AutoStartConfig$, () => AutoStopConfig$, () => NetworkConfiguration$, 0, () => ImageConfigurationInput$, () => WorkerTypeSpecificationInputMap, () => InteractiveConfiguration$, 0, [() => ConfigurationList, 0], () => MonitoringConfiguration$, () => DiskEncryptionConfiguration$, () => SchedulerConfiguration$, () => IdentityCenterConfigurationInput$, () => JobLevelCostAllocationConfiguration$]
579587
];
580588
export var UpdateApplicationResponse$: StaticStructureSchema = [3, n0, _UARp,
581589
0,
@@ -629,6 +637,7 @@ var PolicyArnList = 64 | 0;
629637
var SecurityGroupIds = 64 | 0;
630638
var SubnetIds = 64 | 0;
631639
var TagKeyList = 64 | 0;
640+
var EncryptionContext = 128 | 0;
632641
var InitialCapacityConfigMap: StaticMapSchema = [2, n0, _ICCM,
633642
0, 0, () => InitialCapacityConfig$
634643
];

clients/client-emr-serverless/test/index-objects.spec.mjs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ import {
2222
DeleteApplicationCommand,
2323
DeleteApplicationRequest$,
2424
DeleteApplicationResponse$,
25+
DiskEncryptionConfiguration$,
2526
EMRServerless,
2627
EMRServerlessClient,
2728
EMRServerlessServiceException,
@@ -169,6 +170,7 @@ assert(typeof CreateApplicationRequest$ === "object");
169170
assert(typeof CreateApplicationResponse$ === "object");
170171
assert(typeof DeleteApplicationRequest$ === "object");
171172
assert(typeof DeleteApplicationResponse$ === "object");
173+
assert(typeof DiskEncryptionConfiguration$ === "object");
172174
assert(typeof GetApplicationRequest$ === "object");
173175
assert(typeof GetApplicationResponse$ === "object");
174176
assert(typeof GetDashboardForJobRunRequest$ === "object");

clients/client-emr-serverless/test/index-types.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ export type {
6767
CreateApplicationResponse,
6868
DeleteApplicationRequest,
6969
DeleteApplicationResponse,
70+
DiskEncryptionConfiguration,
7071
GetApplicationRequest,
7172
GetApplicationResponse,
7273
GetDashboardForJobRunRequest,

codegen/sdk-codegen/aws-models/emr-serverless.json

Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,12 @@
129129
"monitoringConfiguration": {
130130
"target": "com.amazonaws.emrserverless#MonitoringConfiguration"
131131
},
132+
"diskEncryptionConfiguration": {
133+
"target": "com.amazonaws.emrserverless#DiskEncryptionConfiguration",
134+
"traits": {
135+
"smithy.api#documentation": "<p>The configuration object that allows encrypting local disks.</p>"
136+
}
137+
},
132138
"interactiveConfiguration": {
133139
"target": "com.amazonaws.emrserverless#InteractiveConfiguration",
134140
"traits": {
@@ -1296,6 +1302,12 @@
12961302
"traits": {
12971303
"smithy.api#documentation": "<p>The override configurations for monitoring.</p>"
12981304
}
1305+
},
1306+
"diskEncryptionConfiguration": {
1307+
"target": "com.amazonaws.emrserverless#DiskEncryptionConfiguration",
1308+
"traits": {
1309+
"smithy.api#documentation": "<p>The override configuration to encrypt local disks.</p>"
1310+
}
12991311
}
13001312
},
13011313
"traits": {
@@ -1476,6 +1488,12 @@
14761488
"smithy.api#documentation": "<p>The configuration setting for monitoring.</p>"
14771489
}
14781490
},
1491+
"diskEncryptionConfiguration": {
1492+
"target": "com.amazonaws.emrserverless#DiskEncryptionConfiguration",
1493+
"traits": {
1494+
"smithy.api#documentation": "<p>The configuration object that allows encrypting local disks.</p>"
1495+
}
1496+
},
14791497
"interactiveConfiguration": {
14801498
"target": "com.amazonaws.emrserverless#InteractiveConfiguration",
14811499
"traits": {
@@ -1577,6 +1595,26 @@
15771595
"type": "structure",
15781596
"members": {}
15791597
},
1598+
"com.amazonaws.emrserverless#DiskEncryptionConfiguration": {
1599+
"type": "structure",
1600+
"members": {
1601+
"encryptionContext": {
1602+
"target": "com.amazonaws.emrserverless#EncryptionContext",
1603+
"traits": {
1604+
"smithy.api#documentation": "<p>Specifies the optional encryption context that will be used when encrypting the data. An encryption context is a collection of non-secret key-value pairs that represent additional authenticated data. </p>"
1605+
}
1606+
},
1607+
"encryptionKeyArn": {
1608+
"target": "com.amazonaws.emrserverless#EncryptionKeyArn",
1609+
"traits": {
1610+
"smithy.api#documentation": "<p>The KMS key ARN to encrypt local disks.</p>"
1611+
}
1612+
}
1613+
},
1614+
"traits": {
1615+
"smithy.api#documentation": "<p>The configuration object that allows encrypting local disks.</p>"
1616+
}
1617+
},
15801618
"com.amazonaws.emrserverless#DiskSize": {
15811619
"type": "string",
15821620
"traits": {
@@ -1603,6 +1641,38 @@
16031641
}
16041642
}
16051643
},
1644+
"com.amazonaws.emrserverless#EncryptionContext": {
1645+
"type": "map",
1646+
"key": {
1647+
"target": "com.amazonaws.emrserverless#EncryptionContextKey"
1648+
},
1649+
"value": {
1650+
"target": "com.amazonaws.emrserverless#EncryptionContextValue"
1651+
},
1652+
"traits": {
1653+
"smithy.api#length": {
1654+
"max": 8
1655+
}
1656+
}
1657+
},
1658+
"com.amazonaws.emrserverless#EncryptionContextKey": {
1659+
"type": "string",
1660+
"traits": {
1661+
"smithy.api#length": {
1662+
"min": 1,
1663+
"max": 128
1664+
}
1665+
}
1666+
},
1667+
"com.amazonaws.emrserverless#EncryptionContextValue": {
1668+
"type": "string",
1669+
"traits": {
1670+
"smithy.api#length": {
1671+
"min": 1,
1672+
"max": 384
1673+
}
1674+
}
1675+
},
16061676
"com.amazonaws.emrserverless#EncryptionKeyArn": {
16071677
"type": "string",
16081678
"traits": {
@@ -4081,6 +4151,12 @@
40814151
"smithy.api#documentation": "<p>The configuration setting for monitoring.</p>"
40824152
}
40834153
},
4154+
"diskEncryptionConfiguration": {
4155+
"target": "com.amazonaws.emrserverless#DiskEncryptionConfiguration",
4156+
"traits": {
4157+
"smithy.api#documentation": "<p>The configuration object that allows encrypting local disks.</p>"
4158+
}
4159+
},
40844160
"schedulerConfiguration": {
40854161
"target": "com.amazonaws.emrserverless#SchedulerConfiguration",
40864162
"traits": {

0 commit comments

Comments
 (0)