File tree Expand file tree Collapse file tree 1 file changed +15
-1
lines changed Expand file tree Collapse file tree 1 file changed +15
-1
lines changed Original file line number Diff line number Diff line change 1- import type { ClientOptions , Options , TracePropagationTargets } from '@sentry/types' ;
1+ import type { ClientOptions , Options , SamplingContext , TracePropagationTargets } from '@sentry/types' ;
22
33import type { NodeTransportOptions } from './transports' ;
44
@@ -8,6 +8,20 @@ export interface BaseNodeOptions {
88 */
99 profilesSampleRate ?: number ;
1010
11+ /**
12+ * Function to compute profiling sample rate dynamically and filter unwanted profiles.
13+ *
14+ * Profiling is enabled if either this or `profilesSampleRate` is defined. If both are defined, `profilesSampleRate` is
15+ * ignored.
16+ *
17+ * Will automatically be passed a context object of default and optional custom data. See
18+ * {@link Transaction.samplingContext} and {@link Hub.startTransaction}.
19+ *
20+ * @returns A sample rate between 0 and 1 (0 drops the profile, 1 guarantees it will be sent). Returning `true` is
21+ * equivalent to returning 1 and returning `false` is equivalent to returning 0.
22+ */
23+ profilesSampler ?: ( samplingContext : SamplingContext ) => number | boolean ;
24+
1125 /** Sets an optional server name (device name) */
1226 serverName ?: string ;
1327
You can’t perform that action at this time.
0 commit comments