Skip to content

Commit eef253e

Browse files
committed
fix(snuba): Actually retry requests on POST
Follow up to #11108 since that didn't actually do anything.
1 parent 0843762 commit eef253e

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

src/sentry/utils/snuba.py

+8-1
Original file line numberDiff line numberDiff line change
@@ -229,7 +229,14 @@ def options_override(overrides):
229229

230230
_snuba_pool = connection_from_url(
231231
settings.SENTRY_SNUBA,
232-
retries=5,
232+
retries=urllib3.Retry(
233+
total=5,
234+
# Expand our retries to POST since all of
235+
# our requests are POST and they don't mutate, so they
236+
# are safe to retry. Without this, we aren't
237+
# actually retrying at all.
238+
method_whitelist={'GET', 'POST'},
239+
),
233240
timeout=30,
234241
maxsize=10,
235242
)

0 commit comments

Comments
 (0)