DependencyTelemetry Class

Definition

The class that represents information about the collected dependency.

public sealed class DependencyTelemetry : Microsoft.ApplicationInsights.Extensibility.Implementation.OperationTelemetry, Microsoft.ApplicationInsights.DataContracts.ISupportSampling
Inheritance
DependencyTelemetry
Implements

Inherited Members

Microsoft.ApplicationInsights.Extensibility.Implementation.OperationTelemetry

Constructors

DependencyTelemetry()

Initializes a new instance of the DependencyTelemetry class.

DependencyTelemetry(String, String, String, String)

Initializes a new instance of the DependencyTelemetry class with the given dependencyName, target, dependencyName, data property values.

DependencyTelemetry(String, String, DateTimeOffset, TimeSpan, Boolean)

Initializes a new instance of the DependencyTelemetry class with the given dependencyName, data, startTime, duration and success property values.

DependencyTelemetry(String, String, String, String, DateTimeOffset, TimeSpan, String, Boolean)

Initializes a new instance of the DependencyTelemetry class with the given dependencyName, target, dependencyName, data, startTime, duration, resultCode and success and property values.

Properties

CommandName

Gets or sets text of SQL command or empty it not applicable.

Context

Gets the context associated with the current telemetry item.

Data

Gets or sets data associated with the current dependency instance. Command name/statement statement for SQL dependency, URL for http dependency.

DependencyTypeName

Gets or sets the dependency type name.

Duration

Gets or sets the amount of time it took the application to handle the request.

Id

Gets or sets Dependency ID.

Metrics

Gets a dictionary of application-defined event metrics.

Name

Gets or sets resource name.

Properties

Gets a dictionary of application-defined property names and values providing additional information about this remote dependency.

ResultCode

Gets or sets the Result Code.

Sequence

Gets or sets the value that defines absolute order of the telemetry item.

Success

Gets or sets a value indicating whether the dependency call was successful or not.

Target

Gets or sets target of dependency call. SQL server name, url host, etc.

Timestamp

Gets or sets date and time when telemetry was recorded.

Type

Gets or sets the dependency type name.

Explicit Interface Implementations

ITelemetry.Sanitize()

Sanitizes the properties based on constraints.

ISupportSampling.SamplingPercentage

Gets or sets data sampling percentage (between 0 and 100).

Extension Methods

IsDefined(Object)
IsNull(Object)
IsPrimitive(Object)