Skip to content
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

Equinox.Tool: Add support for Cosmos Autoscaling #302

Merged
merged 2 commits into from
Nov 17, 2021
Merged

Equinox.Tool: Add support for Cosmos Autoscaling #302

merged 2 commits into from
Nov 17, 2021

Conversation

belcher-rok
Copy link
Contributor

@belcher-rok belcher-rok commented Nov 17, 2021

Adds an --autoscale/-A switch to the eqx tool to support autoscaling throughput of Cosmos containers and databases. Specifying this flag causes the --rus parameter to be interpreted as "Maximum RU/s" and changes the default value to 4000 RU/s (the minimum MaxRUs value allowed by Cosmos).

There are no changes to existing behavior. The Propulsion tool is also unaffected.

There are breaking changes in the Equinox.CosmosStore.Core.Initialization.init function, specifically the mode parameter's Provisioning type had its rus members changed to Throughput type. The initAux function remains unchanged.

There is no plan to update the Propulsion tool since the minimum RU/s in both Manual and Autoscale mode is 400 which should be fine for the vast majority of 'aux' containers.

Adds an `--autoscale`/`-A` switch to the `eqx` tool to enable support
for the Autoscaling feature of Cosmos Containers and Databases.
Specifying this flag causes the `--rus` parameter to be interpreted
as "Maximum RU/s" and changes the default value to 4000 RU/s, the
minimum value allowed by Cosmos.
@CLAassistant
Copy link

CLAassistant commented Nov 17, 2021

CLA assistant check
All committers have signed the CLA.

Copy link
Member

@deviousasti deviousasti left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for this PR!
Adding auto-scaling throughput seems pretty useful.
Tagging @bartelink

tools/Equinox.Tool/Program.fs Outdated Show resolved Hide resolved
src/Equinox.CosmosStore/CosmosStore.fs Outdated Show resolved Hide resolved
src/Equinox.CosmosStore/CosmosStore.fs Outdated Show resolved Hide resolved
src/Equinox.CosmosStore/CosmosStore.fs Outdated Show resolved Hide resolved
src/Equinox.CosmosStore/CosmosStore.fs Outdated Show resolved Hide resolved
src/Equinox.CosmosStore/CosmosStore.fs Outdated Show resolved Hide resolved
src/Equinox.CosmosStore/CosmosStore.fs Outdated Show resolved Hide resolved
src/Equinox.CosmosStore/CosmosStore.fs Outdated Show resolved Hide resolved
@bartelink
Copy link
Collaborator

bartelink commented Nov 17, 2021

This looks great, thanks!

Thanks for making the initial PR minimal and easy to review (without random whitespace changes).

That said... I passive-aggressively pushed a commit just now with some formatting nits I wanted to do anyway addressed - some of these overlap with suggestions from @deviousasti

@belcher-rok Can you git reset head~1 my commit and apply it under your own name with any tweaks you see fit (I think @deviousasti's explicit throughput = annotations are good) -- my goal is that I'd like the PR to be under your name as it should be.

Also, would you mind adding a line to the changelog.md with a link to the article you cited in the overview too pls?

Copy link
Collaborator

@bartelink bartelink left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good; minor comments added

Copy link
Member

@deviousasti deviousasti left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Will merge after you force-push.

@belcher-rok
Copy link
Contributor Author

belcher-rok commented Nov 17, 2021

🙏 Thanks for the feedback @bartelink and @deviousasti! I need to learn more about partial active pattern -- they behave like magic🎇

Also, thanks for making these tools and frameworks available for all!

@deviousasti deviousasti merged commit abb3366 into jet:master Nov 17, 2021
@belcher-rok belcher-rok deleted the cosmos-autoscale branch November 17, 2021 22:44
@bartelink
Copy link
Collaborator

Thanks for the contribution, and for doing the topping and tailing
As you're prob aware, this is released https://twitter.com/rbartelink/status/1461393707220049930
FYI after all that 'final' cleanup, I found more room for polish, which will slip in at a later date... #303

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants