-
Notifications
You must be signed in to change notification settings - Fork 9.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Enable EMR cluster configuration through the InstanceGroup param #1071
Conversation
EMR has three ways to configure cluster resources: the coreInstanceCount/ coreInstanceType params, the InstanceGroup structure, and the InstanceFleet structure (which only exists in very new EMR releases). At the moment, Terraform only supports the first one of those (coreInstanceCount). This is extremely limiting, among other things it doesn't allow the user to set EBS options or use spot prices. This commit adds support for InstanceGroup to aws_emr_cluster resources, and makes the masterInstanceCount optional since there is now an alternative.
+2!! |
+1 |
If anything needs a merge, it's this PR. |
I've just tested and confirmed that this works. In lieu of say:
We can use:
Note: the |
What about disk size? |
There seem to be more options that what I used here; check the PR's diff for everything that's available. Otherwise, disk size of the instances is controlled by the |
Also, how does these changes relate to the existing |
@jennyfountain: Disk size is controlled through the
|
Hey @apetresc, thank you a million for this PR! Awesome contribution. |
@grubernaut Yes, absolutely :) I'm on vacation until the end of next week, but I'll add those tests as soon as I'm back. |
Hey @grubernaut, sorry for the delay! As requested, I've added an acceptance test for the
Thanks! |
Oh, one more note:
|
@apetresc, yup, not a problem! Pulling down your branch now to run through the test suite :) |
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome work here! Just needs documentation and it's ready to go!
Great. I guess this just means documenting the new fields in |
@apetresc yup exactly! |
@grubernaut Done! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks!
@apetresc should be released with the next release of the AWS provider, which is |
Hi @apetresc What about Thanks for your contribution ! |
Enable EMR cluster configuration through the InstanceGroup param
Is there a way we can specify the root volume size for both Master and core instances ? Thanks for all the contribution , ebs_config is working perfectly. |
@vishnuravi3186 Yes, just create multiple |
@apetresc Thanks for the quick reply , yep I implemented in the same way , the ebs volume attached to each node is fine with the size what i mentioned , My question is about the root volume which is by default set as 10gb , Is there a way we can increase , In Amazon UI we can mention root volume size upto 100gb , I saw somewhere a feature has been added to implement ebs root volume size. Example: ebs_root_volume_size = 100 Let me know if this can be enabled. |
Ooh sorry, you're right, I misunderstood. Let me take a look at the API docs and see how easy this would be to implement... |
@apetresc Any updates on this feature ? |
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks! |
This fixes #869 and #389.
EMR has three ways to configure cluster resources: the
coreInstanceCount
/coreInstanceType
params, the InstanceGroup structure, and the InstanceFleet structure (which only exists in very new EMR releases). At the moment, Terraform only supports the first one of those (coreInstanceCount
). This is extremely limiting, among other things it doesn't allow the user to set EBS options or use spot prices.This commit adds support for InstanceGroup to
aws_emr_cluster
resources, and makes themasterInstanceCount
optional since there is now an alternative.I have not added any tests yet, but manual testing indicates all the new features work as expected. Existing unit tests continue to pass.