File tree Expand file tree Collapse file tree 3 files changed +3
-6
lines changed Expand file tree Collapse file tree 3 files changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -2,7 +2,6 @@ import { getCurrentHub, Hub } from '@sentry/hub';
2
2
import {
3
3
Event ,
4
4
Measurements ,
5
- MeasurementUnit ,
6
5
Transaction as TransactionInterface ,
7
6
TransactionContext ,
8
7
TransactionMetadata ,
@@ -72,10 +71,10 @@ export class Transaction extends SpanClass implements TransactionInterface {
72
71
* Set observed measurement for this transaction.
73
72
* @param name Name of the measurement
74
73
* @param value Value of the measurement
75
- * @param unit Unit of the measurement. (Defaults to 'ms' - milliseconds )
74
+ * @param unit Unit of the measurement. (Defaults to an empty string )
76
75
* @hidden
77
76
*/
78
- public setMeasurement ( name : string , value : number , unit : MeasurementUnit = 'ms ' ) : void {
77
+ public setMeasurement ( name : string , value : number , unit : string = '' ) : void {
79
78
this . _measurements [ name ] = { value, unit } ;
80
79
}
81
80
Original file line number Diff line number Diff line change @@ -54,7 +54,6 @@ export { Stacktrace } from './stacktrace';
54
54
export {
55
55
CustomSamplingContext ,
56
56
Measurements ,
57
- MeasurementUnit ,
58
57
SamplingContext ,
59
58
TraceparentData ,
60
59
Transaction ,
Original file line number Diff line number Diff line change @@ -115,8 +115,7 @@ export interface SamplingContext extends CustomSamplingContext {
115
115
request ?: ExtractedNodeRequestData ;
116
116
}
117
117
118
- export type MeasurementUnit = 'ns' | 'ms' | 's' ;
119
- export type Measurements = Record < string , { value : number ; unit : MeasurementUnit } > ;
118
+ export type Measurements = Record < string , { value : number ; unit : string } > ;
120
119
121
120
export type TransactionSamplingMethod = 'explicitly_set' | 'client_sampler' | 'client_rate' | 'inheritance' ;
122
121
You can’t perform that action at this time.
0 commit comments