Error handlers
Customize the handling of the errors originating from the app.
npm install @dynatrace-sdk/error-handlers
Interfaces
CommonSerializedError
Common serialized JS Error
Properties
Name | Type |
---|---|
cause | any |
details | any |
errorRef | string |
message*required | string |
name*required | string |
stack | string |
type*required | COMMON |
HttpSerializedError
Serialized http exception with response status
Properties
Name | Type |
---|---|
unknown | |
cause | any |
details | any |
errorRef | string |
message*required | string |
name*required | string |
stack | string |
status*required | number |
type*required | HTTP |
Functions
addGlobalErrorSerializer
addGlobalErrorSerializer(serializer): void
Registers a global error serializer for handling uncatched errors.
Parameters
Name | Type | Description |
---|---|---|
serializer*required | GlobalErrorSerializer | Asynchronous function which serializes error if it match the condition |
isGlobalErrorSerializerSupported
Still have questions?
Find answers in the Dynatrace Community