Browse Source

Expose a new Relay option to send attachment contents inline (#71646)

This will be used in relay starting with this PR:
https://github.com/getsentry/relay/pull/3654
Arpad Borsos 9 months ago
parent
commit
dafd2e61d8
2 changed files with 5 additions and 0 deletions
  1. 4 0
      src/sentry/options/defaults.py
  2. 1 0
      src/sentry/relay/globalconfig.py

+ 4 - 0
src/sentry/options/defaults.py

@@ -1053,8 +1053,12 @@ register("enhancers.use-zstd", default=False, flags=FLAG_AUTOMATOR_MODIFIABLE)
 register("eventattachments.store-blobs.projects", default=[], flags=FLAG_AUTOMATOR_MODIFIABLE)
 # Percentage sample rate for `EventAttachment`s that should use direct blob storage.
 register("eventattachments.store-blobs.sample-rate", default=0.0, flags=FLAG_AUTOMATOR_MODIFIABLE)
+
 # Percentage sample rate for "small" `EventAttachment`s to be stored inline.
 register("eventattachments.store-small-inline", default=0.0, flags=FLAG_AUTOMATOR_MODIFIABLE)
+# Percentage rollout rate to avoid sending `attachment_chunk`s for small indvidual attachments.
+register("relay.inline-attachments.rollout-rate", default=0.0, flags=FLAG_AUTOMATOR_MODIFIABLE)
+
 
 # All Relay options (statically authenticated Relays can be registered here)
 register("relay.static_auth", default={}, flags=FLAG_NOSTORE)

+ 1 - 0
src/sentry/relay/globalconfig.py

@@ -27,6 +27,7 @@ RELAY_OPTIONS: list[str] = [
     "relay.span-extraction.sample-rate",
     "relay.force_full_normalization",
     "relay.disable_normalization.processing",
+    "relay.inline-attachments.rollout-rate",
 ]