AZ-204 Developing Solutions for Microsoft Azure Exam

You can develop, but can you develop for the cloud? Harness your development skills and learn how to create robust solutions for Microsoft Azure, aiming for your Microsoft Certified: Azure Developer Associate certification!

Intermediate

Gauge your current knowledge

Practice test preview

Set and retrieve properties and metadata

...

Sample Question

A development team is building an application that uploads various document types, such as PDFs and images, to Azure Blob Storage. For each uploaded document, they need to ensure that the browser correctly interprets the file type by setting the appropriate Content-Type property. Additionally, they must attach custom information, specifically a ProjectID and DocumentVersion, to each blob for internal tracking and categorization. The team is using the Azure Blob Storage .NET SDK. Which of the following approaches should the team use to efficiently set both the standard `Content-Type` and the custom `ProjectID` and `DocumentVersion` for each blob?

  • Set the Content-Type using the blob's HTTP headers (system properties) and store ProjectID and DocumentVersion as user-defined metadata using a key-value dictionary.
  • Set Content-Type as a system property and embed ProjectID and DocumentVersion within the blob's content as JSON.
  • Utilize blob index tags for ProjectID and DocumentVersion, and set Content-Type as a system property.
  • Store Content-Type, ProjectID, and DocumentVersion all as user-defined metadata.
View the answer & explanation →