Class CfnCluster
- All Implemented Interfaces:
IInspectable,IClusterRef,IEnvironmentAware,ITaggable,software.amazon.jsii.JsiiSerializable,software.constructs.IConstruct,software.constructs.IDependable
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 .
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.
Example:
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interfaceApplicationis a property ofAWS::EMR::Cluster.static interfaceAutoScalingPolicyis a subproperty ofInstanceGroupConfig.static interfaceAn auto-termination policy for an Amazon EMR cluster.static interfaceBootstrapActionConfigis a property ofAWS::EMR::Clusterthat can be used to run bootstrap actions on EMR clusters.static final classA fluent builder forCfnCluster.static interfaceCloudWatchAlarmDefinitionis a subproperty of theScalingTriggerproperty, which determines when to trigger an automatic scaling activity.static interfaceThe Amazon EC2 unit limits for a managed scaling policy.static interfacestatic interfaceEbsBlockDeviceConfigis a subproperty of theEbsConfigurationproperty type.static interfaceEbsConfigurationis a subproperty ofInstanceFleetConfigorInstanceGroupConfig.static interfaceTheHadoopJarStepConfigproperty type specifies a job flow step consisting of a JAR file whose main function will be executed.static interfaceUseInstanceFleetConfigto define instance fleets for an EMR cluster.static interfaceInstanceFleetProvisioningSpecificationis a subproperty ofInstanceFleetConfig.static interfaceThe resize specification for On-Demand and Spot Instances in the fleet.static interfaceUseInstanceGroupConfigto define instance groups for an EMR cluster.static interfacestatic interfaceJobFlowInstancesConfigis a property of theAWS::EMR::Clusterresource.static interfaceKerberosAttributesis a property of theAWS::EMR::Clusterresource.static interfaceKeyValueis a subproperty of theHadoopJarStepConfigproperty type.static interfaceManaged scaling policy for an Amazon EMR cluster.static interfaceMetricDimensionis a subproperty of theCloudWatchAlarmDefinitionproperty type.static interfaceDescribes the strategy for using unused Capacity Reservations for fulfilling On-Demand capacity.static interfaceThe launch specification for On-Demand Instances in the instance fleet, which determines the allocation strategy.static interfaceThe resize specification for On-Demand Instances in the instance fleet, which contains the resize timeout period.static interfacePlacement group configuration for an Amazon EMR cluster.static interfacePlacementTypeis a property of theAWS::EMR::Clusterresource.static interfaceScalingActionis a subproperty of theScalingRuleproperty type.static interfaceScalingConstraintsis a subproperty of theAutoScalingPolicyproperty type.static interfaceScalingRuleis a subproperty of theAutoScalingPolicyproperty type.static interfaceScalingTriggeris a subproperty of theScalingRuleproperty type.static interfaceScriptBootstrapActionConfigis a subproperty of theBootstrapActionConfigproperty type.static interfaceSimpleScalingPolicyConfigurationis a subproperty of theScalingActionproperty type.static interfaceSpotProvisioningSpecificationis a subproperty of theInstanceFleetProvisioningSpecificationsproperty type.static interfaceThe resize specification for Spot Instances in the instance fleet, which contains the resize timeout period.static interfaceStepConfigis a property of theAWS::EMR::Clusterresource.static interfaceVolumeSpecificationis a subproperty of theEbsBlockDeviceConfigproperty type.Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationModeNested classes/interfaces inherited from interface software.amazon.awscdk.interfaces.emr.IClusterRef
IClusterRef.Jsii$Default, IClusterRef.Jsii$ProxyNested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$DefaultNested classes/interfaces inherited from interface software.amazon.awscdk.IInspectable
IInspectable.Jsii$Default, IInspectable.Jsii$ProxyNested classes/interfaces inherited from interface software.amazon.awscdk.ITaggable
ITaggable.Jsii$Default, ITaggable.Jsii$Proxy -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe CloudFormation resource type name for this resource class. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedCfnCluster(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protectedCfnCluster(software.amazon.jsii.JsiiObjectRef objRef) CfnCluster(software.constructs.Construct scope, String id, CfnClusterProps props) Create a newAWS::EMR::Cluster. -
Method Summary
Modifier and TypeMethodDescriptionstatic IClusterReffromClusterId(software.constructs.Construct scope, String id, String clusterId) Creates a new IClusterRef from a clusterId.A JSON string for selecting additional features.The applications to install on this cluster, for example, Spark, Flink, Oozie, Zeppelin, and so on.The unique identifier for the cluster.The public DNS name of the master node (instance), such asec2-12-123-123-123.us-west-2.compute.amazonaws.com.rproxy.govskope.ca.An IAM role for automatic scaling policies.An auto-termination policy for an Amazon EMR cluster.A list of bootstrap actions to run before Hadoop starts on the cluster nodes.A reference to a Cluster resource.Applies only to Amazon EMR releases 4.x and later.Available only in Amazon EMR releases 5.7.0 and later.The IOPS, of the Amazon EBS root device volume of the Linux AMI that is used for each Amazon EC2 instance.The size, in GiB, of the Amazon EBS root device volume of the Linux AMI that is used for each Amazon EC2 instance.The throughput, in MiB/s, of the Amazon EBS root device volume of the Linux AMI that is used for each Amazon EC2 instance.A specification of the number and type of Amazon EC2 instances.Also called instance profile and Amazon EC2 role.Attributes for Kerberos configuration when Kerberos authentication is enabled using a security configuration.The AWS KMS key used for encrypting log files.The path to the Amazon S3 location where logs for this cluster are stored.Creates or updates a managed scaling policy for an Amazon EMR cluster.getName()The name of the cluster.The Amazon Linux release specified in a cluster launch RunJobFlow request.Returns union: eitherIResolvableor Listinvalid input: '<'eitherIResolvableorCfnCluster.PlacementGroupConfigProperty>The Amazon EMR release label, which determines the version of open-source application packages installed on the cluster.The way that individual Amazon EC2 instances terminate when an automatic scale-in activity occurs or an instance group is resized.The name of the security configuration applied to the cluster.The IAM role that Amazon EMR assumes in order to access AWS resources on your behalf.Specifies the number of steps that can be executed concurrently.getSteps()A list of steps to run.getTags()Tag Manager which manages the tags for this resource.A list of tags associated with a cluster.Indicates whether the cluster is visible to all IAM users of the AWS account associated with the cluster.voidinspect(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.renderProperties(Map<String, Object> props) voidsetAdditionalInfo(Object value) A JSON string for selecting additional features.voidsetApplications(List<Object> value) The applications to install on this cluster, for example, Spark, Flink, Oozie, Zeppelin, and so on.voidsetApplications(IResolvable value) The applications to install on this cluster, for example, Spark, Flink, Oozie, Zeppelin, and so on.voidsetAutoScalingRole(String value) An IAM role for automatic scaling policies.voidAn auto-termination policy for an Amazon EMR cluster.voidAn auto-termination policy for an Amazon EMR cluster.voidsetBootstrapActions(List<Object> value) A list of bootstrap actions to run before Hadoop starts on the cluster nodes.voidsetBootstrapActions(IResolvable value) A list of bootstrap actions to run before Hadoop starts on the cluster nodes.voidsetConfigurations(List<Object> value) Applies only to Amazon EMR releases 4.x and later.voidsetConfigurations(IResolvable value) Applies only to Amazon EMR releases 4.x and later.voidsetCustomAmiId(String value) Available only in Amazon EMR releases 5.7.0 and later.voidsetEbsRootVolumeIops(Number value) The IOPS, of the Amazon EBS root device volume of the Linux AMI that is used for each Amazon EC2 instance.voidsetEbsRootVolumeSize(Number value) The size, in GiB, of the Amazon EBS root device volume of the Linux AMI that is used for each Amazon EC2 instance.voidsetEbsRootVolumeThroughput(Number value) The throughput, in MiB/s, of the Amazon EBS root device volume of the Linux AMI that is used for each Amazon EC2 instance.voidsetInstances(IResolvable value) A specification of the number and type of Amazon EC2 instances.voidA specification of the number and type of Amazon EC2 instances.voidsetJobFlowRole(String value) Also called instance profile and Amazon EC2 role.voidsetKerberosAttributes(IResolvable value) Attributes for Kerberos configuration when Kerberos authentication is enabled using a security configuration.voidAttributes for Kerberos configuration when Kerberos authentication is enabled using a security configuration.voidsetLogEncryptionKmsKeyId(String value) The AWS KMS key used for encrypting log files.voidThe path to the Amazon S3 location where logs for this cluster are stored.voidCreates or updates a managed scaling policy for an Amazon EMR cluster.voidCreates or updates a managed scaling policy for an Amazon EMR cluster.voidThe name of the cluster.voidsetOsReleaseLabel(String value) The Amazon Linux release specified in a cluster launch RunJobFlow request.voidsetPlacementGroupConfigs(List<Object> value) voidvoidsetReleaseLabel(String value) The Amazon EMR release label, which determines the version of open-source application packages installed on the cluster.voidsetScaleDownBehavior(String value) The way that individual Amazon EC2 instances terminate when an automatic scale-in activity occurs or an instance group is resized.voidsetSecurityConfiguration(String value) The name of the security configuration applied to the cluster.voidsetServiceRole(String value) The IAM role that Amazon EMR assumes in order to access AWS resources on your behalf.voidsetStepConcurrencyLevel(Number value) Specifies the number of steps that can be executed concurrently.voidA list of steps to run.voidsetSteps(IResolvable value) A list of steps to run.voidsetTagsRaw(List<CfnTag> value) A list of tags associated with a cluster.voidsetVisibleToAllUsers(Boolean value) Indicates whether the cluster is visible to all IAM users of the AWS account associated with the cluster.voidsetVisibleToAllUsers(IResolvable value) Indicates whether the cluster is visible to all IAM users of the AWS account associated with the cluster.Methods inherited from class software.amazon.awscdk.CfnResource
addDeletionOverride, addDependency, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getAtt, getCfnOptions, getCfnResourceType, getEnv, getMetadata, getUpdatedProperites, getUpdatedProperties, isCfnResource, obtainDependencies, obtainResourceDependencies, removeDependency, replaceDependency, shouldSynthesize, toString, validatePropertiesMethods inherited from class software.amazon.awscdk.CfnRefElement
getRefMethods inherited from class software.amazon.awscdk.CfnElement
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalIdMethods inherited from class software.constructs.Construct
getNode, isConstructMethods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface software.constructs.IConstruct
getNodeMethods inherited from interface software.amazon.awscdk.interfaces.IEnvironmentAware
getEnvMethods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
-
-
Constructor Details
-
CfnCluster
protected CfnCluster(software.amazon.jsii.JsiiObjectRef objRef) -
CfnCluster
protected CfnCluster(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnCluster
@Stability(Stable) public CfnCluster(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnClusterProps props) Create a newAWS::EMR::Cluster.- Parameters:
scope- Scope in which this resource is defined. This parameter is required.id- Construct identifier for this resource (unique in its scope). This parameter is required.props- Resource properties. This parameter is required.
-
-
Method Details
-
fromClusterId
@Stability(Stable) @NotNull public static IClusterRef fromClusterId(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull String clusterId) Creates a new IClusterRef from a clusterId.- Parameters:
scope- This parameter is required.id- This parameter is required.clusterId- This parameter is required.
-
inspect
Examines the CloudFormation resource and discloses attributes.- Specified by:
inspectin interfaceIInspectable- Parameters:
inspector- tree inspector to collect and process attributes. This parameter is required.
-
renderProperties
@Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String, Object> props) - Overrides:
renderPropertiesin classCfnResource- Parameters:
props- This parameter is required.
-
getAttrId
The unique identifier for the cluster. -
getAttrMasterPublicDns
The public DNS name of the master node (instance), such asec2-12-123-123-123.us-west-2.compute.amazonaws.com. -
getCfnProperties
- Overrides:
getCfnPropertiesin classCfnResource
-
getClusterRef
A reference to a Cluster resource.- Specified by:
getClusterRefin interfaceIClusterRef
-
getTags
Tag Manager which manages the tags for this resource. -
getInstances
A specification of the number and type of Amazon EC2 instances.Returns union: either
IResolvableorCfnCluster.JobFlowInstancesConfigProperty -
setInstances
A specification of the number and type of Amazon EC2 instances. -
setInstances
@Stability(Stable) public void setInstances(@NotNull CfnCluster.JobFlowInstancesConfigProperty value) A specification of the number and type of Amazon EC2 instances. -
getJobFlowRole
Also called instance profile and Amazon EC2 role. -
setJobFlowRole
Also called instance profile and Amazon EC2 role. -
getName
The name of the cluster. -
setName
The name of the cluster. -
getServiceRole
The IAM role that Amazon EMR assumes in order to access AWS resources on your behalf. -
setServiceRole
The IAM role that Amazon EMR assumes in order to access AWS resources on your behalf. -
getAdditionalInfo
A JSON string for selecting additional features. -
setAdditionalInfo
A JSON string for selecting additional features. -
getApplications
The applications to install on this cluster, for example, Spark, Flink, Oozie, Zeppelin, and so on.Returns union: either
IResolvableor Listinvalid input: '<'eitherIResolvableorCfnCluster.ApplicationProperty> -
setApplications
The applications to install on this cluster, for example, Spark, Flink, Oozie, Zeppelin, and so on. -
setApplications
The applications to install on this cluster, for example, Spark, Flink, Oozie, Zeppelin, and so on. -
getAutoScalingRole
An IAM role for automatic scaling policies. -
setAutoScalingRole
An IAM role for automatic scaling policies. -
getAutoTerminationPolicy
An auto-termination policy for an Amazon EMR cluster.Returns union: either
IResolvableorCfnCluster.AutoTerminationPolicyProperty -
setAutoTerminationPolicy
An auto-termination policy for an Amazon EMR cluster. -
setAutoTerminationPolicy
@Stability(Stable) public void setAutoTerminationPolicy(@Nullable CfnCluster.AutoTerminationPolicyProperty value) An auto-termination policy for an Amazon EMR cluster. -
getBootstrapActions
A list of bootstrap actions to run before Hadoop starts on the cluster nodes.Returns union: either
IResolvableor Listinvalid input: '<'eitherIResolvableorCfnCluster.BootstrapActionConfigProperty> -
setBootstrapActions
A list of bootstrap actions to run before Hadoop starts on the cluster nodes. -
setBootstrapActions
A list of bootstrap actions to run before Hadoop starts on the cluster nodes. -
getConfigurations
Applies only to Amazon EMR releases 4.x and later. The list of configurations that are supplied to the Amazon EMR cluster.Returns union: either
IResolvableor Listinvalid input: '<'eitherIResolvableorCfnCluster.ConfigurationProperty> -
setConfigurations
Applies only to Amazon EMR releases 4.x and later. The list of configurations that are supplied to the Amazon EMR cluster. -
setConfigurations
Applies only to Amazon EMR releases 4.x and later. The list of configurations that are supplied to the Amazon EMR cluster. -
getCustomAmiId
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. -
setCustomAmiId
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. -
getEbsRootVolumeIops
The IOPS, of the Amazon EBS root device volume of the Linux AMI that is used for each Amazon EC2 instance. -
setEbsRootVolumeIops
The IOPS, of the Amazon EBS root device volume of the Linux AMI that is used for each Amazon EC2 instance. -
getEbsRootVolumeSize
The size, in GiB, of the Amazon EBS root device volume of the Linux AMI that is used for each Amazon EC2 instance. -
setEbsRootVolumeSize
The size, in GiB, of the Amazon EBS root device volume of the Linux AMI that is used for each Amazon EC2 instance. -
getEbsRootVolumeThroughput
The throughput, in MiB/s, of the Amazon EBS root device volume of the Linux AMI that is used for each Amazon EC2 instance. -
setEbsRootVolumeThroughput
The throughput, in MiB/s, of the Amazon EBS root device volume of the Linux AMI that is used for each Amazon EC2 instance. -
getKerberosAttributes
Attributes for Kerberos configuration when Kerberos authentication is enabled using a security configuration.Returns union: either
IResolvableorCfnCluster.KerberosAttributesProperty -
setKerberosAttributes
Attributes for Kerberos configuration when Kerberos authentication is enabled using a security configuration. -
setKerberosAttributes
@Stability(Stable) public void setKerberosAttributes(@Nullable CfnCluster.KerberosAttributesProperty value) Attributes for Kerberos configuration when Kerberos authentication is enabled using a security configuration. -
getLogEncryptionKmsKeyId
The AWS KMS key used for encrypting log files. -
setLogEncryptionKmsKeyId
The AWS KMS key used for encrypting log files. -
getLogUri
The path to the Amazon S3 location where logs for this cluster are stored. -
setLogUri
The path to the Amazon S3 location where logs for this cluster are stored. -
getManagedScalingPolicy
Creates or updates a managed scaling policy for an Amazon EMR cluster.Returns union: either
IResolvableorCfnCluster.ManagedScalingPolicyProperty -
setManagedScalingPolicy
Creates or updates a managed scaling policy for an Amazon EMR cluster. -
setManagedScalingPolicy
@Stability(Stable) public void setManagedScalingPolicy(@Nullable CfnCluster.ManagedScalingPolicyProperty value) Creates or updates a managed scaling policy for an Amazon EMR cluster. -
getOsReleaseLabel
The Amazon Linux release specified in a cluster launch RunJobFlow request. -
setOsReleaseLabel
The Amazon Linux release specified in a cluster launch RunJobFlow request. -
getPlacementGroupConfigs
Returns union: eitherIResolvableor Listinvalid input: '<'eitherIResolvableorCfnCluster.PlacementGroupConfigProperty> -
setPlacementGroupConfigs
-
setPlacementGroupConfigs
-
getReleaseLabel
The Amazon EMR release label, which determines the version of open-source application packages installed on the cluster. -
setReleaseLabel
The Amazon EMR release label, which determines the version of open-source application packages installed on the cluster. -
getScaleDownBehavior
The way that individual Amazon EC2 instances terminate when an automatic scale-in activity occurs or an instance group is resized. -
setScaleDownBehavior
The way that individual Amazon EC2 instances terminate when an automatic scale-in activity occurs or an instance group is resized. -
getSecurityConfiguration
The name of the security configuration applied to the cluster. -
setSecurityConfiguration
The name of the security configuration applied to the cluster. -
getStepConcurrencyLevel
Specifies the number of steps that can be executed concurrently. -
setStepConcurrencyLevel
Specifies the number of steps that can be executed concurrently. -
getSteps
A list of steps to run.Returns union: either
IResolvableor Listinvalid input: '<'eitherIResolvableorCfnCluster.StepConfigProperty> -
setSteps
A list of steps to run. -
setSteps
A list of steps to run. -
getTagsRaw
A list of tags associated with a cluster. -
setTagsRaw
A list of tags associated with a cluster. -
getVisibleToAllUsers
Indicates whether the cluster is visible to all IAM users of the AWS account associated with the cluster.Returns union: either
BooleanorIResolvable -
setVisibleToAllUsers
Indicates whether the cluster is visible to all IAM users of the AWS account associated with the cluster. -
setVisibleToAllUsers
Indicates whether the cluster is visible to all IAM users of the AWS account associated with the cluster.
-