JobStateTimeLimitActionsReason Enum
The reason to log for the action being taken.
Example
ts
new batch.JobQueue(this, 'JobQueue', {
jobStateTimeLimitActions: [
{
action: batch.JobStateTimeLimitActionsAction.CANCEL,
maxTime: cdk.Duration.minutes(10),
reason: batch.JobStateTimeLimitActionsReason.INSUFFICIENT_INSTANCE_CAPACITY,
state: batch.JobStateTimeLimitActionsState.RUNNABLE,
},
]
});
python
batch.JobQueue(self, "JobQueue",
job_state_time_limit_actions=[batch.JobStateTimeLimitAction(
action=batch.JobStateTimeLimitActionsAction.CANCEL,
max_time=cdk.Duration.minutes(10),
reason=batch.JobStateTimeLimitActionsReason.INSUFFICIENT_INSTANCE_CAPACITY,
state=batch.JobStateTimeLimitActionsState.RUNNABLE
)
]
)
java
JobQueue.Builder.create(this, "JobQueue")
.jobStateTimeLimitActions(List.of(JobStateTimeLimitAction.builder()
.action(JobStateTimeLimitActionsAction.CANCEL)
.maxTime(Duration.minutes(10))
.reason(JobStateTimeLimitActionsReason.INSUFFICIENT_INSTANCE_CAPACITY)
.state(JobStateTimeLimitActionsState.RUNNABLE)
.build()))
.build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
new JobQueue(this, "JobQueue", new JobQueueProps {
JobStateTimeLimitActions = new [] { new JobStateTimeLimitAction {
Action = JobStateTimeLimitActionsAction.CANCEL,
MaxTime = Duration.Minutes(10),
Reason = JobStateTimeLimitActionsReason.INSUFFICIENT_INSTANCE_CAPACITY,
State = JobStateTimeLimitActionsState.RUNNABLE
} }
});
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
batch.NewJobQueue(this, jsii.String("JobQueue"), &JobQueueProps{
JobStateTimeLimitActions: []JobStateTimeLimitAction{
&JobStateTimeLimitAction{
Action: batch.JobStateTimeLimitActionsAction_CANCEL,
MaxTime: cdk.Duration_Minutes(jsii.Number(10)),
Reason: batch.JobStateTimeLimitActionsReason_INSUFFICIENT_INSTANCE_CAPACITY,
State: batch.JobStateTimeLimitActionsState_RUNNABLE,
},
},
})
Members
| Member | Description |
|---|---|
INSUFFICIENT_INSTANCE_CAPACITY | All connected compute environments have insufficient capacity errors. |
COMPUTE_ENVIRONMENT_MAX_RESOURCE | All compute environments have a maxvCpus parameter that is smaller than the job requirements. |
JOB_RESOURCE_REQUIREMENT | None of the compute environments have instances that meet the job requirements. |
Referenced by
JobStateTimeLimitAction.reasonreasonreasonReasonReason