Skip to content

Commit 32346f8

Browse files
ichinaAbhiPrasadimatwawana
authored
ref(serverless): new options for ignoring sentry errors (#4755)
Documents `ignoreSentryErrors` added to the AWS Lambda integration in the JavaScript SDKs v6.18.0 Co-authored-by: Abhijeet Prasad <[email protected]> Co-authored-by: Isabel <[email protected]>
1 parent 0095eef commit 32346f8

File tree

1 file changed

+15
-0
lines changed
  • src/platforms/node/guides/aws-lambda

1 file changed

+15
-0
lines changed

src/platforms/node/guides/aws-lambda/index.mdx

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,21 @@ exports.handler = Sentry.AWSLambda.wrapHandler(() => {
100100
// `first` and `second` errors are captured
101101
```
102102

103+
## Ignore Sentry Errors
104+
_(New in version 6.18.0)_
105+
106+
By default, Sentry fails Lambda invocation if it is unable to send events to Sentry.
107+
In this case, even if all reported errors were handled and your handler executed successfully, Sentry will fail the whole Lambda invocation.
108+
109+
The `ignoreSentryErrors` (default: `false`) option ignores all the errors raised by Sentry
110+
111+
```javascript {tabTitle:ignoreSentryErrors}
112+
exports.handler = Sentry.AWSLambda.wrapHandler(yourHandler, {
113+
// Ignore any errors raised by the Sentry SDK on attempts to send events to Sentry
114+
ignoreSentryErrors: true,
115+
});
116+
```
117+
103118
## Behavior
104119

105120
With the AWS Lambda integration enabled, the Node SDK will:

0 commit comments

Comments
 (0)