Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Slow clean tagged events and overload Cassandra by overfetch insufficient data for deleteFromTagView #1103

Open
Valocop opened this issue May 31, 2024 · 5 comments

Comments

@Valocop
Copy link

Valocop commented May 31, 2024

The problem is that when we try to clean events by tags, Cassandra Journal runs a stream with current events by tag and over fetch data by fetching event payload for every event. It takes a lot of time to clean tag_views.
Better make stream that will be fetch events without payload, these data will be enough for deleteFromTagView.

I faced this problem when cleaning events in tag with a lot of events (millions) and the payload is a big.

Can we fix it, please?
Thanks

@patriknw
Copy link
Member

patriknw commented Jun 3, 2024

Good point, I'll try to adjust that later this week, unless you want to fix it?

@Valocop
Copy link
Author

Valocop commented Jun 5, 2024

I would be very grateful for your help!
I can try, but I need to discuss how to implement it.
Better add a new method or change current currentEventsByTagInternal(...) and use flag for fetching all data or without event payload?
@patriknw

Thanks

@patriknw
Copy link
Member

patriknw commented Jun 5, 2024

I guess, since most things are the same it would be easiest with a flag. In the end it's a different cql (prepared statement) and change in deserializeEventsByTagRow. The payload in the PersistentRepr could be set to NotUsed for this case.

@patriknw
Copy link
Member

@Valocop Are you working on this, or shall I give it a try?

@Valocop
Copy link
Author

Valocop commented Jul 5, 2024

@Valocop Are you working on this, or shall I give it a try?
@patriknw

Sorry for waiting, yes, you can try, unfortunately, I can't join right now

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants