@Generated(value="jsii-pacmak/1.58.0 (build f8ba112)", date="2022-05-20T22:20:05.680Z") public enum ComputeResourceType extends java.lang.Enum<ComputeResourceType>
Example:
Vpc vpc = new Vpc(this, "VPC"); ComputeEnvironment spotEnvironment = ComputeEnvironment.Builder.create(this, "MySpotEnvironment") .computeResources(ComputeResources.builder() .type(ComputeResourceType.SPOT) .bidPercentage(75) // Bids for resources at 75% of the on-demand price .vpc(vpc) .build()) .build();
Enum Constant and Description |
---|
FARGATE
(experimental) Resources will be Fargate resources.
|
FARGATE_SPOT
(experimental) Resources will be Fargate Spot resources.
|
ON_DEMAND
(experimental) Resources will be EC2 On-Demand resources.
|
SPOT
(experimental) Resources will be EC2 SpotFleet resources.
|
Modifier and Type | Method and Description |
---|---|
static ComputeResourceType |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static ComputeResourceType[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final ComputeResourceType ON_DEMAND
public static final ComputeResourceType SPOT
public static final ComputeResourceType FARGATE
public static final ComputeResourceType FARGATE_SPOT
Fargate Spot uses spare capacity in the AWS cloud to run your fault-tolerant, time-flexible jobs at up to a 70% discount. If AWS needs the resources back, jobs running on Fargate Spot will be interrupted with two minutes of notification.
public static ComputeResourceType[] values()
for (ComputeResourceType c : ComputeResourceType.values()) System.out.println(c);
public static ComputeResourceType valueOf(java.lang.String name)
name
- the name of the enum constant to be returned.java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null