402 Commits

Author SHA1 Message Date
Dan Egnor
87a02bcf68 Replace the stub GoogleTransport with callout to the
GoogleTransportService (which lives in vendor/google).
Use the Google transport by default.
Also, fix a bug: Thread.run() != Thread.start()
2009-06-17 18:23:05 -07:00
Android (Google) Code Review
5cc37854d4 am 07ca8c71: Merge change 4438 into donut
Merge commit '07ca8c71f47ac8c61b3aef0210e44d2c48e62e48'

* commit '07ca8c71f47ac8c61b3aef0210e44d2c48e62e48':
  Fix many of the ANRs introduced by scheduling classes.
2009-06-17 15:39:06 -07:00
Christopher Tate
1bd88ca88f am aa088447: Hold the current transport instantiated all the time.
Merge commit 'aa088447baadd2e0bbcfd18cc529645610c13ddc'

* commit 'aa088447baadd2e0bbcfd18cc529645610c13ddc':
  Hold the current transport instantiated all the time.
2009-06-17 15:37:53 -07:00
Jacek Surazski
f829a78f6c add exception message to ApplicationErrorReport
useful signal for clustering
2009-06-17 21:48:17 +02:00
Suchi Amalapurapu
1ccac75e1f Remove circular dependency in PackageManager. api freeStorage uses PendingIntent from android.app
Create a new public IntentSender class that can be used by PackageManager instead.
This new class uses IIntentSender internally and can only be created by PendingIntent for now.
Provide a new getIntentSender api in PendingIntent to create an instance of this class.
Move IIntentSender and IIntentReceiver from android.app to android.content
Change imports of IIntentSender and IIntentReceiver to reflect the new package name
The PackageManager api has been named as freeStorageWithIntent and will be renamed as freeStorage
once the older api(which has been deprecated) will be removed shortly.
2009-06-17 11:31:26 -07:00
Christopher Tate
ff4a203c78 am 63d27000: Allow privileged callers to schedule a backup pass for any app.
Merge commit '63d2700036d0f73cbde27f0fa724d30045b4bb07'

* commit '63d2700036d0f73cbde27f0fa724d30045b4bb07':
  Allow privileged callers to schedule a backup pass for any app.
2009-06-17 10:48:22 -07:00
Android (Google) Code Review
07ca8c71f4 Merge change 4438 into donut
* changes:
  Fix many of the ANRs introduced by scheduling classes.
2009-06-17 10:38:44 -07:00
Dianne Hackborn
82f3f0008e Fix many of the ANRs introduced by scheduling classes.
We weren't bumping the oom_adj of processes receiving a registered broadcast.  Previously
this wasn't a problem, because those processes are allowed to have their oom_adj
managed by whatever else is in them and if the registered receiver goes away no problem.
But now this is also controlling the scheduling class, so we need to bump them up.

This is probably good anyway, since the developer has the same assurance of their process
not being killing in the middle of registered receivers like it had always been for
manifest receivers.

Also fixed a small issue where we were not recomputing the oom_adh after finished with
a broadcast.
2009-06-16 18:49:05 -07:00
Christopher Tate
aa088447ba Hold the current transport instantiated all the time.
We no longer instantiate the transport just for the duration of handling a
backup or restore operation.  Instead, we hold the object forever (replacing it
if instructed to do so).  This makes it easier for transports to watch system
state and help set backup timing policy.

Also fixes up the IBackupTransport documentation a bit.
2009-06-16 18:25:46 -07:00
Christopher Tate
63d2700036 Allow privileged callers to schedule a backup pass for any app. 2009-06-16 17:18:05 -07:00
Android (Google) Code Review
714000456b am febde5fc: Merge change 4389 into donut
Merge commit 'febde5fc290eb422f78b47f393dc451394751d59'

* commit 'febde5fc290eb422f78b47f393dc451394751d59':
  More bmgr work; fix clear-data signalling
2009-06-16 16:43:17 -07:00
Christopher Tate
f68eb500f9 More bmgr work; fix clear-data signalling
The 'list sets' and 'restore token#' commands from bmgr now do what they are
supposed to.  At this point we see the restore target's data being cleared
properly and its agent being launched and invoked for restore.
2009-06-16 13:58:17 -07:00
Android (Google) Code Review
22a9f7a52e am 6297cb2e: Merge change 4287 into donut
Merge commit '6297cb2eb57c183e202744516a96b2dbbf204a09'

* commit '6297cb2eb57c183e202744516a96b2dbbf204a09':
  Sketch out a 'bmgr' command line tool
2009-06-16 08:37:18 -07:00
Android (Google) Code Review
6297cb2eb5 Merge change 4287 into donut
* changes:
  Sketch out a 'bmgr' command line tool
2009-06-15 19:03:48 -07:00
Christopher Tate
ace7f094bf Sketch out a 'bmgr' command line tool
Not finished, but eventually will allow adb shell access to the Backup Manager
for testing purposes etc.
2009-06-15 18:07:25 -07:00
Dianne Hackborn
a2aaa9e38f resolved conflicts for merge of 6edb3487 to master 2009-06-15 17:17:49 -07:00
Dianne Hackborn
cfaef699e1 Implement permission test for activity, window, service manager.
This also includes some changes to the window manager permission checks.  Almost all of these
are to make it most testable (through an exception on a permission failure), though there is
one permission check that needed to be added: updateOrientationFromAppTokens().
2009-06-15 14:35:07 -07:00
Christopher Tate
daf701fa62 am 2fdd428e: Fix some backup reader/writer issues; make local transport do backup
Merge commit '2fdd428e0f18384160f7c38ce3a2cd9ba7e7b2c2'

* commit '2fdd428e0f18384160f7c38ce3a2cd9ba7e7b2c2':
  Fix some backup reader/writer issues; make local transport do backup
  Fix the jni initializer.
  Add RestoreFileHelper, BackupDataInput, and add java wrappers for the methods on BackupDataOutput.
  Fix bug #1812041: activity manager crash with bad args.
  Journal backup requests so that they won't be lost in a crash
  Fix data connection issues.
2009-06-14 21:13:03 -07:00
Android (Google) Code Review
be3615bded Merge change 4112 into donut
* changes:
  Fix bug #1812041: activity manager crash with bad args.
2009-06-12 18:03:11 -07:00
Dianne Hackborn
75b038545e Fix bug #1812041: activity manager crash with bad args.
There was old code that would kill the system process in some cases when there
was a bad activity token.  This is really no longer used, except in a few
places where it allows apps to kill the system.  So just get rid of it and
make the world a better place.
2009-06-12 15:43:26 -07:00
Christopher Tate
cde87f45e0 Journal backup requests so that they won't be lost in a crash
When an application requests a backup via dataChanged(), we now journal that
fact on disk.  The journal persists and is only removed following a successful
backup pass.  When the backup manager is started at boot time, it looks for any
existing journal files and schedules a backup for the apps listed in them, on
the expectation that the device shut down or crashed before a backup could be
performed.
2009-06-12 13:57:39 -07:00
Christopher Tate
0c32f14ef1 am 9bbc21a7: Flesh out restore interface on manager; work up most of LocalTransport
Merge commit '9bbc21a773cbdfbef2876a75c32bda5839647751'

* commit '9bbc21a773cbdfbef2876a75c32bda5839647751':
  Flesh out restore interface on manager; work up most of LocalTransport
2009-06-11 00:56:29 -07:00
Android (Google) Code Review
74c2acee04 am 238bf47a: Merge change 3826 into donut
Merge commit '238bf47a850532233ed51362dca95facf8680770'

* commit '238bf47a850532233ed51362dca95facf8680770':
  LocationManagerService: Fix logic error removing multiple dead receivers.
2009-06-11 00:45:02 -07:00
Christopher Tate
9bbc21a773 Flesh out restore interface on manager; work up most of LocalTransport 2009-06-10 20:38:54 -07:00
Android (Google) Code Review
de115412d5 Merge change 3841
* changes:
  Fix botched merge from commit b61498d1ac8e25f0024dcde46b41bcf0d8336d89
2009-06-10 18:06:18 -07:00
Eric Fischer
f40e1a5fa6 Fix botched merge from commit b61498d1ac8e25f0024dcde46b41bcf0d8336d89 2009-06-10 18:02:15 -07:00
Android (Google) Code Review
238bf47a85 Merge change 3826 into donut
* changes:
  LocationManagerService: Fix logic error removing multiple dead receivers.
2009-06-10 17:32:21 -07:00
Simon Schoar
4686657cee LocationManagerService: Fix logic error removing multiple dead receivers.
If multiple receivers are dead, only the first one will be added.
found in http://code.google.com/p/android/issues/detail?id=2651

Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-06-10 20:23:31 -04:00
Christopher Tate
bb8d0dfed9 am c7b31e3c: The rest of the basic flow for restore
Merge commit 'c7b31e3c3cd71129557d4bf9e3fbcebb9235aba5'

* commit 'c7b31e3c3cd71129557d4bf9e3fbcebb9235aba5':
  The rest of the basic flow for restore
2009-06-10 17:19:57 -07:00
Christopher Tate
c7b31e3c3c The rest of the basic flow for restore
Also moved the processOneBackup() implementation into the Thread class that runs
the backup sequence.
2009-06-10 16:43:50 -07:00
Mitsuru Oshima
bd6b11dd58 am e5fb3288: resolution support fix/improvement * adding compatibility menu * backup gravity * set expanable=true if the screen size is hvga * density. * added "supports any density" mode. I\'ll add sdk check later. * disallow to catch orientation c
Merge commit 'e5fb328825995aa33b5b7ecf8b5bee2b17f81715'

* commit 'e5fb328825995aa33b5b7ecf8b5bee2b17f81715':
  resolution support fix/improvement
2009-06-10 16:31:36 -07:00
Romain Guy
b61498d1ac resolved conflicts for merge of f31cbb to master 2009-06-10 16:30:18 -07:00
Mitsuru Oshima
e5fb328825 resolution support fix/improvement
* adding compatibility menu
    * backup gravity
    * set expanable=true if the screen size is hvga * density.
    * added "supports any density" mode. I'll add sdk check later.
    * disallow to catch orientation change event if the app is not expandable. This
      was causing layout problem under non-expandable mode. I discussed this with Mike C
      and we agreed to do this approach for now. We'll revisit if this causes problem to
      a lot of applications.
2009-06-10 15:22:17 -07:00
Romain Guy
06882f8eff Enable HierarchyViewer on debuggable builds, even if they're secure.
That will let us (finally) use the tool on userdebug builds.
2009-06-10 14:44:11 -07:00
Android (Google) Code Review
49dd371730 am b81645c8: Merge change 3726 into donut
Merge commit 'b81645c868b3d596b5ac56822959feb629a8651e'

* commit 'b81645c868b3d596b5ac56822959feb629a8651e':
  ActivityManager: Ensure that we clear the calling process identity around calls to Process.setProcessGroup().
2009-06-10 11:09:13 -07:00
Android (Google) Code Review
b81645c868 Merge change 3726 into donut
* changes:
  ActivityManager: Ensure that we clear the calling process identity around calls to Process.setProcessGroup().
2009-06-10 11:07:58 -07:00
Christopher Tate
21444c5427 am df01deaa: More restore plumbing, plus add suggested-backoff to transport API
Merge commit 'df01deaacff82b918b4f0ba774d5ad3087543629'

* commit 'df01deaacff82b918b4f0ba774d5ad3087543629':
  More restore plumbing, plus add suggested-backoff to transport API
2009-06-10 10:59:20 -07:00
Christopher Tate
df01deaacf More restore plumbing, plus add suggested-backoff to transport API
Adds most of the code for a background-thread restore process, structured much
like the backup thread.  Broke some common functionality out into a helper
function for doing a synchronous wait for a requested agent to attach.

Added a method to IBackupTransport whereby the transport will be asked for
an opinion on whether this is a good time for a backup to happen.  It will
reply with the results of its policymaking around backoff intervals, time-of-day
selection, etc.
2009-06-10 10:53:24 -07:00
San Mehat
9438de2001 ActivityManager: Ensure that we clear the calling process identity around calls to Process.setProcessGroup().
Signed-off-by: San Mehat <san@google.com>
2009-06-10 09:12:37 -07:00
Jaikumar Ganesh
d5ac1ae36b Framework changes for bluez4.
Changes in the Bluetooth JNI calls and framework functions
for Bluez4.
2009-06-09 17:21:08 -07:00
Android (Google) Code Review
a92f696407 am d2d058b7: Merge change 3506 into donut
Merge commit 'd2d058b7d657e73255c3665c8b2f63845a8d25d0'

* commit 'd2d058b7d657e73255c3665c8b2f63845a8d25d0':
  Revamp IRestoreSession a bit
2009-06-08 16:42:21 -07:00
Christopher Tate
9b3905c4a2 Revamp IRestoreSession a bit
We now supply an array of RestoreSet objects instead of wacky Bundle
shenanigans.  Also, pushed beginRestoreSession() out to the BackupManager
concrete interface class so that SetupWizard can use it.

(beginRestoreSession() is @hide, non-privileged apps cannot use it.  It's
also guarded by android.permission.BACKUP enforcement.)
2009-06-08 16:01:24 -07:00
Android (Google) Code Review
40dabea7d8 am 9d9953d9: Merge change 3420 into donut
Merge commit '9d9953d94de4d17722ba2c768b92bd4ebeec908c'

* commit '9d9953d94de4d17722ba2c768b92bd4ebeec908c':
  LocationManagerService: Remove some unneeded imports.
2009-06-07 21:04:43 -07:00
Christopher Tate
bd235f10a9 am 8c850b79: Add IRestoreSession interface for the restore flow
Merge commit '8c850b792f2d371fd8a4aff146d9d757ee982539'

* commit '8c850b792f2d371fd8a4aff146d9d757ee982539':
  Add IRestoreSession interface for the restore flow
2009-06-07 21:04:39 -07:00
Android (Google) Code Review
9d9953d94d Merge change 3420 into donut
* changes:
  LocationManagerService: Remove some unneeded imports.
2009-06-07 20:30:45 -07:00
Mike Lockwood
6ba283f726 LocationManagerService: Remove some unneeded imports.
Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-06-07 23:29:25 -04:00
Christopher Tate
8c850b792f Add IRestoreSession interface for the restore flow
Restore is a fairly complicated, somewhat stateful process, so we introduce
a new interface to encapsulate the various bits and pieces into a nicely
separable component.  In particular, this will make it much cleaner to
open and interrogate an expensive-to-construct transport and then reuse it
for the actual restore process itself.
2009-06-07 19:33:20 -07:00
Android (Google) Code Review
4dde34b2f0 am da55569b: Merge change 3417 into donut
Merge commit 'da55569b0aaf98ff4d472d85ae1b038e76e1e9c3'

* commit 'da55569b0aaf98ff4d472d85ae1b038e76e1e9c3':
  Adjust IBackupTransport interface
2009-06-07 14:12:04 -07:00
Christopher Tate
7b88128e08 Adjust IBackupTransport interface
Instead of just passing a package name to performBackup, pass the whole
PackageInfo struct, explicitly including the list of signatures for the package.
No need to make each transport look this up individually when it's a necessary
part of the backup payload for each app.
2009-06-07 13:55:42 -07:00
Android (Google) Code Review
36d3ebb880 am 19cd309f: Merge change 3017 into donut
Merge commit '19cd309f9eccdf8454dc6e5076013588b7a170a3'

* commit '19cd309f9eccdf8454dc6e5076013588b7a170a3':
  Add the EAP related fields for WiFi configuration.
2009-06-05 21:18:02 -07:00