Skip to content

Commit

Permalink
fix(relocation): Adjust log level (#75093)
Browse files Browse the repository at this point in the history
Fixes: SENTRY-3CH0
Fixes: SENTRY-3CH2
Fixes: SENTRY-3CGZ
Fixes: SENTRY-3CH1
  • Loading branch information
azaslavsky committed Jul 26, 2024
1 parent e928219 commit 84e405e
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions src/sentry/tasks/relocation.py
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,7 @@ def fulfill_cross_region_export_request(
path = f"runs/{uuid}/saas_to_saas_export/{org_slug}.tar"
relocation_storage = get_relocation_storage()
fp = BytesIO()
logger.error(
logger.info(
"fulfill_cross_region_export_request: exporting",
extra=logger_data,
)
Expand All @@ -374,15 +374,15 @@ def fulfill_cross_region_export_request(
org_filter={org_slug},
printer=LoggingPrinter(uuid),
)
logger.error(
logger.info(
"fulfill_cross_region_export_request: exported",
extra=logger_data,
)

fp.seek(0)
relocation_storage.save(path, fp)
logger_data["encrypted_contents_size"] = fp.tell()
logger.error(
logger.info(
"fulfill_cross_region_export_request: saved",
extra=logger_data,
)
Expand All @@ -400,7 +400,7 @@ def fulfill_cross_region_export_request(
org_slug=org_slug,
).dict(),
).save()
logger.error(
logger.info(
"fulfill_cross_region_export_request: scheduled",
extra=logger_data,
)
Expand Down Expand Up @@ -432,15 +432,15 @@ def cross_region_export_timeout_check(

logger_data = {"uuid": str(relocation.uuid), "task": "cross_region_export_timeout_check"}
logger.info(
"Cross region timeout check: started",
"cross_region_export_timeout_check: started",
extra=logger_data,
)

# We've moved past the `UPLOADING_START` step, so the cross-region response was received, one
# way or another.
if relocation.latest_task != OrderedTask.UPLOADING_START.name:
logger.info(
"Cross region timeout check: no timeout detected",
"cross_region_export_timeout_check: no timeout detected",
extra=logger_data,
)
return
Expand All @@ -449,15 +449,15 @@ def cross_region_export_timeout_check(
# nothing.
if relocation.status == Relocation.Status.FAILURE.value:
logger.info(
"Cross region timeout check: task already failed",
"cross_region_export_timeout_check: task already failed",
extra=logger_data,
)
return

reason = ERR_UPLOADING_CROSS_REGION_TIMEOUT.substitute(delta=CROSS_REGION_EXPORT_TIMEOUT)
logger_data["reason"] = reason
logger.error(
"Cross region timeout check: timeout detected",
"cross_region_export_timeout_check: timeout detected",
extra=logger_data,
)

Expand Down

0 comments on commit 84e405e

Please sign in to comment.