fix(objectstore): Propagate attachment retention#5774
Conversation
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
| .event_attachments | ||
| .for_project(scoping.organization_id.value(), scoping.project_id.value()) | ||
| .session(&self.objectstore_client); | ||
| let retention = envelope.envelope().retention(); |
There was a problem hiding this comment.
Flagging this to double-check: Attachments never used standard event retention. IIRC, they are by default stored for 30 days even if event retention is set to 90. I don't recall there were ever any plan overrides.
If we make this change, we should check if event attachments by definition have the same retention as events or whether we need to expose a separate config to Relay.
c3365a9 to
acee0b3
Compare
acee0b3 to
5028241
Compare
It is a form of attachments that we build a while back: https://develop.sentry.dev/sdk/telemetry/attachments/#trace-attachments |

objectstore clients in Relay and Sentry are hardcoded to use 30d TTL retention for all attachments. we need to instead inherit the correct retention policy from the event/envelope/project/whatever.
questions:
ctx.event_retention().standardandenvelope.envelope().retention()the correct places to inherit the retention policy from?Ref INGEST-837