Skip to content

Commit a8c16df

Browse files
committed
fix(aws-glue-alpha): address PR review feedback for metrics control
- Fix JSDoc @default comments to be drop-in values without explanatory text - Improve README example by removing redundant enableObservabilityMetrics line - Enhance integration test with AwsSdkCall assertions to validate actual job configurations - Add comprehensive API-level validation that metrics arguments are correctly included/excluded Addresses review feedback from @iankhou on PR #35154: - JSDoc @default values now follow CDK conventions - README example is cleaner and more accurate - Integration test now validates real AWS API responses instead of just deployment - Added assertions to verify --enable-metrics and --enable-observability-metrics arguments are properly handled in job DefaultArguments The enhanced integration test uses awsApiCall('Glue', 'getJob') to validate: - Jobs with disabled metrics don't have metrics arguments - Jobs with selective control have correct argument combinations - Default behavior maintains backward compatibility
1 parent 2675a1f commit a8c16df

File tree

9 files changed

+31276
-13
lines changed

9 files changed

+31276
-13
lines changed

packages/@aws-cdk/aws-glue-alpha/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -367,7 +367,7 @@ new glue.PySparkEtlJob(stack, 'SelectiveJob', {
367367
role,
368368
script,
369369
enableMetrics: false,
370-
enableObservabilityMetrics: true,
370+
// enableObservabilityMetrics defaults to true
371371
});
372372
```
373373

packages/@aws-cdk/aws-glue-alpha/lib/jobs/ray-job.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ export interface RayJobProps extends JobProps {
3535
*
3636
* When enabled, adds '--enable-metrics' to job arguments.
3737
*
38-
* @default true - metrics are enabled by default for backward compatibility
38+
* @default true
3939
*/
4040
readonly enableMetrics?: boolean;
4141

@@ -44,7 +44,7 @@ export interface RayJobProps extends JobProps {
4444
*
4545
* When enabled, adds '--enable-observability-metrics': 'true' to job arguments.
4646
*
47-
* @default true - observability metrics are enabled by default for backward compatibility
47+
* @default true
4848
*/
4949
readonly enableObservabilityMetrics?: boolean;
5050
}

packages/@aws-cdk/aws-glue-alpha/lib/jobs/spark-job.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ export interface SparkJobProps extends JobProps {
107107
*
108108
* When enabled, adds '--enable-metrics' to job arguments.
109109
*
110-
* @default true - metrics are enabled by default for backward compatibility
110+
* @default true
111111
*/
112112
readonly enableMetrics?: boolean;
113113

@@ -116,7 +116,7 @@ export interface SparkJobProps extends JobProps {
116116
*
117117
* When enabled, adds '--enable-observability-metrics': 'true' to job arguments.
118118
*
119-
* @default true - observability metrics are enabled by default for backward compatibility
119+
* @default true
120120
*/
121121
readonly enableObservabilityMetrics?: boolean;
122122
}

0 commit comments

Comments
 (0)