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

fix(base): clear a room's send queue and dependent event queue after removing it from the state store #4295

Merged

Conversation

bnjbvr
Copy link
Member

@bnjbvr bnjbvr commented Nov 19, 2024

Since this wasn't properly done for the dependent send queue for rooms, technically we should run a migration to look for the entries in the dependent send queue table, and remove all those that don't correspond to known room ids. I didn't bother here because the value seems quite low (this shouldn't affect many lines), but if the reviewer strongly feels about it, we could clean it up.

@bnjbvr bnjbvr requested a review from a team as a code owner November 19, 2024 15:18
@bnjbvr bnjbvr requested review from poljar and removed request for a team November 19, 2024 15:18
Copy link

codecov bot commented Nov 19, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 85.02%. Comparing base (0b16d48) to head (56863b4).
Report is 4 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #4295      +/-   ##
==========================================
- Coverage   85.02%   85.02%   -0.01%     
==========================================
  Files         274      274              
  Lines       30107    30126      +19     
==========================================
+ Hits        25599    25615      +16     
- Misses       4508     4511       +3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.


🚨 Try these New Features:

Copy link
Contributor

@poljar poljar left a comment

Choose a reason for hiding this comment

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

Don't we need this for the IndexedDB store? Don't we have support for the send queue there?

@bnjbvr
Copy link
Member Author

bnjbvr commented Nov 19, 2024

Thanks for the review!

It was correctly implemented for the indexeddb state store 🙃 (as proven by the tests not failing without any additional changes there). So yeah, our implementations were a bit inconsistent before…

@bnjbvr bnjbvr merged commit efeac2e into main Nov 19, 2024
40 checks passed
@bnjbvr bnjbvr deleted the bnjbvr/clean-send-queue-and-dependent-when-removing-room branch November 19, 2024 15:50
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

Successfully merging this pull request may close these issues.

2 participants