mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-03-11 02:12:21 -05:00
Misc Sentry tweaks (#18900)
no refs - Removed redundant duplicated `save_revision` tag when capturing slow saves - Standardised Sentry tags casing (`snake_case`) - Renamed tag `adminX settings component-` to `adminx_settings_component`
This commit is contained in:
parent
c490fb0940
commit
bcfb8e1291
4 changed files with 5 additions and 7 deletions
|
@ -24,7 +24,7 @@ class ErrorBoundary extends React.Component<ErrorBoundaryProps> {
|
|||
|
||||
componentDidCatch(error: unknown, info: ErrorInfo) {
|
||||
Sentry.withScope((scope) => {
|
||||
scope.setTag('adminX settings component-', info.componentStack);
|
||||
scope.setTag('adminx_settings_component', info.componentStack);
|
||||
Sentry.captureException(error);
|
||||
});
|
||||
// eslint-disable-next-line no-console
|
||||
|
|
|
@ -695,7 +695,6 @@ export default class LexicalEditorController extends Controller {
|
|||
scope.setTag('post_type', post.isPage ? 'page' : 'post');
|
||||
scope.setTag('save_revision', options.adapterOptions?.saveRevision);
|
||||
scope.setTag('email_segment', options.adapterOptions?.emailSegment);
|
||||
scope.setTag('save_revision', options.adapterOptions?.saveRevision);
|
||||
scope.setTag('convert_to_lexical', options.adapterOptions?.convertToLexical);
|
||||
});
|
||||
}
|
||||
|
@ -708,7 +707,6 @@ export default class LexicalEditorController extends Controller {
|
|||
scope.setTag('post_type', post.isPage ? 'page' : 'post');
|
||||
scope.setTag('save_revision', options.adapterOptions?.saveRevision);
|
||||
scope.setTag('email_segment', options.adapterOptions?.emailSegment);
|
||||
scope.setTag('save_revision', options.adapterOptions?.saveRevision);
|
||||
scope.setTag('convert_to_lexical', options.adapterOptions?.convertToLexical);
|
||||
});
|
||||
}
|
||||
|
|
|
@ -305,9 +305,9 @@ class ajaxService extends AjaxService {
|
|||
method: request.method,
|
||||
status
|
||||
});
|
||||
Sentry.setTag('ajaxStatus', status);
|
||||
Sentry.setTag('ajaxUrl', request.url);
|
||||
Sentry.setTag('ajaxMethod', request.method);
|
||||
Sentry.setTag('ajax_status', status);
|
||||
Sentry.setTag('ajax_url', request.url);
|
||||
Sentry.setTag('ajax_method', request.method);
|
||||
|
||||
if (headers['content-version']) {
|
||||
const contentVersion = semverCoerce(headers['content-version']);
|
||||
|
|
|
@ -39,7 +39,7 @@ if (sentryConfig && !sentryConfig.disabled) {
|
|||
event.tags.type = exception.errorType;
|
||||
event.tags.code = exception.code;
|
||||
event.tags.id = exception.id;
|
||||
event.tags.statusCode = exception.statusCode;
|
||||
event.tags.status_code = exception.statusCode;
|
||||
}
|
||||
return event;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue