Skip to content

Commit 951d363

Browse files
author
awstools
committed
feat(client-batch): Add support for listing jobs by share identifier and getting snapshots of active capacity utilization by job queue and share.
1 parent 6af8b6b commit 951d363

9 files changed

Lines changed: 681 additions & 27 deletions

File tree

clients/client-batch/src/commands/DescribeServiceJobCommand.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,12 @@ export interface DescribeServiceJobCommandOutput extends DescribeServiceJobRespo
5353
* // statusReason: "STRING_VALUE",
5454
* // },
5555
* // ],
56+
* // capacityUsage: [ // ServiceJobCapacityUsageDetailList
57+
* // { // ServiceJobCapacityUsageDetail
58+
* // capacityUnit: "STRING_VALUE",
59+
* // quantity: Number("double"),
60+
* // },
61+
* // ],
5662
* // createdAt: Number("long"),
5763
* // isTerminated: true || false,
5864
* // jobArn: "STRING_VALUE",
@@ -74,6 +80,7 @@ export interface DescribeServiceJobCommandOutput extends DescribeServiceJobRespo
7480
* // },
7581
* // ],
7682
* // },
83+
* // scheduledAt: Number("long"),
7784
* // schedulingPriority: Number("int"),
7885
* // serviceRequestPayload: "STRING_VALUE",
7986
* // serviceJobType: "SAGEMAKER_TRAINING", // required

clients/client-batch/src/commands/GetJobQueueSnapshotCommand.ts

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,8 @@ export interface GetJobQueueSnapshotCommandInput extends GetJobQueueSnapshotRequ
2727
export interface GetJobQueueSnapshotCommandOutput extends GetJobQueueSnapshotResponse, __MetadataBearer {}
2828

2929
/**
30-
* <p>Provides a list of the first 100 <code>RUNNABLE</code> jobs associated to a single job queue.</p>
30+
* <p>Provides a list of the first 100 <code>RUNNABLE</code> jobs associated to a single job
31+
* queue and includes capacity utilization, including total usage and breakdown by share for fairshare scheduling job queues. </p>
3132
* @example
3233
* Use a bare-bones client and the command you need to make an API call.
3334
* ```javascript
@@ -51,6 +52,29 @@ export interface GetJobQueueSnapshotCommandOutput extends GetJobQueueSnapshotRes
5152
* // ],
5253
* // lastUpdatedAt: Number("long"),
5354
* // },
55+
* // queueUtilization: { // QueueSnapshotUtilizationDetail
56+
* // totalCapacityUsage: [ // QueueSnapshotCapacityUsageList
57+
* // { // QueueSnapshotCapacityUsage
58+
* // capacityUnit: "STRING_VALUE",
59+
* // quantity: Number("double"),
60+
* // },
61+
* // ],
62+
* // fairshareUtilization: { // FairshareUtilizationDetail
63+
* // activeShareCount: Number("long"),
64+
* // topCapacityUtilization: [ // FairshareCapacityUtilizationList
65+
* // { // FairshareCapacityUtilization
66+
* // shareIdentifier: "STRING_VALUE",
67+
* // capacityUsage: [ // FairshareCapacityUsageList
68+
* // { // FairshareCapacityUsage
69+
* // capacityUnit: "STRING_VALUE",
70+
* // quantity: Number("double"),
71+
* // },
72+
* // ],
73+
* // },
74+
* // ],
75+
* // },
76+
* // lastUpdatedAt: Number("long"),
77+
* // },
5478
* // };
5579
*
5680
* ```

clients/client-batch/src/commands/ListJobsCommand.ts

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,6 @@ export interface ListJobsCommandOutput extends ListJobsResponse, __MetadataBeare
4040
* <p>An array job ID to return a list of the children for that job</p>
4141
* </li>
4242
* </ul>
43-
* <p>You can filter the results by job status with the <code>jobStatus</code> parameter. If you
44-
* don't specify a status, only <code>RUNNING</code> jobs are returned.</p>
4543
* @example
4644
* Use a bare-bones client and the command you need to make an API call.
4745
* ```javascript
@@ -74,7 +72,15 @@ export interface ListJobsCommandOutput extends ListJobsResponse, __MetadataBeare
7472
* // jobArn: "STRING_VALUE",
7573
* // jobId: "STRING_VALUE", // required
7674
* // jobName: "STRING_VALUE", // required
75+
* // capacityUsage: [ // JobCapacityUsageSummaryList
76+
* // { // JobCapacityUsageSummary
77+
* // capacityUnit: "STRING_VALUE",
78+
* // quantity: Number("double"),
79+
* // },
80+
* // ],
7781
* // createdAt: Number("long"),
82+
* // scheduledAt: Number("long"),
83+
* // shareIdentifier: "STRING_VALUE",
7884
* // status: "SUBMITTED" || "PENDING" || "RUNNABLE" || "STARTING" || "RUNNING" || "SUCCEEDED" || "FAILED",
7985
* // statusReason: "STRING_VALUE",
8086
* // startedAt: Number("long"),

clients/client-batch/src/commands/ListServiceJobsCommand.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,10 +61,17 @@ export interface ListServiceJobsCommandOutput extends ListServiceJobsResponse, _
6161
* // value: "STRING_VALUE", // required
6262
* // },
6363
* // },
64+
* // capacityUsage: [ // ServiceJobCapacityUsageSummaryList
65+
* // { // ServiceJobCapacityUsageSummary
66+
* // capacityUnit: "STRING_VALUE",
67+
* // quantity: Number("double"),
68+
* // },
69+
* // ],
6470
* // createdAt: Number("long"),
6571
* // jobArn: "STRING_VALUE",
6672
* // jobId: "STRING_VALUE", // required
6773
* // jobName: "STRING_VALUE", // required
74+
* // scheduledAt: Number("long"),
6875
* // serviceJobType: "SAGEMAKER_TRAINING", // required
6976
* // shareIdentifier: "STRING_VALUE",
7077
* // status: "SUBMITTED" || "PENDING" || "RUNNABLE" || "SCHEDULED" || "STARTING" || "RUNNING" || "SUCCEEDED" || "FAILED",

0 commit comments

Comments
 (0)