Skip to content

Commit

Permalink
Add Docs for enabled option for Java SDK (#7654)
Browse files Browse the repository at this point in the history
  • Loading branch information
lbloder committed Aug 18, 2023
1 parent aae383f commit 91d4466
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/platforms/common/configuration/options.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -575,7 +575,7 @@ If the callback is not set, or it returns `undefined`, the default naming scheme
</PlatformSection>
<ConfigKey name="enabled" supported={["javascript", "node"]}>
<ConfigKey name="enabled" supported={["javascript", "node", "java"]}>
Specifies whether this SDK should send events to Sentry. Defaults to `true`. Setting this to `enabled: false` doesn't prevent all overhead from Sentry instrumentation. To disable Sentry completely, depending on environment, call `Sentry.init` conditionally.
Expand Down
16 changes: 16 additions & 0 deletions src/platforms/java/common/configuration/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -297,6 +297,22 @@ SENTRY_DEBUG=true
sentry.debug=true
```

### Disable Sentry

To disable Sentry, use the `enabled` option:

```properties {tabTitle:sentry.properties}
enabled=false
```

```properties {tabTitle:environment variable}
SENTRY_ENABLED=false
```

```properties {tabTitle:system property}
sentry.enabled=false
```

## Configuring Timeouts

It’s possible to manually set the connection timeouts length with `connectionTimeoutMillis` and `readTimeoutMillis`:
Expand Down

1 comment on commit 91d4466

@vercel
Copy link

@vercel vercel bot commented on 91d4466 Aug 18, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

sentry-docs – ./

sentry-docs-git-master.sentry.dev
docs.sentry.io
sentry-docs.sentry.dev

Please sign in to comment.