Skip to content

Commit

Permalink
chore(sentry): send PII, increase rates a bit, include cache spans
Browse files Browse the repository at this point in the history
  • Loading branch information
thejoeejoee committed Sep 18, 2024
1 parent f0d9e9f commit 6f40a55
Showing 1 changed file with 14 additions and 3 deletions.
17 changes: 14 additions & 3 deletions fiesta/fiesta/settings/logging.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
from __future__ import annotations

from configurations.values import SecretValue, Value
from sentry_sdk.integrations.django import DjangoIntegration


class LoggingConfigMixin:
Expand Down Expand Up @@ -76,10 +77,20 @@ def post_setup(cls):
if cls.SENTRY_DSN:
sentry_sdk.init(
dsn=cls.SENTRY_DSN,
# sample only 10% of events to reduce incoming data
traces_sample_rate=0.1,
profiles_sample_rate=0.1,
# sample only 50 % of events to reduce incoming data
# currently about 6M spans per peak month
traces_sample_rate=0.5,
profiles_sample_rate=0.5,
environment=cls.ENVIRONMENT_NAME,
release=cls.RELEASE_NAME,
enable_tracing=True,
send_default_pii=True,
auto_enabling_integrations=True,
auto_session_tracking=True,
integrations=[
DjangoIntegration(
# include spans from caches
cache_spans=True,
),
],
)

0 comments on commit 6f40a55

Please sign in to comment.