Welcome to ExamTopics
ExamTopics Logo
- Expert Verified, Online, Free.

Unlimited Access

Get Unlimited Contributor Access to the all ExamTopics Exams!
Take advantage of PDF Files for 1000+ Exams along with community discussions and pass IT Certification Exams Easily.

Exam AZ-305 topic 6 question 1 discussion

Actual exam question from Microsoft's AZ-305
Question #: 1
Topic #: 6
[All AZ-305 Questions]

You need to recommend a solution for the App1 maintenance task. The solution must minimize costs.
What should you include in the recommendation?

  • A. an Azure logic app
  • B. an Azure function
  • C. an Azure virtual machine
  • D. an App Service WebJob
Show Suggested Answer Hide Answer
Suggested Answer: A 🗳️
Every hour, you will run a maintenance task by invoking a PowerShell script that copies files from all the App1 instances. The PowerShell script will run from a central location.
App1 will have six instances: three in the East US Azure region and three in the West Europe Azure region.
You can create and manage workflows with Azure PowerShell in Azure Logic Apps.
You can create a Consumption logic app in multi-tenant Azure Logic Apps by using the JSON file for a logic app workflow definition. You can then manage your logic app by running the cmdlets in the Az.LogicApp PowerShell module.
Reference:
https://docs.microsoft.com/en-us/azure/logic-apps/quickstart-logic-apps-azure-powershell

Comments

Chosen Answer:
This is a voting comment (?) , you can switch to a simple comment.
Switch to a voting comment New
Tusharsp
Highly Voted 1 year, 4 months ago
Selected Answer: A
Azure function will need to be run from every region. This will need 2 functions. Logic app can be created centrally and executed for both regions as per given requirement. "The PowerShell script will run from a central location."
upvoted 26 times
pkkalra
1 year, 4 months ago
Azure function as a resource is created in a region but it can access data store from a different region if access is provided. A single function from a region should be able to do the job. I have no reason to believe that a logic app can access data store from two regions but a function cannot. Answer is B.
upvoted 6 times
...
AzureJobsTillRetire
1 year, 4 months ago
You can create a Consumption logic app in multi-tenant Azure Logic Apps by using the JSON file for a logic app workflow definition. You can then manage your logic app by running the cmdlets in the Az.LogicApp PowerShell module. Reference: https://docs.microsoft.com/en-us/azure/logic-apps/quickstart-logic-apps-azure-powershell
upvoted 2 times
...
AzureJobsTillRetire
1 year, 4 months ago
"Azure Functions resources are region-specific and can't be moved across regions. You must create a copy of your existing function app resources in the target region, then redeploy your functions code over to the new app." https://learn.microsoft.com/en-us/azure/azure-functions/functions-move-across-regions
upvoted 4 times
...
...
techrat
Highly Voted 1 year ago
I am confident it's B. Azure Function. I had this question on the exam today, and I got 979, in the Design Infrastrcture Solutions, I was 100% correct, and this quesiton belongs to this catagory.
upvoted 16 times
...
Chenn
Most Recent 2 weeks ago
The correct answer is B. an Azure Function. Azure Functions is a serverless compute service that lets you run event-triggered code without having to explicitly provision or manage infrastructure. In this case, you can create a timer-triggered function that runs your PowerShell script every hour. This approach is cost-effective because with Azure Functions, you only pay for the time your code runs. Option A, Azure Logic App, is more suited for workflows and would be an overkill for this scenario. Option C, an Azure Virtual Machine, would require you to manage the infrastructure and would be more costly. Option D, an App Service WebJob, could also work but it would require an App Service plan which might be more expensive than Azure Functions. Therefore, Azure Functions would be the most cost-effective solution for this scenario.
upvoted 1 times
...
Lazylinux
3 weeks ago
Selected Answer: B
I would agree with B and below show why https://learn.microsoft.com/en-us/azure/azure-functions/functions-compare-logic-apps-ms-flow-webjobs
upvoted 1 times
...
ubdubdoo
1 month ago
Azure Logic Apps does not have a native connector to directly run PowerShell scripts within its workflows
upvoted 1 times
...
varinder82
1 month, 3 weeks ago
Final Answer: an Azure logic app
upvoted 1 times
...
177c705
2 months, 2 weeks ago
B. an Azure function
upvoted 2 times
...
IN4Dev
2 months, 2 weeks ago
Selected Answer: B
PowerShell script and every hour, this is Azure Function for sure.
upvoted 3 times
...
BShelat
5 months, 1 week ago
"Every hour, you will run a maintenance task by invoking a PowerShell script that copies files from all the App1 instances. " --> This shows that require coding for copying is taken care of by PowerShell script and now it just need to be scheduled and executed. Logic App does not need coding Azure Functions need coding. So ruling out Azure Functions. Answer is Logic App.
upvoted 1 times
mtc9
2 months, 1 week ago
Bro you need to run a PS script, which can be the code of the function
upvoted 1 times
...
...
ziggy1117
5 months, 1 week ago
Selected Answer: A
Azure Logic App. The key here is the term "every hour" "Every hour, you will run a maintenance task by invoking a PowerShell script that copies files from all the App1 instances. The PowerShell script will run from a central location." In Azure Logic App, you can schedule every hour.
upvoted 1 times
xRiot007
2 months, 3 weeks ago
Wrong. The thing you call "key" should be "minimize costs". As for "every hour" all those options can be timed to execute hourly.
upvoted 2 times
...
dlenc
4 months ago
timer-triggered azure function: exists
upvoted 2 times
...
...
Paul_white
5 months, 2 weeks ago
For the App1 maintenance task, I would recommend using an **Azure Function** (Option B). Azure Functions is a serverless compute service that lets you run event-triggered code without having to explicitly provision or manage infrastructure. Given that the maintenance task needs to run every hour, this can be easily configured with a timer trigger in Azure Functions. This approach would minimize costs as you only pay for the compute time you consume - there is no charge when your code is not running. Plus, with Azure Functions, you can write your function code in PowerShell, which aligns with your requirement to run a PowerShell script.
upvoted 4 times
...
xxavimr
8 months ago
Selected Answer: A
Both Azure function and Logic App may solve the problem but in terms of cost, Logic App is more efficient. Azure Functions need to have VNet integration to connect to every resource. As it is in different regions, they need Dedicated plan with a VNet Gateway (with its charges). See the matrix in https://learn.microsoft.com/en-us/azure/azure-functions/functions-networking-options?tabs=azure-cli#virtual-network-integration
upvoted 2 times
...
Red0101
8 months, 1 week ago
Selected Answer: A
I'd say Logic App because we don't know how much time the powershell script is going to take (with the risk of being over the 10 minutes allowed from the consumption plan); and something should still trigger the azure function periodically, so it would require another component
upvoted 1 times
mtc9
2 months, 1 week ago
The function code can be the script itlelf, so you don't need to code 2 components
upvoted 1 times
...
...
Red0101
8 months, 1 week ago
I'd say Logic App because we don't know how much time the powershell script is going to take (with the risk of being over the 10 minutes allowed from the consumption plan); and something should still trigger the azure function periodically, so it would require another component
upvoted 2 times
...
Leocan
8 months, 1 week ago
Selected Answer: B
I choose B.
upvoted 2 times
...
Raj70
9 months ago
Super clear that one cannot run functions with one central copy across regions. So it has to be Logic Apps.
upvoted 2 times
...
daniloaclima
10 months, 3 weeks ago
Selected Answer: A
https://docs.microsoft.com/en-us/azure/logic-apps/quickstart-logic-apps-azure-powershell
upvoted 1 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 ...