| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
| |
insert() was trying to be too clever, and it would end up delaying
the media scanner until the next download happened. This resulted
in duplicate photos in DocumentsUI.
Bug: 11081685
Change-Id: Ic9549ede38118372849119dd3a21415a4723e9f5
|
|
|
|
|
| |
Bug: 10943812
Change-Id: Ib0cb3e608c1f40a2e2fcd6e493c8f920d8b4221b
|
|
|
|
|
|
|
|
| |
When deleting downloads, revoke any Uri permission grants, which
removes from getPersistedUriPermissions().
Bug: 10928851
Change-Id: I3e90c4071385832dcb3e0cf9ca3fdccafbe30037
|
|
|
|
|
|
|
|
|
|
|
| |
Add column to mark downloads as being writable, and allow documents
to be created under Downloads backend. Update database when writing
is finished, and generate unique filenames when they already exist.
Check canonical path on incoming _DATA paths.
Bug: 10667164, 10892621, 10893268
Change-Id: I8c203b96ff042a895b58686903fcd07fc755a00f
|
|
|
|
| |
Change-Id: I4839fd07abdd1c6b866f1d94dc36567df047e30c
|
|
|
|
|
|
|
|
|
| |
The lifetime of DownloadService can be limited, and it's often
missing from bugreports. The provider has a much longer lifetime,
so have it dump raw data about recent downloads.
Bug: 7350685
Change-Id: I55c9d602d77014ea27820936f1cf5c8ad24f286a
|
|
|
|
|
|
|
|
| |
Now the final errors are always thrown, and the outer code decides
how to handle them as retries. Also clean up method signatures.
Bug: 8022478
Change-Id: I4e7e43be793294ab837370df521e7c381e0bb6c3
|
|
|
|
|
|
|
| |
Now DownloadService creates and owns the lifecycle of its own
StorageManager instance.
Change-Id: I8f6bedc02f1dbe610a8e6a25d55383a12716d344
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Switch to using new inbox-style notifications when collapsing multiple
downloads. Correctly handles clustering, including cancellation of
stale notifications. All notifications are now handled in a single
class, making it easier to reason about correctness.
Fixed bugs around handling of visibility flags. Move away from using
"int" as internal keys, since they can overflow. Started work for
time estimates, will finish in a future CL.
Explicitly pass all relevant IDs to DownloadReceiver instead of doing
a second racy query. Fix StrictMode warnings when querying in
DownloadReceiver.
Bug: 6777872, 5463678, 6663547, 6967346, 6634261, 5608365
Change-Id: I5eb47b73b90b6250acec2ce5bf8d7a274ed9d3a9
|
|
|
|
|
| |
Bug: 6358473
Change-Id: Ied4a6c8194d0cbb735e43cf7d7759f4674efe535
|
|
|
|
|
|
|
|
|
|
|
|
| |
Include flag with each download to indicate if its allowed to proceed
over metered networks. Downloads are left in WAITING_FOR_NETWORK
state, similar to how ALLOWED_NETWORK_TYPES is handled.
Also keep blocked downloads in WAITING_FOR_NETWORK state instead
of marking them as failed.
Bug: 3001465, 5734560
Change-Id: I80bb9aa9bd25ddf6f7a2472db344b6ba6878bd74
|
|
|
|
|
|
|
|
|
| |
When viewing file://-style downloads, open through DownloadsProvider
so that FLAG_GRANT_READ_URI_PERMISSION works. Add support for
OpenableColumns to support external apps probing for metadata.
Bug: 6343461
Change-Id: I630405406321ea1871c62cbcded55a4ee024ef6e
|
|
|
|
|
| |
Bug: 5606426
Change-Id: I9b9cee142c360da2a30a4bb8be8dcf40b8c7e43e
|
|
|
|
|
| |
Bug: 5449870
Change-Id: I3219273be9b796b123545c811e5f39fa83b5768e
|
|
|
|
|
|
| |
Bug: 5010576
Change-Id: I2f9bcad41cf50ed0b17dd487d0389f7b38500fd7
|
|
|
|
|
|
|
|
| |
Updates list of allowed visibility values to enable Request builders
to use Request.VISIBILITY_VISIBLE_NOTIFY_COMPLETED.
Bug: 4283223
Change-Id: I8ebe4a13f95a58f25f6025946a6d4725261717f2
|
|
|
|
| |
Change-Id: I6192a829c7cac86c55a0f67364ebd722504d5dc7
|
|
|
|
| |
Change-Id: I9f9f6f2e0b2bd18f3767574fc51301b75bb1b76d
|
|\
| |
| |
| |
| |
| |
| | |
don\'t check mobile download limits"
* commit '6e9abd8e04c4aaafb8493a25efc34f4dd4fa6013':
Revert "bug:3414192 if otaupdate column is set, don't check mobile download limits"
|
| |
| |
| |
| |
| |
| | |
limits"
This reverts commit ea245800c69d6bc10dc2680e6a242f59e9cb49b6.
|
|\|
| |
| |
| |
| |
| |
| | |
flag set, validate caller\'s perms" into honeycomb"
* commit '49663f1ffe58a546fb0d2ab84898843ef5e89eb5':
Revert "Merge "bug:3341145 if ignore_size_limits flag set, validate caller's perms" into honeycomb"
|
| |
| |
| |
| |
| |
| |
| | |
perms" into honeycomb"
This reverts commit 3e7bb1c5d7e7d1a013df959c1a6947b33df0a0fd, reversing
changes made to b2085f61b37ad4a70c799012f25ff62a38173f68.
|
|\|
| |
| |
| |
| | |
* commit 'afefa43d9919f9284885f7080111c54a50c4fc90':
Revert "bug:3420722"
|
| |
| |
| |
| | |
This reverts commit 1cccc19b596f168ed34126db38b046ab164e063b.
|
|\|
| |
| |
| | |
Change-Id: I477599f16db5ea64e4fbc4d2be68dcedf2c80269
|
| |
| |
| |
| | |
Change-Id: Id40d2dbbefe5fa2546f8c5231be5f7fe9a7b43d6
|
|\|
| |
| |
| | |
Change-Id: I27a615509269f256cf66de2dd217d8c4667caab4
|
| |
| |
| |
| |
| |
| | |
and then of course ignore the mobile network size limits
Change-Id: I6765be9255187f93bd51acecc19a15db4f324204
|
| |
| |
| |
| |
| |
| |
| | |
Prevents null pointer exception when using
DownloadManager.completedDownload
Change-Id: I53859705c5e925f2320491451e41a631e4fed715
|
|\|
| |
| |
| |
| |
| |
| | |
check mobile download limits
* commit '8db8fba215a981edd24ad1f7118d3397be0114d2':
bug:3414192 if otaupdate column is set, don't check mobile download limits
|
| |
| |
| |
| |
| |
| |
| | |
this allows OTA update to work without being subject to download limits
on mobile networks.
Change-Id: I92c60ba3ecbde615bd93778b391a5fe067dbd2fe
|
|/
|
|
| |
Change-Id: Ib9d4df107787191a5349365908cbe096b67770dc
|
|
|
|
|
|
|
|
|
|
| |
make sure the doanloads data dir size is limited by some quote -
100MB default and 200MB for SR.
bug:3286430
tests are in Change-Id: I688f7e058511089bec7fa21e972e23780604d98a
Change-Id: Iba7fab9fa91ea018f35e1c3ef5ec0e6b03cba650
|
|
|
|
|
|
|
|
|
|
| |
bug:3264401
still to do:
make sure only N bytes are taken up by downloads dir
N = a value specific to each device.
default = 100MB.
Change-Id: I2a49f4b3831d3a8d7be13b5fd46d85d56e831e38
|
|\
| |
| |
| |
| |
| |
| | |
ACCESS_ALL_DOWNLOADS
* commit '5c29cce0bac00a7a32cd92210825a789e140cf94':
Don't filter by UID for apps with ACCESS_ALL_DOWNLOADS
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Old platform behavior of DownloadProvider would allow anyone with
special access to access all the downloads. New behavior is to return
/my_downloads/ on an .insert() call. For things that aren't using the
new API where DownloadInfo.getAllDownloadsUri() is accessible, make any
application with ACCESS_ALL_DOWNLOADS permission bypass the calling UID
check for /my_downloads/
Bug: 3242328
Change-Id: I536fde4525dd74066879f7c7da7fa609ff344645
|
| |
| |
| |
| | |
Change-Id: I8940778292d0a9166cfcfb92d37ea568b8f6ceef
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
useful for debugging for bugs like bug:3187299
without this error message, one doesn't know WHY downloads
fail.
to prevent PII info in database,
there is a STOPSHIP comment around storage of this error
message in database.
Change-Id: I612e383aef8483b68b772f70dff722a5daea2ef5
|
| |
| |
| |
| | |
Change-Id: I96f0b51295611b67735c1b726bcd46bbeaa90613
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
1. if an application designates a downloaded file to be mediascanner
scannable or not, store that fact in database.
2. use the above to determine whether a file shoudl be mediascanned or not
in DownloadService
3. implement code to return mimetype for the new Uri "/public_downloads"
introduced in CL: I1f5dd734e394db0056579a3a0c26862fee27981e
Change-Id: I5c062ad6d1b58306044cee49ff3827e908d27fd9
|
| |
| |
| |
| | |
Change-Id: I2edf1bef5e741de8193cb293807e3ace42003b0c
|
|\|
| |
| |
| |
| |
| |
| | |
Merge commit '3e759e21291d6ca1a49ded3f24f3be0a26af4e2b'
* commit '3e759e21291d6ca1a49ded3f24f3be0a26af4e2b':
fix broken build bug:3095237
|
| |
| |
| |
| | |
Change-Id: I7e1fe99cc482fc270894a820049275fc0c64233e
|
|\|
| |
| |
| |
| |
| |
| |
| |
| | |
correctly
Merge commit '57c4e9180e3a339dba984f1c8dff76ef18443a7a'
* commit '57c4e9180e3a339dba984f1c8dff76ef18443a7a':
bug:3069735 in Download UI app, handle deletes correctly
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
gingerbread.
High-level details
1. When a file is downloaded by DownloadManager, metadata about the file
is stored in 2 databases: DownloadProvider and MediaProvider.
2. So, when it is to be deleted, its metadata needs to be cleaned up from
both the databases.
3. But the 2 databases use differnt content-uri's as "primary keys" and
DownloadProvider loses the "primary-key" of the row in MediaProvider
database.
4. Easiest thing would have been to have DownloadProvider give filepath
to MediaProvider and let MediaProvider linearly scan its database
to locate the row and delete it.
5. The other - faster but more coding for now - option is to have
DownloadProvider store the "primary-key" of the MediaProvider's
row. implemented in this CL.
Low-level details
1. add 2 new columns to downloads table in downloads.db:
mediaprovider_uri = downloaded file's content_uri in mediaprovider db
this column is null for downloads that finished before this column is
added to the database.
deleted = flag is set to true if a file is to be deleted
2. download UI app shows only those files whose 'deleted' flag is not set.
3. when the user deletes downloads from download UI app,
3.1. if mediaprovider_uri is NOT null, then the row is deleted from
downloads table AND from the mediaprovider database.
3.2 if mediaprovider_uri is NULL, then its row in downloads database
is marked 'tp be deleted' by setting 'deleted' column to '1'.
4. When DownloadService (in DownloadProvider) processes all rows from
downloads table, if it sees any rows wth 'deleted' = 1, then
it uses MediaScanner Service to re-scan the file,
get the mediaprovider_uri from MediaProvider
and update the row in downloads table with this mediaprovider_uri value
and then delete the row by doing the following
1. delete it from MediaProvider database using mediaprovider_uri
2. delete it from DownloadProvider database
Problem with this solution:
There is a small window where it is deleted by the user on the Download app
(and the row disappears from the display) but it is still present in
Gallery app.
Thats due to the following asynchronous operations
1. DownladService which processes rows-to-be-deleted is not always up
2. DownloadService uses asynchronous call to have the file re-scanned
by MediaScanner to get mediaprovider_uri
Change-Id: Ib90eb9e647f543312c865d3bbf9a06fb867a648b
|
|\|
| |
| |
| |
| |
| |
| |
| |
| | |
queries." into gingerbread
Merge commit '1f262cf3af0512e0d621b7818aab9bb79527f01f'
* commit '1f262cf3af0512e0d621b7818aab9bb79527f01f':
Make DownloadProvider use parameterized queries.
|
| |
| |
| |
| |
| |
| |
| |
| | |
This avoids filling up the query cache unnecessary, but required some
structural changes to ease the passing around of a selection along
with its arguments.
Change-Id: I724185763b94146d17573cab68f675c24e49634e
|
|\|
| |
| |
| |
| |
| |
| | |
Merge commit '42469fa405c7aa891e7c431cd65edd424803979c'
* commit '42469fa405c7aa891e7c431cd65edd424803979c':
Avoid NPE when checking file URI in DownloadProvider
|
| |
| |
| |
| | |
Change-Id: Ic937b05308cecce244725e25767a3a1310a8463d
|
|\|
| |
| |
| |
| |
| |
| |
| |
| | |
in old downloads" into gingerbread
Merge commit '04d7025262d7f6c5c372ec699d78b18d05b0400b'
* commit '04d7025262d7f6c5c372ec699d78b18d05b0400b':
DB migration to eliminate some null fields in old downloads
|