AZ-204 practice question 8 of 35

You are developing several microservices to run on Azure Container Apps. External HTTP ingress traffic has been enabled for the microservices. The microservices must be deployed to the same virtual network and write logs to the same Log Analytics workspace. You need to deploy the microservices. What should you do?

Full set: 489 questions

Domain Develop Azure compute solutions

Answer options
A: Enable multiple revision mode.
B: Use a separate environment for each container.
C: Enable single revision mode.
D: Use a private container registry image and single image for all containers.
E: Use a single environment for all containers. Correct answer
Correct Answer:
E. Use a single environment for all containers.
Explanation

An Azure Container Apps environment serves as a secure boundary for a group of container apps. By design, all container apps deployed within the same environment share common resources. This includes being deployed into the same virtual network and writing logs to the same configured Log Analytics workspace. Therefore, placing all microservices in a single environment directly satisfies the requirements for shared networking and logging in the most efficient way.

Why Incorrect

A. Enable multiple revision mode: Revision modes control versioning and traffic splitting for a single container app, not the shared infrastructure for multiple apps.
B. Use a separate environment for each container: This would isolate each microservice into its own virtual network and require separate logging configurations, directly violating the requirements.
C. Enable single revision mode: Like multiple revision mode, this is a setting for an individual container app's update strategy and is irrelevant to shared networking or logging.
D. Use a private container registry image and single image for all containers: The image source is unrelated to networking or logging. Using a single image for all microservices contradicts the microservice architectural pattern.

References

1. Microsoft Learn, Azure Container Apps environments: "An environment creates a secure boundary around a group of container apps. Container Apps in the same environment are deployed in the same virtual network and write logs to the same Log Analytics workspace." This statement directly confirms that a single environment meets the question's requirements.

Source: Microsoft Docs, "Azure Container Apps environments", Introduction section.

2. Microsoft Learn, Networking architecture in Azure Container Apps: "All container apps in an environment share the same virtual network (VNet)." This document clarifies that the VNet is a property of the environment, shared by all apps within it.

Source: Microsoft Docs, "Networking architecture in Azure Container Apps", Virtual network integration section.

3. Microsoft Learn, Log monitoring in Azure Container Apps: "Azure Container Apps is integrated with Azure Monitor Log Analytics to monitor and analyze your container app's logs. When you create a Container App environment, a Log Analytics workspace is created for you, or you can use an existing one." This shows the one-to-one link between an environment and a Log Analytics workspace.

Source: Microsoft Docs, "Log monitoring in Azure Container Apps", Introduction section.

Scroll to Top