Page MenuHomePhabricator

[web] Persist web sessions
ClosedPublic

Authored by michal on Mar 14 2024, 4:30 AM.
Tags
None
Referenced Files
F3363780: D11326.id38333.diff
Mon, Nov 25, 3:23 AM
F3363360: D11326.diff
Mon, Nov 25, 1:56 AM
Unknown Object (File)
Thu, Nov 7, 2:27 AM
Unknown Object (File)
Oct 15 2024, 8:36 PM
Unknown Object (File)
Oct 15 2024, 8:36 PM
Unknown Object (File)
Oct 15 2024, 8:36 PM
Unknown Object (File)
Oct 15 2024, 8:36 PM
Unknown Object (File)
Oct 15 2024, 8:35 PM
Subscribers

Details

Summary

Required for ENG-6657 : Migrate session creation code to shared worker

We need to start persisting web sessions. Notification sessions are going to be persisted in indexedDB as they currently are.

Depends on D11299

Test Plan

Create a dummy session during initalization. Reload web page. Check that the session (runtime object) is no longer there. Initialize the crypto account (rehydrate). Check that the session exists.

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

web/shared-worker/types/sqlite-query-executor.js
36 ↗(On Diff #38059)

If I understand correctly this needs to be changed to targetDeviceID right? Is there a task for this?

From a quick look the sqlite table column also is named target_user_id so this would probably need a migration. But I don't think we depend on this column name anywhere in code (we just treat the values in the table as pairs).

kamil added inline comments.
web/shared-worker/types/sqlite-query-executor.js
36 ↗(On Diff #38059)

Yes, it should be targetDeviceID - could you create a followup task?

web/shared-worker/worker/worker-crypto.js
7–10 ↗(On Diff #38059)

why this change?

130 ↗(On Diff #38059)

Can this error be less generic?

This revision is now accepted and ready to land.Mar 18 2024, 5:26 AM