package awsemr // 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* . // // Example: // // The code below shows an example of how to instantiate this type. // // The values are placeholders you should change. // import "github.com/aws/aws-cdk-go/awscdk" // // var configurationProperty_ configurationProperty // // instanceGroupConfigProperty := &InstanceGroupConfigProperty{ // InstanceCount: jsii.Number(123), // InstanceType: jsii.String("instanceType"), // // // the properties below are optional // AutoScalingPolicy: &AutoScalingPolicyProperty{ // Constraints: &ScalingConstraintsProperty{ // MaxCapacity: jsii.Number(123), // MinCapacity: jsii.Number(123), // }, // Rules: []interface{}{ // &ScalingRuleProperty{ // Action: &ScalingActionProperty{ // SimpleScalingPolicyConfiguration: &SimpleScalingPolicyConfigurationProperty{ // ScalingAdjustment: jsii.Number(123), // // // the properties below are optional // AdjustmentType: jsii.String("adjustmentType"), // CoolDown: jsii.Number(123), // }, // // // the properties below are optional // Market: jsii.String("market"), // }, // Name: jsii.String("name"), // Trigger: &ScalingTriggerProperty{ // CloudWatchAlarmDefinition: &CloudWatchAlarmDefinitionProperty{ // ComparisonOperator: jsii.String("comparisonOperator"), // MetricName: jsii.String("metricName"), // Period: jsii.Number(123), // Threshold: jsii.Number(123), // // // the properties below are optional // Dimensions: []interface{}{ // &MetricDimensionProperty{ // Key: jsii.String("key"), // Value: jsii.String("value"), // }, // }, // EvaluationPeriods: jsii.Number(123), // Namespace: jsii.String("namespace"), // Statistic: jsii.String("statistic"), // Unit: jsii.String("unit"), // }, // }, // // // the properties below are optional // Description: jsii.String("description"), // }, // }, // }, // BidPrice: jsii.String("bidPrice"), // Configurations: []interface{}{ // &configurationProperty{ // Classification: jsii.String("classification"), // ConfigurationProperties: map[string]*string{ // "configurationPropertiesKey": jsii.String("configurationProperties"), // }, // Configurations: []interface{}{ // configurationProperty_, // }, // }, // }, // CustomAmiId: jsii.String("customAmiId"), // EbsConfiguration: &EbsConfigurationProperty{ // EbsBlockDeviceConfigs: []interface{}{ // &EbsBlockDeviceConfigProperty{ // VolumeSpecification: &VolumeSpecificationProperty{ // SizeInGb: jsii.Number(123), // VolumeType: jsii.String("volumeType"), // // // the properties below are optional // Iops: jsii.Number(123), // }, // // // the properties below are optional // VolumesPerInstance: jsii.Number(123), // }, // }, // EbsOptimized: jsii.Boolean(false), // }, // Market: jsii.String("market"), // Name: jsii.String("name"), // } // // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-emr-cluster-instancegroupconfig.html // type CfnCluster_InstanceGroupConfigProperty struct { // Target number of instances for the instance group. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-emr-cluster-instancegroupconfig.html#cfn-emr-cluster-instancegroupconfig-instancecount // InstanceCount *float64 `field:"required" json:"instanceCount" yaml:"instanceCount"` // The Amazon EC2 instance type for all instances in the instance group. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-emr-cluster-instancegroupconfig.html#cfn-emr-cluster-instancegroupconfig-instancetype // InstanceType *string `field:"required" json:"instanceType" yaml:"instanceType"` // `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) . // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-emr-cluster-instancegroupconfig.html#cfn-emr-cluster-instancegroupconfig-autoscalingpolicy // AutoScalingPolicy interface{} `field:"optional" json:"autoScalingPolicy" yaml:"autoScalingPolicy"` // 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. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-emr-cluster-instancegroupconfig.html#cfn-emr-cluster-instancegroupconfig-bidprice // BidPrice *string `field:"optional" json:"bidPrice" yaml:"bidPrice"` // > 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). // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-emr-cluster-instancegroupconfig.html#cfn-emr-cluster-instancegroupconfig-configurations // Configurations interface{} `field:"optional" json:"configurations" yaml:"configurations"` // The custom AMI ID to use for the provisioned instance group. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-emr-cluster-instancegroupconfig.html#cfn-emr-cluster-instancegroupconfig-customamiid // CustomAmiId *string `field:"optional" json:"customAmiId" yaml:"customAmiId"` // EBS configurations that will be attached to each Amazon EC2 instance in the instance group. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-emr-cluster-instancegroupconfig.html#cfn-emr-cluster-instancegroupconfig-ebsconfiguration // EbsConfiguration interface{} `field:"optional" json:"ebsConfiguration" yaml:"ebsConfiguration"` // Market type of the Amazon EC2 instances used to create a cluster node. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-emr-cluster-instancegroupconfig.html#cfn-emr-cluster-instancegroupconfig-market // Market *string `field:"optional" json:"market" yaml:"market"` // Friendly name given to the instance group. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-emr-cluster-instancegroupconfig.html#cfn-emr-cluster-instancegroupconfig-name // Name *string `field:"optional" json:"name" yaml:"name"` }