MicrosoftDocs / azure-docs

Open source documentation of Microsoft Azure
https://docs.microsoft.com/azure
Creative Commons Attribution 4.0 International
10.25k stars 21.42k forks source link

--name AzureFunctionsQuickstart-rg not clear enough #80435

Closed tomcam closed 3 years ago

tomcam commented 3 years ago

Your docs are so good that occasional misses stand out more. Starting under https://docs.microsoft.com/en-us/azure/azure-functions/create-first-function-cli-python?tabs=azure-cli%2Cbash%2Cbrowser#create-supporting-azure-resources-for-your-function you'll see this example:

az group create --name AzureFunctionsQuickstart-rg --location <REGION> So many questions.

You folks rock. I am loving using these materials and am staggered by the amount of things that could have been left as "exercises for the reader" but were made explicit instead. Thanks a zillion.l

Document Details

Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

SamaraSoucy-MSFT commented 3 years ago

Thank you so much for the kudos! Let me check on this and I will get back to you shortly.

SamaraSoucy-MSFT commented 3 years ago

I'm not sure what you mean about AzureFunctionsQuickstart being a user-defined name- could you clarify what you are looking for a little bit?

For the -rg suffix, that is a naming convention that's often used to help keep track of resource types when different resources have similar names. For example I might have 'samara-rg', which then contains 'samara-vm' and 'samara-ip'. Those could all have the same name, but that can get confusing. If you are curious, there are some recommendations here, though you can define your own scheme: https://docs.microsoft.com/en-us/azure/cloud-adoption-framework/ready/azure-best-practices/resource-naming

--location is a required parameter in the az group create command: https://docs.microsoft.com/en-us/cli/azure/group?view=azure-cli-latest#az_group_create If you are only going to deploy to a single region, then it is generally best to deploy in the region physically closest since you'll have faster response times since a longer physical distance means that it will take longer for the data to travel.

What is more important is keeping resources that talk to each other in the same region as much as possible as there is a cost for data traffic between regions. There are a few exceptions, services like databases that designed to be setup in multiple regions will not have any additional costs for keeping the two copies in sync. If you do something like deploy your database and your function app in different regions though you may end up with a higher cost than you expected.

SamaraSoucy-MSFT commented 3 years ago

I'm going to close this thread. If there are further questions regarding this matter, please tag me in your reply. We will gladly reopen the issue and continue the discussion.