bigdaddydad / android-xbmcremote

Automatically exported from code.google.com/p/android-xbmcremote
0 stars 0 forks source link

Backup hosts to the cloud #509

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
Starting with Froyo, Android has the ability to automatically backup data to 
Google's cloud servers:

http://developer.android.com/guide/topics/data/backup.html

It would be nice if the remote took advantage of this to keep a backup of the 
hosts. Whenever a user reinstalled the remote app, it would automatically 
recover them.

Original issue reported on code.google.com by Anthony....@gmail.com on 27 Apr 2011 at 4:32

GoogleCodeExporter commented 8 years ago
Here's a patch (against rev 769) that provides an implementation of this. I've 
done some basic testing, but some other people should definitely take a look at 
it.

It sends a backup request any time a host is added, modified, or removed. The 
backup operation takes all of the Hosts, converts them to a JSON string, and 
puts that into the backup file. The restore operation clears the Hosts database 
and inserts the backed-up ones from the serialized JSON information.

The Android documentation (above) has instructions on testing this feature.

Original comment by Anthony....@gmail.com on 27 Apr 2011 at 4:36

Attachments:

GoogleCodeExporter commented 8 years ago
Just realized that the issue defaulted to Accepted. Changing to New.

Original comment by Anthony....@gmail.com on 19 May 2011 at 11:31

GoogleCodeExporter commented 8 years ago
What is the api_key good for? Do we have to register this somewhere? Is this 
api_key already registered? Is it a good idea to have that in an open source 
app?

Original comment by till.ess...@googlemail.com on 22 May 2011 at 9:10

GoogleCodeExporter commented 8 years ago
The API key is from here, and there's a unique key per Android app (based on 
the package name):

http://code.google.com/android/backup/signup.html

(someone that officially represents the app should probably go there, to agree 
to the terms that you won't sue Google if something isn't backed up, etc...)

It shouldn't be a problem to have this key in the open -- if another app tried 
to use it, it would fail because it would be for the wrong package.

More info here: 
http://developer.android.com/guide/topics/data/backup.html#BackupKey

Original comment by Anthony....@gmail.com on 23 May 2011 at 3:14

GoogleCodeExporter commented 8 years ago
Cool idea.

Original comment by phree...@gmail.com on 13 Aug 2011 at 11:45