Courseiva
Develop Azure compute solutionshardMultiple ChoiceObjective-mapped

AZ-204 Develop Azure compute solutions Practice Question

You are deploying a containerized application on Azure Container Instances (ACI) that needs to run as a background job every hour. The job processes data from an Azure SQL Database and sends a report via email. You need to minimize costs while ensuring the job runs reliably on schedule. The job takes about 10 minutes to complete. What should you do?

⚠ Common exam trap

A common mix-up: candidates assume an Azure Function with a timer trigger is the cheapest option, but they overlook the Function's execution timeout limits and the need to manage container lifecycle, making Logic Apps the more reliable and cost-effective choice for this specific scenario.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

Create an Azure Logic App with a recurrence trigger that starts the container group using the 'Start Container Group' action, and stop it after completion.

It uses Azure Logic Apps with a recurrence trigger to start the container group only when needed, and stops it after the job completes. This minimizes costs by avoiding continuous running charges for the container, while the Logic App itself incurs minimal execution cost. The job's 10-minute duration fits well within the 1-hour recurrence window, ensuring reliable scheduling without idle compute time.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • Use Azure Batch with a job schedule to run the container as a task.

    Why it's wrong here

    While Azure Batch can execute containerized tasks, its design is optimized for large-scale, parallel, and high-performance computing (HPC) workloads across a pool of virtual machines. For a single, occasional containerized application, the operational overhead of setting up and managing Batch pools, along with the continuous cost of pool VMs, is disproportionately high and inefficient compared to serverless container options.

  • Create an Azure Logic App with a recurrence trigger that starts the container group using the 'Start Container Group' action, and stop it after completion.

    Why this is correct

    This solution effectively leverages Azure Logic Apps' serverless workflow capabilities to precisely manage the lifecycle of an Azure Container Instance (ACI) container group. A recurrence trigger initiates the workflow on a defined schedule, and the dedicated 'Start Container Group' and 'Stop Container Group' actions ensure the container is provisioned and de-provisioned only for the duration of the task, significantly minimizing operational costs for intermittent workloads.

  • Deploy the container on a single Azure virtual machine and schedule it using Windows Task Scheduler.

    Why it's wrong here

    Deploying a container on a dedicated Azure Virtual Machine (VM) introduces substantial overhead and continuous cost, particularly for an occasional workload. A VM incurs billing for compute, storage, and networking resources around the clock, regardless of whether the container is actively processing. This approach completely undermines the cost-efficiency benefits offered by serverless container solutions like Azure Container Instances, which only bill for actual container runtime.

  • Use an Azure Function with a timer trigger that uses the Azure Container Instances SDK to start the container group.

    Why it's wrong here

    Using the Azure Container Instances SDK within a timer-triggered Azure Function to start the container group incurs the overhead of provisioning a new container instance from scratch each hour, including image pull and network setup, which adds several minutes of runtime cost beyond the 10-minute job window. This approach is tempting because Azure Functions natively support scheduled execution via timer triggers, and the SDK provides programmatic control over container lifecycles, making it a valid pattern for on-demand container orchestration when the job duration is unpredictable or requires dynamic scaling.

About these practice questions

Courseiva writes every AZ-204 question from scratch — 881 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This AZ-204 practice question is part of Courseiva's free Microsoft certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the AZ-204 exam.