05-11-2011 02:15 PM - edited 05-11-2011 03:24 PM
It seems that "HTML5 Local storage" only gets deleted when a Webworks app is uninstalled, not when it's updated. So, that's good news, but I still don't know whether it can be trusted for long term storage of things like settings:
1) Is "HTML5 Local Storage" deleted when the OS gets updated?
2) Is "HTML5 Databases" also managed the same way or is data safer there?
3) Are those "files" saved with backups and can they be restored?
4) When will we finally be able to store files on the filesystem?
EDIT: I've revised my questions as some of my assumptions were based on old tests done with an earlier version of the simulator
08-05-2011 04:04 PM
Hello bobbyboy1999, I've collected some answers over time.
1. It survives OS updates
2. It is managed the same way.
3. They are saved with OS backups and can be restored
4. It is possible to do by writting your own extension or you can wait for the next release of the SDK
So, it is safe to use localstorage or WebDB for settings and a backup should be sent to the cloud if you've made a promise to your customers
08-05-2011 04:14 PM
Great answers as always, thank you.
Just to be clear, a Web DB, as application data, is backed up whenever the device is run through the backup utility on BB Desktop. Correct? Assuming, of course, the user has the settings checked to backup Application Data?
And, your last comment about backing up to the cloud, is only as an extra layer of security against data loss (because the data is, assuming the users are somewhat diligent, already backed up with BB Desktop)?
Thank you again.
08-05-2011 04:24 PM
Yes, the desktop utility will take care of the backup as long as the user ticks that option.
I saw your question regarding local backups and I too wish there was an easy way to create a sql dump, but I haven't really looked into it.
Regarding the cloud, I'm more concerned about data corruption when using localstorage because it can prevent an app from working until you completely erase all data, but yes, depending on your app, the data could be quite valuable and frequent backups should be performed because you can't rely on the user to do that .