Share via


TelemetryExtensions.PostCorrelatedFaultEvent Method

Definition

Overloads

PostCorrelatedFaultEvent(TelemetrySession, TelemetryScope<OperationEvent>, String, String, Exception, Func<IFaultUtility,Int32>)

Posts a FaultEvent that is correlated with operation to session.

PostCorrelatedFaultEvent(TelemetrySession, TelemetryScope<OperationEvent>, String, String, FaultSeverity, Exception, Func<IFaultUtility,Int32>)

Posts a FaultEvent that is correlated with operation to session.

PostCorrelatedFaultEvent(TelemetrySession, TelemetryScope<OperationEvent>, String, String, Exception, Func<IFaultUtility,Int32>)

Posts a FaultEvent that is correlated with operation to session.

public static void PostCorrelatedFaultEvent (this Microsoft.VisualStudio.Telemetry.TelemetrySession session, Microsoft.VisualStudio.Telemetry.TelemetryScope<Microsoft.VisualStudio.Telemetry.OperationEvent> operation, string? faultEventName, string faultDescription, Exception? exceptionObject = default, Func<Microsoft.VisualStudio.Telemetry.IFaultUtility,int>? gatherEventDetails = default);
static member PostCorrelatedFaultEvent : Microsoft.VisualStudio.Telemetry.TelemetrySession * Microsoft.VisualStudio.Telemetry.TelemetryScope<Microsoft.VisualStudio.Telemetry.OperationEvent> * string * string * Exception * Func<Microsoft.VisualStudio.Telemetry.IFaultUtility, int> -> unit
<Extension()>
Public Sub PostCorrelatedFaultEvent (session As TelemetrySession, operation As TelemetryScope(Of OperationEvent), faultEventName As String, faultDescription As String, Optional exceptionObject As Exception = Nothing, Optional gatherEventDetails As Func(Of IFaultUtility, Integer) = Nothing)

Parameters

session
TelemetrySession

The telemetry session.

operation
TelemetryScope<OperationEvent>

The telemetry operation.

faultEventName
String

The name of the fault event. If this is null, the name of the fault event is the name of operation's EndEvent with a "-fault" suffix appended to it.

faultDescription
String

The description of the fault.

exceptionObject
Exception

The exception to include with the fault event.

gatherEventDetails
Func<IFaultUtility,Int32>

This delegate is called to gather expensive details (like jscript call stacks) only when not sampled. The callback parameter can be cast to to a FaultEvent or (IVsFaultEvent in native) which inherits from TelemetryEvent (IVsTelemetryEvent in native) Microsoft.VisualStudio.Telemetry.IFaultUtility.

Applies to

PostCorrelatedFaultEvent(TelemetrySession, TelemetryScope<OperationEvent>, String, String, FaultSeverity, Exception, Func<IFaultUtility,Int32>)

Posts a FaultEvent that is correlated with operation to session.

public static void PostCorrelatedFaultEvent (this Microsoft.VisualStudio.Telemetry.TelemetrySession session, Microsoft.VisualStudio.Telemetry.TelemetryScope<Microsoft.VisualStudio.Telemetry.OperationEvent> operation, string? faultEventName, string faultDescription, Microsoft.VisualStudio.Telemetry.FaultSeverity faultSeverity, Exception? exceptionObject = default, Func<Microsoft.VisualStudio.Telemetry.IFaultUtility,int>? gatherEventDetails = default);
static member PostCorrelatedFaultEvent : Microsoft.VisualStudio.Telemetry.TelemetrySession * Microsoft.VisualStudio.Telemetry.TelemetryScope<Microsoft.VisualStudio.Telemetry.OperationEvent> * string * string * Microsoft.VisualStudio.Telemetry.FaultSeverity * Exception * Func<Microsoft.VisualStudio.Telemetry.IFaultUtility, int> -> unit
<Extension()>
Public Sub PostCorrelatedFaultEvent (session As TelemetrySession, operation As TelemetryScope(Of OperationEvent), faultEventName As String, faultDescription As String, faultSeverity As FaultSeverity, Optional exceptionObject As Exception = Nothing, Optional gatherEventDetails As Func(Of IFaultUtility, Integer) = Nothing)

Parameters

session
TelemetrySession

The telemetry session.

operation
TelemetryScope<OperationEvent>

The telemetry operation.

faultEventName
String

The name of the fault event. If this is null, the name of the fault event is the name of operation's EndEvent with a "-fault" suffix appended to it.

faultDescription
String

The description of the fault.

faultSeverity
FaultSeverity

The severity of the fault, used to identify actionable or important faults in divisional tools and reporting.

exceptionObject
Exception

The exception to include with the fault event.

gatherEventDetails
Func<IFaultUtility,Int32>

This delegate is called to gather expensive details (like jscript call stacks) only when not sampled. The callback parameter can be cast to to a FaultEvent or (IVsFaultEvent in native) which inherits from TelemetryEvent (IVsTelemetryEvent in native) Microsoft.VisualStudio.Telemetry.IFaultUtility.

Applies to