File tree 3 files changed +12
-2
lines changed
3 files changed +12
-2
lines changed Original file line number Diff line number Diff line change @@ -18,6 +18,7 @@ export type {
18
18
} from '@sentry/types' ;
19
19
export type { AddRequestDataToEventOptions } from '@sentry/utils' ;
20
20
21
+ export type { TransactionNamingScheme } from './requestdata' ;
21
22
export type { NodeOptions } from './types' ;
22
23
23
24
export {
Original file line number Diff line number Diff line change 3
3
4
4
import { EventProcessor , Hub , Integration } from '@sentry/types' ;
5
5
6
- import { addRequestDataToEvent , AddRequestDataToEventOptions , DEFAULT_USER_INCLUDES } from '../requestdata' ;
6
+ import {
7
+ addRequestDataToEvent ,
8
+ AddRequestDataToEventOptions ,
9
+ DEFAULT_USER_INCLUDES ,
10
+ TransactionNamingScheme ,
11
+ } from '../requestdata' ;
7
12
8
13
type RequestDataOptions = {
9
14
/**
@@ -19,6 +24,9 @@ type RequestDataOptions = {
19
24
user ?: boolean | Array < typeof DEFAULT_USER_INCLUDES [ number ] > ;
20
25
} ;
21
26
27
+ /** Whether to identify transactions by parameterized path, parameterized path with method, or handler name */
28
+ transactionNamingScheme : TransactionNamingScheme ;
29
+
22
30
/**
23
31
* Function for adding request data to event. Defaults to `addRequestDataToEvent` from `@sentry/node` for now, but
24
32
* left injectable so this integration can be moved to `@sentry/core` and used in browser-based SDKs in the future.
@@ -39,6 +47,7 @@ const DEFAULT_OPTIONS = {
39
47
url : true ,
40
48
user : DEFAULT_USER_INCLUDES ,
41
49
} ,
50
+ transactionNamingScheme : 'methodpath' ,
42
51
} ;
43
52
44
53
/** Add data about a request to an event. Primarily for use in Node-based SDKs, but included in `@sentry/integrations`
Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ export interface AddRequestDataToEventOptions {
25
25
} ;
26
26
}
27
27
28
- type TransactionNamingScheme = 'path' | 'methodPath' | 'handler' ;
28
+ export type TransactionNamingScheme = 'path' | 'methodPath' | 'handler' ;
29
29
30
30
/**
31
31
* Sets parameterized route as transaction name e.g.: `GET /users/:id`
You can’t perform that action at this time.
0 commit comments