InstanceFleetArgs

data class InstanceFleetArgs(val clusterId: Output<String>? = null, val instanceTypeConfigs: Output<List<InstanceFleetInstanceTypeConfigArgs>>? = null, val launchSpecifications: Output<InstanceFleetLaunchSpecificationsArgs>? = null, val name: Output<String>? = null, val targetOnDemandCapacity: Output<Int>? = null, val targetSpotCapacity: Output<Int>? = null) : ConvertibleToJava<InstanceFleetArgs>

Provides an Elastic MapReduce Cluster Instance Fleet configuration. See Amazon Elastic MapReduce Documentation for more information.

NOTE: At this time, Instance Fleets cannot be destroyed through the API nor web interface. Instance Fleets are destroyed when the EMR Cluster is destroyed. the provider will resize any Instance Fleet to zero when destroying the resource.

Example Usage

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.emr.InstanceFleet;
import com.pulumi.aws.emr.InstanceFleetArgs;
import com.pulumi.aws.emr.inputs.InstanceFleetInstanceTypeConfigArgs;
import com.pulumi.aws.emr.inputs.InstanceFleetLaunchSpecificationsArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var task = new InstanceFleet("task", InstanceFleetArgs.builder()
.clusterId(aws_emr_cluster.cluster().id())
.instanceTypeConfigs(
InstanceFleetInstanceTypeConfigArgs.builder()
.bidPriceAsPercentageOfOnDemandPrice(100)
.ebsConfigs(InstanceFleetInstanceTypeConfigEbsConfigArgs.builder()
.size(100)
.type("gp2")
.volumesPerInstance(1)
.build())
.instanceType("m4.xlarge")
.weightedCapacity(1)
.build(),
InstanceFleetInstanceTypeConfigArgs.builder()
.bidPriceAsPercentageOfOnDemandPrice(100)
.ebsConfigs(InstanceFleetInstanceTypeConfigEbsConfigArgs.builder()
.size(100)
.type("gp2")
.volumesPerInstance(1)
.build())
.instanceType("m4.2xlarge")
.weightedCapacity(2)
.build())
.launchSpecifications(InstanceFleetLaunchSpecificationsArgs.builder()
.spotSpecifications(InstanceFleetLaunchSpecificationsSpotSpecificationArgs.builder()
.allocationStrategy("capacity-optimized")
.blockDurationMinutes(0)
.timeoutAction("TERMINATE_CLUSTER")
.timeoutDurationMinutes(10)
.build())
.build())
.targetOnDemandCapacity(1)
.targetSpotCapacity(1)
.build());
}
}

Import

EMR Instance Fleet can be imported with the EMR Cluster identifier and Instance Fleet identifier separated by a forward slash (/), e.g., console

$ pulumi import aws:emr/instanceFleet:InstanceFleet example j-123456ABCDEF/if-15EK4O09RZLNR

Constructors

Link copied to clipboard
constructor(clusterId: Output<String>? = null, instanceTypeConfigs: Output<List<InstanceFleetInstanceTypeConfigArgs>>? = null, launchSpecifications: Output<InstanceFleetLaunchSpecificationsArgs>? = null, name: Output<String>? = null, targetOnDemandCapacity: Output<Int>? = null, targetSpotCapacity: Output<Int>? = null)

Properties

Link copied to clipboard
val clusterId: Output<String>? = null

ID of the EMR Cluster to attach to. Changing this forces a new resource to be created.

Link copied to clipboard

Configuration block for instance fleet

Link copied to clipboard

Configuration block for launch specification

Link copied to clipboard
val name: Output<String>? = null

Friendly name given to the instance fleet.

Link copied to clipboard
val targetOnDemandCapacity: Output<Int>? = null

The target capacity of On-Demand units for the instance fleet, which determines how many On-Demand instances to provision.

Link copied to clipboard
val targetSpotCapacity: Output<Int>? = null

The target capacity of Spot units for the instance fleet, which determines how many Spot instances to provision.

Functions

Link copied to clipboard
open override fun toJava(): InstanceFleetArgs