Skip to content

Conversation

shashjar
Copy link
Member

@shashjar shashjar commented Oct 10, 2025

Sets up double deletion of occurrences with EAP, as described in ID-997.

When deleting events from eventstore, we should also delete from EAP using the in-progress DeleteTraceItems endpoint (protobuf definition).

Copy link

linear bot commented Oct 10, 2025

@github-actions github-actions bot added the Scope: Backend Automatically applied to PRs that change backend components label Oct 10, 2025

# Enables deletion from EAP for a set of projects
register(
"eventstream.eap.deletion_enabled.project_allowlist",
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does a project allowlist fit with how we want to do initial rollout/testing?

logger = logging.getLogger(__name__)


def delete_groups_from_eap_rpc(
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would like opinions on how to organize this code, e.g. in a separate file as drafted or alongside the Snuba eventstream impl

and_filter=AndFilter(filters=[project_filter, group_id_filter])
)
filter_with_type = TraceItemFilterWithType(
item_type=TRACE_ITEM_TYPE_OCCURRENCE,
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm unclear why we have both TRACE_ITEM_TYPE_OCCURRENCE & TRACE_ITEM_TYPE_ERROR. I thought we were using "occurrences" as the term for all error events stored in EAP?

from sentry.testutils.cases import TestCase


class TestEAPDeletion(TestCase):
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Basic tests for now, to be improved later

@shashjar shashjar changed the title feat(occurrences on eap): Sets up double deletion of occurrences with EAP feat(eap): Sets up double deletion of occurrences with EAP Oct 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Scope: Backend Automatically applied to PRs that change backend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant