Azure / azure-libraries-for-net

Azure libraries for .Net
MIT License
379 stars 192 forks source link

[QUERY] SQL DB Hyperscale ServiceObjectiveName/Cores #923

Open tlorton opened 4 years ago

tlorton commented 4 years ago

Query/Question What are the available options for the ServiceObjectiveName if the DatabaseEdition is Hyperscale?

When I create a Hyperscale DB, the ServiceObjectiveName default is Gen4 I believe. Is there a way to specify Gen5 and the amount of cores?

I found the list of ServiceObjectiveNames, but none of them seem to correlate to Hyperscale values. https://docs.microsoft.com/en-us/dotnet/api/microsoft.azure.management.sql.models.serviceobjectivename?view=azure-dotnet

Why is this not a Bug or a feature Request? Not a bug because creating a Hyperscale DB works as expected.

Setup (please complete the following information if applicable):

yaohaizh commented 4 years ago

@tlorton currently this is not supported in this version of fluent .NET lib.

tlorton commented 4 years ago

@yaohaizh Is there a ServiceObjectiveName from those values that works with Hyperscale? I keep receiving errors like this: Microsoft.Rest.Azure.CloudException: Long running operation failed with status 'Failed'. Additional Info:'The edition 'Hyperscale' does not support the service objective 'Basic'.'

And yes I am aware that Basic will never work, just trying to prove a point.

tlorton commented 4 years ago

Is there a way Microsoft would recommend to create Hyperscale databases? Using Azure CLI?

tlorton commented 4 years ago

As a "workaround", a really helpful person helped me figure it out here: https://stackoverflow.com/questions/59277121/sql-db-hyperscale-serviceobjectivename-cores/59281290#59281290

jeroenterheerdt commented 4 years ago

hey @tlorton - not sure how this has escaped our attention for so long - sorry about that. Just to reply to your question, you can absolutely use Azure CLI to create Hyperscale databases: az sql db create -g mygroup -s myserver -n mydb -e Hyperscale --read-replicas 5. Hope this helps.

tlorton commented 4 years ago

That does not help as I am trying to using the azure-libraries-for-net SDK.

jeroenterheerdt commented 4 years ago

@tlorton - thanks. I'll let @yaohaizh respond to our plans here.