Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1464)

Unified Diff: content/browser/service_worker/service_worker_url_request_job.h

Issue 2448353002: [BlobAsync] Moving async handling into BlobStorageContext & quota out. (Closed)
Patch Set: comments Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/browser/service_worker/service_worker_url_request_job.h
diff --git a/content/browser/service_worker/service_worker_url_request_job.h b/content/browser/service_worker/service_worker_url_request_job.h
index 103e15e873b85f87cd76730c02ba37a2a04f3077..020842dd18f9eef8ec65562731d3a97bf9d15121 100644
--- a/content/browser/service_worker/service_worker_url_request_job.h
+++ b/content/browser/service_worker/service_worker_url_request_job.h
@@ -141,7 +141,7 @@ class CONTENT_EXPORT ServiceWorkerURLRequestJob : public net::URLRequestJob {
base::WeakPtr<ServiceWorkerURLRequestJob> GetWeakPtr();
private:
- class BlobConstructionWaiter;
+ class FileSizeResolver;
enum ResponseType {
NOT_DETERMINED,
@@ -167,7 +167,8 @@ class CONTENT_EXPORT ServiceWorkerURLRequestJob : public net::URLRequestJob {
// Creates BlobDataHandle of the request body from |body_|. This handle
// |request_body_blob_data_handle_| will be deleted when
// ServiceWorkerURLRequestJob is deleted.
- // This must not be called until all blobs in |body_| finished construction.
+ // This must not be called until all files in |body_| with unknown size have
+ // their sizes populated.
void CreateRequestBodyBlob(std::string* blob_uuid, uint64_t* blob_size);
// For FORWARD_TO_SERVICE_WORKER case.
@@ -223,9 +224,9 @@ class CONTENT_EXPORT ServiceWorkerURLRequestJob : public net::URLRequestJob {
bool IsMainResourceLoad() const;
- // For waiting for request body blobs to finish construction.
+ // For waiting for files sizes of request body files with unknown sizes.
bool HasRequestBody();
- void RequestBodyBlobsCompleted(bool success);
+ void RequestBodyFileSizesResolved(bool success);
// Not owned.
Delegate* delegate_;
@@ -277,7 +278,7 @@ class CONTENT_EXPORT ServiceWorkerURLRequestJob : public net::URLRequestJob {
ServiceWorkerHeaderList cors_exposed_header_names_;
- std::unique_ptr<BlobConstructionWaiter> blob_construction_waiter_;
+ std::unique_ptr<FileSizeResolver> file_size_resolver_;
bool worker_already_activated_ = false;
EmbeddedWorkerStatus initial_worker_status_ = EmbeddedWorkerStatus::STOPPED;

Powered by Google App Engine
This is Rietveld 408576698