Azure App Service Web Apps · AZ-204: Developing Solutions for Microsoft Azure Develop Azure Compute Solutions
A web app has production and staging deployment slots. Each slot must use a different API endpoint, and the endpoint must remain associated with its…
Practice question from Azure App Service Web Apps (AZ-204: Developing Solutions for Microsoft Azure Develop Azure Compute Solutions), with the correct answer and a step-by-step solution.
easy · MCQ · Q-A2E2A1
A web app has production and staging deployment slots. Each slot must use a different API endpoint, and the endpoint must remain associated with its slot when a swap occurs. What should you do?
- A.Hard-code the endpoint in the application source code for each slot.
- B.Store the endpoint in an App Service application setting and mark the setting as a deployment slot setting.Correct answer
- C.Store the endpoint in the deployment package filename.
- D.Store the endpoint in an Azure Storage account and change the storage account during every swap.
Solution
Application settings are exposed to the web app as environment variables. Marking the setting as a deployment slot setting makes it sticky, so its value remains with the slot instead of moving during a swap.
More from Azure App Service Web Apps
- A team wants to release a new version of an Azure App Service web app with minimal production downtime. The team has a staging slot and a p…
- An ASP.NET Core web app hosted in Azure App Service must access a database password without storing the password in source code or in a dep…
- A company hosts an ASP.NET Core web app in Azure App Service. The company requires every request sent over HTTP to be redirected automatica…
- An Azure App Service web app must make outbound calls to a private REST API hosted inside an Azure virtual network. The web app must remain…
Practise more Develop Azure Compute Solutions
Sign up free for adaptive practice on this chapter, with instant feedback and hints on every question.
Start practising freeFree to start · No credit card needed