-
Notifications
You must be signed in to change notification settings - Fork 397
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
Fully support mixed instance policy #232
Conversation
I just realized tests were not updated - handling that now. |
6baee97
to
91e4cc2
Compare
It looks like some shippable tests have failed due to issues pulling docker images. |
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.
Thanks for taking the time to submit this change. I've retriggered the failed CI tests and they're now passing.
Mostly nits:
- Please add some additional tasks to the integration tests rather than updating the existing tasks: it's important that we know that the existing behaviour doesn't change and break as people move between versions.
- Please add a changelog fragment: https://docs.ansible.com/ansible/latest/community/development_process.html#changelogs-how-to
- Unfortunately I think we need to use a different name for the new return data, switching from a list to a dict will break existing playbooks. (full_mixed_instances_policy ?) (@jillr @garethr any opinions?)
Thanks for the feedback. I'll make the requested adjustments and submit for review, |
Restore mixed_instances_policy backwards compatibility by using mixed_instances_policy_full to return full dictionary. Also, fix some doc typos, add CHANGELOG fragment, and split into separate test case. Addresses feedback in ansible-collections#232
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
@JacobHenner can you resolve the change requst by @tremble? |
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.
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.
Previously, setting instances_distribution was not supported. instances_distribution should be supported, to allow users to enable spot instances within their mixed instance ASGs. Note: The type and significance of the mixed_instance_policy has changed. It now captures all of the mixed_instance_policy configuration parameters, rather than just a list of instance types. Fixes ansible-collections#231
Restore mixed_instances_policy backwards compatibility by using mixed_instances_policy_full to return full dictionary. Also, fix some doc typos, add CHANGELOG fragment, and split into separate test case. Addresses feedback in ansible-collections#232
@JacobHenner, don't be surprised. I just rebased your PR :-). |
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.
Apologies this one stalled @JacobHenner, I think we just need to add back the import for camel_dict_to_snake_dict (I suspect it was removed in another commit now that this PR has been rebased). That should get the sanity tests passing so that we can merge.
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.
A few minor bits and pieces. Let's see if we can get this over the finishing line
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.
Ran the tests locally. ec2_launch_template is currently broken but once fixed the unsupported ec2_asg tests pass with this change.
Restore mixed_instances_policy backwards compatibility by using mixed_instances_policy_full to return full dictionary. Also, fix some doc typos, add CHANGELOG fragment, and split into separate test case. Addresses feedback in ansible-collections#232
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.
Noticed some missing version_added.
Thanks for your time and effort on this. Sorry it's taken a while to get this merged. |
* Fully support mixed instance policy Previously, setting instances_distribution was not supported. instances_distribution should be supported, to allow users to enable spot instances within their mixed instance ASGs. Note: The type and significance of the mixed_instance_policy has changed. It now captures all of the mixed_instance_policy configuration parameters, rather than just a list of instance types. Fixes ansible-collections#231 * Restore mixed_instances_policy backwards-compat Restore mixed_instances_policy backwards compatibility by using mixed_instances_policy_full to return full dictionary. Also, fix some doc typos, add CHANGELOG fragment, and split into separate test case. Addresses feedback in ansible-collections#232 * Only return mixed_instances_policy_full if set
* Fully support mixed instance policy Previously, setting instances_distribution was not supported. instances_distribution should be supported, to allow users to enable spot instances within their mixed instance ASGs. Note: The type and significance of the mixed_instance_policy has changed. It now captures all of the mixed_instance_policy configuration parameters, rather than just a list of instance types. Fixes ansible-collections#231 * Restore mixed_instances_policy backwards-compat Restore mixed_instances_policy backwards compatibility by using mixed_instances_policy_full to return full dictionary. Also, fix some doc typos, add CHANGELOG fragment, and split into separate test case. Addresses feedback in ansible-collections#232 * Only return mixed_instances_policy_full if set
* Fully support mixed instance policy Previously, setting instances_distribution was not supported. instances_distribution should be supported, to allow users to enable spot instances within their mixed instance ASGs. Note: The type and significance of the mixed_instance_policy has changed. It now captures all of the mixed_instance_policy configuration parameters, rather than just a list of instance types. Fixes ansible-collections#231 * Restore mixed_instances_policy backwards-compat Restore mixed_instances_policy backwards compatibility by using mixed_instances_policy_full to return full dictionary. Also, fix some doc typos, add CHANGELOG fragment, and split into separate test case. Addresses feedback in ansible-collections#232 * Only return mixed_instances_policy_full if set
SUMMARY
Previously, setting instances_distribution was not supported.
instances_distribution should be supported, to allow users to enable
spot instances within their mixed instance ASGs.
Note: The type and significance of the mixed_instance_policy has
changed. It now captures all of the mixed_instance_policy configuration
parameters, rather than just a list of instance types.
Fixes #231
ISSUE TYPE
COMPONENT NAME
ec2_asg