Soru

Zorluk: ZorImplement Durable Functions

You are developing a document migration solution using Azure Durable Functions. The workflow uses a Fan-out/Fan-in pattern to process documents concurrently. One of the activity functions performs optical character recognition (OCR) on large PDF files; this task is CPU-intensive and can take up to 20 minutes to complete. The function app must also access files stored in an Azure Storage account that is secured behind a private endpoint inside an Azure Virtual Network.

You need to choose the most cost-effective hosting plan and configuration that meets these requirements.

Which hosting plan and configuration should you select?

  1. A
    The Azure Functions Consumption plan, because it scales to zero to minimize costs and supports virtual network integration through service endpoints.
  2. B
    The Azure App Service plan (Shared tier), because it offers a low-cost dedicated instance and supports execution timeouts of up to 30 minutes.
  3. The Azure Functions Premium plan, because it supports virtual network integration to access the private endpoint and allows for unbounded function execution timeouts.Cevap
  4. D
    The Azure Functions Premium plan, while refactoring the OCR task to execute directly within the orchestrator function to ensure state persistence.

Cevap

The Azure Functions Premium plan, because it supports virtual network integration to access the private endpoint and allows for unbounded function execution timeouts.
The Azure Functions Premium plan is the correct choice because it supports outbound virtual network integration, enabling access to resources behind private endpoints, and allows for unbounded execution times (guaranteed up to 60 minutes and configuration-unbounded), which is necessary for the 20-minute OCR activity function.

Adım Adım Çözüm

1
Analyze the network integration requirements.
Outbound virtual network integration is required because the Azure Storage account is secured behind a private endpoint.
This rules out the Consumption plan and lower-tier App Service plans (Free/Shared), as they do not support outbound virtual network integration.
2
Analyze the execution timeout constraints.
The optical character recognition (OCR) task runs up to 20 minutes.
This exceeds the maximum 10-minute execution limit of the Consumption plan. The hosting plan must support extended or unbounded execution durations, which the Premium and Dedicated plans do.
3
Evaluate the placement of the long-running task within the Durable Functions execution model.
The long-running OCR task must be executed as an activity function, not directly in the orchestrator.
Orchestrator functions must remain deterministic and must not perform I/O-bound or CPU-intensive work. Placing the OCR processing logic directly inside the orchestrator would block the orchestrator thread and cause execution failures.

Anahtar Kavram

Selecting hosting plans based on execution limits and network requirements, while maintaining orchestrator determinism.
Bu soruyu puanla