зеркало из https://github.com/mozilla/fxa.git
Merge pull request #16537 from mozilla/bug-sentry-tracing-sample-rate-no-applied
bug(content): Fix SENTRY_TRACES_SAMPLE_RATE not being applied
This commit is contained in:
Коммит
96f6e974fa
|
@ -110,7 +110,7 @@ function loadConf() {
|
|||
},
|
||||
tracesSampleRate: {
|
||||
doc: 'Rate at which sentry traces are captured',
|
||||
default: 1.0,
|
||||
default: 0,
|
||||
format: 'Number',
|
||||
env: 'SENTRY_TRACES_SAMPLE_RATE',
|
||||
},
|
||||
|
|
|
@ -91,7 +91,7 @@ const conf = convict({
|
|||
},
|
||||
tracesSampleRate: {
|
||||
doc: 'Rate at which sentry traces are captured',
|
||||
default: 1.0,
|
||||
default: 0,
|
||||
format: 'Number',
|
||||
env: 'SENTRY_TRACES_SAMPLE_RATE',
|
||||
},
|
||||
|
|
|
@ -122,7 +122,7 @@ const conf = convict({
|
|||
},
|
||||
tracesSampleRate: {
|
||||
doc: 'Rate at which sentry traces are captured',
|
||||
default: 1.0,
|
||||
default: 0,
|
||||
format: 'Number',
|
||||
env: 'SENTRY_TRACES_SAMPLE_RATE',
|
||||
},
|
||||
|
|
|
@ -1655,7 +1655,7 @@ const convictConf = convict({
|
|||
},
|
||||
tracesSampleRate: {
|
||||
doc: 'Rate at which sentry traces are captured',
|
||||
default: 1.0,
|
||||
default: 0,
|
||||
format: 'Number',
|
||||
env: 'SENTRY_TRACES_SAMPLE_RATE',
|
||||
},
|
||||
|
|
|
@ -38,6 +38,7 @@ const settingsConfig = {
|
|||
dsn: config.get('sentry.dsn'),
|
||||
env: config.get('sentry.env'),
|
||||
sampleRate: config.get('sentry.sampleRate'),
|
||||
tracesSampleRate: config.get('sentry.tracesSampleRate'),
|
||||
clientName: config.get('sentry.clientName'),
|
||||
serverName: config.get('sentry.serverName'),
|
||||
},
|
||||
|
|
|
@ -778,7 +778,7 @@ const conf = (module.exports = convict({
|
|||
},
|
||||
tracesSampleRate: {
|
||||
doc: 'Rate at which sentry traces are captured',
|
||||
default: 1.0,
|
||||
default: 0,
|
||||
format: 'Number',
|
||||
env: 'SENTRY_TRACES_SAMPLE_RATE',
|
||||
},
|
||||
|
|
|
@ -34,6 +34,7 @@ module.exports = function (config) {
|
|||
const SENTRY_CLIENT_DSN = config.get('sentry.dsn');
|
||||
const SENTRY_CLIENT_ENV = config.get('sentry.env');
|
||||
const SENTRY_SAMPLE_RATE = config.get('sentry.sampleRate');
|
||||
const SENTRY_TRACES_SAMPLE_RATE = config.get('sentry.tracesSampleRate');
|
||||
const SENTRY_CLIENT_NAME = config.get('sentry.clientName');
|
||||
const OAUTH_SERVER_URL = config.get('oauth_url');
|
||||
const PAIRING_CHANNEL_URI = config.get('pairing.server_base_uri');
|
||||
|
@ -100,6 +101,7 @@ module.exports = function (config) {
|
|||
env: SENTRY_CLIENT_ENV,
|
||||
sampleRate: SENTRY_SAMPLE_RATE,
|
||||
clientName: SENTRY_CLIENT_NAME,
|
||||
tracesSampleRate: SENTRY_TRACES_SAMPLE_RATE,
|
||||
},
|
||||
staticResourceUrl: STATIC_RESOURCE_URL,
|
||||
subscriptions: SUBSCRIPTIONS,
|
||||
|
|
|
@ -59,6 +59,7 @@ if (config.get('sentry.dsn')) {
|
|||
dsn: config.get('sentry.dsn'),
|
||||
env: config.get('sentry.env'),
|
||||
sampleRate: config.get('sentry.sampleRate'),
|
||||
tracesSampleRate: config.get('sentry.tracesSampleRate'),
|
||||
serverName: config.get('sentry.serverName'),
|
||||
},
|
||||
},
|
||||
|
|
|
@ -330,7 +330,7 @@ module.exports = function (fs, path, url, convict) {
|
|||
},
|
||||
tracesSampleRate: {
|
||||
doc: 'Rate at which sentry traces are captured',
|
||||
default: 1.0,
|
||||
default: 0,
|
||||
format: 'Number',
|
||||
env: 'SENTRY_TRACES_SAMPLE_RATE',
|
||||
},
|
||||
|
|
|
@ -218,7 +218,7 @@ const conf = convict({
|
|||
},
|
||||
tracesSampleRate: {
|
||||
doc: 'Rate at which sentry traces are captured',
|
||||
default: 1.0,
|
||||
default: 0,
|
||||
format: 'Number',
|
||||
env: 'SENTRY_TRACES_SAMPLE_RATE',
|
||||
},
|
||||
|
|
|
@ -260,7 +260,7 @@ const conf = convict({
|
|||
},
|
||||
tracesSampleRate: {
|
||||
doc: 'Rate at which sentry traces are captured',
|
||||
default: 1.0,
|
||||
default: 0,
|
||||
format: 'Number',
|
||||
env: 'SENTRY_TRACES_SAMPLE_RATE',
|
||||
},
|
||||
|
|
|
@ -297,7 +297,7 @@ const conf = convict({
|
|||
},
|
||||
tracesSampleRate: {
|
||||
doc: 'Rate at which sentry traces are captured',
|
||||
default: 1.0,
|
||||
default: 0,
|
||||
format: 'Number',
|
||||
env: 'SENTRY_TRACES_SAMPLE_RATE',
|
||||
},
|
||||
|
|
|
@ -142,6 +142,7 @@ const expectedMergedConfig = {
|
|||
dsn: 'https://foo.sentry.io/bar',
|
||||
env: 'test',
|
||||
sampleRate: 1.0,
|
||||
tracesSampleRate: 0,
|
||||
serverName: 'fxa-payments-server',
|
||||
},
|
||||
servers: {
|
||||
|
|
|
@ -15,13 +15,12 @@ export interface Config {
|
|||
termsOfService: string;
|
||||
};
|
||||
newsletterId: string;
|
||||
productRedirectURLs: {
|
||||
[productId: string]: string;
|
||||
};
|
||||
productRedirectURLs: { [productId: string]: string };
|
||||
sentry: {
|
||||
dsn: string;
|
||||
env: string;
|
||||
sampleRate: number;
|
||||
tracesSampleRate?: number;
|
||||
clientName?: string;
|
||||
serverName?: string;
|
||||
};
|
||||
|
@ -74,6 +73,7 @@ export function defaultConfig(): Config {
|
|||
dsn: '',
|
||||
env: 'local',
|
||||
sampleRate: 1.0,
|
||||
tracesSampleRate: 0,
|
||||
serverName: 'fxa-payments-server',
|
||||
clientName: 'fxa-payments-client',
|
||||
},
|
||||
|
|
|
@ -341,7 +341,7 @@ const conf = convict({
|
|||
},
|
||||
tracesSampleRate: {
|
||||
doc: 'Rate at which sentry traces are captured',
|
||||
default: 1.0,
|
||||
default: 0,
|
||||
format: 'Number',
|
||||
env: 'SENTRY_TRACES_SAMPLE_RATE',
|
||||
},
|
||||
|
|
|
@ -35,7 +35,7 @@ export function buildSentryConfig(config: SentryConfigOpts, log: ILogger) {
|
|||
clientName: config.sentry?.clientName,
|
||||
serverName: config.sentry?.serverName,
|
||||
fxaName: config.sentry?.clientName || config.sentry?.serverName,
|
||||
tracesSampleRate: config.sentry?.tracesSampleRate || 1.0,
|
||||
tracesSampleRate: config.sentry?.tracesSampleRate,
|
||||
};
|
||||
|
||||
return opts;
|
||||
|
|
Загрузка…
Ссылка в новой задаче