diff --git a/src/OpenTelemetry.Api/Trace/ActivityExtensions.cs b/src/OpenTelemetry.Api/Trace/ActivityExtensions.cs index 036d8c11a7..d8ac769b9c 100644 --- a/src/OpenTelemetry.Api/Trace/ActivityExtensions.cs +++ b/src/OpenTelemetry.Api/Trace/ActivityExtensions.cs @@ -57,20 +57,26 @@ public static Status GetStatus(this Activity activity) } /// - /// Adds an activity event containing information from the specified exception. + /// Adds an containing information from the specified exception. /// /// Activity instance. /// Exception to be recorded. + /// The exception is recorded as per specification. + /// "exception.stacktrace" is represented using the value of Exception.ToString. + /// [MethodImpl(MethodImplOptions.AggressiveInlining)] public static void RecordException(this Activity activity, Exception? ex) => RecordException(activity, ex, default); /// - /// Adds an activity event containing information from the specified exception and additional tags. + /// Adds an containing information from the specified exception and additional tags. /// /// Activity instance. /// Exception to be recorded. /// Additional tags to record on the event. + /// The exception is recorded as per specification. + /// "exception.stacktrace" is represented using the value of Exception.ToString. + /// [MethodImpl(MethodImplOptions.AggressiveInlining)] public static void RecordException(this Activity activity, Exception? ex, in TagList tags) {