exam questions

Exam AZ-204 All Questions

View all questions & answers for the AZ-204 exam

Exam AZ-204 topic 2 question 7 discussion

Actual exam question from Microsoft's AZ-204
Question #: 7
Topic #: 2
[All AZ-204 Questions]

Note: This question is part of a series of questions that present the same scenario. Each question in the series contains a unique solution that might meet the stated goals. Some question sets might have more than one correct solution, while others might not have a correct solution.
After you answer a question in this section, you will NOT be able to return to it. As a result, these questions will not appear in the review screen.
You develop and deploy an Azure App Service API app to a Windows-hosted deployment slot named Development. You create additional deployment slots named Testing and Production. You enable auto swap on the Production deployment slot.
You need to ensure that scripts run and resources are available before a swap operation occurs.
Solution: Disable auto swap. Update the app with a method named statuscheck to run the scripts. Re-enable auto swap and deploy the app to the Production slot.
Does the solution meet the goal?

  • A. No
  • B. Yes
Show Suggested Answer Hide Answer
Suggested Answer: A 🗳️

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
robin1337
Highly Voted 2 years, 3 months ago
It depends.... has the app an WEBSITE_SWAP_WARMUP_PING_PATH set to /statuscheck?? Seriously, I hold multiple certifications, tricky hands-on ones but this certification is a joke. Microsoft, who is designing those questions?!? It's not just this one, there are so many bad questions.
upvoted 24 times
[Removed]
2 years, 1 month ago
Same experience here. I have many AWS certifications, OCP-11 certification, etc. This is really a joke of a certification. I do not even know what Microsoft expects and more importantly the kind of people ready to live with this kind of questions from Microsoft and trying to remember it.
upvoted 11 times
...
robin1337
2 years, 3 months ago
Ok, my bad autoswap has to be configured on the Staging Slot. So "You enable auto swap on the Production deployment slot." is not what you would do. Answer is A (NO).
upvoted 9 times
...
...
GMartinez
Highly Voted 2 years, 5 months ago
Selected Answer: A
Instead, use applicationInitialization
upvoted 22 times
TonyMel
1 year, 7 months ago
correct, in 2023Mar24, score: 904/1000
upvoted 5 times
...
...
Isoldhe
Most Recent 8 months, 1 week ago
Selected Answer: B
Copilot AI: The solution you proposed does meet the goal. Disabling auto swap, updating the app with a method named statuscheck to run the scripts, re-enabling auto swap and deploying the app to the Production slot is one of the possible ways to ensure that scripts run and resources are available before a swap operation occurs. This method uses the applicationInitialization configuration element in the web.config file to specify the statuscheck method as a custom initialization action. The statuscheck method will run the scripts and check the availability of the resources before the app is swapped.
upvoted 3 times
...
manopeydakon
9 months, 4 weeks ago
How can it say: Correct Answer: B 🗳️ then, "Instead" update the web.config file to include the applicationInitialization configuration element.. Sounds very wrong!
upvoted 3 times
...
Tarajee
1 year, 1 month ago
Got this on 2023sept
upvoted 1 times
...
GuruPratap
1 year, 7 months ago
Yes, the solution should meet the goal of ensuring that scripts run and resources are available before a swap operation occurs. By disabling auto swap, the deployment to the Production slot will not occur until it is manually initiated. Then, the app can be updated with a method named statuscheck to run the necessary scripts and ensure that resources are available. Once the app has been updated, auto swap can be re-enabled and the updated app can be deployed to the Production slot. This approach allows for greater control over when the swap occurs and ensures that the necessary steps are taken before the swap happens.
upvoted 5 times
...
Saronyo
1 year, 8 months ago
Selected B , Application initialisation can be set up to do the statuscheck . auto swap will deploy it to production after warm up
upvoted 3 times
red0400
1 year, 8 months ago
Exactly
upvoted 1 times
...
...
kociuba
1 year, 10 months ago
got in on my exam 30-12-2022 score: 818
upvoted 2 times
Congphan
1 year, 10 months ago
what is your choice?
upvoted 2 times
...
...
mdg3501
1 year, 10 months ago
got this on 2022-12-7
upvoted 1 times
...
micro9000
1 year, 11 months ago
The answer is A, you still need to set the WEBSITE_WARMUP_PATH in app settings WEBSITE_WARMUP_PATH: A relative path on the site that should be pinged whenever the site restarts (not only during slot swaps). Example values include /statuscheck or the root path, /. https://learn.microsoft.com/en-us/azure/app-service/deploy-staging-slots#Auto-Swap
upvoted 2 times
...
[Removed]
2 years, 1 month ago
Deploy the app directly to the Production slot will fail the auto swap. But that is a detail in the question that will be missed by a person who did some reading on the auto swap because he is thinking of app initialization option vs custom_warmup with those properties. Do not be evil, Microsoft.
upvoted 2 times
...
N9
2 years, 2 months ago
Selected Answer: A
web.config file with applicationinitialization is correct answer. So A is the correct answer.
upvoted 2 times
...
Dani_ac7
2 years, 4 months ago
Selected Answer: B
applicationInitialization
upvoted 2 times
...
Lucky_me
2 years, 4 months ago
Selected Answer: B
although the provided explaination in the answer section, is not related to the correct option, however, the solution provided in the question would actually work, and that's is the correct "Manual Way" of making sure the deployment slot is warmed up and running before swap, so the solution would work and correct.
upvoted 3 times
...
Satish_Babu
2 years, 4 months ago
Selected Answer: A
No, No, because correct solution is updating the web.config file to include applicationinitialization configuration element for running initializing resources.
upvoted 1 times
cemepo9819
2 years, 3 months ago
multiple solutions can be correct.
upvoted 4 times
...
...
omega11
2 years, 4 months ago
I say A, "No". The reason why setting up auto swap is to warm up the application to prevent downtime, so deploying to the production slot directly is killing the purpose. https://docs.microsoft.com/en-us/azure/app-service/deploy-staging-slots#specify-custom-warm-up
upvoted 3 times
...
Eltooth
2 years, 4 months ago
Selected Answer: A
A seems to be correct answer.
upvoted 2 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago