Data loss after sleep wakeup
Posted: Thu Oct 15, 2020 2:02 pm
Hi!
I've been having a bit of a data loss issue where I click save, the text I wrote was not saved, but the windows was still closed. This caused a bit swearing.
I think what's happening is that after waking my computer up, login session may no longer be valid, and save fails. However, this happens silently. Then, when I go back to open up my document, it's just not there.
I have too proposed solutions:
(1) Do not close unless absolutely sure that data was saved, by some kind of special confirmation code (perhaps a cache could deliver a 200 even though data was not saved, just as an example) and then do not close window unless saved
(2) Use localstorage as a backup client-side autosave- for starters, it would be enough just to be able to go through recent changes and perhaps find your text to copy and paste, nothing really fancy required there- just store the data in an extra place as a failsafe. This should probably be done all the time rather than just upon clicking save.
Preferably both. Bludit is so nice because it's so relaxing to type in, but of course potential data loss has a way of making you nervous.
Existing autosaves seem to silently fail as well in this condition- this should at least display a warning. So, in summary, it would appear that saving is insufficiently robust.
I've been having a bit of a data loss issue where I click save, the text I wrote was not saved, but the windows was still closed. This caused a bit swearing.
I think what's happening is that after waking my computer up, login session may no longer be valid, and save fails. However, this happens silently. Then, when I go back to open up my document, it's just not there.
I have too proposed solutions:
(1) Do not close unless absolutely sure that data was saved, by some kind of special confirmation code (perhaps a cache could deliver a 200 even though data was not saved, just as an example) and then do not close window unless saved
(2) Use localstorage as a backup client-side autosave- for starters, it would be enough just to be able to go through recent changes and perhaps find your text to copy and paste, nothing really fancy required there- just store the data in an extra place as a failsafe. This should probably be done all the time rather than just upon clicking save.
Preferably both. Bludit is so nice because it's so relaxing to type in, but of course potential data loss has a way of making you nervous.
Existing autosaves seem to silently fail as well in this condition- this should at least display a warning. So, in summary, it would appear that saving is insufficiently robust.