android icon indicating copy to clipboard operation
android copied to clipboard

Make sure only one sync job is running at a time

Open JonasMayerDev opened this issue 1 year ago • 4 comments

Before running sync worker, check if another sync worker is already running. Before in theory 2 sync jobs could run and potentially mess with each other (maybe leads to https://github.com/nextcloud/android/issues/11974)

  • [X] Tests written, or not not needed

JonasMayerDev avatar Jan 15 '24 14:01 JonasMayerDev

Problem: With current implementation when periodic sync worker is started and immediate filesync is already running because of changed files it will skip periodic sync which is not intended... But it is really unlikely since immediate file sync with changed files should only run for under 1 sec.

JonasMayerDev avatar Apr 09 '24 15:04 JonasMayerDev

Codacy

Lint

TypemasterPR
Warnings7272
Errors33

SpotBugs

CategoryBaseNew
Bad practice6666
Correctness7373
Dodgy code349349
Experimental11
Internationalization77
Malicious code vulnerability22
Multithreaded correctness66
Performance5757
Security1919
Total580580

github-actions[bot] avatar May 03 '24 11:05 github-actions[bot]

APK file: https://www.kaminsky.me/nc-dev/android-artifacts/12372.apk

qrcode

To test this change/fix you can simply download above APK file and install and test it in parallel to your existing Nextcloud app.

github-actions[bot] avatar May 03 '24 11:05 github-actions[bot]