File tree Expand file tree Collapse file tree 2 files changed +13
-1
lines changed Expand file tree Collapse file tree 2 files changed +13
-1
lines changed Original file line number Diff line number Diff line change 1
1
/* eslint-disable max-lines */
2
- import { Span as SpanInterface , SpanContext } from '@sentry/types' ;
2
+ import { Span as SpanInterface , SpanContext , Transaction } from '@sentry/types' ;
3
3
import { dropUndefinedKeys , timestampWithMs , uuid4 } from '@sentry/utils' ;
4
4
5
5
import { SpanStatus } from './spanstatus' ;
@@ -99,6 +99,11 @@ export class Span implements SpanInterface, SpanContext {
99
99
*/
100
100
public spanRecorder ?: SpanRecorder ;
101
101
102
+ /**
103
+ * @inheritDoc
104
+ */
105
+ public transaction ?: Transaction ;
106
+
102
107
/**
103
108
* You should never call the constructor manually, always use `hub.startSpan()`.
104
109
* @internal
Original file line number Diff line number Diff line change
1
+ import { Transaction } from './transaction' ;
2
+
1
3
/** Interface holding all properties that can be set on a Span on creation. */
2
4
export interface SpanContext {
3
5
/**
@@ -84,6 +86,11 @@ export interface Span extends SpanContext {
84
86
*/
85
87
data : { [ key : string ] : any } ;
86
88
89
+ /**
90
+ * The transaction containing this span
91
+ */
92
+ transaction ?: Transaction ;
93
+
87
94
/**
88
95
* Sets the finish timestamp on the current span.
89
96
* @param endTimestamp Takes an endTimestamp if the end should not be the time when you call this function.
You can’t perform that action at this time.
0 commit comments