Page MenuHomePhabricator

[lib] refactor `createOlmSessionWithPeer` -> `createOlmSessionsWithUser`
ClosedPublic

Authored by kamil on Sep 18 2024, 4:51 AM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Oct 22, 10:41 AM
Unknown Object (File)
Tue, Oct 22, 10:21 AM
Unknown Object (File)
Tue, Oct 22, 10:21 AM
Unknown Object (File)
Tue, Oct 22, 10:20 AM
Unknown Object (File)
Sun, Oct 20, 7:45 PM
Unknown Object (File)
Sat, Oct 19, 2:20 PM
Unknown Object (File)
Oct 4 2024, 6:24 AM
Unknown Object (File)
Oct 3 2024, 6:57 PM
Subscribers

Details

Summary

ENG-9106.

This API better matches Identity API, which returns data for all user devices.

Additionally, session creation for each device is done in parallel.

Test Plan

Tested in D13376

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

kamil held this revision as a draft.
lib/utils/crypto-utils.js
184 ↗(On Diff #44289)

This change is a fix for ENG-9278.

We shouldn't throw it as this is a regular case:

  • having singleton device list
  • having an out-of-sync device list in auxUserStore (e.g. device on logout failed to send updates) - created ENG-9332 to track.
kamil published this revision for review.Sep 18 2024, 5:42 AM
kamil edited the test plan for this revision. (Show Details)
lib/components/peer-olm-session-creator-provider.react.js
13–16 ↗(On Diff #44289)

It's weird that this is defined here but SessionCreationOptions is defined above createOlmSessionsWithUser

Would it make sense to move this definition to be closer to SessionCreationOptions?

This revision is now accepted and ready to land.Sep 18 2024, 7:21 AM
lib/utils/crypto-utils.js
243–247 ↗(On Diff #44289)

It might be a good idea to also log an exception

  • log exception
  • move type definition to a better place