File tree 2 files changed +12
-2
lines changed
2 files changed +12
-2
lines changed Original file line number Diff line number Diff line change @@ -74,9 +74,12 @@ export class Tracing implements Integration {
74
74
* @param transaction Optional transaction
75
75
*/
76
76
public static startTrace ( hub : Hub , transaction ?: string ) : void {
77
+ const span = hub . startSpan ( {
78
+ transaction,
79
+ } ) ;
80
+
77
81
hub . configureScope ( scope => {
78
- // scope.startSpan();
79
- scope . setTransaction ( transaction ) ;
82
+ scope . setSpan ( span ) ;
80
83
} ) ;
81
84
}
82
85
Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ import { Event, EventHint } from './event';
4
4
import { Integration , IntegrationClass } from './integration' ;
5
5
import { Scope } from './scope' ;
6
6
import { Severity } from './severity' ;
7
+ import { Span , SpanDetails } from './span' ;
7
8
import { User } from './user' ;
8
9
9
10
/**
@@ -170,4 +171,10 @@ export interface Hub {
170
171
171
172
/** Returns all trace headers that are currently on the top scope. */
172
173
traceHeaders ( ) : { [ key : string ] : string } ;
174
+
175
+ /** JSDoc */
176
+ startSpan ( spanDetails ?: SpanDetails ) : Span ;
177
+
178
+ /** JSDoc */
179
+ finishSpan ( span : Span ) : string | undefined ;
173
180
}
You can’t perform that action at this time.
0 commit comments