nerdexam
Microsoft

DP-420 · Question #175

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…

The correct answer is D. Create a new synthetic key that contains deviceId and a random number. Creating a synthetic key that combines deviceId with a random number helps distribute writes more evenly across partitions, effectively minimizing partition skew and avoiding hot partitions. This approach also helps to maintain a balance of write operations, ensuring that no…

Design and implement data distribution

Question

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?

Exhibit

DP-420 question #175 exhibit

Options

  • AUse deviceId as the partition key.
  • BCreate a new Synthetic key that contains deviceId and deviceManufacturer.
  • CUse deviceManufacturer as the partition key.
  • DCreate a new synthetic key that contains deviceId and a random number.

How the community answered

(64 responses)
  • A
    14% (9)
  • B
    6% (4)
  • C
    3% (2)
  • D
    77% (49)

Explanation

Creating a synthetic key that combines deviceId with a random number helps distribute writes more evenly across partitions, effectively minimizing partition skew and avoiding hot partitions. This approach also helps to maintain a balance of write operations, ensuring that no single partition is overwhelmed, which can occur if using deviceId alone, especially if devices write data

Topics

#Partition key#Hot partitions#Write optimization#Synthetic key

Community Discussion

No community discussion yet for this question.

Full DP-420 Practice