Description[ServiceWorkerCache] Implement storage::QuotaClient
Adds a QuotaClient for the ServiceWorkerCache system.
* Calls to the QuotaManagerProxy like (NotifyStorageAccessed/StorageModified/OriginInUse/etc..) will be in an upcoming CL.
* The ServiceWorkerCacheQuotaClient is registered by the ServiceWorkerCacheStorageManager. The QuotaClient holds a WeakPtr to the ServiceWorkerCacheStorageManager since the manager is destroyed before the QuotaClient.
* Added a number of unittests. They fit better into the StorageManager tests file than in their own file as they rely on a lot of the StorageManager infrastructure.
* In order to support QuotaClient the ServiceWorkerCacheStorageManager needs to be able to list the origins it supports. This data is not currently stored so an "origin" member has been added to the CacheStorage index protobuf. We won't report the origins of existing caches (if any even exist at this point) until their index is next written.
BUG=420159
Committed: https://crrev.com/22fcbd3c898136dfe839de3ca5cb0633c17bb163
Cr-Commit-Position: refs/heads/master@{#300187}
Patch Set 1 #Patch Set 2 : QuotaClientMask #Patch Set 3 : Delete the cache backends #Patch Set 4 : Separated quota client into own file, added unit tests #Patch Set 5 : Rebase #Patch Set 6 : static index file name #Patch Set 7 : Nit #
Total comments: 8
Patch Set 8 : Address comments from PS7 #
Total comments: 4
Patch Set 9 : Rebase #Patch Set 10 : Add comment for the quota client #
Total comments: 2
Patch Set 11 : ServiceWorkerCacheStorageManager no longer ref counted, use weakptr instead #
Total comments: 2
Patch Set 12 : Address comments from PS 10+11 #Messages
Total messages: 20 (5 generated)
|