5 years, 4 months ago
(2015-08-04 10:33:39 UTC)
#8
Hi jkarlin@, can you review this?
jkarlin
This looks good. Just a couple places we could reduce code duplication. https://codereview.chromium.org/1248003004/diff/120001/content/browser/cache_storage/cache_storage_cache.cc File content/browser/cache_storage/cache_storage_cache.cc ...
5 years, 4 months ago
(2015-08-04 13:25:07 UTC)
#9
5 years, 4 months ago
(2015-08-05 08:01:50 UTC)
#10
Patchset #2 (id:140001) has been deleted
nhiroki
Thank you for reviewing. Updated. Can you take another look? https://codereview.chromium.org/1248003004/diff/120001/content/browser/cache_storage/cache_storage_cache.cc File content/browser/cache_storage/cache_storage_cache.cc (right): https://codereview.chromium.org/1248003004/diff/120001/content/browser/cache_storage/cache_storage_cache.cc#newcode624 ...
5 years, 4 months ago
(2015-08-05 08:03:04 UTC)
#11
5 years, 4 months ago
(2015-08-06 03:34:24 UTC)
#13
Patchset #4 (id:200001) has been deleted
nhiroki
Thank you for your comments! Updated. https://codereview.chromium.org/1248003004/diff/180001/content/browser/cache_storage/cache_storage_cache.cc File content/browser/cache_storage/cache_storage_cache.cc (right): https://codereview.chromium.org/1248003004/diff/180001/content/browser/cache_storage/cache_storage_cache.cc#newcode179 content/browser/cache_storage/cache_storage_cache.cc:179: void PopulateServiceWorkerResponse(const CacheMetadata& ...
5 years, 4 months ago
(2015-08-06 03:36:53 UTC)
#14
Thank you for your comments! Updated.
https://codereview.chromium.org/1248003004/diff/180001/content/browser/cache_...
File content/browser/cache_storage/cache_storage_cache.cc (right):
https://codereview.chromium.org/1248003004/diff/180001/content/browser/cache_...
content/browser/cache_storage/cache_storage_cache.cc:179: void
PopulateServiceWorkerResponse(const CacheMetadata& metadata,
On 2015/08/05 12:09:05, jkarlin wrote:
> Perhaps rename to PopularResponseMetadata or
> PopulateServiceWorkerResponseMetadata since it doesn't populate the body.
Good point. Renamed this.
https://codereview.chromium.org/1248003004/diff/180001/content/browser/cache_...
content/browser/cache_storage/cache_storage_cache.cc:205: if (enumerated_entry)
On 2015/08/05 12:09:05, jkarlin wrote:
> Why is this in the for loop now?
Oh..., this is just a mistake. Fixed. Thanks!
https://codereview.chromium.org/1248003004/diff/180001/content/browser/cache_...
content/browser/cache_storage/cache_storage_cache.cc:231:
std::vector<ServiceWorkerResponse> out_responses;
On 2015/08/05 12:09:05, jkarlin wrote:
> scoped_ptr<std::vector<ServiceWorkerResponse>> to prevent copying the
responses?
Done.
https://codereview.chromium.org/1248003004/diff/180001/content/browser/cache_...
content/browser/cache_storage/cache_storage_cache.cc:732: // Create a blob with
the response body data.
On 2015/08/05 12:09:05, jkarlin wrote:
> The block of code below is duplicated from MatchDidReadMetadata. Please merge
> into a function.
Factored out the block into PopulateResponseBody().
https://codereview.chromium.org/1248003004/diff/180001/content/browser/cache_...
File content/browser/cache_storage/cache_storage_cache.h (right):
https://codereview.chromium.org/1248003004/diff/180001/content/browser/cache_...
content/browser/cache_storage/cache_storage_cache.h:52: const
std::vector<ServiceWorkerResponse>&,
On 2015/08/05 12:09:05, jkarlin wrote:
> Let's make this a scoped_ptr<std::vector<ServiceWorkerResponse>> to reduce
> copying the responses. That makes it consistent with Keys as well.
Done.
https://codereview.chromium.org/1248003004/diff/180001/content/browser/cache_...
content/browser/cache_storage/cache_storage_cache.h:74: // Returns
CACHE_STORAGE_OK and all responses in this cache. If there is no
On 2015/08/05 12:09:05, jkarlin wrote:
> s/there is no response/there are no responses/
Done.
https://codereview.chromium.org/1248003004/diff/180001/content/browser/cache_...
File content/browser/cache_storage/cache_storage_cache_unittest.cc (right):
https://codereview.chromium.org/1248003004/diff/180001/content/browser/cache_...
content/browser/cache_storage/cache_storage_cache_unittest.cc:146: if
(actual.blob_uuid.empty())
On 2015/08/05 12:09:05, jkarlin wrote:
> Can you compare the blob contents of the two responses with
> CacheStorageCacheTest::CopyBody here? That would simplify the tests further.
> You'd have to move CacheStorageCacheTest::CopyBody into the unnamed namespace,
> which is better anyway.
Calling CopyBody() here might complicate this function because it requires two
more arguments (expected_body and actual_body_handle). Instead, I renamed this
function to "ResponseMetadataEqual()" and introduced a separate function
"ResponseBodiesEqual()" for comparing the blob contents. How does this look?
jkarlin
lgtm with changes https://codereview.chromium.org/1248003004/diff/220001/content/browser/cache_storage/cache_storage_cache.h File content/browser/cache_storage/cache_storage_cache.h (right): https://codereview.chromium.org/1248003004/diff/220001/content/browser/cache_storage/cache_storage_cache.h#newcode54 content/browser/cache_storage/cache_storage_cache.h:54: ScopedVector<storage::BlobDataHandle>)>; Likewise, please make this a ...
5 years, 4 months ago
(2015-08-06 15:11:13 UTC)
#15
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1248003004/280001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1248003004/280001
5 years, 4 months ago
(2015-08-07 13:12:47 UTC)
#20
Try jobs failed on following builders: mac_chromium_rel_ng on tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_rel_ng/builds/96462)
5 years, 4 months ago
(2015-08-07 14:33:54 UTC)
#22
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1248003004/280001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1248003004/280001
5 years, 4 months ago
(2015-08-07 14:35:26 UTC)
#24
Issue 1248003004: CacheStorage: Implement Cache.matchAll()
(Closed)
Created 5 years, 5 months ago by nhiroki
Modified 5 years, 4 months ago
Reviewers: jkarlin
Base URL: https://chromium.googlesource.com/chromium/src.git@master
Comments: 24