File tree Expand file tree Collapse file tree 1 file changed +39
-1
lines changed
packages/apm/src/integrations Expand file tree Collapse file tree 1 file changed +39
-1
lines changed Original file line number Diff line number Diff line change @@ -8,10 +8,28 @@ import {
8
8
supportsNativeFetch ,
9
9
} from '@sentry/utils' ;
10
10
11
- /** JSDoc */
11
+ /**
12
+ * Options for Tracing integration
13
+ */
12
14
interface TracingOptions {
15
+ /**
16
+ * List of strings / regex where the integration should create Spans out of. Additionally this will be used
17
+ * to define which outgoing requests the `sentry-trace` header will be attached to.
18
+ *
19
+ * Default: ['localhost', /^\//]
20
+ */
13
21
tracingOrigins : Array < string | RegExp > ;
22
+ /**
23
+ * Flag to disable patching all together for fetch requests.
24
+ *
25
+ * Default: true
26
+ */
14
27
traceFetch : boolean ;
28
+ /**
29
+ * Flag to disable patching all together for xhr requests.
30
+ *
31
+ * Default: true
32
+ */
15
33
traceXHR : boolean ;
16
34
/**
17
35
* This function will be called before creating a span for a request with the given url.
@@ -20,8 +38,28 @@ interface TracingOptions {
20
38
* By default it uses the `tracingOrigins` options as a url match.
21
39
*/
22
40
shouldCreateSpanForRequest ( url : string ) : boolean ;
41
+ /**
42
+ * The time to wait in ms until the transaction will be finished. The transaction will use the end timestamp of
43
+ * the last finished span as the endtime for the transaction.
44
+ *
45
+ * Default: 500
46
+ */
23
47
idleTimeout : number ;
48
+ /**
49
+ * Flag to enable/disable creation of `navigation` transaction on history changes. Useful for react applications with
50
+ * a router.
51
+ *
52
+ * Default: true
53
+ */
24
54
startTransactionOnLocationChange : boolean ;
55
+ /**
56
+ * Sample to determine if the Integration should instrument anything. The decision will be taken once per load
57
+ * on initalization.
58
+ * 0 = 0% chance of instrumenting
59
+ * 1 = 100% change of instrumenting
60
+ *
61
+ * Default: 1
62
+ */
25
63
tracesSampleRate : number ;
26
64
}
27
65
You can’t perform that action at this time.
0 commit comments