Microsoft

DP-420 Free Practice Questions — Page 2

Question 11

You are designing an Azure Cosmos DB for NoSQL solution to store data from IoT devices. Writes from the devices will occur every second. Data will be retained indefinitely. The following is a sample of the data. You need to select a partition key that meets the following requirements for writes: • Minimizes the partition skew • Avoids capacity limits • Avoids hot partitions What should you do?

A. Use deviceId as the partition key.
B. Create a new synthetic key that contains deviceId and timestamp.
C. Use sensor1value as the partition key.
D. Create a new synthetic key that contains deviceId and sensor1Value.
Show Answer
Correct Answer: B
Explanation:
A synthetic partition key combining deviceId and timestamp distributes frequent writes across many partition-key values, reducing skew and the risk of hot partitions or per-partition capacity limits. Using only deviceId can concentrate a device’s writes in one partition; sensor values are not suitable partition keys because they can have low cardinality or skew.

Question 12

You are designing an Azure Cosmos DB for NoSQL solution to store data from IoT devices. Writes from the devices will occur every second. Data will be retained indefinitely. The following is a sample of the data. You need to select a partition key that meets the following requirements for writes: • Minimizes the partition skew • Avoids capacity limits • Avoids hot partitions What should you do?

A. Use deviceId as the partition key.
B. Create a new Synthetic key that contains deviceId and deviceManufacturer.
C. Use deviceManufacturer as the partition key.
D. Create a new synthetic key that contains deviceId and a random number.
Show Answer
Correct Answer: D
Explanation:
A synthetic key combining deviceId with a random number spreads a device’s writes across multiple logical partitions, reducing hot partitions and skew. It also avoids concentrating indefinitely retained data under a single deviceId, helping prevent a logical partition from reaching its storage limit.

Question 13

You plan to create an Azure Cosmos DB account that will use an integrated cache. What will prevent you from using an integrated cache?

A. a user-assigned managed identity
B. Azure Private Link
C. a default consistency level of Session
D. availability zones
Show Answer
Correct Answer: D
Explanation:
Integrated cache uses the dedicated gateway. Dedicated gateway provisioning for accounts configured with availability zones is supported only in East US and North Europe, so availability zones can prevent its use in other regions. Private Link can be configured with a separate endpoint for the dedicated gateway, and Session consistency is compatible.

Question 14

You have an Azure subscription. The subscription contains an Azure Cosmos DB for NoSQL account named account1 that hosts a container named Container1. Container1 has a provisioned throughput of 100 request units per second (RU/s) and uses a single physical partition. You are evaluating the available throughput for Container1. What is the maximum burst capacity that Container1 can accumulate?

A. 300 RU/s
B. 1,000 RU/s
C. 30,000 RU/s
D. 100,000 RU/s
Show Answer
Correct Answer: C
Explanation:
Burst capacity can accumulate up to 300 seconds of unused throughput. With 100 RU/s on the single physical partition, the maximum is 100 × 300 = 30,000 RU.

Question 15

You have an Azure subscription. The subscription contains an Azure Cosmos DB for NoSQL account named account1 that hosts a container named Devices. Devices has a partition key named type. You plan to execute the following query. SELECT d.deviceName FROM d WHERE d.deviceId = 'ABC102' AND d.type = 'car' AND d.importanceId = 4 You are evaluating the resource utilization of the query. How will the query be executed?

A. as an in-partition query
B. as a parallel cross-partition query
C. as a cross-partition query
Show Answer
Correct Answer: A
Explanation:
The query filters on `type`, which is the container’s partition key, with an equality condition. Cosmos DB can route it to the single partition for `type = 'car'`, so it executes as an in-partition query. The other filters do not require a cross-partition scan.

Question 16

You have an Azure Cosmos DB for NoSQL account. The account hosts a container that has the change feed enabled. You are building an app by using the Azure Cosmos DB SDK. The app will read items from the change feed by using a pull model. You need to ensure that multiple threads can read the change feed in parallel. What should you include?

A. the ChangeFeedStartFrom value
B. the pagesize value
C. the FeedRange value
D. a stream-based iterator
Show Answer
Correct Answer: C
Explanation:
Use a FeedRange to divide the container’s partition-key ranges among readers, allowing multiple threads to read the change feed in parallel.

Question 17

HOTSPOT You have an Azure Cosmos DB for NoSQL account named account1. You plan to implement the integrated cache for account1. You need to configure the connectivity mode and the consistency level for requests that target account1. The solution must maximize consistency while using the integrated cache. What should you configure? To answer, select the appropriate options in the answer area. NOTE: Each correct selection is worth one point.

Illustration for DP-420 question 17
Show Answer
Correct Answer: Connectivity mode: Gateway mode with a dedicated gateway Consistency level: Session
Explanation:
The integrated cache is accessed through a dedicated gateway. Session is the strongest consistency level that can use the cache; stronger levels bypass it.

Question 18

HOTSPOT You have an Azure subscription. You need to deploy the following resources to an Azure Cosmos DB for NoSQL account: • A container • A user-defined function (UDF) The solution must minimize the possibility of the deployment failing. How should you complete the template? To answer, select the appropriate options in the answer area. NOTE: Each correct selection is worth one point.

Illustration for DP-420 question 18
Show Answer
Correct Answer: First blank: "apiVersion": Second blank: "dependsOn":
Explanation:
The API version specifies how to deploy the UDF resource. The dependency ensures the container is deployed before the UDF, reducing the chance of failure.

Question 19

DRAG DROP You have an Azure Cosmos DB for NoSQL account named account1 that has a periodic backup policy with a four-hour backup interval and an eight-hour retention period. The account1 account contains a single database named db1 and containers that have stored procedures. An administrator deletes db1 accidentally. You need to ensure that the contents of db1, including all of its items, is available as soon as possible. How should you perform the procedure? To answer, drag the missing actions to the correct order. Each action 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.

Illustration for DP-420 question 19
Show Answer
Correct Answer: Step 1: Increase the retention period of the account. Step 2: Submit a request ticket. Step 3: Recreate the stored procedures.
Explanation:
Increasing retention helps preserve the available backup while support processes the restore. Periodic backups do not restore stored procedures, so they must be recreated.

Question 20

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 section, you will NOT be able to return to it. As a result, these questions will not appear in the review screen. You have a container named container1 in an Azure Cosmos DB for NoSQL account. You need to make the contents of container1 available as reference data for an Azure Stream Analytics job. Solution: You create an Azure Synapse pipeline that uses Azure Cosmos DB for NoSQL as the input and Azure Blob Storage as the output. Does this meet the goal?

A. Yes
B. No
Show Answer
Correct Answer: A
Explanation:
Yes. Azure Stream Analytics can use data in Azure Blob Storage as reference data. A Synapse pipeline can copy the container contents from Azure Cosmos DB for NoSQL to Blob Storage, making them available to the job.

$19

Get all 177 questions with detailed answers and explanations

  • Instant download HTML + PDF delivered the moment payment clears.
  • Secure Stripe checkout we never see or store your card details.
  • 7-day refund if files are defective see our refund policy.