exam questions

Exam AZ-204 All Questions

View all questions & answers for the AZ-204 exam

Exam AZ-204 topic 6 question 62 discussion

Actual exam question from Microsoft's AZ-204
Question #: 54
Topic #: 6
[All AZ-204 Questions]

Case study -

This is a case study. Case studies are not timed separately. You can use as much exam time as you would like to complete each case. However, there may be additional case studies and sections on this exam. You must manage your time to ensure that you are able to complete all questions included on this exam in the time provided.

To answer the questions included in a case study, you will need to reference information that is provided in the case study. Case studies might contain exhibits and other resources that provide more information about the scenario that is described in the case study. Each question is independent of the other questions in this case study.

At the end of this case study, a review screen will appear. This screen allows you to review your answers and to make changes before you move to the next section of the exam. After you begin a new section, you cannot return to this section.


To start the case study -
To display the first question in this case study, click the Next button. Use the buttons in the left pane to explore the content of the case study before you answer the questions. Clicking these buttons displays information such as business requirements, existing environment, and problem statements. When you are ready to answer a question, click the Question button to return to the question.


Background -

Fourth Coffee is a global coffeehouse chain and coffee company recognized as one of the world’s most influential coffee brands. The company is renowned for its specialty coffee beverages, including a wide range of espresso-based drinks, teas, and other beverages. Fourth Coffee operates thousands of stores worldwide.


Current environment -

The company is developing cloud-native applications hosted in Azure.


Corporate website -
The company hosts a public website located at http://www.fourthcoffee.com/. The website is used to place orders as well as view and update inventory items.


Inventory items -
In addition to its core coffee offerings, Fourth Coffee recently expanded its menu to include inventory items such as lunch items, snacks, and merchandise. Corporate team members constantly update inventory. Users can customize items. Corporate team members configure inventory items and associated images on the website.


Orders -
Associates in the store serve customized beverages and items to customers. Orders are placed on the website for pickup.

The application components process data as follows:

1. Azure Traffic Manager routes a user order request to the corporate website hosted in Azure App Service.
2. Azure Content Delivery Network serves static images and content to the user.
3. The user signs in to the application through a Microsoft Entra ID for customers tenant.
4. Users search for items and place an order on the website as item images are pulled from Azure Blob Storage.
5. Item customizations are placed in an Azure Service Bus queue message.
6. Azure Functions processes item customizations and saves the customized items to Azure Cosmos DB.
7. The website saves order details to Azure SQL Database.
8. SQL Database query results are cached in Azure Cache for Redis to improve performance.

The application consists of the following Azure services:




Requirements -

The application components must meet the following requirements:

• Azure Cosmos DB development must use a native API that receives the latest updates and stores data in a document format.
• Costs must be minimized for all Azure services.
• Developers must test Azure Blob Storage integrations locally before deployment to Azure. Testing must support the latest versions of the Azure Storage APIs.


Corporate website -
• User authentication and authorization must allow one-time passcode sign-in methods and social identity providers (Google or Facebook).
• Static web content must be stored closest to end users to reduce network latency.


Inventory items -
• Customized items read from Azure Cosmos DB must maximize throughput while ensuring data is accurate for the current user on the website.
• Processing of inventory item updates must automatically scale and enable updates across an entire Azure Cosmos DB container.
• Inventory items must be processed in the order they were placed in the queue.
• Inventory item images must be stored as JPEG files in their native format to include exchangeable image file format (data) stored with the blob data upon upload of the image file.
• The Inventory Items API must securely access the Azure Cosmos DB data.


Orders -
• Orders must receive inventory item changes automatically after inventory items are updated or saved.


Issues -

• Developers are storing the Azure Cosmos DB credentials in an insecure clear text manner within the Inventory Items API code.
• Production Azure Cache for Redis maintenance has negatively affected application performance.


You need to implement the processing of enqueue inventory items.

Which message value should you use?

  • A. Sequence number
  • B. Timestamp
  • C. Session identifier
  • D. Partition key
Show Suggested Answer Hide Answer
Suggested Answer: C 🗳️

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
Thameur01
3 days, 8 hours ago
Selected Answer: C
Session identifier
upvoted 1 times
...
d90b583
2 months, 2 weeks ago
Selected Answer: C
https://learn.microsoft.com/en-us/azure/service-bus-messaging/message-sessions#sequencing-vs-sessions Written in above link - If messages just need to be retrieved in order, you don't need to use sessions. If messages need to be processed in order, use sessions.
upvoted 2 times
...
Zezere
2 months, 3 weeks ago
Selected Answer: C
Azure documentation (not chatGPT bullshit): "To create a first-in, first-out (FIFO) guarantee in Service Bus, use sessions. Message sessions enable exclusive, ordered handling of unbounded sequences of related messages. To allow for handling sessions in high-scale, high-availability systems, the session feature also allows for storing session state, which allows sessions to safely move between handlers. For more information, see Message sessions: first in, first out (FIFO)."
upvoted 1 times
...
lamvit
3 months ago
Selected Answer: C
One of the requirements is "Inventory items must be processed in the order they were placed in the queue." So the sequence number is not sufficient, since "Sequence number on its own guarantees the queuing order and the extractor order of messages, but not the processing order, which requires sessions." https://learn.microsoft.com/en-us/azure/service-bus-messaging/message-sequencing#sequence-number We have to use sessions here https://learn.microsoft.com/en-us/azure/service-bus-messaging/message-sessions
upvoted 2 times
...
examtopicsLogin123
3 months, 2 weeks ago
Selected Answer: A
On the one hand, documentation says: "Sequence number ... is more precise than a time stamp as an order criterion" And Timestamp is more for cases when we need to check whether a work item was submitted before a deadline. https://learn.microsoft.com/en-us/azure/service-bus-messaging/message-sequencing#sequence-number On the other hand, they can use partitioned queue for Azure Service Bus, because: "Fourth Coffee operates thousands of stores worldwide" Documentation says: "For partitioned entities, the sequence number is issued relative to the partition." https://learn.microsoft.com/en-us/azure/service-bus-messaging/service-bus-partitioning#how-it-works https://learn.microsoft.com/en-us/azure/service-bus-messaging/message-sequencing The case study says nothing about the partitions, so I'll hope they aren't used.
upvoted 2 times
...
Mattt
5 months, 2 weeks ago
Selected Answer: A
- inventory items must be processed in the order they were placed in the queue Sequence Number: Using a sequence number ensures that each message can be uniquely identified and processed in the exact order it was enqueued. This is crucial for maintaining the correct processing order of inventory items, especially when multiple items may be processed simultaneously or when they are related to a single user session.
upvoted 3 times
Dan696969
2 months, 2 weeks ago
I fed all the articles to AI and AI says A. It first started off with C until I gave it the articles everyone posted.
upvoted 1 times
...
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago