boyle / 2018-measure-stress

Using machine learning to investigate sympathetic activation of the autonomic nervous system (SAANS) during the treatment of mild traumatic brain injury, chronic pain, and post-traumatic stress disorder.
3 stars 1 forks source link

Deal with data connection loss #26

Closed fcharih closed 5 years ago

fcharih commented 5 years ago

The app should be able to be robust to loss of internet connectivity. The most obvious way to deal with that is to implement local storage:

  1. Data is saved on the device during the session;
  2. At end of session: an attempt is made to upload the session data to the server;
    • If upload is unsuccessful; the file is stored in a directory of failed uploads.
    • User is asked to answer a security question whose answer will let them claim ownership of the file once connection is re-established. (i.e. what was your first pet's name, paternal grandmother's given name, etc.)
  3. When connection is re-established, file ownership can be claimed and file is uploaded.
  4. File integrity verification (with hashing?)