New issue
Advanced search Search tips

Issue 740740 link

Starred by 3 users

Issue metadata

Status: Fixed
Owner:
Closed: Oct 2017
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug
Proj-Servicification

Blocking:
issue 611935
issue 749275



Sign in to add a comment

[mojo-blobs] Add API to mojo Blob interface to read data from the Blob

Project Member Reported by mek@chromium.org, Jul 10 2017

Issue description

This new API should ultimately replace BlobReader and form the basis of BlobURLRequestJob (and its servicified replacement).

API would probably look something like:

interface Blob {
 // [...]

  ReadAll(handle<data_pipe_producer> pipe) => (BlobReadResult);
  Read(uint64 offset, uint64 length, handle<data_pipe_producer> pipe) => (BlobReadResult);
  ReadSideData() => (array<uint8> side_data);
};


Exact details TBD, and to figure out as other parts of the system (FileReader, but also internal users such as CacheStorage::Put) are migrated over.

 

Comment 1 by mek@chromium.org, Jul 26 2017

Status: Started (was: Available)

Comment 2 by mek@chromium.org, Jul 26 2017

Blocking: 749275
Project Member

Comment 3 by bugdroid1@chromium.org, Aug 12 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9

commit 9c36621a58bd944d46e5ddcc8303c13ec92d0ff9
Author: Marijn Kruisselbrink <mek@chromium.org>
Date: Sat Aug 12 03:36:22 2017

Add ReadAll/ReadRange methods to Blob mojo interface.

Follow up patches will change the FileReader/FileReaderSync web APIs
to use these methods to read blobs (avoiding the need to create blob
URLs), and blob consumers in the browser process (such as
CacheStorageBlobToDiskCache) should also ultimately be updated to use
this interface to stream data from blobs.

In this CL BlobURLLoader is modified to share most of the implementation
of reading a blob into a datastream. In the future it might make sense
for BlobURLLoader to just wrap the the Blob.ReadRange mojo interface
method directly instead.

Bug:  740740 
Change-Id: Idf6c13420e9cfad548c94f5eca0d4c7ab7b4405e
Reviewed-on: https://chromium-review.googlesource.com/576628
Commit-Queue: Marijn Kruisselbrink <mek@chromium.org>
Reviewed-by: Daniel Cheng <dcheng@chromium.org>
Reviewed-by: John Abd-El-Malek <jam@chromium.org>
Reviewed-by: Daniel Murphy <dmurph@chromium.org>
Cr-Commit-Position: refs/heads/master@{#493951}
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/content/browser/BUILD.gn
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/content/browser/appcache/appcache_update_url_loader_request.cc
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/content/browser/appcache/appcache_update_url_loader_request.h
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/content/browser/appcache/appcache_url_loader_job.cc
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/content/browser/appcache/appcache_url_loader_job.h
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/content/browser/blob_storage/blob_url_loader_factory.cc
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/content/browser/service_worker/service_worker_installed_scripts_sender.cc
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/content/common/BUILD.gn
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/content/network/BUILD.gn
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/content/network/DEPS
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/content/network/url_loader_impl.cc
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/content/network/url_loader_impl.h
[add] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/services/network/DEPS
[add] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/services/network/public/cpp/BUILD.gn
[rename] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/services/network/public/cpp/net_adapters.cc
[rename] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/services/network/public/cpp/net_adapters.h
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/storage/DEPS
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/storage/browser/BUILD.gn
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/storage/browser/blob/blob_impl.cc
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/storage/browser/blob/blob_impl.h
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/storage/browser/blob/blob_impl_unittest.cc
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/storage/browser/blob/blob_registry_impl_unittest.cc
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/storage/browser/blob/blob_url_request_job.cc
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/storage/browser/blob/blob_url_request_job.h
[add] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/storage/browser/blob/mojo_blob_reader.cc
[add] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/storage/browser/blob/mojo_blob_reader.h
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/storage/public/interfaces/blobs.mojom
[modify] https://crrev.com/9c36621a58bd944d46e5ddcc8303c13ec92d0ff9/third_party/WebKit/Source/platform/blob/BlobDataTest.cpp

Comment 4 by mek@chromium.org, Oct 12 2017

Status: Fixed (was: Started)

Comment 5 by laforge@google.com, Nov 7 2017

Components: Internals>Network>Service

Comment 6 by laforge@google.com, Nov 7 2017

Components: -Internals>Network>Service Internals>Services>Network
Apologies, applied the wrong component in bulk.

Comment 7 by laforge@google.com, Nov 8 2017

Components: Internals>Services>Storage
Setting Internals>Services>Storage to all children of issue 611935

Sign in to add a comment