HomePhabricator
Diffusion Comm 70d516d8aa73

[SQLite] recreate table for Outbound P2P messages

Description

[SQLite] recreate table for Outbound P2P messages

Summary:

  1. Updating table name to be more readable.
  2. Adding a column with status.

Note 1:
This table is empty in the current state so it's safe to just drop and create.

Note 2:
With the current design, we allow for ciphertext to be the empty string. This is the case when we need to send something to a peer but olm session not exist or is malformed. The alternative is making this field nullable, but this will make implementation more complex and will require a lot of additional code (mostly because of ENG-5719) so going for the empty string when ciphertext is missing.

Note 3:
We need a bit different API to this table - updated in the next diffs along with tests.

Depends on D12047

Test Plan:

  1. Migration succeeded.
  2. Creating DB from scratch works.
  3. Tests

Reviewers: tomek, marcin

Reviewed By: marcin

Subscribers: ashoat

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

Details

Provenance
kamilAuthored on May 16 2024, 4:44 AM
Reviewer
marcin
Differential Revision
D12068: [SQLite] recreate table for Outbound P2P messages
Parents
rCOMMc5c181b5b06f: [lib] add `deviceID` prop to Tunnelbroker's `MessageProcessed`
Branches
Unknown
Tags
Unknown