HomePhabricator
Diffusion Comm 76679970b6b9

[native] Stop persisting `messageIDs` in `messageStore.threads`

Description

[native] Stop persisting messageIDs in messageStore.threads

Summary:
Revision for task ENG-1430.

We do want to stop persisting messageIDs since they can be deterministically generated based on SQLite output (and we already do it in code).
Transformation is needed to provide ability to omit deeply nested fields, also, outbound function (second argument) assigns an empty array to messageIDs before re-hydration because we always expect this field to be defined.

Test Plan:

  1. Make some interaction on app, close, and check if on application run after persist/REHYDRATE we have empty messageIDs in state (it'll mean that data stopped being persisted)
  2. Close app, kill keyserver and run app (to make sure we interact only with SQLite) to check if messages and threads were computed properly.

Reviewers: tomek, atul, abosh

Reviewed By: tomek

Subscribers: ashoat, atul, abosh

Differential Revision: https://phab.comm.dev/D5001

Details

Provenance
kamilAuthored on Sep 1 2022, 2:13 AM
Reviewer
tomek
Differential Revision
D5001: [native] Stop persisting `messageIDs` in `messageStore.threads`
Parents
rCOMMdf8776bb2c05: [web/native] nested quotation display limit
Branches
Unknown
Tags
Unknown