Black Friday Special Sale - Limited Time 70% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: mxmas70

Home > Microsoft > Microsoft Certified: Azure Developer Associate > AZ-204

AZ-204 Developing Solutions for Microsoft Azure Question and Answers

Question # 4

You need to configure API Management for authentication.

Which policy values should you use? To answer, select the appropriate options in the answer area.

NOTE: Each correct selection is worth one point.

Full Access
Question # 5

You need to configure the integration for Azure Service Bus and Azure Event Grid.

How should you complete the CLI statement? To answer, select the appropriate options in the answer area.

NOTE: Each correct selection is worth one point.

Full Access
Question # 6

You need to retrieve the database connection string.

Which values should you use? To answer, select the appropriate options in the answer area.

NOTE: Each correct selection is worth one point.

Full Access
Question # 7

You need to authenticate the user to the corporate website as indicated by the architectural diagram.

Which two values should you use? Each correct answer presents part of the solution.

NOTE: Each correct selection is worth one point.

A.

ID token signature

B.

ID token claims

C.

HTTP response code

D.

Azure AD endpoint URI

E.

Azure AD tenant ID

Full Access
Question # 8

QUESTION 1

You need to correct the RequestUserApproval Function app error.

What should you do?

A.

Update line RA13 to use the async keyword and return an HttpRequest object value.

B.

Configure the Function app to use an App Service hosting plan. Enable the Always On setting of the hosting plan.

C.

Update the function to be stateful by using Durable Functions to process the request payload.

D.

Update the functionTimeout property of the host.json project file to 15 minutes.

Full Access
Question # 9

You need to configure Azure Service Bus to Event Grid integration.

Which Azure Service Bus settings should you use? To answer, select the appropriate options in the answer area.

NOTE: Each correct selection is worth one point.

Full Access
Question # 10

You need to ensure that all messages from Azure Event Grid are processed.

What should you use?

A.

Azure Event Grid topic

B.

Azure Service Bus topic

C.

Azure Service Bus queue

D.

Azure Storage queue

E.

Azure Logic App custom connector

Full Access
Question # 11

You need to investigate the Azure Function app error message in the development environment.

What should you do?

A.

Connect Live Metrics Stream from Application Insights to the Azure Function app and filter the metrics.

B.

Create a new Azure Log Analytics workspace and instrument the Azure Function app with Application Insights.

C.

Update the Azure Function app with extension methods from Microsoft.Extensions.Logging to log events by using the log instance.

D.

Add a new diagnostic setting to the Azure Function app to send logs to Log Analytics.

Full Access
Question # 12

You need to correct the corporate website error.

Which four actions should you recommend be performed in sequence? To answer, move the appropriate actions from the list of actions to the answer area and arrange them in the correct order.

Full Access
Question # 13

You need to correct the Azure Logic app error message.

Which configuration values should you use? To answer, select the appropriate options in the answer area.

NOTE: Each correct selection is worth one point.

Full Access
Question # 14

You need to configure security and compliance for the corporate website files.

Which Azure Blob storage settings should you use? To answer, select the appropriate options in the answer area.

NOTE: Each correct selection is worth one point.

Full Access
Question # 15

you need to reduce read latency for the retail store solution.

What are two possible ways to achieve the goal? Each correct answer presents a complete solution.

NOTE: Each correct selection is worth one point.

A.

Create a new composite index for the store location data queries in Azure Cosmos DB. Modify the queries to support parameterized SQL and update the Azure function app to call the new Queries.

B.

Configure Azure Cosmos DB consistency to strong consistency Increase the RUs for the container supporting store location data.

C.

Provision an Azure Cosmos OB dedicated gateway, update blob storage to use the new dedicated gateway endpoint.

D.

Configure Azure Cosmos DB consistency to session consistency. Cache session tokens in a new Azure Redis cache instance after every write. Update reads to use the session token stored in Azure Redis.

E.

Provision an Azure Cosmos DB dedicated gateway Update the Azure Function app connection string to use the new dedicated gateway endpoint.

Full Access
Question # 16

You need to Implement the retail store location Azure Function.

How should you configure the solution? To answer, select the appropriate options in the answer area.

NOTE: Each correct selection is worth one point.

Full Access
Question # 17

You need to secure the corporate website to meet the security requirements.

What should you do?

A.

Create an App Service instance with a standard plan. Configure the custom domain with a TLS/SSL certificate.

B.

Create an Azure Application Gateway with a Web Application Firewall (WAF). Configure end-to-end TLS encryption and the WAF.

C.

Create an Azure Cache for Radis instance. Update the code to support the cache.

D.

Create an Azure Content Delivery Network profile and endpoint. Configure the endpoint.

Full Access
Question # 18

You need to configure the Account Kind, Replication, and Storage tier options for the corporate website’s Azure Storage account.

How should you complete the configuration? To answer, select the appropriate options in the dialog box in the answer area.

NOTE: Each correct selection is worth one point.

Full Access
Question # 19

You need to implement an aggregate of telemetry values for distributor API calls.

Which Application Insights API method should you use?

A.

TrackTrace

B.

Track Exception

C.

TrackEvent

D.

TrackDependency

E.

TrackMetric

Full Access
Question # 20

You need to test the availability of the corporate website.

Which two test types can you use?

A.

Custom testing using the TrackAvailability API method

B.

Standard

C.

URL Ping

D.

Multi-step

Full Access
Question # 21

You need to implement the corporate website.

How should you configure the solution?

Full Access
Question # 22

You need to implement event routing for retail store location data.

Which configuration should you use?

Full Access
Question # 23

YOU need to reliably identify the delivery driver profile information.

How should you configure the system? To answer, select the appropriate options in the answer area.

NOTE Each correct selection is worth one point.

Full Access
Question # 24

You need to implement the delivery service telemetry data

How should you configure the solution?

NOTE: Each correct selection is worth one point.

Full Access
Question # 25

You need to secure the Azure Functions to meet the security requirements.

Which two actions should you perform? Each correct answer presents part of the solution.

NOTE: Each correct selection is worth one point.

A.

Store the RSA-HSM key in Azure Cosmos DB. Apery the built-in policies for customer-managed keys and allowed locations.

B.

Create a free tier Azure App Configuration instance with a new Azure AD service principal.

C.

Store the RSA-HSM key in Azure Key Vault with soft-delete and purge-protection features enabled.

D.

Store the RSA-HSM key in Azure Blob storage with an Immutability policy applied to the container.

E.

Create a standard tier Azure App Configuration instance with an assigned Azure AD managed identity.

Full Access
Question # 26

You are developing several microservices named serviceA. serviceB, and serviceC. You deploy the microservices to a new Azure Container Apps environment. You have the following requirements.

• The microservices must persist data to storage.

• serviceA must persist data only visible to the current container and the storage must be restricted to the amount of disk space available in the container

• servtceB must persist data for the lifetime of the replica and allow multiple containers in the replica to mount the same storage location.

• serviceC must persist data beyond the lifetime of the replica while allowing multiple containers to access the storage and enable per object permissions.

You need to configure storage for each microservice.

Full Access
Question # 27

You need to secure the Azure Functions to meet the security requirements.

Which two actions should you perform? Each correct answer presents part of the solution

NOTE: Each correct selection is worth one point.

A.

Store the RSA-HSM key in Azure Key Vault with soft-delete and purge-protection features enabled

B.

Store the RSA-HSM key in Azure Blob storage with an immutability policy applied to the container.

C.

Store the RSA-HSM key in Azure Cosmos DB. Apply the built-in policies for customer-managed Keys and allowed locations

D.

Create a standard tier Azure App Configuration instance with an assigned Azure AD managed identity.

E.

Create a free tier Azure App Configuration instance with a new Azure AD service principal.

Full Access
Question # 28

You need to audit the retail store sales transactions.

What are two possible ways to achieve the goal? Each correct answer presents a complete solution.

NOTE: Each correct selection is worth one point.

A.

Update the retail store location data upload process to include blob index tags. Create an Azure Function to process the blob index tags and filter by store location

B.

Enable blob versioning for the storage account. Use an Azure Function to process a list of the blob versions per day.

C.

Process an Azure Storage blob inventory report by using an Azure Function. Create rule filters on the blob inventory report,

D.

Subscribe to blob storage events by using an Azure Function and Azure Event Grid. Filter the events by store location.

E.

Process the change feed logs of the Azure Blob storage account by using an Azure Function. Specify a time range for the change feed data.

Full Access
Question # 29

Note: This question is part of a series of questions that present the same scenario. Each question in the series contains a unique solution. Determine whether the solution meets the stated goals.

You are developing and deploying several ASP.Net web applications to Azure App Service. You plan to save session state information and HTML output. You must use a storage mechanism with the following requirements:

•Share session state across all ASP.NET web applications

•Support controlled, concurrent access to the same session state data for multiple readers and a single writer

•Save full HTTP responses for concurrent requests

You need to store the information.

Proposed Solution: Add the web applications to Docker containers. Deploy the containers. Deploy the containers to Azure Kubernetes Service (AKS).

Does the solution meet the goal?

A.

Yes

B.

No

Full Access
Question # 30

You develop a REST API. You implement a user delegation SAS token to communicate with Azure Blob

storage.

The token is compromised.

You need to revoke the token.

What are two possible ways to achieve this goal? Each correct answer presents a complete solution.

NOTE: Each correct selection is worth one point.

A.

Revoke the delegation keys

B.

Delete the stored access policy.

C.

Regenerate the account key.

D.

Remove the role assignment for the security principle.

Full Access
Question # 31

You are developing an e-commerce solution that uses a microservice architecture.

You need to design a communication backplane for communicating transactional messages between various parts of the solution. Messages must be communicated in first-in-first-out (FIFO) order.

What should you use?

A.

Azure Storage Queue

B.

Azure Event Hub

C.

Azure Service Bus

D.

Azure Event Grid

Full Access
Question # 32

You are developing an Azure messaging solution.

You need to ensure that the solution that meets the following requirements:

• Provide transactional support

• Provide duplicate detection.

• Store the messages for an unlimited period of time

Which two technologies will meet the requirements? Each correct answer presents a complete solution NOTE Each correct selection is worth one point.

A.

Azure Service Bus Queue

B.

Azure Storage Queue

C.

Azure Service Bus Topic

D Azure Event Hub

Full Access
Question # 33

You develop and deploy an Azure App Service web app that connects to Azure Cache for Redis as a content cache. An resources have been deployed to East US 2 region.

The security team requires the from Azure Cache for Redis:

The number of Redis client connections from an associated IP address.

Redis operations completed on the content cache.

The location (region) in which the Azure Cache for Redis instance was accessed.

The audit information must be captured and analyzed by a security team application deployed to Central US region

You need to log information on all client corrections to the cache.

Which configuration values should you use?

Full Access
Question # 34

You are implementing a software as a service (SaaS) ASP.NET Core web service that will run as an Azure Web App. The web service will use an on-premises SQL Server database for storage. The web service also includes a WebJob that processes data updates. Four customers will use the web service.

    Each instance of the WebJob processes data for a single customer and must run as a singleton instance.

    Each deployment must be tested by using deployment slots prior to serving production data.

    Azure costs must be minimized.

    Azure resources must be located in an isolated network.

You need to configure the App Service plan for the Web App.

How should you configure the App Service plan? To answer, select the appropriate settings in the answer area.

NOTE: Each correct selection is worth one point.

Full Access
Question # 35

You are preparing to deploy an ASP.NET Core website to an Azure Web App from a GitHub repository. The website includes static content generated by a script.

You plan to use the Azure Web App continuous deployment feature.

You need to run the static generation script before the website starts serving traffic.

What are two possible ways to achieve this goal? Each correct answer presents a complete solution.

NOTE: Each correct selection is worth one point.

A.

Create a file named .deployment in the root of the repository that calls a script which generates the static content and deploys the website.

B.

Add a PreBuild target in the websites csproj project file that runs the static content generation script.

C.

Create a file named run.cmd in the folder /run that calls a script which generates the static content and deploys the website.

D.

Add the path to the static content generation tool to WEBSITE_RUN_FROM_PACKAGE setting in the host.json file.

Full Access
Question # 36

You develop and deploy an Azure App Service web app to a production environment. You enable the Always On setting and the Application Insights site extensions. You deploy a code update and receive multiple failed requests and exceptions in the web app. You need to validate the performance and failure counts of the web app in near real time. Which Application Insights tool should you use?

A.

Snapshot Debugger

B.

Profiler

C.

Smart Detection

D.

Live Metrics Stream

E.

Application Map

Full Access
Question # 37

You develop an app that allows users to upload photos and videos to Azure storage. The app uses a storage REST API call to upload the media to a blob storage account named Account1. You have blob storage

containers named Container1 and Container2.

Uploading of videos occurs on an irregular basis.

You need to copy specific blobs from Container1 to Container2 in real time when specific requirements are

met, excluding backup blob copies.

What should you do?

A.

Download the blob to a virtual machine and then upload the blob to Container2.

B.

Run the Azure PowerShell command Start-AzureStorageBlobCopy.

C.

Copy blobs to Container2 by using the Put Blob operation of the Blob Service REST API.

D.

Use AzCopy with the Snapshot switch blobs to Container2.

Full Access
Question # 38

Note: This question is part of a series of questions that present the same scenario. Each question in the series contains a unique solution that might meet the stated goals. Some question sets might have more than one correct solution, while others might not have a correct solution.

After you answer a question in this question, you will NOT be able to return to it. As a result, these questions will not appear in the review screen.

You are developing a solution that will be deployed to an Azure Kubernetes Service (AKS) cluster. The solution will include a custom VNet, Azure Container Registry images, and an Azure Storage account.

The solution must allow dynamic creation and management of all Azure resources within the AKS cluster.

You need to configure an AKS cluster for use with the Azure APIs.

Solution: Enable the Azure Policy Add-on for Kubernetes to connect the Azure Policy service to the GateKeeper admission controller for the AKS cluster. Apply a built-in policy to the cluster.

Does the solution meet the goal?

A.

Yes

B.

No

Full Access
Question # 39

You are developing an Azure Function App. You develop code by using a language that is not supported by the Azure Function App host. The code language supports HTTP primitives.

You must deploy the code to a production Azure Function App environment.

You need to configure the app for deployment.

Which configuration values should you use? To answer, select the appropriate options in the answer area.

NOTE: Each correct selection is worth one point.

Full Access
Question # 40

You need to implement the Azure Function for delivery driver profile information.

Which configurations should you use? To answer, select the appropriate options in the answer area.

NOTE: Each correct selection is worth one point.

Full Access
Question # 41

You are developing a web application that uses the Microsoft identify platform for user and resource authentication. The web application calls several REST APIs.

You are implementing various authentication and authorization flows for the web application.

You need to validate the claims in the authentication token.

Which token type should use? To answer, select the appropriate options in the answer area.

NOTE: Each correct selection is worth one point.

Full Access
Question # 42

You need to investigate the http server log output to resolve the issue with the ContentUploadService.

Which command should you use first?

A.

az webapp log

B.

az ams live-output

C.

az monitor activity-log

D.

az container attach

Full Access
Question # 43

You need to add code at line AM10 of the application manifest to ensure that the requirement for manually reviewing content can be met.

How should you complete the code? To answer, select the appropriate options in the answer area.

NOTE: Each correct selection is worth one point.

Full Access
Question # 44

You need to add code at line EG15 in EventGridController.cs to ensure that the Log policy applies to all services.

How should you complete the code? To answer, drag the appropriate code segments to the correct locations. Each code segment may be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to view content.

NOTE: Each correct selection is worth one point.

Full Access
Question # 45

You need to implement telemetry for non-user actions.

How should you complete the Filter class? To answer, drag the appropriate code segments to the correct locations. Each code segment may be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to view content.

NOTE: Each correct selection is worth one point.

Full Access
Question # 46

You need to ensure that the solution can meet the scaling requirements for Policy Service.

Which Azure Application Insights data model should you use?

A.

an Application Insights dependency

B.

an Application Insights event

C.

an Application Insights trace

D.

an Application Insights metric

Full Access
Question # 47

You need to insert code at line LE03 of LoginEvent.cs to ensure that all authentication events are processed correctly.

How should you complete the code? To answer, select the appropriate options in the answer area.

NOTE: Each correct selection is worth one point.

Full Access
Question # 48

You need to implement the Log policy.

How should you complete the EnsureLogging method in EventGridController.cs? To answer, select the appropriate options in the answer area.

NOTE: Each correct selection is worth one point.

Full Access
Question # 49

You need to ensure that PolicyLib requirements are met.

How should you complete the code segment? To answer, drag the appropriate code segments to the correct locations. Each code segment may be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to view content.

NOTE: Each correct selection is worth one point.

Full Access
Question # 50

You need to configure Azure Cosmos DB.

Which settings should you use? To answer, select the appropriate options in the answer area.

NOTE: Each correct selection is worth one point.

Full Access
Question # 51

You need to implement the Log policy.

How should you complete the Azure Event Grid subscription? To answer, drag the appropriate JSON segments to the correct locations. Each JSON segment may be used once, more than once, or not at all. You may need to drag the split bar between panes to view content.

NOTE: Each correct selection is worth one point.

Full Access
Question # 52

You need to deploy a new version of the LabelMaker application to ACR.

Which three actions should you perform in sequence? To answer, move the appropriate actions from the list of actions to the answer area and arrange them in the correct order.

Full Access
Question # 53

You need to access data from the user claim object in the e-commerce web app.

What should you do first?

A.

Write custom code to make a Microsoft Graph API call from the e-commerce web app.

B.

Assign the Contributor RBAC role to the e-commerce web app by using the Resource Manager create role assignment API.

C.

Update the e-commerce web app to read the HTTP request header values.

D.

Using the Azure CLI, enable Cross-origin resource sharing (CORS) from the e-commerce checkout API to the e-commerce web app.

Full Access
Question # 54

You need to resolve a notification latency issue.

Which two actions should you perform? Each correct answer presents part of the solution.

NOTE: Each correct selection is worth one point.

A.

Set Always On to true.

B.

Ensure that the Azure Function is using an App Service plan.

C.

Set Always On to false.

D.

Ensure that the Azure Function is set to use a consumption plan.

Full Access
Question # 55

You need to retrieve all order line items from Order.json and sort the data alphabetically by the city.

How should you complete the code? To answer, select the appropriate options in the answer area.

NOTE: Each correct selection is worth one point.

Full Access
Question # 56

You need to support the requirements for the Shipping Logic App.

What should you use?

A.

Azure Active Directory Application Proxy

B.

Point-to-Site (P2S) VPN connection

C.

Site-to-Site (S2S) VPN connection

D.

On-premises Data Gateway

Full Access
Question # 57

You need to add code at line PC32 in Processing.cs to implement the GetCredentials method in the Processing class.

How should you complete the code? To answer, drag the appropriate code segments to the correct locations. Each code segment may be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to view content.

NOTE: Each correct selection is worth one point.

Full Access
Question # 58

You need to resolve the log capacity issue.

What should you do?

A.

Create an Application Insights Telemetry Filter

B.

Change the minimum log level in the host.json file for the function

C.

Implement Application Insights Sampling

D.

Set a LogCategoryFilter during startup

Full Access
Question # 59

You need to add code at line PC26 of Processing.cs to ensure that security policies are met.

How should you complete the code that you will add at line PC26? To answer, select the appropriate options in the answer area.

NOTE: Each correct selection is worth one point.

Full Access
Question # 60

You need to ensure receipt processing occurs correctly.

What should you do?

A.

Use blob properties to prevent concurrency problems

B.

Use blob SnapshotTime to prevent concurrency problems

C.

Use blob metadata to prevent concurrency problems

D.

Use blob leases to prevent concurrency problems

Full Access
Question # 61

You need to resolve the capacity issue.

What should you do?

A.

Convert the trigger on the Azure Function to an Azure Blob storage trigger

B.

Ensure that the consumption plan is configured correctly to allow scaling

C.

Move the Azure Function to a dedicated App Service Plan

D.

Update the loop starting on line PC09 to process items in parallel

Full Access
Question # 62

You need to ensure the security policies are met.

What code do you add at line CS07 of ConfigureSSE.ps1?

A.

–PermissionsToKeys create, encrypt, decrypt

B.

–PermissionsToCertificates create, encrypt, decrypt

C.

–PermissionsToCertificates wrapkey, unwrapkey, get

D.

–PermissionsToKeys wrapkey, unwrapkey, get

Full Access
Question # 63

You need to ensure disaster recovery requirements are met.

What code should you add at line PC16?

To answer, drag the appropriate code fragments to the correct locations. Each code fragment may be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to view content.

NOTE: Each correct selection is worth one point.

Full Access