Loading services/backup/java/com/android/server/backup/UserBackupManagerService.java +13 −5 Original line number Diff line number Diff line Loading @@ -234,8 +234,10 @@ public class UserBackupManagerService { // CPU on bring-up and increase time-to-UI. private static final long INITIALIZATION_DELAY_MILLIS = 3000; // Timeout interval for deciding that a bind or clear-data has taken too long private static final long TIMEOUT_INTERVAL = 10 * 1000; // Timeout interval for deciding that a bind has taken too long. private static final long BIND_TIMEOUT_INTERVAL = 10 * 1000; // Timeout interval for deciding that a clear-data has taken too long. private static final long CLEAR_DATA_TIMEOUT_INTERVAL = 30 * 1000; // User confirmation timeout for a full backup/restore operation. It's this long in // order to give them time to enter the backup password. Loading Loading @@ -1449,7 +1451,7 @@ public class UserBackupManagerService { // success; wait for the agent to arrive // only wait 10 seconds for the bind to happen long timeoutMark = System.currentTimeMillis() + TIMEOUT_INTERVAL; long timeoutMark = System.currentTimeMillis() + BIND_TIMEOUT_INTERVAL; while (mConnecting && mConnectedAgent == null && (System.currentTimeMillis() < timeoutMark)) { try { Loading Loading @@ -1554,16 +1556,22 @@ public class UserBackupManagerService { // can't happen because the activity manager is in this process } // only wait 10 seconds for the clear data to happen long timeoutMark = System.currentTimeMillis() + TIMEOUT_INTERVAL; // Only wait 30 seconds for the clear data to happen. long timeoutMark = System.currentTimeMillis() + CLEAR_DATA_TIMEOUT_INTERVAL; while (mClearingData && (System.currentTimeMillis() < timeoutMark)) { try { mClearDataLock.wait(5000); } catch (InterruptedException e) { // won't happen, but still. mClearingData = false; Slog.w(TAG, "Interrupted while waiting for " + packageName + " data to be cleared", e); } } if (mClearingData) { Slog.w(TAG, "Clearing app data for " + packageName + " timed out"); } } } Loading Loading
services/backup/java/com/android/server/backup/UserBackupManagerService.java +13 −5 Original line number Diff line number Diff line Loading @@ -234,8 +234,10 @@ public class UserBackupManagerService { // CPU on bring-up and increase time-to-UI. private static final long INITIALIZATION_DELAY_MILLIS = 3000; // Timeout interval for deciding that a bind or clear-data has taken too long private static final long TIMEOUT_INTERVAL = 10 * 1000; // Timeout interval for deciding that a bind has taken too long. private static final long BIND_TIMEOUT_INTERVAL = 10 * 1000; // Timeout interval for deciding that a clear-data has taken too long. private static final long CLEAR_DATA_TIMEOUT_INTERVAL = 30 * 1000; // User confirmation timeout for a full backup/restore operation. It's this long in // order to give them time to enter the backup password. Loading Loading @@ -1449,7 +1451,7 @@ public class UserBackupManagerService { // success; wait for the agent to arrive // only wait 10 seconds for the bind to happen long timeoutMark = System.currentTimeMillis() + TIMEOUT_INTERVAL; long timeoutMark = System.currentTimeMillis() + BIND_TIMEOUT_INTERVAL; while (mConnecting && mConnectedAgent == null && (System.currentTimeMillis() < timeoutMark)) { try { Loading Loading @@ -1554,16 +1556,22 @@ public class UserBackupManagerService { // can't happen because the activity manager is in this process } // only wait 10 seconds for the clear data to happen long timeoutMark = System.currentTimeMillis() + TIMEOUT_INTERVAL; // Only wait 30 seconds for the clear data to happen. long timeoutMark = System.currentTimeMillis() + CLEAR_DATA_TIMEOUT_INTERVAL; while (mClearingData && (System.currentTimeMillis() < timeoutMark)) { try { mClearDataLock.wait(5000); } catch (InterruptedException e) { // won't happen, but still. mClearingData = false; Slog.w(TAG, "Interrupted while waiting for " + packageName + " data to be cleared", e); } } if (mClearingData) { Slog.w(TAG, "Clearing app data for " + packageName + " timed out"); } } } Loading