Sampling
Learn how to configure the volume of error and transaction events sent to Sentry.
Adding Sentry to your app gives you a great deal of very valuable information about errors and performance you wouldn't otherwise get. And lots of information is good -- as long as it's the right information, at a reasonable volume.
To send a representative sample of your errors to Sentry, set the sample_rate
option in your SDK configuration to a number between 0
(0% of errors sent) and 1
(100% of errors sent). This is a static rate, which will apply equally to all errors. For example, to sample 25% of your errors:
extends SentryConfiguration
## Tip: Assign configuration script in the Project Settings.
func _configure(options: SentryOptions):
options.sample_rate = 0.25
The error sample rate defaults to 1
, meaning all errors are sent to Sentry.
Changing the error sample rate requires re-deployment. In addition, setting an SDK sample rate limits visibility into the source of events. Setting a rate limit for your project (which only drops events when volume is high) may better suit your needs.
Our documentation is open source and available on GitHub. Your contributions are welcome, whether fixing a typo (drat!) or suggesting an update ("yeah, this would be better").