Free DP-420 Exam Braindumps (page: 7)

Page 6 of 23

You are building an application that will store data in an Azure Cosmos DB Core (SQL) API account. The account uses the session default consistency level. The account is used by ve other applications. The account has a single read-write region and 10 additional read region. Approximately 20 percent of the items stored in the account are updated hourly.
Several users will access the new application from multiple devices.
You need to ensure that the users see the same item values consistently when they browse from the different devices. The solution must NOT affect the other applications.
Which two actions should you perform? Each correct answer presents part of the solution.
NOTE: Each correct selection is worth one point.

  1. Set the default consistency level to eventual
  2. Associate a session token to the device
  3. Use implicit session management when performing read requests
  4. Provide a stored session token when performing read requests
  5. Associate a session token to the user account

Answer(s): D,E

Explanation:

Use Session consistency and use Stateful Entities in Durable Functions or something similar that will allow you to implement a distributed mutex to store and update the Session token across multiple Cosmos client instances.
Note: The session consistency is the default consistency that you get while con guring the cosmos DB account. This level of consistency honors the client session. It ensures a strong consistency for an application session with the same session token. What that means is that whatever is written by a session will return the latest version for reads as well, from that same session.
Incorrect:
Not A: Eventual consistency is the weakest consistency level of all. The rst thing to consider in this model is that there is no guarantee on the order of the data and also no guarantee of how long the data can take to replicate. As the name suggests, the reads are consistent, but eventually.
This model offers high availability and low latency along with the highest throughput of all. This model suits the application that does not require any ordering guarantee. The best usage of this type of model would be the count of retweets, likes, non-threaded comments where the count is more important than any other information.
Not B: The reads should be the same from different devices.


Reference:

https://stackover ow.com/questions/64084499/can-i-use-a-client-constructed-session-token-for-cosmosdb



HOTSPOT (Drag and Drop is not supported).
You have a container that stores data about families.
The following is a sample document.



You run the following query against the container.



For each of the following statements, select Yes if the statement is true. Otherwise, select No.
NOTE: Each correct selection is worth one point.
Hot Area:

  1. See Explanation section for answer.

Answer(s): A

Explanation:



Box 1: No
The result is empty, since the cross product of each item from source and an empty set is empty:
Note: Joins result in a complete cross product of the sets participating in the join. The result of an N-way join is a set of N-element tuples, where each value in the tuple is associated with the aliased set participating in the join and can be accessed by referencing that alias in other clauses.

Box 2: No
The cross join is not on the pets.

Box 3: Yes
The cross join is not on the pets.


Reference:

https://docs.microsoft.com/en-us/azure/cosmos-db/sql/sql-query-join



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 an Azure Cosmos DB Core (SQL) API account named account1 that uses autoscale throughput. You need to run an Azure function when the normalized request units per second for a container in account1 exceeds a speci c value. Solution: You con gure Azure Event Grid to send events to the function by using an Event Grid trigger in the function.
Does this meet the goal?

  1. Yes
  2. No

Answer(s): B

Explanation:

Instead con gure an Azure Monitor alert to trigger the function.
You can set up alerts from the Azure Cosmos DB pane or the Azure Monitor service in the Azure portal.


Reference:

https://docs.microsoft.com/en-us/azure/cosmos-db/create-alerts



You have an application named App1 that reads the data in an Azure Cosmos DB Core (SQL) API account. App1 runs the same read queries every minute. The default consistency level for the account is set to eventual.
You discover that every query consumes request units (RUs) instead of using the cache. You verify the IntegratedCacheiteItemHitRate metric and the IntegratedCacheQueryHitRate metric. Both metrics have values of 0. You verify that the dedicated gateway cluster is provisioned and used in the connection string.
You need to ensure that App1 uses the Azure Cosmos DB integrated cache.
What should you con gure?

  1. the indexing policy of the Azure Cosmos DB container
  2. the consistency level of the requests from App1
  3. the connectivity mode of the App1 CosmosClient
  4. the default consistency level of the Azure Cosmos DB account

Answer(s): C

Explanation:

Because the integrated cache is speci c to your Azure Cosmos DB account and requires signi cant CPU and memory, it requires a dedicated gateway node.
Connect to Azure Cosmos DB using gateway mode.


Reference:

https://docs.microsoft.com/en-us/azure/cosmos-db/integrated-cache-faq






Post your Comments and Discuss Microsoft DP-420 exam with other Community members: