Which two Dependency Telemetry properties should you store in the database?

Posted by: Pdfprep Category: AZ-204 Tags: , ,

You are developing an ASP.NET Core Web API web service. The web service uses Azure Application Insights for all telemetry and dependency tracking. The web service reads and writes data to a database other than Microsoft SQL Server.

You need to ensure that dependency tracking works for calls to the third-party database.

Which two Dependency Telemetry properties should you store in the database? Each correct answer presents part of the solution. NOTE: Each correct selection is worth one point.
A . Telemetry.Context.Operation.Id
B . Tetemetry.Context.Cloud.Rolelnstance
C . Telemetry.Id
D . Telemetry.ContextSession.Id
E . Telemetry.Name

Answer: A,C

Explanation:

References: https://docs.microsoft.com/en-us/azure/azure-monitor/app/custom-operations-tracking

Example:

public async Task Enqueue(string payload)

{

// StartOperation is a helper method that initializes the telemetry item

// and allows correlation of this operation with its parent and children.

var operation = telemetryClient.StartOperation<DependencyTelemetry>("enqueue " + queueName);

operation.Telemetry.Type = "Azure Service Bus";

operation.Telemetry.Data = "Enqueue " + queueName;

var message = new BrokeredMessage(payload);

// Service Bus queue allows the property bag to pass along with the message.

// We will use them to pass our correlation identifiers (and other context)

// to the consumer.

message.Properties.Add("ParentId", operation.Telemetry.Id);

message.Properties.Add("RootId", operation.Telemetry.Context.Operation.Id);

Reference: https://docs.microsoft.com/en-us/azure/azure-monitor/app/custom-operations-tracking

Leave a Reply

Your email address will not be published.