Commit Graph

11 Commits

Author SHA1 Message Date
Jorge Martín
841558c3b4 Add session path migration to SessionData 2024-06-06 17:06:57 +02:00
Benoit Marty
7dac89202a Fix existing tests. 2024-06-05 14:59:51 +02:00
Jorge Martin Espinosa
801f0b955d Notifications: simplify the flow by removing persistence (#2924)
* Notifications: simplify the flow by removing persistence. 
* Bump of minSdk to `24` (Android 7).
* Add migration to remove `notification.bin` file
2024-05-29 08:03:23 +00:00
Benoit Marty
ab2e620e39 Rename class (code quality) 2024-05-23 14:38:50 +02:00
Benoit Marty
55fda265d9 Rename class (code quality) 2024-05-23 14:38:49 +02:00
Jorge Martin Espinosa
6257425344 Bump Rust SDK to v0.2.18 and bump app version (#2836)
* Adapt to changes in SDK:
    - Remove name from MatrixRoom, we should use displayName instead.
    - Remove separate invites room list.
    - Added runBlocking to get the now async NotificationClient from the Rust SDK.
    - Made some other functions suspend.
    - Client.resolveRoomAlias now returns a roomId and via parameters, we pass the roomId.

* Add logs removal migration again as `AppMigration03` to make sure we don't leak private data in existing logs.

* Bump app version to `0.4.12`
2024-05-13 16:48:23 +02:00
Jorge Martin Espinosa
9aadec8435 Enforce mandatory session verification only for new logins (#2811)
* Enforce mandatory session verification only for new logins

- Creates `AppMigration` base interface as a way to isolate migration logic, app migrations must implement this interface.
- Creates `AppMigration01` with the existing logs removal migration and `AppMigration02` with the logic to allow existing sessions to skip verification.
- Add `DefaultSessionPreferencesStoreFactory.remove(sessionId)` to allow a ephemeral session store access to exist outside the `SessionScope` for this new migration.

* Fix tests

* Add more tests.

This also includes creating several abstractions.

* Review changes.

- Make `orderedMigrations` a class property, `migrations` just a constructor parameter to avoid incorrect usages.
- Create `lastMigration` property too, use it instead of `MIGRATION_VERSION`.
2024-05-07 14:06:34 +00:00
Benoit Marty
1db515ee17 Please KtLint 2024-04-24 13:28:52 +02:00
Benoit Marty
8d0aa68f9a Add KDoc. 2024-04-24 13:26:27 +02:00
Benoit Marty
46544b1b45 Code quality. 2024-04-24 11:40:09 +02:00
Benoit Marty
f6b5b8419b Implement a migration mechanism to handle internal stuff which need to occur during application upgrade.
Remove VectorFileLogger, it was dead code.
2024-04-24 11:17:23 +02:00