element-hq / element-hq/element-android
F-Droid builds rarely compact database
- Dominant language
- Kotlin
- Stars
- 3.7k
- Forks
- 917
- PR merge metrics
- No merged PRs in 30d
Description
### Steps to reproduce
1. With the F-Droid variant, join many large rooms (1000+ members, such as matrix-hq)
2. Notice the app storage steadily increases (this is expected due to realm's extra storage allocation)
### Outcome
#### What did you expect?
For the session store database to be compacted
#### What happened instead?
The app is currently set up to only compact the database on cold launch, however, the f-droid builds have a noop `GuardService` which forces the `Application` instance to be kept alive which means we end up skipping the compacting.
Compaction can only happen when there are no connections to the database.
### Your phone model
_No response_
### Operating system version
_No response_
### Application version and app store
1.4.0
### Homeserver
_No response_
### Will you send logs?
No
Contributor guide
Assessment
This issue has not been assessed yet.