-
Notifications
You must be signed in to change notification settings - Fork 1.8k
chore: Adds sentry APM #4698
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore: Adds sentry APM #4698
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,5 +17,6 @@ declare const config: { | |
dsn: string; | ||
debug: boolean; | ||
development: boolean; | ||
tracesSampleRate: number; | ||
} | ||
}; |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
import * as Sentry from '@sentry/browser'; | ||
import { CaptureConsole, Dedupe, Ember } from '@sentry/integrations'; | ||
import config from 'open-event-frontend/config/environment'; | ||
import { Integrations as ApmIntegrations } from '@sentry/apm'; | ||
|
||
if (!config.sentry.dsn.includes('dummy')) { | ||
|
||
|
@@ -10,8 +11,10 @@ if (!config.sentry.dsn.includes('dummy')) { | |
new Dedupe(), | ||
new CaptureConsole({ | ||
levels: ['error'] | ||
}) | ||
}), | ||
new ApmIntegrations.Tracing(), | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Codacy found an issue: Unexpected trailing comma. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Codacy found an issue: Expected indentation of 6 spaces but found 12. |
||
], | ||
tracesSampleRate: config.sentry.tracesSampleRate, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Codacy found an issue: Trailing spaces not allowed. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Codacy found an issue: Expected indentation of 4 spaces but found 8. |
||
beforeSend(event: Sentry.Event) { | ||
const exception = event.exception?.values?.[0]; | ||
const errorValue = exception?.value; | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -57,7 +57,8 @@ module.exports = function(environment) { | |
sentry: { | ||
dsn : process.env.SENTRY_DSN || 'https://dummy@getsentry.com/dummy', | ||
debug : !!process.env.SENTRY_DSN, | ||
development : !process.env.SENTRY_DSN | ||
development : !process.env.SENTRY_DSN, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Codacy found an issue: Missing space after key 'development'. |
||
tracesSampleRate: process.env.SENTRY_TRACE_SAMPLE_RATE || 0.01, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Codacy found an issue: Missing space after key 'tracesSampleRate'. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Codacy found an issue: Unexpected trailing comma. |
||
}, | ||
|
||
emberFullCalendar: { | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Codacy found an issue: Expected indentation of 6 spaces but found 12.