Courseiva
Develop Azure compute solutionseasyMultiple ChoiceObjective-mapped

AZ-204 Develop Azure compute solutions Practice Question

You are developing a background job that runs every hour to process data. You choose Azure Functions with a timer trigger. What is the correct format for the cron expression to run at the start of every hour?

⚠ Common exam trap

It's easy for candidates to confuse the six-field Azure Functions cron format with the standard five-field UNIX cron format, leading them to pick '0 * * * * *' (which runs every minute) or '* 0 * * * *' (which runs every second during minute 0).

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

0 0 * * * *

In Azure Functions timer triggers, the cron expression uses six fields: {second} {minute} {hour} {day} {month} {day-of-week}. To run at the start of every hour (i.e., at minute 0 and second 0 of every hour), the expression must be '0 0 * * * *'. Option C correctly sets second to 0, minute to 0, and hour to '*' (every hour), with the remaining fields as '*' (every day, every month, every day-of-week).

Answer analysis

Option-by-option breakdown

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

  • 0 * * * * *

    Why it's wrong here

    This expression specifies that the job should run when the second is 0, regardless of the minute, hour, day of month, month, or day of week. Since the minute field is a wildcard ("*"), this means it will trigger at the 0th second of *every* minute. This results in the job executing 60 times per hour, which is far more frequent than the desired hourly execution.

  • * 0 * * * *

    Why it's wrong here

    This cron expression is configured to trigger for every second ("*") when the minute is exactly 0. This means that for the first minute of every hour (e.g., from 00:00:00 to 00:00:59, then 01:00:00 to 01:00:59, etc.), the job will execute once per second. This results in 60 executions at the start of each hour, which is not the single hourly execution required.

  • 0 0 * * * *

    Why this is correct

    This cron expression precisely defines a schedule for a job to run at the very beginning of every hour. By setting both the second and minute fields to "0", it ensures the trigger occurs exactly at the 0th second of the 0th minute of any given hour. The wildcard "*" in the hour, day of month, month, and day of week fields ensures this execution pattern repeats consistently, once per hour, every hour of every day.

  • 0 0 0 * * *

    Why it's wrong here

    This cron expression specifies that the job should execute precisely at midnight (00:00:00) every day. The "0" in the hour field restricts execution to only the 0th hour of the day, while the "0"s in the second and minute fields ensure it's the very start of that hour. This schedule results in a single daily execution, which does not meet the requirement for a job that needs to run every hour.

Quick reference

Cloud Service Model Comparison

ModelYou ManageProvider ManagesExamples
IaaSOS, runtime, apps, dataHardware, hypervisor, networkingEC2, Azure VMs, GCP Compute Engine
PaaSApps and dataOS, runtime, middleware, hardwareElastic Beanstalk, Azure App Service
SaaSData and settings onlyEverything elseMicrosoft 365, Salesforce, Workday
FaaS / ServerlessFunction code onlyInfra, scaling, runtimeLambda, Azure Functions, Cloud Run
CaaSContainers and appsKubernetes, OS, hardwareEKS, AKS, GKE

Go deeper

Related to this question

About these practice questions

This AZ-204 question is part of Courseiva's 881-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam 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.