

This is the new *CloudFormation Template Reference Guide*. Please update your bookmarks and links. For help getting started with CloudFormation, see the [AWS CloudFormation User Guide](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/Welcome.html).

# AWS::EMR::Cluster
<a name="aws-resource-emr-cluster"></a>

The `AWS::EMR::Cluster` resource specifies an Amazon EMR cluster. This cluster is a collection of Amazon EC2 instances that run open source big data frameworks and applications to process and analyze vast amounts of data. For more information, see the [Amazon EMR Management Guide](https://docs.aws.amazon.com//emr/latest/ManagementGuide/).

Amazon EMR now supports launching task instance groups and task instance fleets as part of the `AWS::EMR::Cluster` resource. This can be done by using the `JobFlowInstancesConfig` property type's `TaskInstanceGroups` and `TaskInstanceFleets` subproperties. Using these subproperties reduces delays in provisioning task nodes compared to specifying task nodes with the `AWS::EMR::InstanceGroupConfig` and `AWS::EMR::InstanceFleetConfig` resources. Please refer to the examples at the bottom of this page to learn how to use these subproperties.

## Syntax
<a name="aws-resource-emr-cluster-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-resource-emr-cluster-syntax.json"></a>

```
{
  "Type" : "AWS::EMR::Cluster",
  "Properties" : {
      "[AdditionalInfo](#cfn-emr-cluster-additionalinfo)" : Json,
      "[Applications](#cfn-emr-cluster-applications)" : [ Application, ... ],
      "[AutoScalingRole](#cfn-emr-cluster-autoscalingrole)" : String,
      "[AutoTerminationPolicy](#cfn-emr-cluster-autoterminationpolicy)" : AutoTerminationPolicy,
      "[BootstrapActions](#cfn-emr-cluster-bootstrapactions)" : [ BootstrapActionConfig, ... ],
      "[Configurations](#cfn-emr-cluster-configurations)" : [ Configuration, ... ],
      "[CustomAmiId](#cfn-emr-cluster-customamiid)" : String,
      "[EbsRootVolumeIops](#cfn-emr-cluster-ebsrootvolumeiops)" : Integer,
      "[EbsRootVolumeSize](#cfn-emr-cluster-ebsrootvolumesize)" : Integer,
      "[EbsRootVolumeThroughput](#cfn-emr-cluster-ebsrootvolumethroughput)" : Integer,
      "[Instances](#cfn-emr-cluster-instances)" : JobFlowInstancesConfig,
      "[JobFlowRole](#cfn-emr-cluster-jobflowrole)" : String,
      "[KerberosAttributes](#cfn-emr-cluster-kerberosattributes)" : KerberosAttributes,
      "[LogEncryptionKmsKeyId](#cfn-emr-cluster-logencryptionkmskeyid)" : String,
      "[LogUri](#cfn-emr-cluster-loguri)" : String,
      "[ManagedScalingPolicy](#cfn-emr-cluster-managedscalingpolicy)" : ManagedScalingPolicy,
      "[Name](#cfn-emr-cluster-name)" : String,
      "[OSReleaseLabel](#cfn-emr-cluster-osreleaselabel)" : String,
      "[PlacementGroupConfigs](#cfn-emr-cluster-placementgroupconfigs)" : [ PlacementGroupConfig, ... ],
      "[ReleaseLabel](#cfn-emr-cluster-releaselabel)" : String,
      "[ScaleDownBehavior](#cfn-emr-cluster-scaledownbehavior)" : String,
      "[SecurityConfiguration](#cfn-emr-cluster-securityconfiguration)" : String,
      "[ServiceRole](#cfn-emr-cluster-servicerole)" : String,
      "[StepConcurrencyLevel](#cfn-emr-cluster-stepconcurrencylevel)" : Integer,
      "[Steps](#cfn-emr-cluster-steps)" : [ StepConfig, ... ],
      "[Tags](#cfn-emr-cluster-tags)" : [ Tag, ... ],
      "[VisibleToAllUsers](#cfn-emr-cluster-visibletoallusers)" : Boolean
    }
}
```

### YAML
<a name="aws-resource-emr-cluster-syntax.yaml"></a>

```
Type: AWS::EMR::Cluster
Properties:
  [AdditionalInfo](#cfn-emr-cluster-additionalinfo): Json
  [Applications](#cfn-emr-cluster-applications): 
    - Application
  [AutoScalingRole](#cfn-emr-cluster-autoscalingrole): String
  [AutoTerminationPolicy](#cfn-emr-cluster-autoterminationpolicy): 
    AutoTerminationPolicy
  [BootstrapActions](#cfn-emr-cluster-bootstrapactions): 
    - BootstrapActionConfig
  [Configurations](#cfn-emr-cluster-configurations): 
    - Configuration
  [CustomAmiId](#cfn-emr-cluster-customamiid): String
  [EbsRootVolumeIops](#cfn-emr-cluster-ebsrootvolumeiops): Integer
  [EbsRootVolumeSize](#cfn-emr-cluster-ebsrootvolumesize): Integer
  [EbsRootVolumeThroughput](#cfn-emr-cluster-ebsrootvolumethroughput): Integer
  [Instances](#cfn-emr-cluster-instances): 
    JobFlowInstancesConfig
  [JobFlowRole](#cfn-emr-cluster-jobflowrole): String
  [KerberosAttributes](#cfn-emr-cluster-kerberosattributes): 
    KerberosAttributes
  [LogEncryptionKmsKeyId](#cfn-emr-cluster-logencryptionkmskeyid): String
  [LogUri](#cfn-emr-cluster-loguri): String
  [ManagedScalingPolicy](#cfn-emr-cluster-managedscalingpolicy): 
    ManagedScalingPolicy
  [Name](#cfn-emr-cluster-name): String
  [OSReleaseLabel](#cfn-emr-cluster-osreleaselabel): String
  [PlacementGroupConfigs](#cfn-emr-cluster-placementgroupconfigs): 
    - PlacementGroupConfig
  [ReleaseLabel](#cfn-emr-cluster-releaselabel): String
  [ScaleDownBehavior](#cfn-emr-cluster-scaledownbehavior): String
  [SecurityConfiguration](#cfn-emr-cluster-securityconfiguration): String
  [ServiceRole](#cfn-emr-cluster-servicerole): String
  [StepConcurrencyLevel](#cfn-emr-cluster-stepconcurrencylevel): Integer
  [Steps](#cfn-emr-cluster-steps): 
    - StepConfig
  [Tags](#cfn-emr-cluster-tags): 
    - Tag
  [VisibleToAllUsers](#cfn-emr-cluster-visibletoallusers): Boolean
```

## Properties
<a name="aws-resource-emr-cluster-properties"></a>

`AdditionalInfo`  <a name="cfn-emr-cluster-additionalinfo"></a>
A JSON string for selecting additional features.  
*Required*: No  
*Type*: Json  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `10280`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`Applications`  <a name="cfn-emr-cluster-applications"></a>
The applications to install on this cluster, for example, Spark, Flink, Oozie, Zeppelin, and so on.  
*Required*: No  
*Type*: Array of [Application](aws-properties-emr-cluster-application.md)  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`AutoScalingRole`  <a name="cfn-emr-cluster-autoscalingrole"></a>
An IAM role for automatic scaling policies. The default role is `EMR_AutoScaling_DefaultRole`. The IAM role provides permissions that the automatic scaling feature requires to launch and terminate Amazon EC2 instances in an instance group.  
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `10280`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`AutoTerminationPolicy`  <a name="cfn-emr-cluster-autoterminationpolicy"></a>
An auto-termination policy for an Amazon EMR cluster. An auto-termination policy defines the amount of idle time in seconds after which a cluster automatically terminates. For alternative cluster termination options, see [Control cluster termination](https://docs.aws.amazon.com/emr/latest/ManagementGuide/emr-plan-termination.html).  
*Required*: No  
*Type*: [AutoTerminationPolicy](aws-properties-emr-cluster-autoterminationpolicy.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`BootstrapActions`  <a name="cfn-emr-cluster-bootstrapactions"></a>
A list of bootstrap actions to run before Hadoop starts on the cluster nodes.  
*Required*: No  
*Type*: Array of [BootstrapActionConfig](aws-properties-emr-cluster-bootstrapactionconfig.md)  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`Configurations`  <a name="cfn-emr-cluster-configurations"></a>
Applies only to Amazon EMR releases 4.x and later. The list of configurations that are supplied to the Amazon EMR cluster.  
*Required*: No  
*Type*: Array of [Configuration](aws-properties-emr-cluster-configuration.md)  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`CustomAmiId`  <a name="cfn-emr-cluster-customamiid"></a>
Available only in Amazon EMR releases 5.7.0 and later. The ID of a custom Amazon EBS-backed Linux AMI if the cluster uses a custom AMI.  
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`EbsRootVolumeIops`  <a name="cfn-emr-cluster-ebsrootvolumeiops"></a>
The IOPS, of the Amazon EBS root device volume of the Linux AMI that is used for each Amazon EC2 instance. Available in Amazon EMR releases 6.15.0 and later.  
*Required*: No  
*Type*: Integer  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`EbsRootVolumeSize`  <a name="cfn-emr-cluster-ebsrootvolumesize"></a>
The size, in GiB, of the Amazon EBS root device volume of the Linux AMI that is used for each Amazon EC2 instance. Available in Amazon EMR releases 4.x and later.  
*Required*: No  
*Type*: Integer  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`EbsRootVolumeThroughput`  <a name="cfn-emr-cluster-ebsrootvolumethroughput"></a>
The throughput, in MiB/s, of the Amazon EBS root device volume of the Linux AMI that is used for each Amazon EC2 instance. Available in Amazon EMR releases 6.15.0 and later.  
*Required*: No  
*Type*: Integer  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`Instances`  <a name="cfn-emr-cluster-instances"></a>
A specification of the number and type of Amazon EC2 instances.  
*Required*: Yes  
*Type*: [JobFlowInstancesConfig](aws-properties-emr-cluster-jobflowinstancesconfig.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`JobFlowRole`  <a name="cfn-emr-cluster-jobflowrole"></a>
Also called instance profile and Amazon EC2 role. An IAM role for an Amazon EMR cluster. The Amazon EC2 instances of the cluster assume this role. The default role is `EMR_EC2_DefaultRole`. In order to use the default role, you must have already created it using the AWS CLI or console.  
*Required*: Yes  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `10280`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`KerberosAttributes`  <a name="cfn-emr-cluster-kerberosattributes"></a>
Attributes for Kerberos configuration when Kerberos authentication is enabled using a security configuration. For more information see [Use Kerberos Authentication](https://docs.aws.amazon.com/emr/latest/ManagementGuide/emr-kerberos.html) in the *Amazon EMR Management Guide*.  
*Required*: No  
*Type*: [KerberosAttributes](aws-properties-emr-cluster-kerberosattributes.md)  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`LogEncryptionKmsKeyId`  <a name="cfn-emr-cluster-logencryptionkmskeyid"></a>
 The AWS KMS key used for encrypting log files. This attribute is only available with Amazon EMR 5.30.0 and later, excluding Amazon EMR 6.0.0.   
*Required*: No  
*Type*: String  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`LogUri`  <a name="cfn-emr-cluster-loguri"></a>
The path to the Amazon S3 location where logs for this cluster are stored.  
*Required*: No  
*Type*: String  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`ManagedScalingPolicy`  <a name="cfn-emr-cluster-managedscalingpolicy"></a>
Creates or updates a managed scaling policy for an Amazon EMR cluster. The managed scaling policy defines the limits for resources, such as Amazon EC2 instances that can be added or terminated from a cluster. The policy only applies to the core and task nodes. The master node cannot be scaled after initial configuration.   
*Required*: No  
*Type*: [ManagedScalingPolicy](aws-properties-emr-cluster-managedscalingpolicy.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Name`  <a name="cfn-emr-cluster-name"></a>
The name of the cluster. This parameter can't contain the characters <, >, \$1, \$1, or ` (backtick).  
*Required*: Yes  
*Type*: String  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`OSReleaseLabel`  <a name="cfn-emr-cluster-osreleaselabel"></a>
The Amazon Linux release specified in a cluster launch RunJobFlow request. If no Amazon Linux release was specified, the default Amazon Linux release is shown in the response.  
*Required*: No  
*Type*: String  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`PlacementGroupConfigs`  <a name="cfn-emr-cluster-placementgroupconfigs"></a>
Property description not available.  
*Required*: No  
*Type*: Array of [PlacementGroupConfig](aws-properties-emr-cluster-placementgroupconfig.md)  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`ReleaseLabel`  <a name="cfn-emr-cluster-releaselabel"></a>
The Amazon EMR release label, which determines the version of open-source application packages installed on the cluster. Release labels are in the form `emr-x.x.x`, where x.x.x is an Amazon EMR release version such as `emr-5.14.0`. For more information about Amazon EMR release versions and included application versions and features, see [https://docs.aws.amazon.com/emr/latest/ReleaseGuide/](https://docs.aws.amazon.com/emr/latest/ReleaseGuide/). The release label applies only to Amazon EMR releases version 4.0 and later. Earlier versions use `AmiVersion`.  
*Required*: No  
*Type*: String  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`ScaleDownBehavior`  <a name="cfn-emr-cluster-scaledownbehavior"></a>
The way that individual Amazon EC2 instances terminate when an automatic scale-in activity occurs or an instance group is resized. `TERMINATE_AT_INSTANCE_HOUR` indicates that Amazon EMR terminates nodes at the instance-hour boundary, regardless of when the request to terminate the instance was submitted. This option is only available with Amazon EMR 5.1.0 and later and is the default for clusters created using that version. `TERMINATE_AT_TASK_COMPLETION` indicates that Amazon EMR adds nodes to a deny list and drains tasks from nodes before terminating the Amazon EC2 instances, regardless of the instance-hour boundary. With either behavior, Amazon EMR removes the least active nodes first and blocks instance termination if it could lead to HDFS corruption. `TERMINATE_AT_TASK_COMPLETION` is available only in Amazon EMR releases 4.1.0 and later, and is the default for versions of Amazon EMR earlier than 5.1.0.  
*Required*: No  
*Type*: String  
*Allowed values*: `TERMINATE_AT_INSTANCE_HOUR | TERMINATE_AT_TASK_COMPLETION`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`SecurityConfiguration`  <a name="cfn-emr-cluster-securityconfiguration"></a>
The name of the security configuration applied to the cluster.  
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `10280`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`ServiceRole`  <a name="cfn-emr-cluster-servicerole"></a>
The IAM role that Amazon EMR assumes in order to access AWS resources on your behalf.  
*Required*: Yes  
*Type*: String  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`StepConcurrencyLevel`  <a name="cfn-emr-cluster-stepconcurrencylevel"></a>
Specifies the number of steps that can be executed concurrently. The default value is `1`. The maximum value is `256`.  
*Required*: No  
*Type*: Integer  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Steps`  <a name="cfn-emr-cluster-steps"></a>
A list of steps to run.  
*Required*: No  
*Type*: Array of [StepConfig](aws-properties-emr-cluster-stepconfig.md)  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`Tags`  <a name="cfn-emr-cluster-tags"></a>
A list of tags associated with a cluster.  
*Required*: No  
*Type*: Array of [Tag](aws-properties-emr-cluster-tag.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`VisibleToAllUsers`  <a name="cfn-emr-cluster-visibletoallusers"></a>
Indicates whether the cluster is visible to all IAM users of the AWS account associated with the cluster. If this value is set to `true`, all IAM users of that AWS account can view and manage the cluster if they have the proper policy permissions set. If this value is `false`, only the IAM user that created the cluster can view and manage it. This value can be changed using the SetVisibleToAllUsers action.  
When you create clusters directly through the EMR console or API, this value is set to `true` by default. However, for `AWS::EMR::Cluster` resources in CloudFormation, the default is `false`.
*Required*: No  
*Type*: Boolean  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

## Return values
<a name="aws-resource-emr-cluster-return-values"></a>

### Ref
<a name="aws-resource-emr-cluster-return-values-ref"></a>

When you pass the logical ID of this resource to the intrinsic `Ref` function, `Ref` returns returns the cluster ID, such as j-1ABCD123AB1A.

For more information about using the `Ref` function, see [https://docs.aws.amazon.com/AWSCloudFormation/latest/TemplateReference/intrinsic-function-reference-ref.html](https://docs.aws.amazon.com/AWSCloudFormation/latest/TemplateReference/intrinsic-function-reference-ref.html).

### Fn::GetAtt
<a name="aws-resource-emr-cluster-return-values-fn--getatt"></a>

The `Fn::GetAtt` intrinsic function returns a value for a specified attribute of this type. The following are the available attributes and sample return values.

For more information about using the `Fn::GetAtt` intrinsic function, see [https://docs.aws.amazon.com/AWSCloudFormation/latest/TemplateReference/intrinsic-function-reference-getatt.html](https://docs.aws.amazon.com/AWSCloudFormation/latest/TemplateReference/intrinsic-function-reference-getatt.html).

#### 
<a name="aws-resource-emr-cluster-return-values-fn--getatt-fn--getatt"></a>

`Id`  <a name="Id-fn::getatt"></a>
The unique identifier for the cluster.

`MasterPublicDNS`  <a name="MasterPublicDNS-fn::getatt"></a>
The public DNS name of the master node (instance), such as `ec2-12-123-123-123.us-west-2.compute.amazonaws.com`.

## Examples
<a name="aws-resource-emr-cluster--examples"></a>

Create cluster examples.

**Topics**
+ [Create a cluster using a custom AMI for EC2 instances](#aws-resource-emr-cluster--examples--Create_a_cluster_using_a_custom_AMI_for_EC2_instances)
+ [Create a cluster and specify the root volume size of EC2 instances](#aws-resource-emr-cluster--examples--Create_a_cluster_and_specify_the_root_volume_size_of_EC2_instances)
+ [Create a cluster with Kerberos authentication](#aws-resource-emr-cluster--examples--Create_a_cluster_with_Kerberos_authentication)
+ [Create a cluster with a managed scaling policy](#aws-resource-emr-cluster--examples--Create_a_cluster_with_a_managed_scaling_policy)
+ [Create a cluster with task instance groups](#aws-resource-emr-cluster--examples--Create_a_cluster_with_task_instance_groups)
+ [Create a cluster with a task instance fleet](#aws-resource-emr-cluster--examples--Create_a_cluster_with_a_task_instance_fleet)

### Create a cluster using a custom AMI for EC2 instances
<a name="aws-resource-emr-cluster--examples--Create_a_cluster_using_a_custom_AMI_for_EC2_instances"></a>

The following example template specifies a cluster using a custom Amazon Linux AMI for the EC2 instances in the cluster.

#### JSON
<a name="aws-resource-emr-cluster--examples--Create_a_cluster_using_a_custom_AMI_for_EC2_instances--json"></a>

```
{
  "AWSTemplateFormatVersion": "2010-09-09",
  "Parameters" : {
    "CustomAmiId" : {
      "Type" : "String"
    },
    "InstanceType" : {
      "Type" : "String"
    },
    "ReleaseLabel" : {
      "Type" : "String"
    },
    "SubnetId" : {
      "Type" : "String"
    },
    "TerminationProtected" : {
      "Type" : "String",
      "Default" : "false"
    },
    "ElasticMapReducePrincipal" : {
      "Type" : "String"
    },
    "Ec2Principal" : {
      "Type" : "String"
    }
  },
  "Resources": {
    "cluster": {
      "Type": "AWS::EMR::Cluster",
      "Properties": {
        "CustomAmiId" : {"Ref" : "CustomAmiId"},
        "Instances": {
          "MasterInstanceGroup": {
            "InstanceCount": 1,
            "InstanceType": {"Ref" : "InstanceType"},
            "Market": "ON_DEMAND",
            "Name": "cfnMaster"
          },
          "CoreInstanceGroup": {
            "InstanceCount": 1,
            "InstanceType": {"Ref" : "InstanceType"},
            "Market": "ON_DEMAND",
            "Name": "cfnCore"
          },
          "TaskInstanceGroups": [
            {
              "InstanceCount": 1,
              "InstanceType": {"Ref" : "InstanceType"},
              "Market": "ON_DEMAND",
              "Name": "cfnTask-1"  
            },
            {
              "InstanceCount": 1,
              "InstanceType": {"Ref" : "InstanceType"},
              "Market": "ON_DEMAND",
              "Name": "cfnTask-2"  
            }
          ],
          "TerminationProtected" : {"Ref" : "TerminationProtected"},
          "Ec2SubnetId" : {"Ref" : "SubnetId"}
        },
        "Name": "CFNtest",
        "JobFlowRole" : {"Ref": "emrEc2InstanceProfile"},
        "ServiceRole" : {"Ref": "emrRole"},
        "ReleaseLabel" : {"Ref" : "ReleaseLabel"},
        "VisibleToAllUsers" : true,
        "Tags": [
          {
            "Key": "key1",
            "Value": "value1"
          }
        ]
      }
    },
    "emrRole": {
      "Type": "AWS::IAM::Role",
      "Properties": {
        "AssumeRolePolicyDocument": {
          "Version": "2012-10-17"		 	 	 ,
          "Statement": [
            {
              "Sid": "",
              "Effect": "Allow",
              "Principal": {
                "Service": {"Ref" : "ElasticMapReducePrincipal"}
              },
              "Action": "sts:AssumeRole"
            }
          ]
        },
        "Path": "/",
        "ManagedPolicyArns": ["arn:aws:iam::aws:policy/service-role/AmazonElasticMapReduceRole"]
      }
    },
    "emrEc2Role": {
      "Type": "AWS::IAM::Role",
      "Properties": {
        "AssumeRolePolicyDocument": {
          "Version": "2012-10-17"		 	 	 ,
          "Statement": [
            {
              "Sid": "",
              "Effect": "Allow",
              "Principal": {
                "Service": {"Ref" : "Ec2Principal"}
              },
              "Action": "sts:AssumeRole"
            }
          ]
        },
        "Path": "/",
        "ManagedPolicyArns": ["arn:aws:iam::aws:policy/service-role/AmazonElasticMapReduceforEC2Role"]
      }
    },
    "emrEc2InstanceProfile": {
      "Type": "AWS::IAM::InstanceProfile",
      "Properties": {
        "Path": "/",
        "Roles": [ {
          "Ref": "emrEc2Role"
        } ]
      }
    }
  }
}
```

#### YAML
<a name="aws-resource-emr-cluster--examples--Create_a_cluster_using_a_custom_AMI_for_EC2_instances--yaml"></a>

```
AWSTemplateFormatVersion: 2010-09-09
Parameters:
  CustomAmiId:
    Type: String
  InstanceType:
    Type: String
  ReleaseLabel:
    Type: String
  SubnetId:
    Type: String
  TerminationProtected:
    Type: String
    Default: 'false'
  ElasticMapReducePrincipal:
    Type: String
  Ec2Principal:
    Type: String
Resources:
  cluster:
    Type: AWS::EMR::Cluster
    Properties:
      CustomAmiId: !Ref CustomAmiId
      Instances:
        MasterInstanceGroup:
          InstanceCount: 1
          InstanceType: !Ref InstanceType
          Market: ON_DEMAND
          Name: cfnMaster
        CoreInstanceGroup:
          InstanceCount: 1
          InstanceType: !Ref InstanceType
          Market: ON_DEMAND
          Name: cfnCore
        TaskInstanceGroups:
          - InstanceCount: 1
            InstanceType: !Ref InstanceType
            Market: ON_DEMAND
            Name: cfnTask-1
          - InstanceCount: 1
            InstanceType: !Ref InstanceType
            Market: ON_DEMAND
            Name: cfnTask-2
        TerminationProtected: !Ref TerminationProtected
        Ec2SubnetId: !Ref SubnetId
      Name: CFNtest
      JobFlowRole: !Ref emrEc2InstanceProfile
      ServiceRole: !Ref emrRole
      ReleaseLabel: !Ref ReleaseLabel
      VisibleToAllUsers: true
      Tags:
        - Key: key1
          Value: value1
  emrRole:
    Type: AWS::IAM::Role
    Properties:
      AssumeRolePolicyDocument:
        Version: 2008-10-17
        Statement:
          - Sid: ''
            Effect: Allow
            Principal:
              Service: !Ref ElasticMapReducePrincipal
            Action: 'sts:AssumeRole'
      Path: /
      ManagedPolicyArns:
        - 'arn:aws:iam::aws:policy/service-role/AmazonElasticMapReduceRole'
  emrEc2Role:
    Type: AWS::IAM::Role
    Properties:
      AssumeRolePolicyDocument:
        Version: 2008-10-17
        Statement:
          - Sid: ''
            Effect: Allow
            Principal:
              Service: !Ref Ec2Principal
            Action: 'sts:AssumeRole'
      Path: /
      ManagedPolicyArns:
        - 'arn:aws:iam::aws:policy/service-role/AmazonElasticMapReduceforEC2Role'
  emrEc2InstanceProfile:
    Type: AWS::IAM::InstanceProfile
    Properties:
      Path: /
      Roles:
        - !Ref emrEc2Role
```

### Create a cluster and specify the root volume size of EC2 instances
<a name="aws-resource-emr-cluster--examples--Create_a_cluster_and_specify_the_root_volume_size_of_EC2_instances"></a>

The following example template enables you to specify the size of the EBS root volume for cluster instances.

#### JSON
<a name="aws-resource-emr-cluster--examples--Create_a_cluster_and_specify_the_root_volume_size_of_EC2_instances--json"></a>

```
{
  "AWSTemplateFormatVersion": "2010-09-09",
  "Parameters" : {
    "InstanceType" : {
      "Type" : "String"
    },
    "ReleaseLabel" : {
      "Type" : "String"
    },
    "SubnetId" : {
      "Type" : "String"
    },
    "TerminationProtected" : {
      "Type" : "String",
      "Default" : "false"
    },
    "EbsRootVolumeSize" : {
      "Type" : "String"
    }
  },
  "Resources": {
    "cluster": {
      "Type": "AWS::EMR::Cluster",
      "Properties": {
        "EbsRootVolumeSize" : {"Ref" : "EbsRootVolumeSize"},
        "Instances": {
          "MasterInstanceGroup": {
            "InstanceCount": 1,
            "InstanceType": {"Ref" : "InstanceType"},
            "Market": "ON_DEMAND",
            "Name": "cfnMaster"
          },
          "CoreInstanceGroup": {
            "InstanceCount": 1,
            "InstanceType": {"Ref" : "InstanceType"},
            "Market": "ON_DEMAND",
            "Name": "cfnCore"
          },
          "TaskInstanceGroups": [
            {
              "InstanceCount": 1,
              "InstanceType": {"Ref" : "InstanceType"},
              "Market": "ON_DEMAND",
              "Name": "cfnTask-1"  
            },
            {
              "InstanceCount": 1,
              "InstanceType": {"Ref" : "InstanceType"},
              "Market": "ON_DEMAND",
              "Name": "cfnTask-2"  
            }
          ],
          "TerminationProtected" : {"Ref" : "TerminationProtected"},
          "Ec2SubnetId" : {"Ref" : "SubnetId"}
        },
        "Name": "CFNtest",
        "JobFlowRole" : {"Ref": "emrEc2InstanceProfile"},
        "ServiceRole" : {"Ref": "emrRole"},
        "ReleaseLabel" : {"Ref" : "ReleaseLabel"},
        "VisibleToAllUsers" : true,
        "Tags": [
          {
            "Key": "key1",
            "Value": "value1"
          }
        ]
      }
    },
    "emrRole": {
      "Type": "AWS::IAM::Role",
      "Properties": {
        "AssumeRolePolicyDocument": {
          "Version": "2012-10-17"		 	 	 ,
          "Statement": [
            {
              "Sid": "",
              "Effect": "Allow",
              "Principal": {
                "Service": "elasticmapreduce.amazonaws.com"
              },
              "Action": "sts:AssumeRole"
            }
          ]
        },
        "Path": "/",
        "ManagedPolicyArns": ["arn:aws:iam::aws:policy/service-role/AmazonElasticMapReduceRole"]
      }
    },
    "emrEc2Role": {
      "Type": "AWS::IAM::Role",
      "Properties": {
        "AssumeRolePolicyDocument": {
          "Version": "2012-10-17"		 	 	 ,
          "Statement": [
            {
              "Sid": "",
              "Effect": "Allow",
              "Principal": {
                "Service": "ec2.amazonaws.com"
              },
              "Action": "sts:AssumeRole"
            }
          ]
        },
        "Path": "/",
        "ManagedPolicyArns": ["arn:aws:iam::aws:policy/service-role/AmazonElasticMapReduceforEC2Role"]
      }
    },
    "emrEc2InstanceProfile": {
      "Type": "AWS::IAM::InstanceProfile",
      "Properties": {
        "Path": "/",
        "Roles": [ {
          "Ref": "emrEc2Role"
        } ]
      }
    }
  }
}
```

#### YAML
<a name="aws-resource-emr-cluster--examples--Create_a_cluster_and_specify_the_root_volume_size_of_EC2_instances--yaml"></a>

```
AWSTemplateFormatVersion: 2010-09-09
Parameters:
  InstanceType:
    Type: String
  ReleaseLabel:
    Type: String
  SubnetId:
    Type: String
  TerminationProtected:
    Type: String
    Default: 'false'
  EbsRootVolumeSize:
    Type: String
Resources:
  cluster:
    Type: AWS::EMR::Cluster
    Properties:
      EbsRootVolumeSize: !Ref EbsRootVolumeSize
      Instances:
        MasterInstanceGroup:
          InstanceCount: 1
          InstanceType: !Ref InstanceType
          Market: ON_DEMAND
          Name: cfnMaster
        CoreInstanceGroup:
          InstanceCount: 1
          InstanceType: !Ref InstanceType
          Market: ON_DEMAND
          Name: cfnCore
        TaskInstanceGroups:
          - InstanceCount: 1
            InstanceType: !Ref InstanceType
            Market: ON_DEMAND
            Name: cfnTask-1
          - InstanceCount: 1
            InstanceType: !Ref InstanceType
            Market: ON_DEMAND
            Name: cfnTask-2
        TerminationProtected: !Ref TerminationProtected
        Ec2SubnetId: !Ref SubnetId
      Name: CFNtest
      JobFlowRole: !Ref emrEc2InstanceProfile
      ServiceRole: !Ref emrRole
      ReleaseLabel: !Ref ReleaseLabel
      VisibleToAllUsers: true
      Tags:
        - Key: key1
          Value: value1
  emrRole:
    Type: AWS::IAM::Role
    Properties:
      AssumeRolePolicyDocument:
        Version: 2008-10-17
        Statement:
          - Sid: ''
            Effect: Allow
            Principal:
              Service: elasticmapreduce.amazonaws.com
            Action: 'sts:AssumeRole'
      Path: /
      ManagedPolicyArns:
        - 'arn:aws:iam::aws:policy/service-role/AmazonElasticMapReduceRole'
  emrEc2Role:
    Type: AWS::IAM::Role
    Properties:
      AssumeRolePolicyDocument:
        Version: 2008-10-17
        Statement:
          - Sid: ''
            Effect: Allow
            Principal:
              Service: ec2.amazonaws.com
            Action: 'sts:AssumeRole'
      Path: /
      ManagedPolicyArns:
        - 'arn:aws:iam::aws:policy/service-role/AmazonElasticMapReduceforEC2Role'
  emrEc2InstanceProfile:
    Type: AWS::IAM::InstanceProfile
    Properties:
      Path: /
      Roles:
        - !Ref emrEc2Role
```

### Create a cluster with Kerberos authentication
<a name="aws-resource-emr-cluster--examples--Create_a_cluster_with_Kerberos_authentication"></a>

The following example template enables you to specify the Kerberos authentication configuration for an EMR cluster.

#### JSON
<a name="aws-resource-emr-cluster--examples--Create_a_cluster_with_Kerberos_authentication--json"></a>

```
{
  "AWSTemplateFormatVersion": "2010-09-09",
  "Parameters" : {
    "CrossRealmTrustPrincipalPassword" : {
      "Type" : "String"
    },
    "KdcAdminPassword" : {
      "Type" : "String"
    },
    "Realm" : {
      "Type" : "String"
    },
    "InstanceType" : {
      "Type" : "String"
    },
    "ReleaseLabel" : {
      "Type" : "String"
    },
    "SubnetId" : {
      "Type" : "String"
    }
  },
  "Resources": {
    "cluster": {
      "Type": "AWS::EMR::Cluster",
      "Properties": {
        "Instances": {
          "MasterInstanceGroup": {
            "InstanceCount": 1,
            "InstanceType": {"Ref" : "InstanceType"},
            "Market": "ON_DEMAND",
            "Name": "cfnMaster"
          },
          "CoreInstanceGroup": {
            "InstanceCount": 1,
            "InstanceType": {"Ref" : "InstanceType"},
            "Market": "ON_DEMAND",
            "Name": "cfnCore"
          },
          "TaskInstanceGroups": [
            {
              "InstanceCount": 1,
              "InstanceType": {"Ref" : "InstanceType"},
              "Market": "ON_DEMAND",
              "Name": "cfnTask-1"  
            },
            {
              "InstanceCount": 1,
              "InstanceType": {"Ref" : "InstanceType"},
              "Market": "ON_DEMAND",
              "Name": "cfnTask-2"  
            }
          ],
          "Ec2SubnetId" : {"Ref" : "SubnetId"}
        },
        "Name": "CFNtest2",
        "JobFlowRole" : {"Ref": "emrEc2InstanceProfile"},
        "KerberosAttributes" : {
          "CrossRealmTrustPrincipalPassword" : "CfnIntegrationTest-1",
          "KdcAdminPassword" : "CfnIntegrationTest-1",
          "Realm": "EC2.INTERNAL"
        },
        "ServiceRole" : {"Ref": "emrRole"},
        "ReleaseLabel" : {"Ref" : "ReleaseLabel"},
        "SecurityConfiguration" : {"Ref" : "securityConfiguration"},
        "VisibleToAllUsers" : true,
        "Tags": [
          {
            "Key": "key1",
            "Value": "value1"
          }
        ]
      }
    },
    "key" : {
      "Type" : "AWS::KMS::Key",
      "Properties" : {
        "KeyPolicy" : {
          "Version": "2012-10-17"		 	 	 ,
          "Id": "key-default-1",
          "Statement": [
            {
              "Sid": "Enable IAM User Permissions",
              "Effect": "Allow",
              "Principal": {
                "AWS": { "Fn::GetAtt" : ["emrEc2Role", "Arn"]}
              },
              "Action": "kms:*",
              "Resource": "*"
            },
            {
              "Sid": "Enable IAM User Permissions",
              "Effect": "Allow",
              "Principal": {
                "AWS": { "Fn::Join" : ["" , ["arn:aws:iam::", {"Ref" : "AWS::AccountId"} ,":root" ]] }
              },
              "Action": "kms:*",
              "Resource": "*"
            }
          ]
        }
      }
    },
    "securityConfiguration": {
      "Type" : "AWS::EMR::SecurityConfiguration",
      "Properties" : {
        "SecurityConfiguration" : {
          "AuthenticationConfiguration": {
            "KerberosConfiguration": {
              "Provider": "ClusterDedicatedKdc",
              "ClusterDedicatedKdcConfiguration": {
                "TicketLifetimeInHours": 24,
                "CrossRealmTrustConfiguration": {
                  "Realm": "AD.DOMAIN.COM",
                  "Domain": "ad.domain.com",
                  "AdminServer": "ad.domain.com",
                  "KdcServer": "ad.domain.com"
                }
              }
            }
          }
        }
      }
    },
    "emrRole": {
      "Type": "AWS::IAM::Role",
      "Properties": {
        "AssumeRolePolicyDocument": {
          "Version": "2012-10-17"		 	 	 ,
          "Statement": [
            {
              "Sid": "",
              "Effect": "Allow",
              "Principal": {
                "Service": "elasticmapreduce.amazonaws.com"
              },
              "Action": "sts:AssumeRole"
            }
          ]
        },
        "Path": "/",
        "ManagedPolicyArns": ["arn:aws:iam::aws:policy/service-role/AmazonElasticMapReduceRole"]
      }
    },
    "emrEc2Role": {
      "Type": "AWS::IAM::Role",
      "Properties": {
        "AssumeRolePolicyDocument": {
          "Version": "2012-10-17"		 	 	 ,
          "Statement": [
            {
              "Sid": "",
              "Effect": "Allow",
              "Principal": {
                "Service": "ec2.amazonaws.com"
              },
              "Action": "sts:AssumeRole"
            }
          ]
        },
        "Path": "/",
        "ManagedPolicyArns": ["arn:aws:iam::aws:policy/service-role/AmazonElasticMapReduceforEC2Role"]
      }
    },
    "emrEc2InstanceProfile": {
      "Type": "AWS::IAM::InstanceProfile",
      "Properties": {
        "Path": "/",
        "Roles": [ {
          "Ref": "emrEc2Role"
        } ]
      }
    }
  },
  "Outputs" : {
    "keyArn" : {
      "Value" : {"Fn::GetAtt" : ["key", "Arn"]}
    }
  }
}
```

#### YAML
<a name="aws-resource-emr-cluster--examples--Create_a_cluster_with_Kerberos_authentication--yaml"></a>

```
AWSTemplateFormatVersion: 2010-09-09
Parameters:
  CrossRealmTrustPrincipalPassword:
    Type: String
  KdcAdminPassword:
    Type: String
  Realm:
    Type: String
  InstanceType:
    Type: String
  ReleaseLabel:
    Type: String
  SubnetId:
    Type: String
Resources:
  cluster:
    Type: 'AWS::EMR::Cluster'
    Properties:
      Instances:
        MasterInstanceGroup:
          InstanceCount: 1
          InstanceType: !Ref InstanceType
          Market: ON_DEMAND
          Name: cfnMaster
        CoreInstanceGroup:
          InstanceCount: 1
          InstanceType: !Ref InstanceType
          Market: ON_DEMAND
          Name: cfnCore
        TaskInstanceGroups:
          - InstanceCount: 1
            InstanceType: !Ref InstanceType
            Market: ON_DEMAND
            Name: cfnTask-1
          - InstanceCount: 1
            InstanceType: !Ref InstanceType
            Market: ON_DEMAND
            Name: cfnTask-2
        Ec2SubnetId: !Ref SubnetId
      Name: CFNtest2
      JobFlowRole: !Ref emrEc2InstanceProfile
      KerberosAttributes:
        CrossRealmTrustPrincipalPassword: CfnIntegrationTest-1
        KdcAdminPassword: CfnIntegrationTest-1
        Realm: EC2.INTERNAL
      ServiceRole: !Ref emrRole
      ReleaseLabel: !Ref ReleaseLabel
      SecurityConfiguration: !Ref securityConfiguration
      VisibleToAllUsers: true
      Tags:
        - Key: key1
          Value: value1
  key:
    Type: 'AWS::KMS::Key'
    Properties:
      KeyPolicy:
        Version: 2012-10-17
        Id: key-default-1
        Statement:
          - Sid: Enable IAM User Permissions
            Effect: Allow
            Principal:
              AWS: !GetAtt 
                - emrEc2Role
                - Arn
            Action: 'kms:*'
            Resource: '*'
          - Sid: Enable IAM User Permissions
            Effect: Allow
            Principal:
              AWS: !Join 
                - ''
                - - 'arn:aws:iam::'
                  - !Ref 'AWS::AccountId'
                  - ':root'
            Action: 'kms:*'
            Resource: '*'
  securityConfiguration:
    Type: 'AWS::EMR::SecurityConfiguration'
    Properties:
      SecurityConfiguration:
        AuthenticationConfiguration:
          KerberosConfiguration:
            Provider: ClusterDedicatedKdc
            ClusterDedicatedKdcConfiguration:
              TicketLifetimeInHours: 24
              CrossRealmTrustConfiguration:
                Realm: AD.DOMAIN.COM
                Domain: ad.domain.com
                AdminServer: ad.domain.com
                KdcServer: ad.domain.com
  emrRole:
    Type: 'AWS::IAM::Role'
    Properties:
      AssumeRolePolicyDocument:
        Version: 2008-10-17
        Statement:
          - Sid: ''
            Effect: Allow
            Principal:
              Service: elasticmapreduce.amazonaws.com
            Action: 'sts:AssumeRole'
      Path: /
      ManagedPolicyArns:
        - 'arn:aws:iam::aws:policy/service-role/AmazonElasticMapReduceRole'
  emrEc2Role:
    Type: 'AWS::IAM::Role'
    Properties:
      AssumeRolePolicyDocument:
        Version: 2008-10-17
        Statement:
          - Sid: ''
            Effect: Allow
            Principal:
              Service: ec2.amazonaws.com
            Action: 'sts:AssumeRole'
      Path: /
      ManagedPolicyArns:
        - 'arn:aws:iam::aws:policy/service-role/AmazonElasticMapReduceforEC2Role'
  emrEc2InstanceProfile:
    Type: 'AWS::IAM::InstanceProfile'
    Properties:
      Path: /
      Roles:
        - !Ref emrEc2Role
Outputs:
  keyArn:
    Value: !GetAtt 
      - key
      - Arn
```

### Create a cluster with a managed scaling policy
<a name="aws-resource-emr-cluster--examples--Create_a_cluster_with_a_managed_scaling_policy"></a>

The following example template enables you to specify the managed scaling policy for an EMR cluster.

#### JSON
<a name="aws-resource-emr-cluster--examples--Create_a_cluster_with_a_managed_scaling_policy--json"></a>

```
{
  "AWSTemplateFormatVersion": "2010-09-09",
  "Parameters" : {
    "InstanceType" : {
      "Type" : "String"
    },
    "ReleaseLabel" : {
      "Type" : "String"
    },
    "SubnetId" : {
      "Type" : "String"
    },
    "MinimumCapacityUnits" : {
      "Type" : "String"
    },
    "MaximumCapacityUnits" : {
      "Type" : "String"
    },
    "MaximumCoreCapacityUnits" : {
      "Type" : "String"
    },
    "MaximumOnDemandCapacityUnits" : {
      "Type" : "String"
    },
    "UnitType" : {
      "Type" : "String"
    }
  },
  "Resources": {
    "cluster": {
      "Type": "AWS::EMR::Cluster",
      "Properties": {
        "Instances": {
          "MasterInstanceGroup": {
            "InstanceCount": 1,
            "InstanceType": {"Ref" : "InstanceType"},
            "Market": "ON_DEMAND",
            "Name": "primary"
          },
          "CoreInstanceGroup": {
            "InstanceCount": 1,
            "InstanceType": {"Ref" : "InstanceType"},
            "Market": "ON_DEMAND",
            "Name": "core"
          },
          "TaskInstanceGroups": [
            {
              "InstanceCount": 1,
              "InstanceType": {"Ref" : "InstanceType"},
              "Market": "ON_DEMAND",
              "Name": "cfnTask-1"  
            },
            {
              "InstanceCount": 1,
              "InstanceType": {"Ref" : "InstanceType"},
              "Market": "ON_DEMAND",
              "Name": "cfnTask-2"  
            }
          ],
          "Ec2SubnetId" : {"Ref" : "SubnetId"}
        },
        "Name": "ManagedScalingExample",
        "JobFlowRole" : "EMR_EC2_DefaultRole",
        "ServiceRole" : "EMR_DefaultRole",
        "ReleaseLabel" : {"Ref" : "ReleaseLabel"},
        "ManagedScalingPolicy" : {
          "ComputeLimits" : {
            "MinimumCapacityUnits" : {"Ref": "MinimumCapacityUnits"},
            "MaximumCapacityUnits" : {"Ref": "MaximumCapacityUnits"},
            "MaximumCoreCapacityUnits" : {"Ref": "MaximumCoreCapacityUnits"},
            "MaximumOnDemandCapacityUnits" : {"Ref": "MaximumOnDemandCapacityUnits"},
            "UnitType" : {"Ref": "UnitType"}
          }
        }
      }
    }
  }
}
```

#### YAML
<a name="aws-resource-emr-cluster--examples--Create_a_cluster_with_a_managed_scaling_policy--yaml"></a>

```
AWSTemplateFormatVersion: 2010-09-09
Parameters:
  InstanceType:
    Type: String
  ReleaseLabel:
    Type: String
  SubnetId:
    Type: String
  MinimumCapacityUnits:
    Type: String
  MaximumCapacityUnits:
    Type: String
  MaximumCoreCapacityUnits:
    Type: String
  MaximumOnDemandCapacityUnits:
    Type: String
  UnitType:
    Type: String
Resources:
  cluster:
    Type: 'AWS::EMR::Cluster'
    Properties:
      Instances:
        MasterInstanceGroup:
          InstanceCount: 1
          InstanceType: !Ref InstanceType
          Market: ON_DEMAND
          Name: primary
        CoreInstanceGroup:
          InstanceCount: 1
          InstanceType: !Ref InstanceType
          Market: ON_DEMAND
          Name: core
        TaskInstanceGroups:
          - InstanceCount: 1
            InstanceType: !Ref InstanceType
            Market: ON_DEMAND
            Name: cfnTask-1
          - InstanceCount: 1
            InstanceType: !Ref InstanceType
            Market: ON_DEMAND
            Name: cfnTask-2
        Ec2SubnetId: !Ref SubnetId
      Name: ManagedScalingExample
      JobFlowRole: EMR_EC2_DefaultRole
      ServiceRole: EMR_DefaultRole
      ReleaseLabel: !Ref ReleaseLabel
      ManagedScalingPolicy:
        ComputeLimits:
          MinimumCapacityUnits: !Ref MinimumCapacityUnits
          MaximumCapacityUnits: !Ref MaximumCapacityUnits
          MaximumCoreCapacityUnits: !Ref MaximumCoreCapacityUnits
          MaximumOnDemandCapacityUnits: !Ref MaximumOnDemandCapacityUnits
          UnitType: !Ref UnitType
```

### Create a cluster with task instance groups
<a name="aws-resource-emr-cluster--examples--Create_a_cluster_with_task_instance_groups"></a>

The following example template enables you to create task instance groups for an EMR cluster.

#### JSON
<a name="aws-resource-emr-cluster--examples--Create_a_cluster_with_task_instance_groups--json"></a>

```
{
  "AWSTemplateFormatVersion": "2010-09-09",
  "Parameters" : {
    "InstanceType" : {
      "Type" : "String"
    },
    "ReleaseLabel" : {
      "Type" : "String"
    },
    "SubnetId" : {
      "Type" : "String"
    },
    "TerminationProtected" : {
      "Type" : "String",
      "Default" : "false"
    },
    "ElasticMapReducePrincipal" : {
      "Type" : "String"
    },
    "Ec2Principal" : {
      "Type" : "String"
    }
  },
  "Resources": {
    "cluster": {
      "Type": "AWS::EMR::Cluster",
      "Properties": {
        "Instances": {
          "MasterInstanceGroup": {
            "InstanceCount": 1,
            "InstanceType": {"Ref" : "InstanceType"},
            "Market": "ON_DEMAND",
            "Name": "cfnMaster"
          },
          "CoreInstanceGroup": {
            "InstanceCount": 1,
            "InstanceType": {"Ref" : "InstanceType"},
            "Market": "ON_DEMAND",
            "Name": "cfnCore"
          },
          "TaskInstanceGroups": [
            {
              "InstanceCount": 1,
              "InstanceType": {"Ref" : "InstanceType"},
              "Market": "ON_DEMAND",
              "Name": "cfnTask-1"  
            },
            {
              "InstanceCount": 1,
              "InstanceType": {"Ref" : "InstanceType"},
              "Market": "ON_DEMAND",
              "Name": "cfnTask-2"  
            }
          ],
          "TerminationProtected" : {"Ref" : "TerminationProtected"},
          "Ec2SubnetId" : {"Ref" : "SubnetId"}
        },
        "Name": "CFNtest",
        "JobFlowRole" : {"Ref": "emrEc2InstanceProfile"},
        "ServiceRole" : {"Ref": "emrRole"},
        "ReleaseLabel" : {"Ref" : "ReleaseLabel"},

        "VisibleToAllUsers" : true,
        "Tags": [
          {
            "Key": "key1",
            "Value": "value1"
          }
        ]
      }
    },
    "emrRole": {
      "Type": "AWS::IAM::Role",
      "Properties": {
        "AssumeRolePolicyDocument": {
          "Version": "2012-10-17"		 	 	 ,
          "Statement": [
            {
              "Sid": "",
              "Effect": "Allow",
              "Principal": {
                "Service": {"Ref" : "ElasticMapReducePrincipal"}
              },
              "Action": "sts:AssumeRole"
            }
          ]
        },
        "Path": "/",
        "ManagedPolicyArns": ["arn:aws:iam::aws:policy/service-role/AmazonElasticMapReduceRole"]
      }
    },
    "emrEc2Role": {
      "Type": "AWS::IAM::Role",
      "Properties": {
        "AssumeRolePolicyDocument": {
          "Version": "2012-10-17"		 	 	 ,
          "Statement": [
            {
              "Sid": "",
              "Effect": "Allow",
              "Principal": {
                "Service": {"Ref" : "Ec2Principal"}
              },
              "Action": "sts:AssumeRole"
            }
          ]
        },
        "Path": "/",
        "ManagedPolicyArns": ["arn:aws:iam::aws:policy/service-role/AmazonElasticMapReduceforEC2Role"]
      }
    },
    "emrEc2InstanceProfile": {
      "Type": "AWS::IAM::InstanceProfile",
      "Properties": {
        "Path": "/",
        "Roles": [ {
          "Ref": "emrEc2Role"
        } ]
      }
    }
  }
}
```

#### YAML
<a name="aws-resource-emr-cluster--examples--Create_a_cluster_with_task_instance_groups--yaml"></a>

```
AWSTemplateFormatVersion: 2010-09-09
Parameters:
  InstanceType:
    Type: String
  ReleaseLabel:
    Type: String
  SubnetId:
    Type: String
  TerminationProtected:
    Type: String
    Default: 'false'
  ElasticMapReducePrincipal:
    Type: String
  Ec2Principal:
    Type: String
Resources:
  cluster:
    Type: AWS::EMR::Cluster
    Properties:
      Instances:
        MasterInstanceGroup:
          InstanceCount: 1
          InstanceType: !Ref InstanceType
          Market: ON_DEMAND
          Name: cfnMaster
        CoreInstanceGroup:
          InstanceCount: 1
          InstanceType: !Ref InstanceType
          Market: ON_DEMAND
          Name: cfnCore
        TaskInstanceGroups:
          - InstanceCount: 1
            InstanceType: !Ref InstanceType
            Market: ON_DEMAND
            Name: cfnTask-1
          - InstanceCount: 1
            InstanceType: !Ref InstanceType
            Market: ON_DEMAND
            Name: cfnTask-2
        TerminationProtected: !Ref TerminationProtected
        Ec2SubnetId: !Ref SubnetId
      Name: CFNtest
      JobFlowRole: !Ref emrEc2InstanceProfile
      ServiceRole: !Ref emrRole
      ReleaseLabel: !Ref ReleaseLabel
      VisibleToAllUsers: true
      Tags:
        - Key: key1
          Value: value1
  emrRole:
    Type: AWS::IAM::Role
    Properties:
      AssumeRolePolicyDocument:
        Version: 2008-10-17
        Statement:
          - Sid: ''
            Effect: Allow
            Principal:
              Service: !Ref ElasticMapReducePrincipal
            Action: 'sts:AssumeRole'
      Path: /
      ManagedPolicyArns:
        - 'arn:aws:iam::aws:policy/service-role/AmazonElasticMapReduceRole'
  emrEc2Role:
    Type: AWS::IAM::Role
    Properties:
      AssumeRolePolicyDocument:
        Version: 2008-10-17
        Statement:
          - Sid: ''
            Effect: Allow
            Principal:
              Service: !Ref Ec2Principal
            Action: 'sts:AssumeRole'
      Path: /
      ManagedPolicyArns:
        - 'arn:aws:iam::aws:policy/service-role/AmazonElasticMapReduceforEC2Role'
  emrEc2InstanceProfile:
    Type: AWS::IAM::InstanceProfile
    Properties:
      Path: /
      Roles:
        - !Ref emrEc2Role
```

### Create a cluster with a task instance fleet
<a name="aws-resource-emr-cluster--examples--Create_a_cluster_with_a_task_instance_fleet"></a>

The following example template enables you to create a task instance fleet for an EMR cluster.

#### JSON
<a name="aws-resource-emr-cluster--examples--Create_a_cluster_with_a_task_instance_fleet--json"></a>

```
{
  "AWSTemplateFormatVersion": "2010-09-09",
  "Parameters" : {
    "InstanceType" : {
      "Type" : "String"
    },
    "ReleaseLabel" : {
      "Type" : "String"
    },
    "SubnetId" : {
      "Type" : "String"
    },
    "TerminationProtected" : {
      "Type" : "String",
      "Default" : "false"
    },
    "ElasticMapReducePrincipal" : {
      "Type" : "String"
    },
    "Ec2Principal" : {
      "Type" : "String"
    }
  },
  "Resources": {
    "cluster": {
      "Type": "AWS::EMR::Cluster",
      "Properties": {
        "Instances": {
          "MasterInstanceFleet": {
            "Name": "cfnMaster",
            "TargetOnDemandCapacity": 1,
            "TargetSpotCapacity": 0,
            "InstanceTypeConfigs": [
              {
                "InstanceType": {"Ref" : "InstanceType"},
                "WeightedCapacity": 1
              }
            ]
          },
          "CoreInstanceFleet": {
            "Name": "cfnCore",
            "TargetOnDemandCapacity": 1,
            "TargetSpotCapacity": 0,
            "InstanceTypeConfigs": [
              {
                "InstanceType": {"Ref" : "InstanceType"},
                "WeightedCapacity": 1
              }
            ]
          },
          "TaskInstanceFleets": [
            {
              "Name": "cfnTask",
              "TargetOnDemandCapacity": 1,
              "TargetSpotCapacity": 0,
              "InstanceTypeConfigs": [
                {
                  "InstanceType": {"Ref" : "InstanceType"},
                  "WeightedCapacity": 1
                }
              ]
            }
          ],
          "TerminationProtected" : {"Ref" : "TerminationProtected"},
          "Ec2SubnetIds" : [
            {"Ref" : "SubnetId"}
          ]
        },
        "Name": "CFNtest",
        "JobFlowRole" : {"Ref": "emrEc2InstanceProfile"},
        "ServiceRole" : {"Ref": "emrRole"},
        "ReleaseLabel" : {"Ref" : "ReleaseLabel"},
        "VisibleToAllUsers" : true,
        "Tags": [
          {
            "Key": "key1",
            "Value": "value1"
          }
        ]
      }
    },
    "emrRole": {
      "Type": "AWS::IAM::Role",
      "Properties": {
        "AssumeRolePolicyDocument": {
          "Version": "2012-10-17"		 	 	 ,
          "Statement": [
            {
              "Sid": "",
              "Effect": "Allow",
              "Principal": {
                "Service": {"Ref" : "ElasticMapReducePrincipal"}
              },
              "Action": "sts:AssumeRole"
            }
          ]
        },
        "Path": "/",
        "ManagedPolicyArns": ["arn:aws:iam::aws:policy/service-role/AmazonElasticMapReduceRole"]
      }
    },
    "emrEc2Role": {
      "Type": "AWS::IAM::Role",
      "Properties": {
        "AssumeRolePolicyDocument": {
          "Version": "2012-10-17"		 	 	 ,
          "Statement": [
            {
              "Sid": "",

              "Effect": "Allow",
              "Principal": {
                "Service": {"Ref" : "Ec2Principal"}
              },
              "Action": "sts:AssumeRole"
            }
          ]
        },
        "Path": "/",
        "ManagedPolicyArns": ["arn:aws:iam::aws:policy/service-role/AmazonElasticMapReduceforEC2Role"]
      }
    },
    "emrEc2InstanceProfile": {
      "Type": "AWS::IAM::InstanceProfile",
      "Properties": {
        "Path": "/",
        "Roles": [ {
          "Ref": "emrEc2Role"
        } ]
      }
    }
  }
}
```

#### YAML
<a name="aws-resource-emr-cluster--examples--Create_a_cluster_with_a_task_instance_fleet--yaml"></a>

```
AWSTemplateFormatVersion: 2010-09-09
Parameters:
  InstanceType:
    Type: String
  ReleaseLabel:
    Type: String
  SubnetId:
    Type: String
  TerminationProtected:
    Type: String
    Default: 'false'
  ElasticMapReducePrincipal:
    Type: String
  Ec2Principal:
    Type: String
Resources:
  cluster:
    Type: AWS::EMR::Cluster
    Properties:
      Instances:
        MasterInstanceFleet:
          Name: cfnMaster
          TargetOnDemandCapacity: 1
          TargetSpotCapacity: 0
          InstanceTypeConfigs:
            - InstanceType: !Ref InstanceType
              WeightedCapacity: 1
        CoreInstanceFleet:
          Name: cfnCore
          TargetOnDemandCapacity: 1
          TargetSpotCapacity: 0
          InstanceTypeConfigs:
            - InstanceType: !Ref InstanceType
              WeightedCapacity: 1
        TaskInstanceFleets:
          - Name: cfnTask
            TargetOnDemandCapacity: 1
            TargetSpotCapacity: 0
            InstanceTypeConfigs:
              - InstanceType: !Ref InstanceType
                WeightedCapacity: 1
        TerminationProtected: !Ref TerminationProtected
        Ec2SubnetIds:
          - !Ref SubnetId
      Name: CFNtest
      JobFlowRole: !Ref emrEc2InstanceProfile
      ServiceRole: !Ref emrRole
      ReleaseLabel: !Ref ReleaseLabel
      VisibleToAllUsers: true
      Tags:
        - Key: key1
          Value: value1
  emrRole:
    Type: AWS::IAM::Role
    Properties:
      AssumeRolePolicyDocument:
        Version: 2008-10-17
        Statement:
          - Sid: ''
            Effect: Allow
            Principal:
              Service: !Ref ElasticMapReducePrincipal
            Action: 'sts:AssumeRole'
      Path: /
      ManagedPolicyArns:
        - 'arn:aws:iam::aws:policy/service-role/AmazonElasticMapReduceRole'
  emrEc2Role:
    Type: AWS::IAM::Role
    Properties:
      AssumeRolePolicyDocument:
        Version: 2008-10-17
        Statement:
          - Sid: ''
            Effect: Allow
            Principal:
              Service: !Ref Ec2Principal
            Action: 'sts:AssumeRole'
      Path: /
      ManagedPolicyArns:
        - 'arn:aws:iam::aws:policy/service-role/AmazonElasticMapReduceforEC2Role'
  emrEc2InstanceProfile:
    Type: AWS::IAM::InstanceProfile
    Properties:
      Path: /
      Roles:
        - !Ref emrEc2Role
```

# AWS::EMR::Cluster Application
<a name="aws-properties-emr-cluster-application"></a>

`Application` is a property of `AWS::EMR::Cluster`. The `Application` property type defines the open-source big data applications for EMR to install and configure when a cluster is created.

With Amazon EMR release version 4.0 and later, the only accepted parameter is the application `Name`. To pass arguments to these applications, you use configuration classifications specified using JSON objects in a `Configuration` property. For more information, see [Configuring Applications](https://docs.aws.amazon.com//emr/latest/ReleaseGuide/emr-configure-apps.html).

With earlier Amazon EMR releases, the application is any AWS or third-party software that you can add to the cluster. You can specify the version of the application and arguments to pass to it. Amazon EMR accepts and forwards the argument list to the corresponding installation script as a bootstrap action argument.

## Syntax
<a name="aws-properties-emr-cluster-application-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-application-syntax.json"></a>

```
{
  "[AdditionalInfo](#cfn-emr-cluster-application-additionalinfo)" : {Key: Value, ...},
  "[Args](#cfn-emr-cluster-application-args)" : [ String, ... ],
  "[Name](#cfn-emr-cluster-application-name)" : String,
  "[Version](#cfn-emr-cluster-application-version)" : String
}
```

### YAML
<a name="aws-properties-emr-cluster-application-syntax.yaml"></a>

```
  [AdditionalInfo](#cfn-emr-cluster-application-additionalinfo): 
    Key: Value
  [Args](#cfn-emr-cluster-application-args): 
    - String
  [Name](#cfn-emr-cluster-application-name): String
  [Version](#cfn-emr-cluster-application-version): String
```

## Properties
<a name="aws-properties-emr-cluster-application-properties"></a>

`AdditionalInfo`  <a name="cfn-emr-cluster-application-additionalinfo"></a>
This option is for advanced users only. This is meta information about clusters and applications that are used for testing and troubleshooting.  
*Required*: No  
*Type*: Object of String  
*Pattern*: `[a-zA-Z0-9]+`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`Args`  <a name="cfn-emr-cluster-application-args"></a>
Arguments for Amazon EMR to pass to the application.  
*Required*: No  
*Type*: Array of String  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`Name`  <a name="cfn-emr-cluster-application-name"></a>
The name of the application.  
*Required*: No  
*Type*: String  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`Version`  <a name="cfn-emr-cluster-application-version"></a>
The version of the application.  
*Required*: No  
*Type*: String  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

# AWS::EMR::Cluster AutoScalingPolicy
<a name="aws-properties-emr-cluster-autoscalingpolicy"></a>

`AutoScalingPolicy` is a subproperty of `InstanceGroupConfig`. `AutoScalingPolicy` defines how an instance group dynamically adds and terminates EC2 instances in response to the value of a CloudWatch metric. For more information, see [Using Automatic Scaling in Amazon EMR](https://docs.aws.amazon.com//emr/latest/ManagementGuide/emr-automatic-scaling.html) in the *Amazon EMR Management Guide*.

## Syntax
<a name="aws-properties-emr-cluster-autoscalingpolicy-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-autoscalingpolicy-syntax.json"></a>

```
{
  "[Constraints](#cfn-emr-cluster-autoscalingpolicy-constraints)" : ScalingConstraints,
  "[Rules](#cfn-emr-cluster-autoscalingpolicy-rules)" : [ ScalingRule, ... ]
}
```

### YAML
<a name="aws-properties-emr-cluster-autoscalingpolicy-syntax.yaml"></a>

```
  [Constraints](#cfn-emr-cluster-autoscalingpolicy-constraints): 
    ScalingConstraints
  [Rules](#cfn-emr-cluster-autoscalingpolicy-rules): 
    - ScalingRule
```

## Properties
<a name="aws-properties-emr-cluster-autoscalingpolicy-properties"></a>

`Constraints`  <a name="cfn-emr-cluster-autoscalingpolicy-constraints"></a>
The upper and lower Amazon EC2 instance limits for an automatic scaling policy. Automatic scaling activity will not cause an instance group to grow above or below these limits.  
*Required*: Yes  
*Type*: [ScalingConstraints](aws-properties-emr-cluster-scalingconstraints.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Rules`  <a name="cfn-emr-cluster-autoscalingpolicy-rules"></a>
The scale-in and scale-out rules that comprise the automatic scaling policy.  
*Required*: Yes  
*Type*: Array of [ScalingRule](aws-properties-emr-cluster-scalingrule.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster AutoTerminationPolicy
<a name="aws-properties-emr-cluster-autoterminationpolicy"></a>

An auto-termination policy for an Amazon EMR cluster. An auto-termination policy defines the amount of idle time in seconds after which a cluster automatically terminates. For alternative cluster termination options, see [Control cluster termination](https://docs.aws.amazon.com/emr/latest/ManagementGuide/emr-plan-termination.html).

## Syntax
<a name="aws-properties-emr-cluster-autoterminationpolicy-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-autoterminationpolicy-syntax.json"></a>

```
{
  "[IdleTimeout](#cfn-emr-cluster-autoterminationpolicy-idletimeout)" : Integer
}
```

### YAML
<a name="aws-properties-emr-cluster-autoterminationpolicy-syntax.yaml"></a>

```
  [IdleTimeout](#cfn-emr-cluster-autoterminationpolicy-idletimeout): Integer
```

## Properties
<a name="aws-properties-emr-cluster-autoterminationpolicy-properties"></a>

`IdleTimeout`  <a name="cfn-emr-cluster-autoterminationpolicy-idletimeout"></a>
Specifies the amount of idle time in seconds after which the cluster automatically terminates. You can specify a minimum of 60 seconds and a maximum of 604800 seconds (seven days).  
*Required*: No  
*Type*: Integer  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster BootstrapActionConfig
<a name="aws-properties-emr-cluster-bootstrapactionconfig"></a>

`BootstrapActionConfig` is a property of `AWS::EMR::Cluster` that can be used to run bootstrap actions on EMR clusters. You can use a bootstrap action to install software and configure EC2 instances for all cluster nodes before EMR installs and configures open-source big data applications on cluster instances. For more information, see [Create Bootstrap Actions to Install Additional Software](https://docs.aws.amazon.com//emr/latest/ManagementGuide/emr-plan-bootstrap.html) in the *Amazon EMR Management Guide*.

## Syntax
<a name="aws-properties-emr-cluster-bootstrapactionconfig-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-bootstrapactionconfig-syntax.json"></a>

```
{
  "[Name](#cfn-emr-cluster-bootstrapactionconfig-name)" : String,
  "[ScriptBootstrapAction](#cfn-emr-cluster-bootstrapactionconfig-scriptbootstrapaction)" : ScriptBootstrapActionConfig
}
```

### YAML
<a name="aws-properties-emr-cluster-bootstrapactionconfig-syntax.yaml"></a>

```
  [Name](#cfn-emr-cluster-bootstrapactionconfig-name): String
  [ScriptBootstrapAction](#cfn-emr-cluster-bootstrapactionconfig-scriptbootstrapaction): 
    ScriptBootstrapActionConfig
```

## Properties
<a name="aws-properties-emr-cluster-bootstrapactionconfig-properties"></a>

`Name`  <a name="cfn-emr-cluster-bootstrapactionconfig-name"></a>
The name of the bootstrap action.  
*Required*: Yes  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`ScriptBootstrapAction`  <a name="cfn-emr-cluster-bootstrapactionconfig-scriptbootstrapaction"></a>
The script run by the bootstrap action.  
*Required*: Yes  
*Type*: [ScriptBootstrapActionConfig](aws-properties-emr-cluster-scriptbootstrapactionconfig.md)  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

# AWS::EMR::Cluster CloudWatchAlarmDefinition
<a name="aws-properties-emr-cluster-cloudwatchalarmdefinition"></a>

`CloudWatchAlarmDefinition` is a subproperty of the `ScalingTrigger `property, which determines when to trigger an automatic scaling activity. Scaling activity begins when you satisfy the defined alarm conditions.

## Syntax
<a name="aws-properties-emr-cluster-cloudwatchalarmdefinition-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-cloudwatchalarmdefinition-syntax.json"></a>

```
{
  "[ComparisonOperator](#cfn-emr-cluster-cloudwatchalarmdefinition-comparisonoperator)" : String,
  "[Dimensions](#cfn-emr-cluster-cloudwatchalarmdefinition-dimensions)" : [ MetricDimension, ... ],
  "[EvaluationPeriods](#cfn-emr-cluster-cloudwatchalarmdefinition-evaluationperiods)" : Integer,
  "[MetricName](#cfn-emr-cluster-cloudwatchalarmdefinition-metricname)" : String,
  "[Namespace](#cfn-emr-cluster-cloudwatchalarmdefinition-namespace)" : String,
  "[Period](#cfn-emr-cluster-cloudwatchalarmdefinition-period)" : Integer,
  "[Statistic](#cfn-emr-cluster-cloudwatchalarmdefinition-statistic)" : String,
  "[Threshold](#cfn-emr-cluster-cloudwatchalarmdefinition-threshold)" : Number,
  "[Unit](#cfn-emr-cluster-cloudwatchalarmdefinition-unit)" : String
}
```

### YAML
<a name="aws-properties-emr-cluster-cloudwatchalarmdefinition-syntax.yaml"></a>

```
  [ComparisonOperator](#cfn-emr-cluster-cloudwatchalarmdefinition-comparisonoperator): String
  [Dimensions](#cfn-emr-cluster-cloudwatchalarmdefinition-dimensions): 
    - MetricDimension
  [EvaluationPeriods](#cfn-emr-cluster-cloudwatchalarmdefinition-evaluationperiods): Integer
  [MetricName](#cfn-emr-cluster-cloudwatchalarmdefinition-metricname): String
  [Namespace](#cfn-emr-cluster-cloudwatchalarmdefinition-namespace): String
  [Period](#cfn-emr-cluster-cloudwatchalarmdefinition-period): Integer
  [Statistic](#cfn-emr-cluster-cloudwatchalarmdefinition-statistic): String
  [Threshold](#cfn-emr-cluster-cloudwatchalarmdefinition-threshold): Number
  [Unit](#cfn-emr-cluster-cloudwatchalarmdefinition-unit): String
```

## Properties
<a name="aws-properties-emr-cluster-cloudwatchalarmdefinition-properties"></a>

`ComparisonOperator`  <a name="cfn-emr-cluster-cloudwatchalarmdefinition-comparisonoperator"></a>
Determines how the metric specified by `MetricName` is compared to the value specified by `Threshold`.  
*Required*: Yes  
*Type*: String  
*Allowed values*: `GREATER_THAN_OR_EQUAL | GREATER_THAN | LESS_THAN | LESS_THAN_OR_EQUAL`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Dimensions`  <a name="cfn-emr-cluster-cloudwatchalarmdefinition-dimensions"></a>
A CloudWatch metric dimension.  
*Required*: No  
*Type*: Array of [MetricDimension](aws-properties-emr-cluster-metricdimension.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`EvaluationPeriods`  <a name="cfn-emr-cluster-cloudwatchalarmdefinition-evaluationperiods"></a>
The number of periods, in five-minute increments, during which the alarm condition must exist before the alarm triggers automatic scaling activity. The default value is `1`.  
*Required*: No  
*Type*: Integer  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`MetricName`  <a name="cfn-emr-cluster-cloudwatchalarmdefinition-metricname"></a>
The name of the CloudWatch metric that is watched to determine an alarm condition.  
*Required*: Yes  
*Type*: String  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Namespace`  <a name="cfn-emr-cluster-cloudwatchalarmdefinition-namespace"></a>
The namespace for the CloudWatch metric. The default is `AWS/ElasticMapReduce`.  
*Required*: No  
*Type*: String  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Period`  <a name="cfn-emr-cluster-cloudwatchalarmdefinition-period"></a>
The period, in seconds, over which the statistic is applied. CloudWatch metrics for Amazon EMR are emitted every five minutes (300 seconds), so if you specify a CloudWatch metric, specify `300`.  
*Required*: Yes  
*Type*: Integer  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Statistic`  <a name="cfn-emr-cluster-cloudwatchalarmdefinition-statistic"></a>
The statistic to apply to the metric associated with the alarm. The default is `AVERAGE`.  
*Required*: No  
*Type*: String  
*Allowed values*: `SAMPLE_COUNT | AVERAGE | SUM | MINIMUM | MAXIMUM`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Threshold`  <a name="cfn-emr-cluster-cloudwatchalarmdefinition-threshold"></a>
The value against which the specified statistic is compared.  
*Required*: Yes  
*Type*: Number  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Unit`  <a name="cfn-emr-cluster-cloudwatchalarmdefinition-unit"></a>
The unit of measure associated with the CloudWatch metric being watched. The value specified for `Unit` must correspond to the units specified in the CloudWatch metric.  
*Required*: No  
*Type*: String  
*Allowed values*: `NONE | SECONDS | MICRO_SECONDS | MILLI_SECONDS | BYTES | KILO_BYTES | MEGA_BYTES | GIGA_BYTES | TERA_BYTES | BITS | KILO_BITS | MEGA_BITS | GIGA_BITS | TERA_BITS | PERCENT | COUNT | BYTES_PER_SECOND | KILO_BYTES_PER_SECOND | MEGA_BYTES_PER_SECOND | GIGA_BYTES_PER_SECOND | TERA_BYTES_PER_SECOND | BITS_PER_SECOND | KILO_BITS_PER_SECOND | MEGA_BITS_PER_SECOND | GIGA_BITS_PER_SECOND | TERA_BITS_PER_SECOND | COUNT_PER_SECOND`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster ComputeLimits
<a name="aws-properties-emr-cluster-computelimits"></a>

 The Amazon EC2 unit limits for a managed scaling policy. The managed scaling activity of a cluster can not be above or below these limits. The limit only applies to the core and task nodes. The master node cannot be scaled after initial configuration. 

## Syntax
<a name="aws-properties-emr-cluster-computelimits-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-computelimits-syntax.json"></a>

```
{
  "[MaximumCapacityUnits](#cfn-emr-cluster-computelimits-maximumcapacityunits)" : Integer,
  "[MaximumCoreCapacityUnits](#cfn-emr-cluster-computelimits-maximumcorecapacityunits)" : Integer,
  "[MaximumOnDemandCapacityUnits](#cfn-emr-cluster-computelimits-maximumondemandcapacityunits)" : Integer,
  "[MinimumCapacityUnits](#cfn-emr-cluster-computelimits-minimumcapacityunits)" : Integer,
  "[UnitType](#cfn-emr-cluster-computelimits-unittype)" : String
}
```

### YAML
<a name="aws-properties-emr-cluster-computelimits-syntax.yaml"></a>

```
  [MaximumCapacityUnits](#cfn-emr-cluster-computelimits-maximumcapacityunits): Integer
  [MaximumCoreCapacityUnits](#cfn-emr-cluster-computelimits-maximumcorecapacityunits): Integer
  [MaximumOnDemandCapacityUnits](#cfn-emr-cluster-computelimits-maximumondemandcapacityunits): Integer
  [MinimumCapacityUnits](#cfn-emr-cluster-computelimits-minimumcapacityunits): Integer
  [UnitType](#cfn-emr-cluster-computelimits-unittype): String
```

## Properties
<a name="aws-properties-emr-cluster-computelimits-properties"></a>

`MaximumCapacityUnits`  <a name="cfn-emr-cluster-computelimits-maximumcapacityunits"></a>
 The upper boundary of Amazon EC2 units. It is measured through vCPU cores or instances for instance groups and measured through units for instance fleets. Managed scaling activities are not allowed beyond this boundary. The limit only applies to the core and task nodes. The master node cannot be scaled after initial configuration.   
*Required*: Yes  
*Type*: Integer  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`MaximumCoreCapacityUnits`  <a name="cfn-emr-cluster-computelimits-maximumcorecapacityunits"></a>
 The upper boundary of Amazon EC2 units for core node type in a cluster. It is measured through vCPU cores or instances for instance groups and measured through units for instance fleets. The core units are not allowed to scale beyond this boundary. The parameter is used to split capacity allocation between core and task nodes.   
*Required*: No  
*Type*: Integer  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`MaximumOnDemandCapacityUnits`  <a name="cfn-emr-cluster-computelimits-maximumondemandcapacityunits"></a>
 The upper boundary of On-Demand Amazon EC2 units. It is measured through vCPU cores or instances for instance groups and measured through units for instance fleets. The On-Demand units are not allowed to scale beyond this boundary. The parameter is used to split capacity allocation between On-Demand and Spot Instances.   
*Required*: No  
*Type*: Integer  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`MinimumCapacityUnits`  <a name="cfn-emr-cluster-computelimits-minimumcapacityunits"></a>
 The lower boundary of Amazon EC2 units. It is measured through vCPU cores or instances for instance groups and measured through units for instance fleets. Managed scaling activities are not allowed beyond this boundary. The limit only applies to the core and task nodes. The master node cannot be scaled after initial configuration.   
*Required*: Yes  
*Type*: Integer  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`UnitType`  <a name="cfn-emr-cluster-computelimits-unittype"></a>
 The unit type used for specifying a managed scaling policy.   
*Required*: Yes  
*Type*: String  
*Allowed values*: `InstanceFleetUnits | Instances | VCPU`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster Configuration
<a name="aws-properties-emr-cluster-configuration"></a>

**Note**  
Used only with Amazon EMR release 4.0 and later.

`Configuration` is a subproperty of `InstanceFleetConfig` or `InstanceGroupConfig`. `Configuration` specifies optional configurations for customizing open-source big data applications and environment parameters. A configuration consists of a classification, properties, and optional nested configurations. A classification refers to an application-specific configuration file. Properties are the settings you want to change in that file. For more information, see [Configuring Applications](https://docs.aws.amazon.com/emr/latest/ReleaseGuide/emr-configure-apps.html) in the *Amazon EMR Release Guide*.

## Syntax
<a name="aws-properties-emr-cluster-configuration-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-configuration-syntax.json"></a>

```
{
  "[Classification](#cfn-emr-cluster-configuration-classification)" : String,
  "[ConfigurationProperties](#cfn-emr-cluster-configuration-configurationproperties)" : {Key: Value, ...},
  "[Configurations](#cfn-emr-cluster-configuration-configurations)" : [ Configuration, ... ]
}
```

### YAML
<a name="aws-properties-emr-cluster-configuration-syntax.yaml"></a>

```
  [Classification](#cfn-emr-cluster-configuration-classification): String
  [ConfigurationProperties](#cfn-emr-cluster-configuration-configurationproperties): 
    Key: Value
  [Configurations](#cfn-emr-cluster-configuration-configurations): 
    - Configuration
```

## Properties
<a name="aws-properties-emr-cluster-configuration-properties"></a>

`Classification`  <a name="cfn-emr-cluster-configuration-classification"></a>
The classification within a configuration.  
*Required*: No  
*Type*: String  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`ConfigurationProperties`  <a name="cfn-emr-cluster-configuration-configurationproperties"></a>
A list of additional configurations to apply within a configuration object.  
*Required*: No  
*Type*: Object of String  
*Pattern*: `[a-zA-Z0-9]+`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Configurations`  <a name="cfn-emr-cluster-configuration-configurations"></a>
A list of additional configurations to apply within a configuration object.  
*Required*: No  
*Type*: Array of [Configuration](#aws-properties-emr-cluster-configuration)  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

# AWS::EMR::Cluster EbsBlockDeviceConfig
<a name="aws-properties-emr-cluster-ebsblockdeviceconfig"></a>

`EbsBlockDeviceConfig` is a subproperty of the `EbsConfiguration` property type. `EbsBlockDeviceConfig` defines the number and type of EBS volumes to associate with all EC2 instances in an EMR cluster.

## Syntax
<a name="aws-properties-emr-cluster-ebsblockdeviceconfig-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-ebsblockdeviceconfig-syntax.json"></a>

```
{
  "[VolumeSpecification](#cfn-emr-cluster-ebsblockdeviceconfig-volumespecification)" : VolumeSpecification,
  "[VolumesPerInstance](#cfn-emr-cluster-ebsblockdeviceconfig-volumesperinstance)" : Integer
}
```

### YAML
<a name="aws-properties-emr-cluster-ebsblockdeviceconfig-syntax.yaml"></a>

```
  [VolumeSpecification](#cfn-emr-cluster-ebsblockdeviceconfig-volumespecification): 
    VolumeSpecification
  [VolumesPerInstance](#cfn-emr-cluster-ebsblockdeviceconfig-volumesperinstance): Integer
```

## Properties
<a name="aws-properties-emr-cluster-ebsblockdeviceconfig-properties"></a>

`VolumeSpecification`  <a name="cfn-emr-cluster-ebsblockdeviceconfig-volumespecification"></a>
EBS volume specifications such as volume type, IOPS, size (GiB) and throughput (MiB/s) that are requested for the EBS volume attached to an Amazon EC2 instance in the cluster.  
*Required*: Yes  
*Type*: [VolumeSpecification](aws-properties-emr-cluster-volumespecification.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`VolumesPerInstance`  <a name="cfn-emr-cluster-ebsblockdeviceconfig-volumesperinstance"></a>
Number of EBS volumes with a specific volume configuration that are associated with every instance in the instance group  
*Required*: No  
*Type*: Integer  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster EbsConfiguration
<a name="aws-properties-emr-cluster-ebsconfiguration"></a>

`EbsConfiguration` is a subproperty of `InstanceFleetConfig` or `InstanceGroupConfig`. `EbsConfiguration` determines the EBS volumes to attach to EMR cluster instances.

## Syntax
<a name="aws-properties-emr-cluster-ebsconfiguration-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-ebsconfiguration-syntax.json"></a>

```
{
  "[EbsBlockDeviceConfigs](#cfn-emr-cluster-ebsconfiguration-ebsblockdeviceconfigs)" : [ EbsBlockDeviceConfig, ... ],
  "[EbsOptimized](#cfn-emr-cluster-ebsconfiguration-ebsoptimized)" : Boolean
}
```

### YAML
<a name="aws-properties-emr-cluster-ebsconfiguration-syntax.yaml"></a>

```
  [EbsBlockDeviceConfigs](#cfn-emr-cluster-ebsconfiguration-ebsblockdeviceconfigs): 
    - EbsBlockDeviceConfig
  [EbsOptimized](#cfn-emr-cluster-ebsconfiguration-ebsoptimized): Boolean
```

## Properties
<a name="aws-properties-emr-cluster-ebsconfiguration-properties"></a>

`EbsBlockDeviceConfigs`  <a name="cfn-emr-cluster-ebsconfiguration-ebsblockdeviceconfigs"></a>
An array of Amazon EBS volume specifications attached to a cluster instance.  
*Required*: No  
*Type*: Array of [EbsBlockDeviceConfig](aws-properties-emr-cluster-ebsblockdeviceconfig.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`EbsOptimized`  <a name="cfn-emr-cluster-ebsconfiguration-ebsoptimized"></a>
Indicates whether an Amazon EBS volume is EBS-optimized. The default is false. You should explicitly set this value to true to enable the Amazon EBS-optimized setting for an EC2 instance.  
*Required*: No  
*Type*: Boolean  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster HadoopJarStepConfig
<a name="aws-properties-emr-cluster-hadoopjarstepconfig"></a>

The `HadoopJarStepConfig` property type specifies a job flow step consisting of a JAR file whose main function will be executed. The main function submits a job for the cluster to execute as a step on the master node, and then waits for the job to finish or fail before executing subsequent steps.

## Syntax
<a name="aws-properties-emr-cluster-hadoopjarstepconfig-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-hadoopjarstepconfig-syntax.json"></a>

```
{
  "[Args](#cfn-emr-cluster-hadoopjarstepconfig-args)" : [ String, ... ],
  "[Jar](#cfn-emr-cluster-hadoopjarstepconfig-jar)" : String,
  "[MainClass](#cfn-emr-cluster-hadoopjarstepconfig-mainclass)" : String,
  "[StepProperties](#cfn-emr-cluster-hadoopjarstepconfig-stepproperties)" : [ KeyValue, ... ]
}
```

### YAML
<a name="aws-properties-emr-cluster-hadoopjarstepconfig-syntax.yaml"></a>

```
  [Args](#cfn-emr-cluster-hadoopjarstepconfig-args): 
    - String
  [Jar](#cfn-emr-cluster-hadoopjarstepconfig-jar): String
  [MainClass](#cfn-emr-cluster-hadoopjarstepconfig-mainclass): String
  [StepProperties](#cfn-emr-cluster-hadoopjarstepconfig-stepproperties): 
    - KeyValue
```

## Properties
<a name="aws-properties-emr-cluster-hadoopjarstepconfig-properties"></a>

`Args`  <a name="cfn-emr-cluster-hadoopjarstepconfig-args"></a>
A list of command line arguments passed to the JAR file's main function when executed.  
*Required*: No  
*Type*: Array of String  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`Jar`  <a name="cfn-emr-cluster-hadoopjarstepconfig-jar"></a>
A path to a JAR file run during the step.  
*Required*: Yes  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `10280`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`MainClass`  <a name="cfn-emr-cluster-hadoopjarstepconfig-mainclass"></a>
The name of the main class in the specified Java file. If not specified, the JAR file should specify a Main-Class in its manifest file.  
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `10280`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`StepProperties`  <a name="cfn-emr-cluster-hadoopjarstepconfig-stepproperties"></a>
A list of Java properties that are set when the step runs. You can use these properties to pass key-value pairs to your main function.  
*Required*: No  
*Type*: Array of [KeyValue](aws-properties-emr-cluster-keyvalue.md)  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

# AWS::EMR::Cluster InstanceFleetConfig
<a name="aws-properties-emr-cluster-instancefleetconfig"></a>

Use `InstanceFleetConfig` to define instance fleets for an EMR cluster. A cluster can not use both instance fleets and instance groups. For more information, see [Configure Instance Fleets](https://docs.aws.amazon.com//emr/latest/ManagementGuide/emr-instance-group-configuration.html) in the *Amazon EMR Management Guide*. 

**Note**  
The instance fleet configuration is available only in Amazon EMR versions 4.8.0 and later, excluding 5.0.x versions.

## Syntax
<a name="aws-properties-emr-cluster-instancefleetconfig-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-instancefleetconfig-syntax.json"></a>

```
{
  "[InstanceTypeConfigs](#cfn-emr-cluster-instancefleetconfig-instancetypeconfigs)" : [ InstanceTypeConfig, ... ],
  "[LaunchSpecifications](#cfn-emr-cluster-instancefleetconfig-launchspecifications)" : InstanceFleetProvisioningSpecifications,
  "[Name](#cfn-emr-cluster-instancefleetconfig-name)" : String,
  "[ResizeSpecifications](#cfn-emr-cluster-instancefleetconfig-resizespecifications)" : InstanceFleetResizingSpecifications,
  "[TargetOnDemandCapacity](#cfn-emr-cluster-instancefleetconfig-targetondemandcapacity)" : Integer,
  "[TargetSpotCapacity](#cfn-emr-cluster-instancefleetconfig-targetspotcapacity)" : Integer
}
```

### YAML
<a name="aws-properties-emr-cluster-instancefleetconfig-syntax.yaml"></a>

```
  [InstanceTypeConfigs](#cfn-emr-cluster-instancefleetconfig-instancetypeconfigs): 
    - InstanceTypeConfig
  [LaunchSpecifications](#cfn-emr-cluster-instancefleetconfig-launchspecifications): 
    InstanceFleetProvisioningSpecifications
  [Name](#cfn-emr-cluster-instancefleetconfig-name): String
  [ResizeSpecifications](#cfn-emr-cluster-instancefleetconfig-resizespecifications): 
    InstanceFleetResizingSpecifications
  [TargetOnDemandCapacity](#cfn-emr-cluster-instancefleetconfig-targetondemandcapacity): Integer
  [TargetSpotCapacity](#cfn-emr-cluster-instancefleetconfig-targetspotcapacity): Integer
```

## Properties
<a name="aws-properties-emr-cluster-instancefleetconfig-properties"></a>

`InstanceTypeConfigs`  <a name="cfn-emr-cluster-instancefleetconfig-instancetypeconfigs"></a>
The instance type configurations that define the Amazon EC2 instances in the instance fleet.  
*Required*: No  
*Type*: Array of [InstanceTypeConfig](aws-properties-emr-cluster-instancetypeconfig.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`LaunchSpecifications`  <a name="cfn-emr-cluster-instancefleetconfig-launchspecifications"></a>
The launch specification for the instance fleet.  
*Required*: No  
*Type*: [InstanceFleetProvisioningSpecifications](aws-properties-emr-cluster-instancefleetprovisioningspecifications.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Name`  <a name="cfn-emr-cluster-instancefleetconfig-name"></a>
The friendly name of the instance fleet.  
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`ResizeSpecifications`  <a name="cfn-emr-cluster-instancefleetconfig-resizespecifications"></a>
The resize specification for the instance fleet.  
*Required*: No  
*Type*: [InstanceFleetResizingSpecifications](aws-properties-emr-cluster-instancefleetresizingspecifications.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`TargetOnDemandCapacity`  <a name="cfn-emr-cluster-instancefleetconfig-targetondemandcapacity"></a>
The target capacity of On-Demand units for the instance fleet, which determines how many On-Demand instances to provision. When the instance fleet launches, Amazon EMR tries to provision On-Demand instances as specified by `InstanceTypeConfig`. Each instance configuration has a specified `WeightedCapacity`. When an On-Demand instance is provisioned, the `WeightedCapacity` units count toward the target capacity. Amazon EMR provisions instances until the target capacity is totally fulfilled, even if this results in an overage. For example, if there are 2 units remaining to fulfill capacity, and Amazon EMR can only provision an instance with a `WeightedCapacity` of 5 units, the instance is provisioned, and the target capacity is exceeded by 3 units.  
If not specified or set to 0, only Spot instances are provisioned for the instance fleet using `TargetSpotCapacity`. At least one of `TargetSpotCapacity` and `TargetOnDemandCapacity` should be greater than 0. For a master instance fleet, only one of `TargetSpotCapacity` and `TargetOnDemandCapacity` can be specified, and its value must be 1.
*Required*: No  
*Type*: Integer  
*Minimum*: `0`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`TargetSpotCapacity`  <a name="cfn-emr-cluster-instancefleetconfig-targetspotcapacity"></a>
The target capacity of Spot units for the instance fleet, which determines how many Spot instances to provision. When the instance fleet launches, Amazon EMR tries to provision Spot instances as specified by `InstanceTypeConfig`. Each instance configuration has a specified `WeightedCapacity`. When a Spot instance is provisioned, the `WeightedCapacity` units count toward the target capacity. Amazon EMR provisions instances until the target capacity is totally fulfilled, even if this results in an overage. For example, if there are 2 units remaining to fulfill capacity, and Amazon EMR can only provision an instance with a `WeightedCapacity` of 5 units, the instance is provisioned, and the target capacity is exceeded by 3 units.  
If not specified or set to 0, only On-Demand instances are provisioned for the instance fleet. At least one of `TargetSpotCapacity` and `TargetOnDemandCapacity` should be greater than 0. For a master instance fleet, only one of `TargetSpotCapacity` and `TargetOnDemandCapacity` can be specified, and its value must be 1.
*Required*: No  
*Type*: Integer  
*Minimum*: `0`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster InstanceFleetProvisioningSpecifications
<a name="aws-properties-emr-cluster-instancefleetprovisioningspecifications"></a>

`InstanceFleetProvisioningSpecification` is a subproperty of `InstanceFleetConfig`. `InstanceFleetProvisioningSpecification` defines the launch specification for Spot instances in an instance fleet, which determines the defined duration and provisioning timeout behavior for Spot instances.

**Note**  
The instance fleet configuration is available only in Amazon EMR versions 4.8.0 and later, excluding 5.0.x versions.

## Syntax
<a name="aws-properties-emr-cluster-instancefleetprovisioningspecifications-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-instancefleetprovisioningspecifications-syntax.json"></a>

```
{
  "[OnDemandSpecification](#cfn-emr-cluster-instancefleetprovisioningspecifications-ondemandspecification)" : OnDemandProvisioningSpecification,
  "[SpotSpecification](#cfn-emr-cluster-instancefleetprovisioningspecifications-spotspecification)" : SpotProvisioningSpecification
}
```

### YAML
<a name="aws-properties-emr-cluster-instancefleetprovisioningspecifications-syntax.yaml"></a>

```
  [OnDemandSpecification](#cfn-emr-cluster-instancefleetprovisioningspecifications-ondemandspecification): 
    OnDemandProvisioningSpecification
  [SpotSpecification](#cfn-emr-cluster-instancefleetprovisioningspecifications-spotspecification): 
    SpotProvisioningSpecification
```

## Properties
<a name="aws-properties-emr-cluster-instancefleetprovisioningspecifications-properties"></a>

`OnDemandSpecification`  <a name="cfn-emr-cluster-instancefleetprovisioningspecifications-ondemandspecification"></a>
 The launch specification for On-Demand Instances in the instance fleet, which determines the allocation strategy and capacity reservation options.  
The instance fleet configuration is available only in Amazon EMR releases 4.8.0 and later, excluding 5.0.x versions. On-Demand Instances allocation strategy is available in Amazon EMR releases 5.12.1 and later.
*Required*: No  
*Type*: [OnDemandProvisioningSpecification](aws-properties-emr-cluster-ondemandprovisioningspecification.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`SpotSpecification`  <a name="cfn-emr-cluster-instancefleetprovisioningspecifications-spotspecification"></a>
The launch specification for Spot instances in the fleet, which determines the allocation strategy, defined duration, and provisioning timeout behavior.  
*Required*: No  
*Type*: [SpotProvisioningSpecification](aws-properties-emr-cluster-spotprovisioningspecification.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster InstanceFleetResizingSpecifications
<a name="aws-properties-emr-cluster-instancefleetresizingspecifications"></a>

The resize specification for On-Demand and Spot Instances in the fleet.

## Syntax
<a name="aws-properties-emr-cluster-instancefleetresizingspecifications-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-instancefleetresizingspecifications-syntax.json"></a>

```
{
  "[OnDemandResizeSpecification](#cfn-emr-cluster-instancefleetresizingspecifications-ondemandresizespecification)" : OnDemandResizingSpecification,
  "[SpotResizeSpecification](#cfn-emr-cluster-instancefleetresizingspecifications-spotresizespecification)" : SpotResizingSpecification
}
```

### YAML
<a name="aws-properties-emr-cluster-instancefleetresizingspecifications-syntax.yaml"></a>

```
  [OnDemandResizeSpecification](#cfn-emr-cluster-instancefleetresizingspecifications-ondemandresizespecification): 
    OnDemandResizingSpecification
  [SpotResizeSpecification](#cfn-emr-cluster-instancefleetresizingspecifications-spotresizespecification): 
    SpotResizingSpecification
```

## Properties
<a name="aws-properties-emr-cluster-instancefleetresizingspecifications-properties"></a>

`OnDemandResizeSpecification`  <a name="cfn-emr-cluster-instancefleetresizingspecifications-ondemandresizespecification"></a>
The resize specification for On-Demand Instances in the instance fleet, which contains the allocation strategy, capacity reservation options, and the resize timeout period.   
*Required*: No  
*Type*: [OnDemandResizingSpecification](aws-properties-emr-cluster-ondemandresizingspecification.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`SpotResizeSpecification`  <a name="cfn-emr-cluster-instancefleetresizingspecifications-spotresizespecification"></a>
The resize specification for Spot Instances in the instance fleet, which contains the allocation strategy and the resize timeout period.   
*Required*: No  
*Type*: [SpotResizingSpecification](aws-properties-emr-cluster-spotresizingspecification.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster InstanceGroupConfig
<a name="aws-properties-emr-cluster-instancegroupconfig"></a>

Use `InstanceGroupConfig` to define instance groups for an EMR cluster. A cluster can not use both instance groups and instance fleets. For more information, see [Create a Cluster with Instance Fleets or Uniform Instance Groups](https://docs.aws.amazon.com//emr/latest/ManagementGuide/emr-instance-group-configuration.html) in the *Amazon EMR Management Guide*.

## Syntax
<a name="aws-properties-emr-cluster-instancegroupconfig-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-instancegroupconfig-syntax.json"></a>

```
{
  "[AutoScalingPolicy](#cfn-emr-cluster-instancegroupconfig-autoscalingpolicy)" : AutoScalingPolicy,
  "[BidPrice](#cfn-emr-cluster-instancegroupconfig-bidprice)" : String,
  "[Configurations](#cfn-emr-cluster-instancegroupconfig-configurations)" : [ Configuration, ... ],
  "[CustomAmiId](#cfn-emr-cluster-instancegroupconfig-customamiid)" : String,
  "[EbsConfiguration](#cfn-emr-cluster-instancegroupconfig-ebsconfiguration)" : EbsConfiguration,
  "[InstanceCount](#cfn-emr-cluster-instancegroupconfig-instancecount)" : Integer,
  "[InstanceType](#cfn-emr-cluster-instancegroupconfig-instancetype)" : String,
  "[Market](#cfn-emr-cluster-instancegroupconfig-market)" : String,
  "[Name](#cfn-emr-cluster-instancegroupconfig-name)" : String
}
```

### YAML
<a name="aws-properties-emr-cluster-instancegroupconfig-syntax.yaml"></a>

```
  [AutoScalingPolicy](#cfn-emr-cluster-instancegroupconfig-autoscalingpolicy): 
    AutoScalingPolicy
  [BidPrice](#cfn-emr-cluster-instancegroupconfig-bidprice): String
  [Configurations](#cfn-emr-cluster-instancegroupconfig-configurations): 
    - Configuration
  [CustomAmiId](#cfn-emr-cluster-instancegroupconfig-customamiid): String
  [EbsConfiguration](#cfn-emr-cluster-instancegroupconfig-ebsconfiguration): 
    EbsConfiguration
  [InstanceCount](#cfn-emr-cluster-instancegroupconfig-instancecount): Integer
  [InstanceType](#cfn-emr-cluster-instancegroupconfig-instancetype): String
  [Market](#cfn-emr-cluster-instancegroupconfig-market): String
  [Name](#cfn-emr-cluster-instancegroupconfig-name): String
```

## Properties
<a name="aws-properties-emr-cluster-instancegroupconfig-properties"></a>

`AutoScalingPolicy`  <a name="cfn-emr-cluster-instancegroupconfig-autoscalingpolicy"></a>
`AutoScalingPolicy` is a subproperty of the [InstanceGroupConfig](https://docs.aws.amazon.com//AWSCloudFormation/latest/UserGuide/aws-properties-emr-cluster-jobflowinstancesconfig-instancegroupconfig.html) property type that specifies the constraints and rules of an automatic scaling policy in Amazon EMR. The automatic scaling policy defines how an instance group dynamically adds and terminates EC2 instances in response to the value of a CloudWatch metric. Only core and task instance groups can use automatic scaling policies. For more information, see [Using Automatic Scaling in Amazon EMR](https://docs.aws.amazon.com//emr/latest/ManagementGuide/emr-automatic-scaling.html).  
*Required*: No  
*Type*: [AutoScalingPolicy](aws-properties-emr-cluster-autoscalingpolicy.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`BidPrice`  <a name="cfn-emr-cluster-instancegroupconfig-bidprice"></a>
If specified, indicates that the instance group uses Spot Instances. This is the maximum price you are willing to pay for Spot Instances. Specify `OnDemandPrice` to set the amount equal to the On-Demand price, or specify an amount in USD.  
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Configurations`  <a name="cfn-emr-cluster-instancegroupconfig-configurations"></a>
Amazon EMR releases 4.x or later.
The list of configurations supplied for an Amazon EMR cluster instance group. You can specify a separate configuration for each instance group (master, core, and task).  
*Required*: No  
*Type*: Array of [Configuration](aws-properties-emr-cluster-configuration.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`CustomAmiId`  <a name="cfn-emr-cluster-instancegroupconfig-customamiid"></a>
The custom AMI ID to use for the provisioned instance group.  
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`EbsConfiguration`  <a name="cfn-emr-cluster-instancegroupconfig-ebsconfiguration"></a>
EBS configurations that will be attached to each Amazon EC2 instance in the instance group.  
*Required*: No  
*Type*: [EbsConfiguration](aws-properties-emr-cluster-ebsconfiguration.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`InstanceCount`  <a name="cfn-emr-cluster-instancegroupconfig-instancecount"></a>
Target number of instances for the instance group.  
*Required*: Yes  
*Type*: Integer  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`InstanceType`  <a name="cfn-emr-cluster-instancegroupconfig-instancetype"></a>
The Amazon EC2 instance type for all instances in the instance group.  
*Required*: Yes  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `1`  
*Maximum*: `256`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Market`  <a name="cfn-emr-cluster-instancegroupconfig-market"></a>
Market type of the Amazon EC2 instances used to create a cluster node.  
*Required*: No  
*Type*: String  
*Allowed values*: `ON_DEMAND | SPOT`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Name`  <a name="cfn-emr-cluster-instancegroupconfig-name"></a>
Friendly name given to the instance group.  
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster InstanceTypeConfig
<a name="aws-properties-emr-cluster-instancetypeconfig"></a>

**Note**  
The instance fleet configuration is available only in Amazon EMR versions 4.8.0 and later, excluding 5.0.x versions.

`InstanceTypeConfig` is a sub-property of `InstanceFleetConfig`. `InstanceTypeConfig` determines the EC2 instances that Amazon EMR attempts to provision to fulfill On-Demand and Spot target capacities.

## Syntax
<a name="aws-properties-emr-cluster-instancetypeconfig-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-instancetypeconfig-syntax.json"></a>

```
{
  "[BidPrice](#cfn-emr-cluster-instancetypeconfig-bidprice)" : String,
  "[BidPriceAsPercentageOfOnDemandPrice](#cfn-emr-cluster-instancetypeconfig-bidpriceaspercentageofondemandprice)" : Number,
  "[Configurations](#cfn-emr-cluster-instancetypeconfig-configurations)" : [ Configuration, ... ],
  "[CustomAmiId](#cfn-emr-cluster-instancetypeconfig-customamiid)" : String,
  "[EbsConfiguration](#cfn-emr-cluster-instancetypeconfig-ebsconfiguration)" : EbsConfiguration,
  "[InstanceType](#cfn-emr-cluster-instancetypeconfig-instancetype)" : String,
  "[Priority](#cfn-emr-cluster-instancetypeconfig-priority)" : Number,
  "[WeightedCapacity](#cfn-emr-cluster-instancetypeconfig-weightedcapacity)" : Integer
}
```

### YAML
<a name="aws-properties-emr-cluster-instancetypeconfig-syntax.yaml"></a>

```
  [BidPrice](#cfn-emr-cluster-instancetypeconfig-bidprice): String
  [BidPriceAsPercentageOfOnDemandPrice](#cfn-emr-cluster-instancetypeconfig-bidpriceaspercentageofondemandprice): Number
  [Configurations](#cfn-emr-cluster-instancetypeconfig-configurations): 
    - Configuration
  [CustomAmiId](#cfn-emr-cluster-instancetypeconfig-customamiid): String
  [EbsConfiguration](#cfn-emr-cluster-instancetypeconfig-ebsconfiguration): 
    EbsConfiguration
  [InstanceType](#cfn-emr-cluster-instancetypeconfig-instancetype): String
  [Priority](#cfn-emr-cluster-instancetypeconfig-priority): Number
  [WeightedCapacity](#cfn-emr-cluster-instancetypeconfig-weightedcapacity): Integer
```

## Properties
<a name="aws-properties-emr-cluster-instancetypeconfig-properties"></a>

`BidPrice`  <a name="cfn-emr-cluster-instancetypeconfig-bidprice"></a>
The bid price for each Amazon EC2 Spot Instance type as defined by `InstanceType`. Expressed in USD. If neither `BidPrice` nor `BidPriceAsPercentageOfOnDemandPrice` is provided, `BidPriceAsPercentageOfOnDemandPrice` defaults to 100%.   
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`BidPriceAsPercentageOfOnDemandPrice`  <a name="cfn-emr-cluster-instancetypeconfig-bidpriceaspercentageofondemandprice"></a>
The bid price, as a percentage of On-Demand price, for each Amazon EC2 Spot Instance as defined by `InstanceType`. Expressed as a number (for example, 20 specifies 20%). If neither `BidPrice` nor `BidPriceAsPercentageOfOnDemandPrice` is provided, `BidPriceAsPercentageOfOnDemandPrice` defaults to 100%.  
*Required*: No  
*Type*: Number  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Configurations`  <a name="cfn-emr-cluster-instancetypeconfig-configurations"></a>
A configuration classification that applies when provisioning cluster instances, which can include configurations for applications and software that run on the cluster.  
*Required*: No  
*Type*: Array of [Configuration](aws-properties-emr-cluster-configuration.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`CustomAmiId`  <a name="cfn-emr-cluster-instancetypeconfig-customamiid"></a>
The custom AMI ID to use for the instance type.  
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`EbsConfiguration`  <a name="cfn-emr-cluster-instancetypeconfig-ebsconfiguration"></a>
The configuration of Amazon Elastic Block Store (Amazon EBS) attached to each instance as defined by `InstanceType`.   
*Required*: No  
*Type*: [EbsConfiguration](aws-properties-emr-cluster-ebsconfiguration.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`InstanceType`  <a name="cfn-emr-cluster-instancetypeconfig-instancetype"></a>
An Amazon EC2 instance type, such as `m3.xlarge`.   
*Required*: Yes  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `1`  
*Maximum*: `256`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Priority`  <a name="cfn-emr-cluster-instancetypeconfig-priority"></a>
The priority at which Amazon EMR launches the Amazon EC2 instances with this instance type. Priority starts at 0, which is the highest priority. Amazon EMR considers the highest priority first.  
*Required*: No  
*Type*: Number  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`WeightedCapacity`  <a name="cfn-emr-cluster-instancetypeconfig-weightedcapacity"></a>
The number of units that a provisioned instance of this type provides toward fulfilling the target capacities defined in `InstanceFleetConfig`. This value is 1 for a master instance fleet, and must be 1 or greater for core and task instance fleets. Defaults to 1 if not specified.   
*Required*: No  
*Type*: Integer  
*Minimum*: `0`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster JobFlowInstancesConfig
<a name="aws-properties-emr-cluster-jobflowinstancesconfig"></a>

`JobFlowInstancesConfig` is a property of the `AWS::EMR::Cluster` resource. `JobFlowInstancesConfig` defines the instance groups or instance fleets that comprise the cluster. `JobFlowInstancesConfig` must contain either `InstanceFleetConfig` or `InstanceGroupConfig`. They cannot be used together.

You can now define task instance groups or task instance fleets using the `TaskInstanceGroups` and `TaskInstanceFleets` subproperties. Using these subproperties reduces delays in provisioning task nodes compared to specifying task nodes with the `InstanceFleetConfig` and `InstanceGroupConfig` resources.

## Syntax
<a name="aws-properties-emr-cluster-jobflowinstancesconfig-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-jobflowinstancesconfig-syntax.json"></a>

```
{
  "[AdditionalMasterSecurityGroups](#cfn-emr-cluster-jobflowinstancesconfig-additionalmastersecuritygroups)" : [ String, ... ],
  "[AdditionalSlaveSecurityGroups](#cfn-emr-cluster-jobflowinstancesconfig-additionalslavesecuritygroups)" : [ String, ... ],
  "[CoreInstanceFleet](#cfn-emr-cluster-jobflowinstancesconfig-coreinstancefleet)" : InstanceFleetConfig,
  "[CoreInstanceGroup](#cfn-emr-cluster-jobflowinstancesconfig-coreinstancegroup)" : InstanceGroupConfig,
  "[Ec2KeyName](#cfn-emr-cluster-jobflowinstancesconfig-ec2keyname)" : String,
  "[Ec2SubnetId](#cfn-emr-cluster-jobflowinstancesconfig-ec2subnetid)" : String,
  "[Ec2SubnetIds](#cfn-emr-cluster-jobflowinstancesconfig-ec2subnetids)" : [ String, ... ],
  "[EmrManagedMasterSecurityGroup](#cfn-emr-cluster-jobflowinstancesconfig-emrmanagedmastersecuritygroup)" : String,
  "[EmrManagedSlaveSecurityGroup](#cfn-emr-cluster-jobflowinstancesconfig-emrmanagedslavesecuritygroup)" : String,
  "[HadoopVersion](#cfn-emr-cluster-jobflowinstancesconfig-hadoopversion)" : String,
  "[KeepJobFlowAliveWhenNoSteps](#cfn-emr-cluster-jobflowinstancesconfig-keepjobflowalivewhennosteps)" : Boolean,
  "[MasterInstanceFleet](#cfn-emr-cluster-jobflowinstancesconfig-masterinstancefleet)" : InstanceFleetConfig,
  "[MasterInstanceGroup](#cfn-emr-cluster-jobflowinstancesconfig-masterinstancegroup)" : InstanceGroupConfig,
  "[Placement](#cfn-emr-cluster-jobflowinstancesconfig-placement)" : PlacementType,
  "[ServiceAccessSecurityGroup](#cfn-emr-cluster-jobflowinstancesconfig-serviceaccesssecuritygroup)" : String,
  "[TaskInstanceFleets](#cfn-emr-cluster-jobflowinstancesconfig-taskinstancefleets)" : [ InstanceFleetConfig, ... ],
  "[TaskInstanceGroups](#cfn-emr-cluster-jobflowinstancesconfig-taskinstancegroups)" : [ InstanceGroupConfig, ... ],
  "[TerminationProtected](#cfn-emr-cluster-jobflowinstancesconfig-terminationprotected)" : Boolean,
  "[UnhealthyNodeReplacement](#cfn-emr-cluster-jobflowinstancesconfig-unhealthynodereplacement)" : Boolean
}
```

### YAML
<a name="aws-properties-emr-cluster-jobflowinstancesconfig-syntax.yaml"></a>

```
  [AdditionalMasterSecurityGroups](#cfn-emr-cluster-jobflowinstancesconfig-additionalmastersecuritygroups): 
    - String
  [AdditionalSlaveSecurityGroups](#cfn-emr-cluster-jobflowinstancesconfig-additionalslavesecuritygroups): 
    - String
  [CoreInstanceFleet](#cfn-emr-cluster-jobflowinstancesconfig-coreinstancefleet): 
    InstanceFleetConfig
  [CoreInstanceGroup](#cfn-emr-cluster-jobflowinstancesconfig-coreinstancegroup): 
    InstanceGroupConfig
  [Ec2KeyName](#cfn-emr-cluster-jobflowinstancesconfig-ec2keyname): String
  [Ec2SubnetId](#cfn-emr-cluster-jobflowinstancesconfig-ec2subnetid): String
  [Ec2SubnetIds](#cfn-emr-cluster-jobflowinstancesconfig-ec2subnetids): 
    - String
  [EmrManagedMasterSecurityGroup](#cfn-emr-cluster-jobflowinstancesconfig-emrmanagedmastersecuritygroup): String
  [EmrManagedSlaveSecurityGroup](#cfn-emr-cluster-jobflowinstancesconfig-emrmanagedslavesecuritygroup): String
  [HadoopVersion](#cfn-emr-cluster-jobflowinstancesconfig-hadoopversion): String
  [KeepJobFlowAliveWhenNoSteps](#cfn-emr-cluster-jobflowinstancesconfig-keepjobflowalivewhennosteps): Boolean
  [MasterInstanceFleet](#cfn-emr-cluster-jobflowinstancesconfig-masterinstancefleet): 
    InstanceFleetConfig
  [MasterInstanceGroup](#cfn-emr-cluster-jobflowinstancesconfig-masterinstancegroup): 
    InstanceGroupConfig
  [Placement](#cfn-emr-cluster-jobflowinstancesconfig-placement): 
    PlacementType
  [ServiceAccessSecurityGroup](#cfn-emr-cluster-jobflowinstancesconfig-serviceaccesssecuritygroup): String
  [TaskInstanceFleets](#cfn-emr-cluster-jobflowinstancesconfig-taskinstancefleets): 
    - InstanceFleetConfig
  [TaskInstanceGroups](#cfn-emr-cluster-jobflowinstancesconfig-taskinstancegroups): 
    - InstanceGroupConfig
  [TerminationProtected](#cfn-emr-cluster-jobflowinstancesconfig-terminationprotected): Boolean
  [UnhealthyNodeReplacement](#cfn-emr-cluster-jobflowinstancesconfig-unhealthynodereplacement): Boolean
```

## Properties
<a name="aws-properties-emr-cluster-jobflowinstancesconfig-properties"></a>

`AdditionalMasterSecurityGroups`  <a name="cfn-emr-cluster-jobflowinstancesconfig-additionalmastersecuritygroups"></a>
A list of additional Amazon EC2 security group IDs for the master node.  
*Required*: No  
*Type*: Array of String  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`AdditionalSlaveSecurityGroups`  <a name="cfn-emr-cluster-jobflowinstancesconfig-additionalslavesecuritygroups"></a>
A list of additional Amazon EC2 security group IDs for the core and task nodes.  
*Required*: No  
*Type*: Array of String  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`CoreInstanceFleet`  <a name="cfn-emr-cluster-jobflowinstancesconfig-coreinstancefleet"></a>
Describes the EC2 instances and instance configurations for the core instance fleet when using clusters with the instance fleet configuration.  
*Required*: No  
*Type*: [InstanceFleetConfig](aws-properties-emr-cluster-instancefleetconfig.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`CoreInstanceGroup`  <a name="cfn-emr-cluster-jobflowinstancesconfig-coreinstancegroup"></a>
Describes the EC2 instances and instance configurations for core instance groups when using clusters with the uniform instance group configuration.  
*Required*: No  
*Type*: [InstanceGroupConfig](aws-properties-emr-cluster-instancegroupconfig.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Ec2KeyName`  <a name="cfn-emr-cluster-jobflowinstancesconfig-ec2keyname"></a>
The name of the Amazon EC2 key pair that can be used to connect to the master node using SSH as the user called "hadoop."  
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Ec2SubnetId`  <a name="cfn-emr-cluster-jobflowinstancesconfig-ec2subnetid"></a>
Applies to clusters that use the uniform instance group configuration. To launch the cluster in Amazon Virtual Private Cloud (Amazon VPC), set this parameter to the identifier of the Amazon VPC subnet where you want the cluster to launch. If you do not specify this value and your account supports EC2-Classic, the cluster launches in EC2-Classic.  
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Ec2SubnetIds`  <a name="cfn-emr-cluster-jobflowinstancesconfig-ec2subnetids"></a>
Applies to clusters that use the instance fleet configuration. When multiple Amazon EC2 subnet IDs are specified, Amazon EMR evaluates them and launches instances in the optimal subnet.  
The instance fleet configuration is available only in Amazon EMR releases 4.8.0 and later, excluding 5.0.x versions.
*Required*: No  
*Type*: Array of String  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`EmrManagedMasterSecurityGroup`  <a name="cfn-emr-cluster-jobflowinstancesconfig-emrmanagedmastersecuritygroup"></a>
The identifier of the Amazon EC2 security group for the master node. If you specify `EmrManagedMasterSecurityGroup`, you must also specify `EmrManagedSlaveSecurityGroup`.  
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`EmrManagedSlaveSecurityGroup`  <a name="cfn-emr-cluster-jobflowinstancesconfig-emrmanagedslavesecuritygroup"></a>
The identifier of the Amazon EC2 security group for the core and task nodes. If you specify `EmrManagedSlaveSecurityGroup`, you must also specify `EmrManagedMasterSecurityGroup`.  
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`HadoopVersion`  <a name="cfn-emr-cluster-jobflowinstancesconfig-hadoopversion"></a>
Applies only to Amazon EMR release versions earlier than 4.0. The Hadoop version for the cluster. Valid inputs are "0.18" (no longer maintained), "0.20" (no longer maintained), "0.20.205" (no longer maintained), "1.0.3", "2.2.0", or "2.4.0". If you do not set this value, the default of 0.18 is used, unless the `AmiVersion` parameter is set in the RunJobFlow call, in which case the default version of Hadoop for that AMI version is used.  
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`KeepJobFlowAliveWhenNoSteps`  <a name="cfn-emr-cluster-jobflowinstancesconfig-keepjobflowalivewhennosteps"></a>
Specifies whether the cluster should remain available after completing all steps. Defaults to `false`. For more information about configuring cluster termination, see [Control Cluster Termination](https://docs.aws.amazon.com/emr/latest/ManagementGuide/emr-plan-termination.html) in the *EMR Management Guide*.  
*Required*: No  
*Type*: Boolean  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`MasterInstanceFleet`  <a name="cfn-emr-cluster-jobflowinstancesconfig-masterinstancefleet"></a>
Describes the EC2 instances and instance configurations for the master instance fleet when using clusters with the instance fleet configuration.  
*Required*: No  
*Type*: [InstanceFleetConfig](aws-properties-emr-cluster-instancefleetconfig.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`MasterInstanceGroup`  <a name="cfn-emr-cluster-jobflowinstancesconfig-masterinstancegroup"></a>
Describes the EC2 instances and instance configurations for the master instance group when using clusters with the uniform instance group configuration.  
*Required*: No  
*Type*: [InstanceGroupConfig](aws-properties-emr-cluster-instancegroupconfig.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Placement`  <a name="cfn-emr-cluster-jobflowinstancesconfig-placement"></a>
The Availability Zone in which the cluster runs.  
*Required*: No  
*Type*: [PlacementType](aws-properties-emr-cluster-placementtype.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`ServiceAccessSecurityGroup`  <a name="cfn-emr-cluster-jobflowinstancesconfig-serviceaccesssecuritygroup"></a>
The identifier of the Amazon EC2 security group for the Amazon EMR service to access clusters in VPC private subnets.  
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`TaskInstanceFleets`  <a name="cfn-emr-cluster-jobflowinstancesconfig-taskinstancefleets"></a>
Describes the EC2 instances and instance configurations for the task instance fleets when using clusters with the instance fleet configuration. These task instance fleets are added to the cluster as part of the cluster launch. Each task instance fleet must have a unique name specified so that CloudFormation can differentiate between the task instance fleets.  
You can currently specify only one task instance fleet for a cluster. After creating the cluster, you can only modify the mutable properties of `InstanceFleetConfig`, which are `TargetOnDemandCapacity` and `TargetSpotCapacity`. Modifying any other property results in cluster replacement.
To allow a maximum of 30 Amazon EC2 instance types per fleet, include `TaskInstanceFleets` when you create your cluster. If you create your cluster without `TaskInstanceFleets`, Amazon EMR uses its default allocation strategy, which allows for a maximum of five Amazon EC2 instance types.
*Required*: No  
*Type*: Array of [InstanceFleetConfig](aws-properties-emr-cluster-instancefleetconfig.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`TaskInstanceGroups`  <a name="cfn-emr-cluster-jobflowinstancesconfig-taskinstancegroups"></a>
Describes the EC2 instances and instance configurations for task instance groups when using clusters with the uniform instance group configuration. These task instance groups are added to the cluster as part of the cluster launch. Each task instance group must have a unique name specified so that CloudFormation can differentiate between the task instance groups.  
After creating the cluster, you can only modify the mutable properties of `InstanceGroupConfig`, which are `AutoScalingPolicy` and `InstanceCount`. Modifying any other property results in cluster replacement.
*Required*: No  
*Type*: Array of [InstanceGroupConfig](aws-properties-emr-cluster-instancegroupconfig.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`TerminationProtected`  <a name="cfn-emr-cluster-jobflowinstancesconfig-terminationprotected"></a>
Specifies whether to lock the cluster to prevent the Amazon EC2 instances from being terminated by API call, user intervention, or in the event of a job-flow error.  
*Required*: No  
*Type*: Boolean  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`UnhealthyNodeReplacement`  <a name="cfn-emr-cluster-jobflowinstancesconfig-unhealthynodereplacement"></a>
Indicates whether Amazon EMR should gracefully replace core nodes that have degraded within the cluster.  
*Required*: No  
*Type*: Boolean  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster KerberosAttributes
<a name="aws-properties-emr-cluster-kerberosattributes"></a>

`KerberosAttributes` is a property of the `AWS::EMR::Cluster` resource. `KerberosAttributes` define the cluster-specific Kerberos configuration when Kerberos authentication is enabled using a security configuration. The cluster-specific configuration must be compatible with the security configuration. For more information see [Use Kerberos Authentication](https://docs.aws.amazon.com/emr/latest/ManagementGuide/emr-kerberos.html) in the *EMR Management Guide*.

## Syntax
<a name="aws-properties-emr-cluster-kerberosattributes-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-kerberosattributes-syntax.json"></a>

```
{
  "[ADDomainJoinPassword](#cfn-emr-cluster-kerberosattributes-addomainjoinpassword)" : String,
  "[ADDomainJoinUser](#cfn-emr-cluster-kerberosattributes-addomainjoinuser)" : String,
  "[CrossRealmTrustPrincipalPassword](#cfn-emr-cluster-kerberosattributes-crossrealmtrustprincipalpassword)" : String,
  "[KdcAdminPassword](#cfn-emr-cluster-kerberosattributes-kdcadminpassword)" : String,
  "[Realm](#cfn-emr-cluster-kerberosattributes-realm)" : String
}
```

### YAML
<a name="aws-properties-emr-cluster-kerberosattributes-syntax.yaml"></a>

```
  [ADDomainJoinPassword](#cfn-emr-cluster-kerberosattributes-addomainjoinpassword): String
  [ADDomainJoinUser](#cfn-emr-cluster-kerberosattributes-addomainjoinuser): String
  [CrossRealmTrustPrincipalPassword](#cfn-emr-cluster-kerberosattributes-crossrealmtrustprincipalpassword): String
  [KdcAdminPassword](#cfn-emr-cluster-kerberosattributes-kdcadminpassword): String
  [Realm](#cfn-emr-cluster-kerberosattributes-realm): String
```

## Properties
<a name="aws-properties-emr-cluster-kerberosattributes-properties"></a>

`ADDomainJoinPassword`  <a name="cfn-emr-cluster-kerberosattributes-addomainjoinpassword"></a>
The Active Directory password for `ADDomainJoinUser`.  
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`ADDomainJoinUser`  <a name="cfn-emr-cluster-kerberosattributes-addomainjoinuser"></a>
Required only when establishing a cross-realm trust with an Active Directory domain. A user with sufficient privileges to join resources to the domain.  
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`CrossRealmTrustPrincipalPassword`  <a name="cfn-emr-cluster-kerberosattributes-crossrealmtrustprincipalpassword"></a>
Required only when establishing a cross-realm trust with a KDC in a different realm. The cross-realm principal password, which must be identical across realms.  
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`KdcAdminPassword`  <a name="cfn-emr-cluster-kerberosattributes-kdcadminpassword"></a>
The password used within the cluster for the kadmin service on the cluster-dedicated KDC, which maintains Kerberos principals, password policies, and keytabs for the cluster.  
*Required*: Yes  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`Realm`  <a name="cfn-emr-cluster-kerberosattributes-realm"></a>
The name of the Kerberos realm to which all nodes in a cluster belong. For example, `EC2.INTERNAL`.   
*Required*: Yes  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

# AWS::EMR::Cluster KeyValue
<a name="aws-properties-emr-cluster-keyvalue"></a>

`KeyValue` is a subproperty of the `HadoopJarStepConfig` property type. `KeyValue` is used to pass parameters to a step.

## Syntax
<a name="aws-properties-emr-cluster-keyvalue-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-keyvalue-syntax.json"></a>

```
{
  "[Key](#cfn-emr-cluster-keyvalue-key)" : String,
  "[Value](#cfn-emr-cluster-keyvalue-value)" : String
}
```

### YAML
<a name="aws-properties-emr-cluster-keyvalue-syntax.yaml"></a>

```
  [Key](#cfn-emr-cluster-keyvalue-key): String
  [Value](#cfn-emr-cluster-keyvalue-value): String
```

## Properties
<a name="aws-properties-emr-cluster-keyvalue-properties"></a>

`Key`  <a name="cfn-emr-cluster-keyvalue-key"></a>
The unique identifier of a key-value pair.  
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `10280`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`Value`  <a name="cfn-emr-cluster-keyvalue-value"></a>
The value part of the identified key.  
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `10280`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

# AWS::EMR::Cluster ManagedScalingPolicy
<a name="aws-properties-emr-cluster-managedscalingpolicy"></a>

 Managed scaling policy for an Amazon EMR cluster. The policy specifies the limits for resources that can be added or terminated from a cluster. The policy only applies to the core and task nodes. The master node cannot be scaled after initial configuration. 

## Syntax
<a name="aws-properties-emr-cluster-managedscalingpolicy-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-managedscalingpolicy-syntax.json"></a>

```
{
  "[ComputeLimits](#cfn-emr-cluster-managedscalingpolicy-computelimits)" : ComputeLimits,
  "[ScalingStrategy](#cfn-emr-cluster-managedscalingpolicy-scalingstrategy)" : String,
  "[UtilizationPerformanceIndex](#cfn-emr-cluster-managedscalingpolicy-utilizationperformanceindex)" : Integer
}
```

### YAML
<a name="aws-properties-emr-cluster-managedscalingpolicy-syntax.yaml"></a>

```
  [ComputeLimits](#cfn-emr-cluster-managedscalingpolicy-computelimits): 
    ComputeLimits
  [ScalingStrategy](#cfn-emr-cluster-managedscalingpolicy-scalingstrategy): String
  [UtilizationPerformanceIndex](#cfn-emr-cluster-managedscalingpolicy-utilizationperformanceindex): Integer
```

## Properties
<a name="aws-properties-emr-cluster-managedscalingpolicy-properties"></a>

`ComputeLimits`  <a name="cfn-emr-cluster-managedscalingpolicy-computelimits"></a>
The Amazon EC2 unit limits for a managed scaling policy. The managed scaling activity of a cluster is not allowed to go above or below these limits. The limit only applies to the core and task nodes. The master node cannot be scaled after initial configuration.  
*Required*: No  
*Type*: [ComputeLimits](aws-properties-emr-cluster-computelimits.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`ScalingStrategy`  <a name="cfn-emr-cluster-managedscalingpolicy-scalingstrategy"></a>
Determines whether a custom scaling utilization performance index can be set. Possible values include *ADVANCED* or *DEFAULT*.  
*Required*: No  
*Type*: String  
*Allowed values*: `DEFAULT | ADVANCED`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`UtilizationPerformanceIndex`  <a name="cfn-emr-cluster-managedscalingpolicy-utilizationperformanceindex"></a>
An integer value that represents an advanced scaling strategy. Setting a higher value optimizes for performance. Setting a lower value optimizes for resource conservation. Setting the value to 50 balances performance and resource conservation. Possible values are 1, 25, 50, 75, and 100.  
*Required*: No  
*Type*: Integer  
*Minimum*: `1`  
*Maximum*: `100`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster MetricDimension
<a name="aws-properties-emr-cluster-metricdimension"></a>

`MetricDimension` is a subproperty of the `CloudWatchAlarmDefinition` property type. `MetricDimension` specifies a CloudWatch dimension, which is specified with a `Key``Value` pair. The key is known as a `Name` in CloudWatch. By default, Amazon EMR uses one dimension whose `Key` is `JobFlowID` and `Value` is a variable representing the cluster ID, which is `${emr.clusterId}`. This enables the automatic scaling rule for EMR to bootstrap when the cluster ID becomes available during cluster creation.

## Syntax
<a name="aws-properties-emr-cluster-metricdimension-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-metricdimension-syntax.json"></a>

```
{
  "[Key](#cfn-emr-cluster-metricdimension-key)" : String,
  "[Value](#cfn-emr-cluster-metricdimension-value)" : String
}
```

### YAML
<a name="aws-properties-emr-cluster-metricdimension-syntax.yaml"></a>

```
  [Key](#cfn-emr-cluster-metricdimension-key): String
  [Value](#cfn-emr-cluster-metricdimension-value): String
```

## Properties
<a name="aws-properties-emr-cluster-metricdimension-properties"></a>

`Key`  <a name="cfn-emr-cluster-metricdimension-key"></a>
The dimension name.  
*Required*: Yes  
*Type*: String  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Value`  <a name="cfn-emr-cluster-metricdimension-value"></a>
The dimension value.  
*Required*: Yes  
*Type*: String  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster OnDemandCapacityReservationOptions
<a name="aws-properties-emr-cluster-ondemandcapacityreservationoptions"></a>

Describes the strategy for using unused Capacity Reservations for fulfilling On-Demand capacity.

## Syntax
<a name="aws-properties-emr-cluster-ondemandcapacityreservationoptions-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-ondemandcapacityreservationoptions-syntax.json"></a>

```
{
  "[CapacityReservationPreference](#cfn-emr-cluster-ondemandcapacityreservationoptions-capacityreservationpreference)" : String,
  "[CapacityReservationResourceGroupArn](#cfn-emr-cluster-ondemandcapacityreservationoptions-capacityreservationresourcegrouparn)" : String,
  "[UsageStrategy](#cfn-emr-cluster-ondemandcapacityreservationoptions-usagestrategy)" : String
}
```

### YAML
<a name="aws-properties-emr-cluster-ondemandcapacityreservationoptions-syntax.yaml"></a>

```
  [CapacityReservationPreference](#cfn-emr-cluster-ondemandcapacityreservationoptions-capacityreservationpreference): String
  [CapacityReservationResourceGroupArn](#cfn-emr-cluster-ondemandcapacityreservationoptions-capacityreservationresourcegrouparn): String
  [UsageStrategy](#cfn-emr-cluster-ondemandcapacityreservationoptions-usagestrategy): String
```

## Properties
<a name="aws-properties-emr-cluster-ondemandcapacityreservationoptions-properties"></a>

`CapacityReservationPreference`  <a name="cfn-emr-cluster-ondemandcapacityreservationoptions-capacityreservationpreference"></a>
Indicates the instance's Capacity Reservation preferences. Possible preferences include:  
+ `open` - The instance can run in any open Capacity Reservation that has matching attributes (instance type, platform, Availability Zone).
+ `none` - The instance avoids running in a Capacity Reservation even if one is available. The instance runs as an On-Demand Instance.
*Required*: No  
*Type*: String  
*Allowed values*: `open | none`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`CapacityReservationResourceGroupArn`  <a name="cfn-emr-cluster-ondemandcapacityreservationoptions-capacityreservationresourcegrouparn"></a>
The ARN of the Capacity Reservation resource group in which to run the instance.  
*Required*: No  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`UsageStrategy`  <a name="cfn-emr-cluster-ondemandcapacityreservationoptions-usagestrategy"></a>
Indicates whether to use unused Capacity Reservations for fulfilling On-Demand capacity.  
If you specify `use-capacity-reservations-first`, the fleet uses unused Capacity Reservations to fulfill On-Demand capacity up to the target On-Demand capacity. If multiple instance pools have unused Capacity Reservations, the On-Demand allocation strategy (`lowest-price`) is applied. If the number of unused Capacity Reservations is less than the On-Demand target capacity, the remaining On-Demand target capacity is launched according to the On-Demand allocation strategy (`lowest-price`).  
If you do not specify a value, the fleet fulfills the On-Demand capacity according to the chosen On-Demand allocation strategy.  
*Required*: No  
*Type*: String  
*Allowed values*: `use-capacity-reservations-first`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster OnDemandProvisioningSpecification
<a name="aws-properties-emr-cluster-ondemandprovisioningspecification"></a>

 The launch specification for On-Demand Instances in the instance fleet, which determines the allocation strategy. 

**Note**  
The instance fleet configuration is available only in Amazon EMR releases 4.8.0 and later, excluding 5.0.x versions. On-Demand Instances allocation strategy is available in Amazon EMR releases 5.12.1 and later.

## Syntax
<a name="aws-properties-emr-cluster-ondemandprovisioningspecification-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-ondemandprovisioningspecification-syntax.json"></a>

```
{
  "[AllocationStrategy](#cfn-emr-cluster-ondemandprovisioningspecification-allocationstrategy)" : String,
  "[CapacityReservationOptions](#cfn-emr-cluster-ondemandprovisioningspecification-capacityreservationoptions)" : OnDemandCapacityReservationOptions
}
```

### YAML
<a name="aws-properties-emr-cluster-ondemandprovisioningspecification-syntax.yaml"></a>

```
  [AllocationStrategy](#cfn-emr-cluster-ondemandprovisioningspecification-allocationstrategy): String
  [CapacityReservationOptions](#cfn-emr-cluster-ondemandprovisioningspecification-capacityreservationoptions): 
    OnDemandCapacityReservationOptions
```

## Properties
<a name="aws-properties-emr-cluster-ondemandprovisioningspecification-properties"></a>

`AllocationStrategy`  <a name="cfn-emr-cluster-ondemandprovisioningspecification-allocationstrategy"></a>
Specifies the strategy to use in launching On-Demand instance fleets. Available options are `lowest-price` and `prioritized`. `lowest-price` specifies to launch the instances with the lowest price first, and `prioritized` specifies that Amazon EMR should launch the instances with the highest priority first. The default is `lowest-price`.  
*Required*: Yes  
*Type*: String  
*Allowed values*: `lowest-price | prioritized`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`CapacityReservationOptions`  <a name="cfn-emr-cluster-ondemandprovisioningspecification-capacityreservationoptions"></a>
The launch specification for On-Demand instances in the instance fleet, which determines the allocation strategy.  
*Required*: No  
*Type*: [OnDemandCapacityReservationOptions](aws-properties-emr-cluster-ondemandcapacityreservationoptions.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster OnDemandResizingSpecification
<a name="aws-properties-emr-cluster-ondemandresizingspecification"></a>

The resize specification for On-Demand Instances in the instance fleet, which contains the resize timeout period. 

## Syntax
<a name="aws-properties-emr-cluster-ondemandresizingspecification-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-ondemandresizingspecification-syntax.json"></a>

```
{
  "[AllocationStrategy](#cfn-emr-cluster-ondemandresizingspecification-allocationstrategy)" : String,
  "[CapacityReservationOptions](#cfn-emr-cluster-ondemandresizingspecification-capacityreservationoptions)" : OnDemandCapacityReservationOptions,
  "[TimeoutDurationMinutes](#cfn-emr-cluster-ondemandresizingspecification-timeoutdurationminutes)" : Integer
}
```

### YAML
<a name="aws-properties-emr-cluster-ondemandresizingspecification-syntax.yaml"></a>

```
  [AllocationStrategy](#cfn-emr-cluster-ondemandresizingspecification-allocationstrategy): String
  [CapacityReservationOptions](#cfn-emr-cluster-ondemandresizingspecification-capacityreservationoptions): 
    OnDemandCapacityReservationOptions
  [TimeoutDurationMinutes](#cfn-emr-cluster-ondemandresizingspecification-timeoutdurationminutes): Integer
```

## Properties
<a name="aws-properties-emr-cluster-ondemandresizingspecification-properties"></a>

`AllocationStrategy`  <a name="cfn-emr-cluster-ondemandresizingspecification-allocationstrategy"></a>
Specifies the allocation strategy to use to launch On-Demand instances during a resize. The default is `lowest-price`.  
*Required*: No  
*Type*: String  
*Allowed values*: `lowest-price | prioritized`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`CapacityReservationOptions`  <a name="cfn-emr-cluster-ondemandresizingspecification-capacityreservationoptions"></a>
Property description not available.  
*Required*: No  
*Type*: [OnDemandCapacityReservationOptions](aws-properties-emr-cluster-ondemandcapacityreservationoptions.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`TimeoutDurationMinutes`  <a name="cfn-emr-cluster-ondemandresizingspecification-timeoutdurationminutes"></a>
On-Demand resize timeout in minutes. If On-Demand Instances are not provisioned within this time, the resize workflow stops. The minimum value is 5 minutes, and the maximum value is 10,080 minutes (7 days). The timeout applies to all resize workflows on the Instance Fleet. The resize could be triggered by Amazon EMR Managed Scaling or by the customer (via Amazon EMR Console, Amazon EMR CLI modify-instance-fleet or Amazon EMR SDK ModifyInstanceFleet API) or by Amazon EMR due to Amazon EC2 Spot Reclamation.  
*Required*: No  
*Type*: Integer  
*Minimum*: `0`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster PlacementGroupConfig
<a name="aws-properties-emr-cluster-placementgroupconfig"></a>

Placement group configuration for an Amazon EMR cluster. The configuration specifies the placement strategy that can be applied to instance roles during cluster creation.

To use this configuration, consider attaching managed policy AmazonElasticMapReducePlacementGroupPolicy to the Amazon EMR role.

## Syntax
<a name="aws-properties-emr-cluster-placementgroupconfig-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-placementgroupconfig-syntax.json"></a>

```
{
  "[InstanceRole](#cfn-emr-cluster-placementgroupconfig-instancerole)" : String,
  "[PlacementStrategy](#cfn-emr-cluster-placementgroupconfig-placementstrategy)" : String
}
```

### YAML
<a name="aws-properties-emr-cluster-placementgroupconfig-syntax.yaml"></a>

```
  [InstanceRole](#cfn-emr-cluster-placementgroupconfig-instancerole): String
  [PlacementStrategy](#cfn-emr-cluster-placementgroupconfig-placementstrategy): String
```

## Properties
<a name="aws-properties-emr-cluster-placementgroupconfig-properties"></a>

`InstanceRole`  <a name="cfn-emr-cluster-placementgroupconfig-instancerole"></a>
Role of the instance in the cluster.  
Starting with Amazon EMR release 5.23.0, the only supported instance role is `MASTER`.  
*Required*: Yes  
*Type*: String  
*Allowed values*: `MASTER | CORE | TASK`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`PlacementStrategy`  <a name="cfn-emr-cluster-placementgroupconfig-placementstrategy"></a>
Amazon EC2 Placement Group strategy associated with instance role.  
Starting with Amazon EMR release 5.23.0, the only supported placement strategy is `SPREAD` for the `MASTER` instance role.  
*Required*: No  
*Type*: String  
*Allowed values*: `SPREAD | PARTITION | CLUSTER | NONE`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

# AWS::EMR::Cluster PlacementType
<a name="aws-properties-emr-cluster-placementtype"></a>

`PlacementType` is a property of the `AWS::EMR::Cluster` resource. `PlacementType` determines the Amazon EC2 Availability Zone configuration of the cluster (job flow).

## Syntax
<a name="aws-properties-emr-cluster-placementtype-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-placementtype-syntax.json"></a>

```
{
  "[AvailabilityZone](#cfn-emr-cluster-placementtype-availabilityzone)" : String
}
```

### YAML
<a name="aws-properties-emr-cluster-placementtype-syntax.yaml"></a>

```
  [AvailabilityZone](#cfn-emr-cluster-placementtype-availabilityzone): String
```

## Properties
<a name="aws-properties-emr-cluster-placementtype-properties"></a>

`AvailabilityZone`  <a name="cfn-emr-cluster-placementtype-availabilityzone"></a>
The Amazon EC2 Availability Zone for the cluster. `AvailabilityZone` is used for uniform instance groups, while `AvailabilityZones` (plural) is used for instance fleets.  
*Required*: Yes  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `10280`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster ScalingAction
<a name="aws-properties-emr-cluster-scalingaction"></a>

`ScalingAction` is a subproperty of the `ScalingRule` property type. `ScalingAction` determines the type of adjustment the automatic scaling activity makes when triggered, and the periodicity of the adjustment.

## Syntax
<a name="aws-properties-emr-cluster-scalingaction-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-scalingaction-syntax.json"></a>

```
{
  "[Market](#cfn-emr-cluster-scalingaction-market)" : String,
  "[SimpleScalingPolicyConfiguration](#cfn-emr-cluster-scalingaction-simplescalingpolicyconfiguration)" : SimpleScalingPolicyConfiguration
}
```

### YAML
<a name="aws-properties-emr-cluster-scalingaction-syntax.yaml"></a>

```
  [Market](#cfn-emr-cluster-scalingaction-market): String
  [SimpleScalingPolicyConfiguration](#cfn-emr-cluster-scalingaction-simplescalingpolicyconfiguration): 
    SimpleScalingPolicyConfiguration
```

## Properties
<a name="aws-properties-emr-cluster-scalingaction-properties"></a>

`Market`  <a name="cfn-emr-cluster-scalingaction-market"></a>
Not available for instance groups. Instance groups use the market type specified for the group.  
*Required*: No  
*Type*: String  
*Allowed values*: `ON_DEMAND | SPOT`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`SimpleScalingPolicyConfiguration`  <a name="cfn-emr-cluster-scalingaction-simplescalingpolicyconfiguration"></a>
The type of adjustment the automatic scaling activity makes when triggered, and the periodicity of the adjustment.  
*Required*: Yes  
*Type*: [SimpleScalingPolicyConfiguration](aws-properties-emr-cluster-simplescalingpolicyconfiguration.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster ScalingConstraints
<a name="aws-properties-emr-cluster-scalingconstraints"></a>

`ScalingConstraints` is a subproperty of the `AutoScalingPolicy` property type. `ScalingConstraints` defines the upper and lower EC2 instance limits for an automatic scaling policy. Automatic scaling activities triggered by automatic scaling rules will not cause an instance group to grow above or shrink below these limits.

## Syntax
<a name="aws-properties-emr-cluster-scalingconstraints-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-scalingconstraints-syntax.json"></a>

```
{
  "[MaxCapacity](#cfn-emr-cluster-scalingconstraints-maxcapacity)" : Integer,
  "[MinCapacity](#cfn-emr-cluster-scalingconstraints-mincapacity)" : Integer
}
```

### YAML
<a name="aws-properties-emr-cluster-scalingconstraints-syntax.yaml"></a>

```
  [MaxCapacity](#cfn-emr-cluster-scalingconstraints-maxcapacity): Integer
  [MinCapacity](#cfn-emr-cluster-scalingconstraints-mincapacity): Integer
```

## Properties
<a name="aws-properties-emr-cluster-scalingconstraints-properties"></a>

`MaxCapacity`  <a name="cfn-emr-cluster-scalingconstraints-maxcapacity"></a>
The upper boundary of Amazon EC2 instances in an instance group beyond which scaling activities are not allowed to grow. Scale-out activities will not add instances beyond this boundary.  
*Required*: Yes  
*Type*: Integer  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`MinCapacity`  <a name="cfn-emr-cluster-scalingconstraints-mincapacity"></a>
The lower boundary of Amazon EC2 instances in an instance group below which scaling activities are not allowed to shrink. Scale-in activities will not terminate instances below this boundary.  
*Required*: Yes  
*Type*: Integer  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster ScalingRule
<a name="aws-properties-emr-cluster-scalingrule"></a>

`ScalingRule` is a subproperty of the `AutoScalingPolicy` property type. `ScalingRule` defines the scale-in or scale-out rules for scaling activity, including the CloudWatch metric alarm that triggers activity, how EC2 instances are added or removed, and the periodicity of adjustments. The automatic scaling policy for an instance group can comprise one or more automatic scaling rules.

## Syntax
<a name="aws-properties-emr-cluster-scalingrule-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-scalingrule-syntax.json"></a>

```
{
  "[Action](#cfn-emr-cluster-scalingrule-action)" : ScalingAction,
  "[Description](#cfn-emr-cluster-scalingrule-description)" : String,
  "[Name](#cfn-emr-cluster-scalingrule-name)" : String,
  "[Trigger](#cfn-emr-cluster-scalingrule-trigger)" : ScalingTrigger
}
```

### YAML
<a name="aws-properties-emr-cluster-scalingrule-syntax.yaml"></a>

```
  [Action](#cfn-emr-cluster-scalingrule-action): 
    ScalingAction
  [Description](#cfn-emr-cluster-scalingrule-description): String
  [Name](#cfn-emr-cluster-scalingrule-name): String
  [Trigger](#cfn-emr-cluster-scalingrule-trigger): 
    ScalingTrigger
```

## Properties
<a name="aws-properties-emr-cluster-scalingrule-properties"></a>

`Action`  <a name="cfn-emr-cluster-scalingrule-action"></a>
The conditions that trigger an automatic scaling activity.  
*Required*: Yes  
*Type*: [ScalingAction](aws-properties-emr-cluster-scalingaction.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Description`  <a name="cfn-emr-cluster-scalingrule-description"></a>
A friendly, more verbose description of the automatic scaling rule.  
*Required*: No  
*Type*: String  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Name`  <a name="cfn-emr-cluster-scalingrule-name"></a>
The name used to identify an automatic scaling rule. Rule names must be unique within a scaling policy.  
*Required*: Yes  
*Type*: String  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Trigger`  <a name="cfn-emr-cluster-scalingrule-trigger"></a>
The CloudWatch alarm definition that determines when automatic scaling activity is triggered.  
*Required*: Yes  
*Type*: [ScalingTrigger](aws-properties-emr-cluster-scalingtrigger.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster ScalingTrigger
<a name="aws-properties-emr-cluster-scalingtrigger"></a>

`ScalingTrigger` is a subproperty of the `ScalingRule` property type. `ScalingTrigger` determines the conditions that trigger an automatic scaling activity.

## Syntax
<a name="aws-properties-emr-cluster-scalingtrigger-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-scalingtrigger-syntax.json"></a>

```
{
  "[CloudWatchAlarmDefinition](#cfn-emr-cluster-scalingtrigger-cloudwatchalarmdefinition)" : CloudWatchAlarmDefinition
}
```

### YAML
<a name="aws-properties-emr-cluster-scalingtrigger-syntax.yaml"></a>

```
  [CloudWatchAlarmDefinition](#cfn-emr-cluster-scalingtrigger-cloudwatchalarmdefinition): 
    CloudWatchAlarmDefinition
```

## Properties
<a name="aws-properties-emr-cluster-scalingtrigger-properties"></a>

`CloudWatchAlarmDefinition`  <a name="cfn-emr-cluster-scalingtrigger-cloudwatchalarmdefinition"></a>
The definition of a CloudWatch metric alarm. When the defined alarm conditions are met along with other trigger parameters, scaling activity begins.  
*Required*: Yes  
*Type*: [CloudWatchAlarmDefinition](aws-properties-emr-cluster-cloudwatchalarmdefinition.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster ScriptBootstrapActionConfig
<a name="aws-properties-emr-cluster-scriptbootstrapactionconfig"></a>

`ScriptBootstrapActionConfig` is a subproperty of the `BootstrapActionConfig` property type. `ScriptBootstrapActionConfig` specifies the arguments and location of the bootstrap script for EMR to run on all cluster nodes before it installs open-source big data applications on them.

## Syntax
<a name="aws-properties-emr-cluster-scriptbootstrapactionconfig-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-scriptbootstrapactionconfig-syntax.json"></a>

```
{
  "[Args](#cfn-emr-cluster-scriptbootstrapactionconfig-args)" : [ String, ... ],
  "[Path](#cfn-emr-cluster-scriptbootstrapactionconfig-path)" : String
}
```

### YAML
<a name="aws-properties-emr-cluster-scriptbootstrapactionconfig-syntax.yaml"></a>

```
  [Args](#cfn-emr-cluster-scriptbootstrapactionconfig-args): 
    - String
  [Path](#cfn-emr-cluster-scriptbootstrapactionconfig-path): String
```

## Properties
<a name="aws-properties-emr-cluster-scriptbootstrapactionconfig-properties"></a>

`Args`  <a name="cfn-emr-cluster-scriptbootstrapactionconfig-args"></a>
A list of command line arguments to pass to the bootstrap action script.  
*Required*: No  
*Type*: Array of String  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`Path`  <a name="cfn-emr-cluster-scriptbootstrapactionconfig-path"></a>
Location in Amazon S3 of the script to run during a bootstrap action.  
*Required*: Yes  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `10280`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

# AWS::EMR::Cluster SimpleScalingPolicyConfiguration
<a name="aws-properties-emr-cluster-simplescalingpolicyconfiguration"></a>

`SimpleScalingPolicyConfiguration` is a subproperty of the `ScalingAction` property type. `SimpleScalingPolicyConfiguration` determines how an automatic scaling action adds or removes instances, the cooldown period, and the number of EC2 instances that are added each time the CloudWatch metric alarm condition is satisfied.

## Syntax
<a name="aws-properties-emr-cluster-simplescalingpolicyconfiguration-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-simplescalingpolicyconfiguration-syntax.json"></a>

```
{
  "[AdjustmentType](#cfn-emr-cluster-simplescalingpolicyconfiguration-adjustmenttype)" : String,
  "[CoolDown](#cfn-emr-cluster-simplescalingpolicyconfiguration-cooldown)" : Integer,
  "[ScalingAdjustment](#cfn-emr-cluster-simplescalingpolicyconfiguration-scalingadjustment)" : Integer
}
```

### YAML
<a name="aws-properties-emr-cluster-simplescalingpolicyconfiguration-syntax.yaml"></a>

```
  [AdjustmentType](#cfn-emr-cluster-simplescalingpolicyconfiguration-adjustmenttype): String
  [CoolDown](#cfn-emr-cluster-simplescalingpolicyconfiguration-cooldown): Integer
  [ScalingAdjustment](#cfn-emr-cluster-simplescalingpolicyconfiguration-scalingadjustment): Integer
```

## Properties
<a name="aws-properties-emr-cluster-simplescalingpolicyconfiguration-properties"></a>

`AdjustmentType`  <a name="cfn-emr-cluster-simplescalingpolicyconfiguration-adjustmenttype"></a>
The way in which Amazon EC2 instances are added (if `ScalingAdjustment` is a positive number) or terminated (if `ScalingAdjustment` is a negative number) each time the scaling activity is triggered. `CHANGE_IN_CAPACITY` is the default. `CHANGE_IN_CAPACITY` indicates that the Amazon EC2 instance count increments or decrements by `ScalingAdjustment`, which should be expressed as an integer. `PERCENT_CHANGE_IN_CAPACITY` indicates the instance count increments or decrements by the percentage specified by `ScalingAdjustment`, which should be expressed as an integer. For example, 20 indicates an increase in 20% increments of cluster capacity. `EXACT_CAPACITY` indicates the scaling activity results in an instance group with the number of Amazon EC2 instances specified by `ScalingAdjustment`, which should be expressed as a positive integer.  
*Required*: No  
*Type*: String  
*Allowed values*: `CHANGE_IN_CAPACITY | PERCENT_CHANGE_IN_CAPACITY | EXACT_CAPACITY`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`CoolDown`  <a name="cfn-emr-cluster-simplescalingpolicyconfiguration-cooldown"></a>
The amount of time, in seconds, after a scaling activity completes before any further trigger-related scaling activities can start. The default value is 0.  
*Required*: No  
*Type*: Integer  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`ScalingAdjustment`  <a name="cfn-emr-cluster-simplescalingpolicyconfiguration-scalingadjustment"></a>
The amount by which to scale in or scale out, based on the specified `AdjustmentType`. A positive value adds to the instance group's Amazon EC2 instance count while a negative number removes instances. If `AdjustmentType` is set to `EXACT_CAPACITY`, the number should only be a positive integer. If `AdjustmentType` is set to `PERCENT_CHANGE_IN_CAPACITY`, the value should express the percentage as an integer. For example, -20 indicates a decrease in 20% increments of cluster capacity.  
*Required*: Yes  
*Type*: Integer  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster SpotProvisioningSpecification
<a name="aws-properties-emr-cluster-spotprovisioningspecification"></a>

`SpotProvisioningSpecification` is a subproperty of the `InstanceFleetProvisioningSpecifications` property type. `SpotProvisioningSpecification` determines the launch specification for Spot instances in the instance fleet, which includes the defined duration and provisioning timeout behavior.

**Note**  
The instance fleet configuration is available only in Amazon EMR versions 4.8.0 and later, excluding 5.0.x versions.

## Syntax
<a name="aws-properties-emr-cluster-spotprovisioningspecification-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-spotprovisioningspecification-syntax.json"></a>

```
{
  "[AllocationStrategy](#cfn-emr-cluster-spotprovisioningspecification-allocationstrategy)" : String,
  "[BlockDurationMinutes](#cfn-emr-cluster-spotprovisioningspecification-blockdurationminutes)" : Integer,
  "[TimeoutAction](#cfn-emr-cluster-spotprovisioningspecification-timeoutaction)" : String,
  "[TimeoutDurationMinutes](#cfn-emr-cluster-spotprovisioningspecification-timeoutdurationminutes)" : Integer
}
```

### YAML
<a name="aws-properties-emr-cluster-spotprovisioningspecification-syntax.yaml"></a>

```
  [AllocationStrategy](#cfn-emr-cluster-spotprovisioningspecification-allocationstrategy): String
  [BlockDurationMinutes](#cfn-emr-cluster-spotprovisioningspecification-blockdurationminutes): Integer
  [TimeoutAction](#cfn-emr-cluster-spotprovisioningspecification-timeoutaction): String
  [TimeoutDurationMinutes](#cfn-emr-cluster-spotprovisioningspecification-timeoutdurationminutes): Integer
```

## Properties
<a name="aws-properties-emr-cluster-spotprovisioningspecification-properties"></a>

`AllocationStrategy`  <a name="cfn-emr-cluster-spotprovisioningspecification-allocationstrategy"></a>
Specifies one of the following strategies to launch Spot Instance fleets: `capacity-optimized`, `price-capacity-optimized`, `lowest-price`, or `diversified`, and `capacity-optimized-prioritized`. For more information on the provisioning strategies, see [Allocation strategies for Spot Instances](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-fleet-allocation-strategy.html) in the *Amazon EC2 User Guide for Linux Instances*.  
When you launch a Spot Instance fleet with the old console, it automatically launches with the `capacity-optimized` strategy. You can't change the allocation strategy from the old console.
*Required*: No  
*Type*: String  
*Allowed values*: `capacity-optimized | price-capacity-optimized | lowest-price | diversified | capacity-optimized-prioritized`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`BlockDurationMinutes`  <a name="cfn-emr-cluster-spotprovisioningspecification-blockdurationminutes"></a>
The defined duration for Spot Instances (also known as Spot blocks) in minutes. When specified, the Spot Instance does not terminate before the defined duration expires, and defined duration pricing for Spot Instances applies. Valid values are 60, 120, 180, 240, 300, or 360. The duration period starts as soon as a Spot Instance receives its instance ID. At the end of the duration, Amazon EC2 marks the Spot Instance for termination and provides a Spot Instance termination notice, which gives the instance a two-minute warning before it terminates.   
Spot Instances with a defined duration (also known as Spot blocks) are no longer available to new customers from July 1, 2021. For customers who have previously used the feature, we will continue to support Spot Instances with a defined duration until December 31, 2022. 
*Required*: No  
*Type*: Integer  
*Minimum*: `0`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`TimeoutAction`  <a name="cfn-emr-cluster-spotprovisioningspecification-timeoutaction"></a>
The action to take when `TargetSpotCapacity` has not been fulfilled when the `TimeoutDurationMinutes` has expired; that is, when all Spot Instances could not be provisioned within the Spot provisioning timeout. Valid values are `TERMINATE_CLUSTER` and `SWITCH_TO_ON_DEMAND`. SWITCH\$1TO\$1ON\$1DEMAND specifies that if no Spot Instances are available, On-Demand Instances should be provisioned to fulfill any remaining Spot capacity.  
*Required*: Yes  
*Type*: String  
*Allowed values*: `SWITCH_TO_ON_DEMAND | TERMINATE_CLUSTER`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`TimeoutDurationMinutes`  <a name="cfn-emr-cluster-spotprovisioningspecification-timeoutdurationminutes"></a>
The Spot provisioning timeout period in minutes. If Spot Instances are not provisioned within this time period, the `TimeOutAction` is taken. Minimum value is 5 and maximum value is 1440. The timeout applies only during initial provisioning, when the cluster is first created.  
*Required*: Yes  
*Type*: Integer  
*Minimum*: `0`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster SpotResizingSpecification
<a name="aws-properties-emr-cluster-spotresizingspecification"></a>

The resize specification for Spot Instances in the instance fleet, which contains the resize timeout period. 

## Syntax
<a name="aws-properties-emr-cluster-spotresizingspecification-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-spotresizingspecification-syntax.json"></a>

```
{
  "[AllocationStrategy](#cfn-emr-cluster-spotresizingspecification-allocationstrategy)" : String,
  "[TimeoutDurationMinutes](#cfn-emr-cluster-spotresizingspecification-timeoutdurationminutes)" : Integer
}
```

### YAML
<a name="aws-properties-emr-cluster-spotresizingspecification-syntax.yaml"></a>

```
  [AllocationStrategy](#cfn-emr-cluster-spotresizingspecification-allocationstrategy): String
  [TimeoutDurationMinutes](#cfn-emr-cluster-spotresizingspecification-timeoutdurationminutes): Integer
```

## Properties
<a name="aws-properties-emr-cluster-spotresizingspecification-properties"></a>

`AllocationStrategy`  <a name="cfn-emr-cluster-spotresizingspecification-allocationstrategy"></a>
Specifies the allocation strategy to use to launch Spot instances during a resize. If you run Amazon EMR releases 6.9.0 or higher, the default is `price-capacity-optimized`. If you run Amazon EMR releases 6.8.0 or lower, the default is `capacity-optimized`.  
*Required*: No  
*Type*: String  
*Allowed values*: `capacity-optimized | price-capacity-optimized | lowest-price | diversified | capacity-optimized-prioritized`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`TimeoutDurationMinutes`  <a name="cfn-emr-cluster-spotresizingspecification-timeoutdurationminutes"></a>
Spot resize timeout in minutes. If Spot Instances are not provisioned within this time, the resize workflow will stop provisioning of Spot instances. Minimum value is 5 minutes and maximum value is 10,080 minutes (7 days). The timeout applies to all resize workflows on the Instance Fleet. The resize could be triggered by Amazon EMR Managed Scaling or by the customer (via Amazon EMR Console, Amazon EMR CLI modify-instance-fleet or Amazon EMR SDK ModifyInstanceFleet API) or by Amazon EMR due to Amazon EC2 Spot Reclamation.  
*Required*: No  
*Type*: Integer  
*Minimum*: `0`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster StepConfig
<a name="aws-properties-emr-cluster-stepconfig"></a>

`StepConfig` is a property of the `AWS::EMR::Cluster` resource. The `StepConfig` property type specifies a cluster (job flow) step, which runs only on the master node. Steps are used to submit data processing jobs to the cluster.

## Syntax
<a name="aws-properties-emr-cluster-stepconfig-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-stepconfig-syntax.json"></a>

```
{
  "[ActionOnFailure](#cfn-emr-cluster-stepconfig-actiononfailure)" : String,
  "[HadoopJarStep](#cfn-emr-cluster-stepconfig-hadoopjarstep)" : HadoopJarStepConfig,
  "[Name](#cfn-emr-cluster-stepconfig-name)" : String
}
```

### YAML
<a name="aws-properties-emr-cluster-stepconfig-syntax.yaml"></a>

```
  [ActionOnFailure](#cfn-emr-cluster-stepconfig-actiononfailure): String
  [HadoopJarStep](#cfn-emr-cluster-stepconfig-hadoopjarstep): 
    HadoopJarStepConfig
  [Name](#cfn-emr-cluster-stepconfig-name): String
```

## Properties
<a name="aws-properties-emr-cluster-stepconfig-properties"></a>

`ActionOnFailure`  <a name="cfn-emr-cluster-stepconfig-actiononfailure"></a>
The action to take when the cluster step fails. Possible values are `CANCEL_AND_WAIT` and `CONTINUE`.  
*Required*: No  
*Type*: String  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`HadoopJarStep`  <a name="cfn-emr-cluster-stepconfig-hadoopjarstep"></a>
The JAR file used for the step.  
*Required*: Yes  
*Type*: [HadoopJarStepConfig](aws-properties-emr-cluster-hadoopjarstepconfig.md)  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`Name`  <a name="cfn-emr-cluster-stepconfig-name"></a>
The name of the step.  
*Required*: Yes  
*Type*: String  
*Pattern*: `[\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*`  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

# AWS::EMR::Cluster Tag
<a name="aws-properties-emr-cluster-tag"></a>

A key-value pair containing user-defined metadata that you can associate with an Amazon EMR resource. Tags make it easier to associate clusters in various ways, such as grouping clusters to track your Amazon EMR resource allocation costs. For more information, see [Tag Clusters](https://docs.aws.amazon.com/emr/latest/ManagementGuide/emr-plan-tags.html). 

## Syntax
<a name="aws-properties-emr-cluster-tag-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-tag-syntax.json"></a>

```
{
  "[Key](#cfn-emr-cluster-tag-key)" : String,
  "[Value](#cfn-emr-cluster-tag-value)" : String
}
```

### YAML
<a name="aws-properties-emr-cluster-tag-syntax.yaml"></a>

```
  [Key](#cfn-emr-cluster-tag-key): String
  [Value](#cfn-emr-cluster-tag-value): String
```

## Properties
<a name="aws-properties-emr-cluster-tag-properties"></a>

`Key`  <a name="cfn-emr-cluster-tag-key"></a>
A user-defined key, which is the minimum required information for a valid tag. For more information, see [Tag](https://docs.aws.amazon.com/emr/latest/ManagementGuide/emr-plan-tags.html).   
*Required*: Yes  
*Type*: String  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Value`  <a name="cfn-emr-cluster-tag-value"></a>
A user-defined value, which is optional in a tag. For more information, see [Tag Clusters](https://docs.aws.amazon.com/emr/latest/ManagementGuide/emr-plan-tags.html).   
*Required*: Yes  
*Type*: String  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::EMR::Cluster VolumeSpecification
<a name="aws-properties-emr-cluster-volumespecification"></a>

`VolumeSpecification` is a subproperty of the `EbsBlockDeviceConfig` property type. `VolumeSecification` determines the volume type, IOPS, and size (GiB) for EBS volumes attached to EC2 instances.

## Syntax
<a name="aws-properties-emr-cluster-volumespecification-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-emr-cluster-volumespecification-syntax.json"></a>

```
{
  "[Iops](#cfn-emr-cluster-volumespecification-iops)" : Integer,
  "[SizeInGB](#cfn-emr-cluster-volumespecification-sizeingb)" : Integer,
  "[Throughput](#cfn-emr-cluster-volumespecification-throughput)" : Integer,
  "[VolumeType](#cfn-emr-cluster-volumespecification-volumetype)" : String
}
```

### YAML
<a name="aws-properties-emr-cluster-volumespecification-syntax.yaml"></a>

```
  [Iops](#cfn-emr-cluster-volumespecification-iops): Integer
  [SizeInGB](#cfn-emr-cluster-volumespecification-sizeingb): Integer
  [Throughput](#cfn-emr-cluster-volumespecification-throughput): Integer
  [VolumeType](#cfn-emr-cluster-volumespecification-volumetype): String
```

## Properties
<a name="aws-properties-emr-cluster-volumespecification-properties"></a>

`Iops`  <a name="cfn-emr-cluster-volumespecification-iops"></a>
The number of I/O operations per second (IOPS) that the volume supports.  
*Required*: No  
*Type*: Integer  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`SizeInGB`  <a name="cfn-emr-cluster-volumespecification-sizeingb"></a>
The volume size, in gibibytes (GiB). This can be a number from 1 - 1024. If the volume type is EBS-optimized, the minimum value is 10.  
*Required*: Yes  
*Type*: Integer  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Throughput`  <a name="cfn-emr-cluster-volumespecification-throughput"></a>
The throughput, in mebibyte per second (MiB/s). This optional parameter can be a number from 125 - 1000 and is valid only for gp3 volumes.  
*Required*: No  
*Type*: Integer  
*Minimum*: `0`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`VolumeType`  <a name="cfn-emr-cluster-volumespecification-volumetype"></a>
The volume type. Volume types supported are gp3, gp2, io1, st1, sc1, and standard.  
*Required*: Yes  
*Type*: String  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)