Page MenuHomePhabricator

[web] Clear database on non-threadStore ops fail
ClosedPublic

Authored by michal on Apr 3 2024, 7:29 AM.
Tags
None
Referenced Files
F3489953: D11544.diff
Wed, Dec 18, 2:16 PM
Unknown Object (File)
Nov 17 2024, 9:44 AM
Unknown Object (File)
Nov 17 2024, 9:27 AM
Unknown Object (File)
Nov 17 2024, 7:39 AM
Unknown Object (File)
Nov 5 2024, 6:54 PM
Unknown Object (File)
Nov 3 2024, 1:59 AM
Unknown Object (File)
Oct 11 2024, 12:18 PM
Unknown Object (File)
Oct 11 2024, 12:18 PM
Subscribers

Details

Summary

ENG-7587 : Should we clear the web DB when some operations fail?
Clean the db on other (non-draft, non-report) ops.

Depends on D11539

Test Plan

Add throw new Error() on message store rekey op. Try sending a message. App displayed an alert and reloaded.

Diff Detail

Repository
rCOMM Comm
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

michal requested review of this revision.Apr 3 2024, 7:44 AM
kamil added inline comments.
web/shared-worker/utils/store.js
209–216 ↗(On Diff #38842)

can this be simplified using entries()? I am mostly worried about cases when someone adds something to storeOperations but forgets add it here so I will also inverse the condition

This revision is now accepted and ready to land.Apr 5 2024, 3:40 AM

Use entries instead of specifying each ops separately.