Closed leviia closed 1 year ago
Hey, sorry for the infinitely late response :sweat:.
There is unfortunately no such thing as a temporary variable :grin:.
The solution I implemented for all OneDrive, Google and Dropbox data migration apps is to have a 1h timeout on the import jobs. This way one can start importing again after an hour if the job was brutally interrupted.
This will be included in all apps next releases. Feel free to reopen if needed.
Hello
First of all thanks for this great app.
There is an issue witch may also exist on integration_google and integration_onedrive.
When you star a sync everything goes well and those config variable are set
The issue appear when you restart the server. Here you can go into a broken state where those two variable are set but nothing is currently running
And it get worse, because even if the user stop the importation, only
importing_dropbox
is cleared as you can see in this codeOn file
src/components/PersonalSettings.vue
So even if a user stop and restart the transfer, it is still stuck because the variable
dropbox_import_running
is never cleared (it is still equals to 1 even if nothing is running)Then when user restart the importation this code is fired
on file
lib/Service/DropboxStorageAPIService.php
As you can see we directly go to return and it just stop. So the user will never be able to start it back by himself. A manual intervention of the administrator is mandatory to clear this variable:
occ user:setting $user integration_dropbox dropbox_import_running 0
And then allow the user to start it back by himself. And this has to be made for every user at every reboot ! this is not ideal.
What I propose is
dropbox_import_running
as a config variable but as a temporary variable so at least when server is rebooted this variable is cleared. And then the user is able to restart the import by himself.importing_dropbox
is set to 1. If so (it means that an import was previously running and has to be restarted) it setimporting_dropbox
to 0 and callimportDropboxJob()
so the import restart by itself at every reboot.Please tell me if you think it is a good idea and if you would like to implement it on mainline so we will all benefit from it. As I said maybe integration_google and integration_onedrive have the same issue.
All the best
Arnaud