-
Notifications
You must be signed in to change notification settings - Fork 88
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
Support specification of multiple scaling strategies #566
Support specification of multiple scaling strategies #566
Conversation
Codecov ReportAll modified lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## develop #566 +/- ##
===========================================
+ Coverage 89.92% 89.98% +0.05%
===========================================
Files 16 16
Lines 2689 2705 +16
===========================================
+ Hits 2418 2434 +16
Misses 271 271
Flags with carried forward coverage won't be shown. Click here to find out more.
☔ View full report in Codecov by Sentry. |
b995f81
to
05e8a0a
Compare
- Use a more extensible configuration parameter for the scaling strategy. - Default to all-or-nothing in case of missing or invalid scaling strategy. Signed-off-by: Eddy Mwiti <[email protected]>
f3197cc
to
5852999
Compare
# At instance launch level, the various scaling strategies can be grouped based on the actual | ||
# launch behaviour i.e. all-or-nothing or best-effort | ||
all_or_nothing_batch = scaling_strategy in [ScalingStrategy.ALL_OR_NOTHING] | ||
|
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.
I'm not sure I understand this comment.
all_or_nothing_batch
is actually a boolean that is passed downstream to FleetManagerFactory
as all_or_nothing
..so maybe it would be better to rename this parameter accordingly since is not clear if/what the _batch
adds
While, regards doing scaling_strategy in [ScalingStrategy.ALL_OR_NOTHING]
instead of scaling_strategy == ScalingStrategy.ALL_OR_NOTHING:
as done a few lines above, I assume that this is because we are planning to add another strategy that falls in the "all or nothing" category.
Is this the meaning of the comment above ?
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.
In all_or_nothing_batch
the _batch
alludes to the way we chunk the launch attempts in "batches" of a certain size/count of instances. So all_or_nothing_batch
implies that each batch will be done in an all-or-nothing fashion.
as done a few lines above, I assume that this is because we are planning to add another strategy that falls in the "all or nothing" category.
Exactly, it was done with this in mind. That expression will be reused in the upcoming PR.
# At fleet management level, the scaling strategies can be grouped based on the actual | ||
# launch behaviour i.e. all-or-nothing or best-effort | ||
all_or_nothing_batch = scaling_strategy in [ScalingStrategy.ALL_OR_NOTHING] | ||
|
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.
See comment above.
Description of changes
all-or-nothing
andbest-effort
).all_or_nothing_batch
configuration parameter has been done as follows:all_or_nothing_batch=False
maps toScalingStrategy.BEST_EFFORT
all_or_nothing_batch=True
maps toScalingStrategy.ALL_OR_NOTHING
all_or_nothing_batch
missing/undefined maps toScalingStrategy.ALL_OR_NOTHING
Enum
.Tests
References
Checklist
develop
add the branch name as prefix in the PR title (e.g.[release-3.6]
).Please review the guidelines for contributing and Pull Request Instructions.
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.