Free DP-420 Exam Braindumps

HOTSPOT (Drag and Drop is not supported).
You are developing an application that will connect to an Azure Cosmos DB Core (SQL) API account. The account has a single read-write region and one additional read region. The regions are con gured for automatic failover. The account has the following connection strings. (Line numbers are included for reference only.)



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 same connection string can still be used.
Azure Cosmos DB Core read write region connection strings
Azure Cosmos DB "primary write region" failover "connection string"

Box 2: No
The AccountEndpoint for both are the same.

Box 3: Yes
The ConnectionPolicy.PreferredLocations property gets and sets the preferred locations (regions) for geo-replicated database accounts in the Azure Cosmos DB service. For example, "East US" as the preferred location.
When EnableEndpointDiscovery is true and the value of this property is non-empty, the SDK uses the locations in the collection in the order they are speci ed to perform operations, otherwise if the value of this property is not speci ed, the SDK uses the write region as the preferred location for all operations.


Reference:

https://docs.microsoft.com/en-us/dotnet/api/microsoft.azure.documents.client.connectionpolicy.preferredlocations



You have a global ecommerce application that stores data in an Azure Cosmos DB Core (SQL) API account. The account is con gured for multi- region writes.
You need to create a stored procedure for a custom con ict resolution policy for a new container. In the event of a con ict caused by a deletion, the deletion must always take priority.
Which parameter should you check in the stored procedure function?

  1. isTombstone
  2. con ictingItems
  3. existingItem
  4. incomingItem

Answer(s): A

Explanation:

isTombstone: Boolean indicating if the incomingItem is con icting with a previously deleted item. When true, existingItem is also null.
Incorrect:
con ictingItems: Array of the committed version of all items in the container that are con icting with incomingItem on ID or any other unique index properties. existingItem: The currently committed item. This value is non-null in an update and null for an insert or deletes. incomingItem:
The item being inserted or updated in the commit that is generating the con icts. Is null for delete operations.


Reference:

https://docs.microsoft.com/en-us/azure/cosmos-db/sql/how-to-manage-con icts



You have an Azure Cosmos DB Core (SQL) API account named account1 that supports an application named App1. App1 uses the consistent pre x consistency level.
You con gure account1 to use a dedicated gateway and integrated cache.
You need to ensure that App1 can use the integrated cache.
Which two actions should you perform for App1? Each correct answer presents part of the solution.
NOTE: Each correct selection is worth one point.

  1. Change the consistency level of requests to session.
  2. Change the account endpoint to http://account1.documents.azure.com.
  3. Change the account endpoint to http://account1.sqlx.cosmos.azure.com.
  4. Change the connection mode to direct.
  5. Change the consistency level of requests to strong.

Answer(s): A,C

Explanation:

C: Modify your application's connection string to use the new dedicated gateway endpoint.
All dedicated gateway connection strings follow the same pattern. Remove documents.azure.com from your original connection string and replace it with sqlx.cosmos.azure.com. A dedicated gateway will always have the same connection string, even if you remove and reprovision it.
A: You must adjust the request consistency to session or eventual. If not, the request will always bypass the integrated cache.


Reference:

https://docs.microsoft.com/en-us/azure/cosmos-db/how-to-con gure-integrated-cache Topic 2



You have an Azure Cosmos DB Core (SQL) API account named account1 that has a single read-write region and one additional read region.
Account1 uses the strong default consistency level.
You have an application that uses the eventual consistency level when submitting requests to account1.
How will writes from the application be handled?

  1. Writes will use the eventual consistency level.
  2. Azure Cosmos DB will reject writes from the application.
  3. Writes will use the strong consistency level.
  4. The write order is not guaranteed during replication.

Answer(s): C

Explanation:

Overriding the default consistency level only applies to reads within the SDK client. An account con gured for strong consistency by default will still write and replicate data synchronously to every region in the account. When the SDK client instance or request overrides this with Session or weaker consistency, reads will be performed using a single replica.


Reference:

https://docs.microsoft.com/en-us/azure/cosmos-db/consistency-levels






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