Function recordExceptionOnActiveSpan

  • Records error on the active span and sets an error status carrying message, or the error's own message. Does nothing when no span is active or while content-safe telemetry is on.

    Parameters

    • error: unknown

      The error to record.

    • Optional message: string

      The status message to use instead of the error's message.

    Returns void