Skip to content

Commit 96345e7

Browse files
sfanahataShannon Anahatabitsandfoxesalexsohn1126
authored
Updated dotnet options to include all defaults (#15218)
## DESCRIBE YOUR PR Updated options with defaults based on move to SDKoption formatting. Preview: https://sentry-docs-git-dotnet-options-updates.sentry.dev/platforms/dotnet/configuration/options/ ## IS YOUR CHANGE URGENT? Help us prioritize incoming PRs by letting us know when the change needs to go live. - [ ] Urgent deadline (GA date, etc.): <!-- ENTER DATE HERE --> - [ ] Other deadline: <!-- ENTER DATE HERE --> - [x] None: Not urgent, can wait up to 1 week+ ## SLA - Teamwork makes the dream work, so please add a reviewer to your PRs. - Please give the docs team up to 1 week to review your PR unless you've added an urgent due date to it. Thanks in advance for your help! ## PRE-MERGE CHECKLIST *Make sure you've checked the following before merging your changes:* - [ ] Checked Vercel preview for correctness, including links - [ ] PR was reviewed and approved by any necessary SMEs (subject matter experts) - [ ] PR was reviewed and approved by a member of the [Sentry docs team](https://github.com/orgs/getsentry/teams/docs) ## LEGAL BOILERPLATE <!-- Sentry employees and contractors can delete or ignore this section. --> Look, I get it. The entity doing business as "Sentry" was incorporated in the State of Delaware in 2015 as Functional Software, Inc. and is gonna need some rights from me in order to utilize my contributions in this here PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Sentry can use, modify, copy, and redistribute my contributions, under Sentry's choice of terms. ## EXTRA RESOURCES - [Sentry Docs contributor guide](https://docs.sentry.io/contributing/) --------- Co-authored-by: Shannon Anahata <[email protected]> Co-authored-by: Stefan Jandl <[email protected]> Co-authored-by: Alex Sohn <[email protected]>
1 parent 5c12959 commit 96345e7

File tree

1 file changed

+10
-20
lines changed

1 file changed

+10
-20
lines changed

docs/platforms/dotnet/common/configuration/options.mdx

Lines changed: 10 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@ Learn more about [DSN utilization](/product/sentry-basics/dsn-explainer/#dsn-uti
2222

2323
</SdkOption>
2424

25-
<SdkOption name="StackTraceMode" type="enum">
25+
<SdkOption name="StackTraceMode" type="enum" defaultValue="Enhanced">
2626

2727
- Original - Default .NET stack trace format.
28-
- Enhanced - Include `async`, return type, arguments, and more.
28+
- Enhanced - **default** Include `async`, return type, arguments, and more.
2929

3030
Before version 3.0.0 of the Sentry SDK for .NET, there was no special treatment for the stack trace. Sentry reported what .NET made available at runtime.
3131
This behavior now called `StackTraceMode.Original`. With the introduction of 3.0, a new default mode is `Enhanced`.
@@ -87,7 +87,7 @@ Turns debug mode on or off. If debug is enabled SDK will attempt to print out us
8787

8888
</SdkOption>
8989

90-
<SdkOption name="DiagnosticLevel" type="enum">
90+
<SdkOption name="DiagnosticLevel" type="enum" defaultValue="debug">
9191

9292
Enabling `debug` mode makes the SDK generate as much diagnostic data as possible. However, if you'd prefer to lower the verbosity of the Sentry SDK diagnostics logs, configure this option to set the appropriate level:
9393

@@ -143,7 +143,7 @@ The maximum number of [envelopes](https://develop.sentry.dev/sdk/data-model/enve
143143

144144
</SdkOption>
145145

146-
<SdkOption name="AttachStacktrace" type="bool">
146+
<SdkOption name="AttachStacktrace" type="bool" defaultValue="true">
147147

148148
When enabled, stack traces are automatically attached to all messages logged. Stack traces are always attached to exceptions; however, when this option is set, stack traces are also sent with messages. This option, for instance, means that stack traces appear next to all log messages.
149149

@@ -193,11 +193,11 @@ This option can be overridden using <PlatformIdentifier name="InAppInclude" />.
193193

194194
<PlatformSection supported={["dotnet.aspnet", "dotnet.aspnetcore"]}>
195195

196-
<SdkOption name="MaxRequestBodySize" type="enum">
196+
<SdkOption name="MaxRequestBodySize" type="enum" defaultValue="none">
197197

198198
This parameter controls whether integrations should capture HTTP request bodies. It can be set to one of the following values:
199199

200-
- `none`: Request bodies are never sent.
200+
- `none`: **default** Request bodies are never sent.
201201
- `small`: Only small request bodies will be captured. The cutoff for small depends on the SDK (typically 4KB).
202202
- `medium`: Medium and small requests will be captured (typically 10KB).
203203
- `always`: The SDK will always capture the request body as long as Sentry can make sense of it.
@@ -208,7 +208,7 @@ This parameter controls whether integrations should capture HTTP request bodies.
208208

209209
<PlatformSection supported={["dotnet.xamarin", "dotnet.maui"]}>
210210

211-
<SdkOption name="AttachScreenshot" type="bool">
211+
<SdkOption name="AttachScreenshot" type="bool" defaultValue="false">
212212

213213
Takes a screenshot of the application when an error happens and includes it as an attachment.
214214
Learn more about enriching events with screenshots in our <PlatformLink to="/enriching-events/screenshots/">Screenshots documentation</PlatformLink>.
@@ -217,23 +217,13 @@ Learn more about enriching events with screenshots in our <PlatformLink to="/enr
217217

218218
</PlatformSection>
219219

220-
<PlatformSection supported={["dotnet.xamarin"]}>
221-
222-
<SdkOption name="ScreenshotQuality" type="enum">
223-
224-
The quality of the attached screenshot. It can be set to `full`, `high`, `medium` or `low`.
225-
226-
</SdkOption>
227-
228-
</PlatformSection>
229-
230-
<SdkOption name="SendClientReports" type="bool">
220+
<SdkOption name="SendClientReports" type="bool" defaultValue="true">
231221

232222
Set this boolean to `false` to disable sending of client reports. Client reports are a protocol feature that let clients send status reports about themselves to Sentry. They are currently mainly used to emit outcomes for events that were never sent.
233223

234224
</SdkOption>
235225

236-
<SdkOption name="CaptureFailedRequests" type="bool">
226+
<SdkOption name="CaptureFailedRequests" type="bool" defaultValue="true">
237227

238228
Once enabled, this feature automatically captures HTTP client errors, like bad response codes, as error events and reports them to Sentry.
239229

@@ -336,7 +326,7 @@ Controls how many seconds to wait before shutting down. Sentry SDKs send events
336326

337327
## Tracing Options
338328

339-
<SdkOption name="TracesSampleRate" type="float">
329+
<SdkOption name="TracesSampleRate" type="float" defaultValue="0.0">
340330

341331
A number between `0` and `1`, controlling the percentage chance a given transaction will be sent to Sentry. (`0` represents 0% while `1` represents 100%.) Applies equally to all transactions created in the app. Either this or <PlatformIdentifier name="TracesSampler" /> must be defined to enable tracing.
342332

0 commit comments

Comments
 (0)