Questions tagged [android-backup-service]

Android Backup Service is integrated with Android's data backup framework to perform data backup and restore for most devices running Android 2.2 or greater, using Google servers and a backup transport on the device.

Android Backup Service is integrated with Android's data backup framework to perform data backup and restore for most devices running Android 2.2 or greater, using Google servers and a backup transport on the device. In some cases, a specific Android-powered device might include a different backup transport for backup services, or might not provide a backup transport at all. Whether or not a device performs backup using Android Backup Service or another service is transparent to applications—the backup APIs used by applications are independent of the backup transport enabled on the device.

225 questions
295
votes
5 answers

What is "android:allowBackup"?

Since the new ADT preview version (version 21), they have a new lint warning that tells me the next thing on the manifest file (in the application tag): Should explicitly set android:allowBackup to true or false (it's true by default, and that can…
android developer
  • 114,585
  • 152
  • 739
  • 1,270
88
votes
6 answers

Android backup/restore: how to backup an internal database?

I have implemented a BackupAgentHelper using the provided FileBackupHelper to backup and restore the native database I have. This is the database you typically use along with ContentProviders and which resides in…
pjv
  • 10,658
  • 6
  • 43
  • 60
36
votes
2 answers

How Do You Test the Android 6.0 Full-Backup Behavior?

TL;DR: How do you successfuly use the command-line tools (or anything else) to test the Android 6.0 backup and restore behavior, as I cannot get them to restore anything? Since I was running into problems earlier with a sample app from my book…
CommonsWare
  • 986,068
  • 189
  • 2,389
  • 2,491
31
votes
8 answers

In android is there any way to preserve SharedPreferences after an uninstall

I am keeping some application meta data in SharedPreferences. Whenever I uninstall the application and reinstall it, the SharedPreferences are deleted. Is there any way to get that to remain, so that if the user does an uninstall and reinstall, they…
Victor Grazi
  • 15,563
  • 14
  • 61
  • 94
26
votes
6 answers

Android - Preserve or delete files created by the application on uninstall

I created an application which creates and stores files to sdcard. Is there a way to bind the folder with application in order to delete all files when the user runs uninstall on android device?
23
votes
4 answers

Android 23+ - Exclude GCM Registration ID from backup

I have an app which uses Azure to send Push notifications. Azure in turn, uses GCM to send to Android devices. I'm noticing that I have a warning in my AndroidManifest.xml stating On SDK version 23 and up, your app data will be automatically…
22
votes
3 answers

BackupManager Not Calling Backup Transport

Alright, so I'm trying to implement Data Backup into my application, and have been following this guide. I've implemented my BackupAgentHelper using a SharedPreferencesBackupHelper. I don't get any errors, and I'm being sure to call dataChanged()…
Kevin Coppock
  • 133,643
  • 45
  • 263
  • 274
21
votes
2 answers

onRestore not invoked for my custom BackupAgent

There are some data in my Android app that I would like to backup and restore. For that purpose I have created a custom implementation of BackupAgent. In my manifest in have included the backup agent as you can see below
mollymay
  • 512
  • 4
  • 13
18
votes
2 answers

Background application without ui

I am new to android development. I want to make one background application, so that it keeps running in background, and it's without any UI, and even its icon do not appear on desktop. In short it's a stealth application. Is it possible?
Mudassir
  • 255
  • 2
  • 4
  • 12
17
votes
3 answers

What is the file name used by default shared preferences?

Android Backup Service requires a filename to backup shared preferences: public static final String PREFS = "PrefFile"; SharedPreferencesBackupHelper helper = new SharedPreferencesBackupHelper(this, PREFS); It is clear what to use if filename…
LA_
  • 19,823
  • 58
  • 172
  • 308
15
votes
3 answers

Android full backup: "file.xml is not in an included path"

I've created backup rules file just like in example https://developer.android.com/guide/topics/data/autobackup:
babay
  • 4,689
  • 1
  • 26
  • 40
15
votes
3 answers

Can Android's keystore be backed up?

Android supports cloud and local backup of APK files, application data, and so on. Is the device keystore included in the backup? (I don't think you can extract private keys from an hardware-backed keystore even in rooted devices, not so sure about…
Daniel
  • 2,380
  • 29
  • 44
15
votes
2 answers

Android backup service - when and how often to backup?

I want to backup my app's data using Android backup service, but I'm concerned about network usage. I have about 500KB of data that needs to be uploaded for each backup operation. Not much, but if the backup is performed 10 times per day, it can…
Andree
  • 3,033
  • 6
  • 36
  • 56
12
votes
2 answers

Determine if system wide backup is enabled programmatically

I was wondering if it possible to determine if the user has enabled the option to backup application data to the cloud from within my android app. I can determine this from the command line, from adb shell by calling: bmgr enabled Does android…
Savvas Dalkitsis
  • 11,476
  • 16
  • 65
  • 104
12
votes
1 answer

Questions about using Android Backup Service with a SQLite database

My app stores all user data and preferences in a SQLite database, which I'd like to persist if the user gets a new phone, reinstalls, or does a factory reset. I've done some reading in Android's Data Backup Guide and their Android Backup Service,…
NSouth
  • 5,067
  • 7
  • 48
  • 83
1
2 3
14 15