-
Notifications
You must be signed in to change notification settings - Fork 3.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[FEATURE REQUEST] Automatic removal of downloaded files and local storage clean up #4320
[FEATURE REQUEST] Automatic removal of downloaded files and local storage clean up #4320
Conversation
For temporal files will also be deleted according to their last modification date with respect to the selected time. |
5b818dd
to
2edfd85
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some changes requested here @Aitorbp
owncloudApp/src/main/java/com/owncloud/android/dependecyinjection/UseCaseModule.kt
Outdated
Show resolved
Hide resolved
...oudApp/src/main/java/com/owncloud/android/usecases/files/DeleteFilesOlderGivenTimeUseCase.kt
Outdated
Show resolved
Hide resolved
owncloudApp/src/main/java/com/owncloud/android/presentation/settings/advanced/AdvanceUtils.kt
Outdated
Show resolved
Hide resolved
owncloudData/src/main/java/com/owncloud/android/data/files/datasources/LocalFileDataSource.kt
Outdated
Show resolved
Hide resolved
...java/com/owncloud/android/data/files/datasources/implementation/OCLocalFileDataSourceTest.kt
Outdated
Show resolved
Hide resolved
owncloudData/src/test/java/com/owncloud/android/data/files/repository/OCFileRepositoryTest.kt
Outdated
Show resolved
Hide resolved
owncloudData/src/main/java/com/owncloud/android/data/files/db/FileDao.kt
Outdated
Show resolved
Hide resolved
owncloudData/src/main/java/com/owncloud/android/data/files/db/FileDao.kt
Outdated
Show resolved
Hide resolved
2d4e65b
to
b05c8f5
Compare
6829116
to
bf6142f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some more changes here @Aitorbp
...pp/src/main/java/com/owncloud/android/presentation/settings/advanced/AdvanceSettingsUtils.kt
Outdated
Show resolved
Hide resolved
...pp/src/main/java/com/owncloud/android/presentation/settings/advanced/AdvanceSettingsUtils.kt
Outdated
Show resolved
Hide resolved
...pp/src/main/java/com/owncloud/android/presentation/settings/advanced/AdvanceSettingsUtils.kt
Outdated
Show resolved
Hide resolved
...rc/main/java/com/owncloud/android/presentation/settings/advanced/SettingsAdvancedFragment.kt
Outdated
Show resolved
Hide resolved
...c/main/java/com/owncloud/android/presentation/settings/advanced/SettingsAdvancedViewModel.kt
Outdated
Show resolved
Hide resolved
...java/com/owncloud/android/workers/RemoveLocallyFilesWithLastUsageOlderThanGivenTimeWorker.kt
Outdated
Show resolved
Hide resolved
owncloudData/src/test/java/com/owncloud/android/data/files/repository/OCFileRepositoryTest.kt
Outdated
Show resolved
Hide resolved
4aa5879
to
4feb544
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM now!
(1) [FIXED]I noticed you removed the release notes from previous versions from the https://github.com/owncloud/android/blob/master/owncloudApp/src/main/res/values-de-rDE/strings.xml ...and more. Two options: either recovering the strings to IMO these actions are not related with the current PR, and should be done in separated place. |
(2) [FIXED]kind of stupid question: what's the best option to display: As reference, iOS app uses open question |
(3) [FIXED]Another minor detail: in the description ( Suggestion, open for discussion/improvement:
Apart of that, you called "selected time" the option to be chosen by the user, so, i'd also call it in the selection line, instead of What do you think? |
…nTimeUseCase, OCFileRepository,LocalFileDataSource and FileDao
…Files in vm, handling prefDeleteLocalFiles in fragment, added component in xml and string
…n the number values
…function cancelAllWorkByTag in workManagerProvider and changed named worker and use case
…SettingsAdvancedViewModelTest
59f2f64
to
aa43a74
Compare
(4) [FIXED]Some regards about the The current behaviour cleans totally up the
Also, in every case, files are removed from the internal storage but not from DB. This is not critical but could make the DB grow in uncontrolled way. My suggested solutions are:
I like 1. the most. So, the final scope would be the real storage itself. I know that all the mentioned cases are pretty corner cases, but if conditions happen it could break the app. And data loss is never valid. |
ca3855a
to
a67d598
Compare
Taken solution was 1). In this iteration, That problem will be moved to another issue inside the epic. For the current PR, it's approved on my side. |
…min by 1 hour an removed author in header
Related Issues
App: #4175
QA
Test plan execution: https://github.com/owncloud/QA/blob/master/Mobile/Android/Executions/Release_4.3/Automatic%20Removal.md
Bugs & improvements:
/tmp
up [FEATURE REQUEST] Automatic removal of downloaded files and local storage clean up #4320 (comment) [FIXED]