Microsoft Certified: Azure Developer Associate Azure Functions and Serverless Computing 1 — Questions and Answers
Question 1: Which Azure Functions hosting plan scales automatically to zero when there is no traffic?
- Dedicated (App Service) plan
- Premium plan
- Consumption plan (Correct answer)
- Flex Consumption plan
Correct answer: Consumption plan
The Consumption plan scales to zero when idle and you pay only for execution time and resource consumption.
Question 2: What attribute marks a C# Azure Function as triggered by an HTTP request?
- [HttpTrigger] (Correct answer)
- [FunctionTrigger("http")]
- [WebHook]
- [RestTrigger]
Correct answer: [HttpTrigger]
The `[HttpTrigger]` attribute on a function parameter configures the Azure Function to execute on incoming HTTP requests.
Question 3: In Azure Durable Functions, which function type orchestrates the execution of other functions?
- Activity function
- Entity function
- Orchestrator function (Correct answer)
- Client function
Correct answer: Orchestrator function
Orchestrator functions define the workflow logic and coordinate calls to activity functions using async/await patterns.
Question 4: What is the default maximum execution timeout for an Azure Function running on the Consumption plan?
- 1 minute
- 5 minutes
- 10 minutes (Correct answer)
- 30 minutes
Correct answer: 10 minutes
On the Consumption plan, Azure Functions default to a 5-minute timeout but the maximum allowed is 10 minutes.
Question 5: Which file defines the bindings and trigger configuration for an Azure Function in the non-isolated worker model?
- host.json
- local.settings.json
- function.json (Correct answer)
- bindings.json
Correct answer: function.json
`function.json` contains the trigger, input binding, and output binding definitions for each Azure Function.
Question 6: What Durable Functions pattern is used to fan out work across multiple parallel activity functions and then aggregate results?
- Chaining
- Fan-out/fan-in (Correct answer)
- Async HTTP API
- Monitor
Correct answer: Fan-out/fan-in
The fan-out/fan-in pattern starts multiple activity functions in parallel and uses `Task.WhenAll` to wait for all results before aggregating.
Which Azure Functions hosting plan scales automatically to zero when there is no traffic?