Microsoft Azure Developer Associate AZ-204 Practice Question

You are developing an Azure Functions app that uses the Azure Cosmos DB .NET v3 SDK. The Orders container is partitioned on /categoryId. For a new checkout event, you must create one Order document and update the associated CategorySummary document that shares the same categoryId. Both changes must either succeed or fail together in a single request from the function, and you prefer to avoid writing any server-side stored procedures. Which SDK feature should you use?

  • Wrap the two SDK calls inside a System.Transactions TransactionScope for automatic commit.

  • Call CreateItemAsync and ReplaceItemAsync inside a TransactionalBatch scoped to the categoryId partition key.

  • Invoke Container.ExecuteStoredProcedureAsync with a stored procedure that performs both operations.

  • Enable bulk execution and invoke CreateItemAsync and ReplaceItemAsync concurrently.

Microsoft Azure Developer Associate AZ-204
Develop for Azure storage
Your Score:
Settings & Objectives
Random Mixed
Questions are selected randomly from all chosen topics, with a preference for those you haven’t seen before. You may see several questions from the same objective or domain in a row.
Rotate by Objective
Questions cycle through each objective or domain in turn, helping you avoid long streaks of questions from the same area. You may see some repeat questions, but the distribution will be more balanced across topics.

Check or uncheck an objective to set which questions you will receive.

Bash, the Crucial Exams Chat Bot
AI Bot