Project: chromium Issues People Development process History Sign in
New issue
Advanced search Search tips
Issue 108012 IndexedDB should support storing File/Blob objects
Starred by 89 users Project Member Reported by ericbidelman@chromium.org, Dec 19, 2011 Back to list
Status: Fixed
Owner: ericu@chromium.org
Closed: Jun 2014
Cc: arthurhsu@chromium.org, jianli@chromium.org, wiltzius@chromium.org, ericu@chromium.org, jsb...@chromium.org, mlamouri@chromium.org, michaeln@chromium.org, dgro...@chromium.org
Components:
OS: ----
Pri: 2
Type: Bug


Sign in to add a comment
FF has this implemented:
https://bugzilla.mozilla.org/show_bug.cgi?id=661877

I'm currently seeing Mac, 18.0.974.0 canary crash when trying to .put() a File.
 
Comment 1 by jsb...@chromium.org, Dec 20, 2011
I started on a WebKit layout test for this:

https://bugs.webkit.org/show_bug.cgi?id=74897

So far it covers:

* primitive values: Undefined, Null, Boolean, Number, String
* Boolean Objects
* Number Objects
* String Objects
* Date Objects
* RegExp Objects
* ImageData Objects
* Blob Objects
* Array Objects
* Object Objects

Still TODO:
* File (i.e. this bug)
* FileList
* Failure cases (other JS objects and host objects) that should throw DATA_CLONE_ERROR
* Nested values

So far the only error I've found is -0 as a primitive value (oddly, new Number(-0) round trips just fine!), but obviously I haven't poked at File yet.

Comment 2 by jsb...@chromium.org, Dec 20, 2011
File via the FileSystem API appears to be working correctly, except that the name property becomes all zeros (!). 

ericbidelman@ - I don't suppose you have a repro handy?
Sure. Attached has code that's compatible with FF (though not currently working in their nightlies),
but repos fine in WebKit. It crashes Chrome for me.

Again: Mac OSX, 10.6.8 17.0.963.12 dev
indexeddb_save_file.html
5.6 KB View Download
Comment 4 by jsb...@chromium.org, Dec 20, 2011
I repro with that test on Linux under chrome, here's the stack:

[4138:4154:524139600550:FATAL:utility_process_host.cc(54)] Check failed: !is_batch_mode_. 
Backtrace:
	base::debug::StackTrace::StackTrace() [0x7f422a6be986]
	logging::LogMessage::~LogMessage() [0x7f422a641e60]
	UtilityProcessHost::~UtilityProcessHost() [0x7f422a2a9810]
	BrowserChildProcessHost::OnChildDisconnected() [0x7f422a132e95]
	base::internal::RunnableAdapter<>::Run() [0x7f422a134ed9]
	base::internal::InvokeHelper<>::MakeItSo() [0x7f422a134cfb]
	base::internal::Invoker<>::Run() [0x7f422a134896]
	base::Callback<>::Run() [0x7f422a00657b]
	MessageLoop::RunTask() [0x7f422a647709]
	MessageLoop::DeferOrRunPendingTask() [0x7f422a647823]
	MessageLoop::DoDelayedWork() [0x7f422a64825b]
	base::MessagePumpLibevent::Run() [0x7f422a604af6]
	MessageLoop::RunInternal() [0x7f422a647361]
	MessageLoop::RunHandler() [0x7f422a647214]
	MessageLoop::Run() [0x7f422a646b27]
	base::Thread::Run() [0x7f422a69a9ca]
	base::Thread::ThreadMain() [0x7f422a69ab4a]
	base::(anonymous namespace)::ThreadFunc() [0x7f422a694d53]
	start_thread [0x7f4224b089ca]
	0x7f4221eed70d

Comment 5 by jsb...@chromium.org, Dec 20, 2011
The important bit in the repro is that the object store has a keyPath and that the data being put contains a File. This triggers the crash regardless of whether autoIncrement is set or whether the path resolves to anything in the data being put.
Comment 6 Deleted
Comment 7 by jsb...@chromium.org, Dec 20, 2011
Looks like the crash in ~UtilityProcessHost is because the utility process is crashing; this leads to the non-clean child disconnect, and the KeyUtilityClient impl doesn't get a change to call EndBatchMode().
Comment 8 by jsb...@chromium.org, Dec 20, 2011
The utility process crash is a segfault with this at the top of the stack:


#0  0x00007fc3b3212321 in v8::Object::GetPointerFromInternalField (this=0x0, index=1) at ../../v8/src/../include/v8.h:4057
#1  0x00007fc3b547c03f in WebCore::V8WorkerContext::toNative (object=...) at gen/webkit/bindings/V8WorkerContext.h:43
#2  0x00007fc3b574c891 in WebCore::V8DOMWrapper::instantiateV8Object (proxy=0x0, type=0x7fc3b9927e20, impl=0x7fc3b1912c00) at ../../third_party/WebKit/Source/WebCore/bindings/v8/V8DOMWrapper.cpp:223
#3  0x00007fc3b5344f42 in WebCore::V8File::wrapSlow (impl=0x7fc3b1912c00) at gen/webcore/bindings/V8File.cpp:144
#4  0x00007fc3b544b87b in WebCore::V8File::wrap (impl=0x7fc3b1912c00) at gen/webkit/bindings/V8File.h:64
#5  0x00007fc3b544b8b9 in WebCore::toV8 (impl=0x7fc3b1912c00) at gen/webkit/bindings/V8File.h:71
#6  0x00007fc3b556ee88 in WebCore::toV8 (impl=...) at gen/webkit/bindings/V8File.h:75
#7  0x00007fc3b573935d in WebCore::(anonymous namespace)::Reader::readFile (this=0x7fff535eac80, value=0x7fff535eab10) at ../../third_party/WebKit/Source/WebCore/bindings/v8/SerializedScriptValue.cpp:1725
#8  0x00007fc3b57379dd in WebCore::(anonymous namespace)::Reader::read (this=0x7fff535eac80, value=0x7fff535eab10, creator=...) at ../../third_party/WebKit/Source/WebCore/bindings/v8/SerializedScriptValue.cpp:1305
#9  0x00007fc3b573a293 in WebCore::(anonymous namespace)::Deserializer::doDeserialize (this=0x7fff535eabf0) at ../../third_party/WebKit/Source/WebCore/bindings/v8/SerializedScriptValue.cpp:1995
#10 0x00007fc3b5739856 in WebCore::(anonymous namespace)::Deserializer::deserialize (this=0x7fff535eabf0) at ../../third_party/WebKit/Source/WebCore/bindings/v8/SerializedScriptValue.cpp:1815
#11 0x00007fc3b573ba5d in WebCore::SerializedScriptValue::deserialize (this=0x7fc3b1945060, messagePorts=0x0) at ../../third_party/WebKit/Source/WebCore/bindings/v8/SerializedScriptValue.cpp:2242
#12 0x00007fc3b571d580 in WebCore::createIDBKeyFromSerializedValueAndKeyPath (value=..., keyPath=...) at ../../third_party/WebKit/Source/WebCore/bindings/v8/IDBBindingUtilities.cpp:133
#13 0x00007fc3b4b0824e in WebKit::WebIDBKey::createFromValueAndKeyPath (serializedScriptValue=..., idbKeyPath=...) at ../../third_party/WebKit/Source/WebKit/chromium/src/WebIDBKey.cpp:83
#14 0x00007fc3b52d186e in webkit_glue::IDBKeysFromValuesAndKeyPath (serialized_script_values=std::vector of length 1, capacity 1 = {...}, idb_key_path=..., values=0x7fff535eae90) at ../../webkit/glue/idb_bindings.cc:37

Comment 9 by jsb...@chromium.org, Dec 20, 2011
Tracing through, everything seems ducky until the V8WorkerContext::toNative call. This might be new.
Comment 10 by jsb...@chromium.org, Jan 20, 2012
I think the bug is in V8DOMWrapper::instantiateV8Object - the code reads:

if (isWrapperOfType(globalPrototype, &V8DOMWindow::info)) {
  // it's a normal DOM window global
} else {
  // must be a worker
}

The else clause's assumption is invalid for utility processes. 
Comment 11 by jsb...@chromium.org, Jan 20, 2012
With this patch in place:

diff --git a/Source/WebCore/bindings/v8/V8DOMWrapper.cpp b/Source/WebCore/bindings/v8/V8DOMWrapper.cpp
index 0b757ca..2e68bab 100644
--- a/Source/WebCore/bindings/v8/V8DOMWrapper.cpp
+++ b/Source/WebCore/bindings/v8/V8DOMWrapper.cpp
@@ -222,8 +222,9 @@ v8::Local<v8::Object> V8DOMWrapper::instantiateV8Object(V8Proxy* proxy, WrapperT
                     proxy = V8Proxy::retrieve(frame);
             }
 #if ENABLE(WORKERS)
-            else
+            else if (isWrapperOfType(globalPrototype, &V8WorkerContext::info)) {
                 workerContext = V8WorkerContext::toNative(lookupDOMWrapper(V8WorkerContext::GetTemplate(), context->Global()));
+            }
 #endif
         }


... Chromium fails a DCHECK in webkit/blob/blob_storage_controller.cc:137, in BlobStorageController::CloneBlob:

BlobData* blob_data = GetBlobDataFromUrl(src_url);
DCHECK(blob_data);


[27193:27209:76966562271:FATAL:blob_storage_controller.cc(137)] Check failed: blob_data. 
Backtrace:
	base::debug::StackTrace::StackTrace() [0x7f9c6be87f7e]
	logging::LogMessage::~LogMessage() [0x7f9c6beb2f20]
	webkit_blob::BlobStorageController::CloneBlob() [0x7f9c6dc93f09]
	BlobMessageFilter::OnCloneBlob() [0x7f9c6c956d80]
	DispatchToMethod<>() [0x7f9c6c957a6b]
	BlobHostMsg_CloneBlob::Dispatch<>() [0x7f9c6c9575d9]
	BlobMessageFilter::OnMessageReceived() [0x7f9c6c9566ea]
	content::BrowserMessageFilter::DispatchMessage() [0x7f9c6c701d17]
	content::BrowserMessageFilter::OnMessageReceived() [0x7f9c6c701bb4]
	IPC::ChannelProxy::Context::TryFilters() [0x7f9c6bb8f8ff]
	IPC::ChannelProxy::Context::OnMessageReceived() [0x7f9c6bb8f983]
	IPC::Channel::ChannelImpl::ProcessIncomingMessages() [0x7f9c6bb8a2bd]
	IPC::Channel::ChannelImpl::OnFileCanReadWithoutBlocking() [0x7f9c6bb8c185]
	base::MessagePumpLibevent::FileDescriptorWatcher::OnFileCanReadWithoutBlocking() [0x7f9c6be74268]
	base::MessagePumpLibevent::OnLibeventNotification() [0x7f9c6be7623b]
	event_process_active [0x7f9c6e4e1779]
	event_base_loop [0x7f9c6e4e1aa8]
	base::MessagePumpLibevent::Run() [0x7f9c6be75a19]
	MessageLoop::RunInternal() [0x7f9c6beb7ba3]
	MessageLoop::RunHandler() [0x7f9c6beb7a56]
	MessageLoop::Run() [0x7f9c6beb738b]
	base::Thread::Run() [0x7f9c6bf0424e]
	base::Thread::ThreadMain() [0x7f9c6bf043ce]
	base::(anonymous namespace)::ThreadFunc() [0x7f9c6befa9cf]
	start_thread [0x7f9c6578d9ca]
	0x7f9c6296670d

Trace/breakpoint trap

Comment 12 by jsb...@chromium.org, Jan 20, 2012
... and the data actually makes it into object store; the above crash occurs when running a cursor over an object store containing the data. 
Comment 13 by jsb...@chromium.org, Jan 20, 2012
Tracing through, in one instance I'm seeing the clone trying to get the data for blob blob:blobinternal%3A%2F%2F/cd58f310-4b12-4fe1-ac5f-065435a8c119 but the map only contains data for blob:blobinternal%3A%2F%2F/a8b2b0cb-a26e-4848-bb6d-515f336f6c59

Perhaps that's meaningful to someone.
Comment 14 by jsb...@chromium.org, Jan 25, 2012
I talked with EricU - the current V8 SSV support is purely intended for passing messages between process about the blobs, not the blobs themselves, so only the blob URL is serialized.

IDB will require serializing the Blob/File/FileList data.

For now we should fail an IDB store if there are Blob/File/FileList objects
Status: Available
Comment 16 by jsb...@chromium.org, Mar 19, 2012
Labels: WebKit-ID-76746
Now that http://webkit.org/b/76746 has landed, Chromium's IDB implementation will now reject values with Blob/File/FileList members (DATA_CLONE_ERR) rather than giving an "Aw Snap!"

This is temporary until we have full support for serializing/deserializing blobs.

Project Member Comment 17 by bugdroid1@chromium.org, Mar 19, 2012
Labels: -WebKit-ID-76746 WebKit-ID-76746-RESOLVED WebKit-Rev-111044
https://bugs.webkit.org/show_bug.cgi?id=76746
http://trac.webkit.org/changeset/111044
Blocking: 121974
Comment 19 by kareng@google.com, Apr 12, 2012
Owner: jsb...@chromium.org
Status: Assigned
Comment 20 by jsb...@chromium.org, Apr 24, 2012
Cc: ericu@chromium.org
Cc: michaeln@chromium.org
Comment 22 by jsb...@chromium.org, May 23, 2012
Owner: ericu@chromium.org
Comment 23 by dim...@chromium.org, Jun 13, 2012
Cc: jianli@chromium.org
We hit this trying to build an offline app. We pull avatar images using XHR (as blobs) then mint URLs for those blobs and set it to img.src. To have an offline app, we want to store those in IDB. 

Eric, what's your prognosis? 
Comment 24 Deleted
Comment 25 by ericu@chromium.org, Jun 13, 2012
We're meeting tomorrow to talk about the next steps for IDB, including this feature.
Comment 26 by jsb...@chromium.org, Jun 22, 2012
Blocking: chromium:92049
any update? when will this fix be released? currently I have to use firefox because of this bug and firefox has implemented this. however firefox has no solution to suggest a file name when download a blob url. I can use Downloadify, but the performance of converting a big blob to a data url is really bad.

thanks.
Danny
Unfortunately, we are not actively working on a fix for this right now - we do want to add blob support, but we don't have the resources to work on this at least for a month or so. We will do our best to update this bug as this changes.
Comment 29 by jsb...@chromium.org, Aug 30, 2012
Attached is a sample feature detection script for blob support. It creates a temporary IndexedDB database and attempts to store a blob, noting success or failure.

Web Applications that require Blob storage support could use this script to confirm support, or fall back to an alternate mechanism if not supported.

blobtest.html
873 bytes View Download
Comment 30 by pira...@gmail.com, Sep 21, 2012
There's any progress with this issue? At least on any nightly or personal branch that i would be able to download and compile (i'm using Ubuntu, if that's matters)?
Comment 31 by laforge@google.com, Oct 17, 2012
Labels: -Feature-IndexedDB WebKit-Storage-IndexedDB
Now let’s see if I cannot motivate you why this would be a great addition. 
 
I workin in a R&D firm on BigData. CouchDB and other NoSQL are ideal for storing the loosely structured mix of imagery, video, meta-info , signals data, etc.  Mobile users (laptops, tablets, phones) need to grab snippets of this and work offline for periods, and then re-connect. I need something for NoSQL on the client side.
 
Think of massive multiplayer outdoor collaboration gaming, where the game database is stored on the cloud and people are constantly connecting and disconnecting.  The CouchDB central store is where all the loosely collected imagery, audio, and derived meta-information  (JSON objects )is collected and processed.

So when you do add it, can you make sure it also works for Chrome for Android?

We don't need any motivation, Blob support has just been below other work in the priority queue. It's bubbling it's way slowly to the top, closer all the time. Supporting it on Android is important too. Hopefully we'll have news soon.
Comment 34 by pira...@gmail.com, Jan 3, 2013
Could you be able to give a (orientative) release? v26? Maybe v27? After v27?
Good to know you are motivated, I have the flexibility to wait. But I do see comments here about serializing/deserializing the blob. I don't know if FireFox is doing that, but if at all possible, I would rather see native binary storage if possible. I am talking about blobs in the 10KB size range, but I would have several hundred, and I need very fast retrieval. Otherwise, I will do a polyfill that uses FileSystemAPI. (Perhaps you can do the same, and store blobs in a hidden directory there?)
In case I was not clear, I meant store a reference in the IDB entry, with metadata and a pointer to the FileSystem binary blob. (Just one possible way to do this).
Comment 37 by pira...@gmail.com, Jan 3, 2013
I would be very interested in your polyfill, since I need to work with several megabytes files with access and modification of chunks and using the FileSystem API to fix IndexedDB would be great. Currently I'm using an on-memory IndexedDB implementation and modifying full blobs just to circunvent temporaly this issue and don't have the files stored it's fairly user unfriendly... I didn't be able to figure out how to create a polyfill to add support for File and Blob objects using FileSystem API (I thought about it some months ago), but if you have some idea and needs help or testing don't doubt in call me :-)

By the way, here is my project: http:// github.com/piranna/ShareIt (I'm using IndexedDB for cache since it's available both for Firefox and Chrome, but first versions were using FileSystem API).
I made the opposite polyfill, idb.filesystem.js (http://ericbidelman.tumblr.com/post/21649963613/idb-filesystem-js-bringing-the-html5-filesystem-api) as a polyfill for the FS API. It uses IDB under the hood for FF and other implementations that support saving Blobs to IDB. You could try 
Comment 39 by pira...@gmail.com, Jan 3, 2013
I did, indeed :-D Also I improved your FileWriter class adding seek() and random write() according to specification that I have been using sucesfully the last months. You have a pull-request with the changes on GitHub :-)
I must have missed that. I'll take a look. Thanks!
Thank You greatly. BTW: It does not seem to work on IE10, although I did get the image blob demo @ https://hacks.mozilla.org/2012/02/storing-images-and-files-in-indexeddb/ to work.
Comment 42 by cos...@gmail.com, Jan 10, 2013
I've been able to work around this bug as follows:

* when writing a Blob, surround it with a try ... catch; in the catch, instantiate a FileReader, readAsBinaryString, store the string
* when reading something that should be a blob, check if typeof value === "string"; if so, return new Blob([value], {type: 'application/octet-stream'}); otherwise return the value, which should be a Blob

This mostly allows me to pretend that Chrome's IndexedDB supports Blobs. It crashed when I gave it a 200Mb movie, but worked like a charm for a ~20Mb movie. So this should do the trick for photos and music.

I hope this helps, and I'm looking forward to a proper fix!
Comment 43 by pira...@gmail.com, Jan 10, 2013
It's a good trick, unluckily it only would work for Blob objects and not
File objects (at least on Firefox they are in fact references to real files
on the computer filesystem), but up to some extend it would be useful :-)
Could you be able to do a polyfill with it? Maybe it would be improved to
store Files on a FileSystem API...

[semi-OffTopic]
By the way, I did some experiments in Chromium using an input element to
get a file from my computer filesystem, later I moved it and the File
object then was shown as a zero-sized file with unknown modification date,
but later moved back to the original position and the File object returned
to show the correct values, so a File object in fact is a reference to the
real file... Maybe this would be useful...
Comment 44 by cos...@gmail.com, Jan 10, 2013
@piranna: Blob support is sufficient for caching data. If you have a file, you can read it into an ArrayBuffer and make a Blob out of that, then store the Blob :D

Also, I was a bit wrong above. Building a Blob out of a binary string requires going through an Uint8Array. (set byte i to string.charCodeAt(i) & 0xff, for i in 0...string.length)

Comment 45 by pira...@gmail.com, Jan 10, 2013
I'm using it just this way to cache downloading content... :-D



copy... :-/
Comment 46 by ygutfre...@gmail.com, Jan 11, 2013
For my app, "Building a Blob out of a binary string requires going through an Uint8Array" seems a bit slow and kludgy. What about the idea of writing the blob to unique place in the FileSystem (/blobstore/key ), and then storing the reference in the objectStore in the format {blob-key: xxx, path: xxxx } 
Comment 47 by pira...@gmail.com, Jan 11, 2013
I found this way better... In fact Firefox do it this way, Blob and
Javascript-generated File objects inserted on IndexedDB are stored directly
on the underlying computer filesystem (or at least I read that...).

How could be done a polyfill for this? Override the ObjectStore methods and
inspect each object attribute to detect when one of them is a Blob object?
Yes that`s right in Firefox blobs are stored in the filesystem and you can even go there and open them.
So i was able to download a movie to the IndexedDB as a blob and then in the filesystem open it with VLC.
BTW the same thing works in IE10.
Comment 49 by pira...@gmail.com, Jan 11, 2013
So it would be great to do a polyfill for this... At least I would have
persistence and don't need to use my in-memory implementation... :-P

Sent from my Android cell phone, please forgive the lack of format on the
text, and my fat thumbs :-P
El 11/01/2013 08:46, <chromium@googlecode.com> escribi
This is just a FYI. Perhaps it will help in your design.

I did a polyfill to store the results in the FileSystem. See below for the full results. But to summarize. It works. But performance is best in IE, which stores the results in the DB. FireFox is very poor. BTW, when I increase the number of files to 6,760 (220MB). I start getting all sorts of xhr error code: 0 errors, and it does not fetch all the PNG files (even though they are there). IE10 works fine with 220MB of files, and finishes in 15s! Superb.

Results Offline blob cache for PNG slippy maps

Testing

    171 PNG files (total of 3.2MB)
    Platforms tested: Chrome v24, FireFox 18, IE 10
    Should also work with Chrome & FF for Android

Fetch from web server

    using XHR2 (supported on almost all browsers) for blob download from web server
    I went with XHR2-Lib by Phil Parsons, which is very much like JQUERY .ajax()
        https://github.com/p-m-p/xhr2-lib

Storage

    IndexedDB for IE and FireFox
    Chrome: Polyfill (blob stored using FileSystem API, reference kept in IndexedDB) polyfill
    A Must read article on "How the browsers store IndexedDB data"
        http://www.aaron-powell.com/web/indexeddb-storage
    Note: FireFox uses SQLlite for the NOSQL IndexedDB. That might be the reason for the slow performance. (blobs stored separately)
    Note: Microsoft IE uses the extensible storage engine:
        http://en.wikipedia.org/wiki/Extensible_Storage_Engine
    Note: Chrome uses LevelDB http://code.google.com/p/leveldb/

Display

    I am using Leaflet http://leafletjs.com/ to show the map tiles
    I used the functional tile layer plugin by Ishmael Smyrnow for fetching the tile layer from the DB
        https://github.com/ismyrnow/Leaflet.functionaltilelayer
    I compared the DB-based tiles layer with a purely local (localhost://) storage
    There is no noticeable difference in performance! between using IndexedDB and local files!

Results

    Chrome: Fetch (6.551s), Store (8.247s), Total Elapsed Time: (13.714s)
    FireFox: Fetch (0.422s), Store (31.519s), Total Elapsed Time: (32.836s)
    IE 10: Fetch (0.668s), Store: (0.896s), Total Elapsed Time: (3.758s)


Comment 51 by d...@arandomurl.com, Feb 11, 2013
Funnily in relation to #32 I have run into this while developing an in browser version of CouchDB (PouchDB)

The problem with polyfilling this with the filesystem api is that you lose transactional semantics on document writes, we need to refcount and do other such things when we write a document and when we break the event loop to store things on the filesystem we get interleaved reads a lot of invalid transaction objects.

It would be nice to see this fixed (alternatively I have heard that this isnt a popular idea but being able to open a transaction with an option to wait for it to be explicitly close would be just as good)
Comment 52 by jsb...@chromium.org, Feb 11, 2013
FYI, you can keep a transaction alive indefinitely by doing something like:

var keep_alive = true; // set to false to allow transaction to finish
var transaction; // the transaction to keep alive
var store = 'store name'; // some object store in scope

(function keepAlive() { 
  if (keep_alive) {
    transaction.objectStore(store).get(0).onsuccess = keepAlive;
  }
}());

Comment 53 by d...@arandomurl.com, Feb 11, 2013
I have to say I did not consider a busy callback loop, thanks, the idea kinda scares me but I can test and see quite how scary it is.
Project Member Comment 54 by bugdroid1@chromium.org, Mar 10, 2013
Labels: -Area-WebKit -WebKit-Storage-IndexedDB Cr-Content Cr-Content-Storage-IndexedDB
Cc: wiltzius@chromium.org
@cos...@gmail.com
Which solution are you using to store and read your videos ? (#42)
It tried using BinaryString for Chrome, but I don't succeed in converting string back to blob using your tip with Uint8Array(#44)

Do you have a working example somewhere ?
Thanks.
Comment 57 by ju.carr...@gmail.com, Mar 26, 2013
Yes, +1 for #56. I would love to see that as well.
Thanks guys!
Comment 58 by cos...@gmail.com, Mar 26, 2013
#56, #57: Here is my code for storing and retrieving Blobs to/from IndexedDB. However, keep in mind that you'll run into http://crbug.com/87772 if your Blob size is on the order of hundreds of megabytes.

Writing: https://github.com/pwnall/dropship-chrome/blob/master/src/coffee/dropship_list.coffee#L149

The workaround for this bug is here: https://github.com/pwnall/dropship-chrome/blob/master/src/coffee/dropship_list.coffee#L210

Reading: https://github.com/pwnall/dropship-chrome/blob/master/src/coffee/dropship_list.coffee#L252

Bug workaround code: https://github.com/pwnall/dropship-chrome/blob/master/src/coffee/dropship_list.coffee#L291

I hope this helps!
Project Member Comment 59 by bugdroid1@chromium.org, Apr 6, 2013
Labels: -Cr-Content Cr-Blink
Project Member Comment 60 by bugdroid1@chromium.org, Apr 6, 2013
Labels: -Cr-Content-Storage-IndexedDB Cr-Blink-Storage-IndexedDB
Comment 61 by ygutfre...@gmail.com, Apr 11, 2013
Any status updates on when this will be resolved?
Comment 62 by jsb...@chromium.org, Apr 11, 2013
The functionality is under active development but we have no target milestone yet.
Comment 63 by ygutfre...@gmail.com, May 12, 2013
PouchDB  now supports native binary blob storage in the web client IndexedDB except in the case of Chrome (where it has to fall back to base64 storage).
Comment 64 by ygutfre...@gmail.com, May 29, 2013
I have created a online demo "JSFIDDLE-Like" at: http://codepen.io/DrYSG/pen/hpqoD which uses XHR2 to fetch binary blobs, and stores them in PouchDB (which uses IndexedDB). PouchDB is currently converting the binary blobs to Base64. But it would be nice if Chrome supported native binary blobs in IDB.


Comment 65 by ygutfre...@gmail.com, May 29, 2013
Oh yes, to operate, fist delete the old database, then reload, then press download tiles. You will statistics as it runs, and an image fetched from IDB when it is done.
Comment 66 by pira...@gmail.com, May 29, 2013
There's currently any way to store File objects instead of Blobs? I'm
interested about storing references to the location of files added by the
user from the hard disk... Also, anybody know if it's supported to store
FileEntries and specially DirEntries?
El 29/05/2013 18:26, <chromium@googlecode.com> escribi
Comment 67 by ericu@chromium.org, May 29, 2013
@piranna: IDB should support anything covered by the Structured Clone algorithm.  So once I get this feature in, it will support Blobs, Files, and FileLists.  It will not support FileEntry or DirEntry; it's not clear what exactly that would mean w.r.t. permissions, file lifetimes, etc., and the FileSystem spec isn't likely to see a lot of further development in the near term.
Comment 68 by pira...@gmail.com, May 29, 2013
Good to know. Seems that Mozilla is doing a copy of the File object instead
of maintain references to the original ones as according to the spec, is
this still true or files will be copied? I'm willing not...
El 29/05/2013 21:21, <chromium@googlecode.com> escribi
Comment 69 by ericu@chromium.org, May 29, 2013
Yes, it will be a copy, just like for strings, numbers, or any other type IDB stores.  That's what it means to store data in a database.  If we just kept a reference to external data, that data could change outside of a transaction, breaking a fundamental assumption of IDB.
Comment 70 by pira...@gmail.com, May 29, 2013
Oh sh*t, that's a big problem for me :-/ I'm creating a P2P filesharing
application using WebRTC and using IndexedDB to host metadata of the files
(mainly the hash), but doing copies will be a waste of space... :-( I
believed for File objects it only stored the reference for them, showing a
null on modifiedTime and length if they was not found the same way it's
done when the File objects are in memory. I supose File objects on
FileLists are also copied inside the database, isn't it? :-(
El 29/05/2013 22:34, <chromium@googlecode.com> escribi
Comment 71 by Deleted ...@, Jun 12, 2013
Any new update??
I think this is a feature that many people are waiting..

Comment 72 by jsb...@chromium.org, Jul 12, 2013
Blocking: chromium:250442
Comment 73 by downch...@gmail.com, Aug 12, 2013
Chrome packaged apps now have a retain method for retaining access to filesystem entries. With those items as well as with standard FileSystem entries, you would simply store the URL reference in IndexedDB if you're looking to reference the FileEntry/DirectoryEntry. A Mozilla developer has started suggesting a new filesystem API, though there's little commitment.

Blob in IndexedDB still seems to be stalled. Use the FileSystem API and string references for the time being.
Comment 74 by pira...@gmail.com, Aug 12, 2013
I would like it to be a real web application, but until the Mozilla suggested filesystem API gets some progress, definitely using packaged apps on Chrome and DeviceStorage on Firefox would be a solution... :-) Thanks for your suggestion! :-D
Comment 75 by ygutfre...@gmail.com, Aug 12, 2013
in note #50 https://code.google.com/p/chromium/issues/detail?id=108012#c50, I indicate that I already tried the hybrid IDB/FileSystem approach (blobs in the FileSystem). It does work, but not as efficiently (performance) or maintainence free (you have to do your own folder load balancing, cleanup, etc.) So I am still hoping that what ericu@cromiumum.org says in #69 https://code.google.com/p/chromium/issues/detail?id=108012#c69 is true, and that the full IDB spec will be implemented (IE10 and IE11 does, *hint* *hint*) and their IDB is very very fast.


Comment 76 by ygutfre...@gmail.com, Aug 20, 2013
I have created another IDB download test. This one uses PouchDB (CouchDB for the browser and mobiles) and it uses IDB underneath. IE11 and FF have native blob support. Chrome is getting a slight performance hit since it does not. 

1. Run http://codepen.io/DrYSG/pen/kdzft 
2. Press [Download]

It will load 171 JPG map tiles via XHR2 and stored them in PouchDB (The table tells you if Binary or Base64 (Chrome) is being used in PouchDB).

[If you want to try with more JPG and get a higher resolution map (600+ tiles) then FORK and change line 1 to 
var serverURL = "https://googledrive.com/host/0B2Ay-nw1QSW2SHhjR0VBZXE2bUU/LittleBlueMarble/" ]

You can also [DELETE] the PouchDB databases.

Please tell me what performance you see. Behind my firewalls I am getting about 24 Files/Sec. in IE11 and  22 Files/sec in Chrome.

One thing to know about this demo, is that it will only spawn "100 threads" of XHR2 download/IDB PUT). This is because of a issue https://code.google.com/p/chromium/issues/detail?id=244910

that I had to solve with throttling how fast Chrome downloads. You can easily FORK the source and  try different numbers of threads.


Also tell me if IE10 is working for you.

FireFox has a real poor IDB (an overlay of WebSQL, and no SPDY support, so performance is very very poor)

You can then look at the full downloaded map by going to:

http://codepen.io/DrYSG/pen/mcdCq
This is the first time I've seen someone say Firefox's IDB implementation
is an overlay of WebSQL. I don't believe this is true. Do you have a source
for that?
Comment 78 by ygutfre...@gmail.com, Aug 20, 2013
Let me be more precise. FF uses SQLlite 

1. http://www.aaron-powell.com/posts/2012-10-05-indexeddb-storage.html
2. http://stackoverflow.com/questions/9846013/how-to-view-indexeddb-content-in-firefox

This allows them to maintain legacy support of the WebSQL API, and also support IDB. But what I think I am finding is that non-SQL to a relational DB is not working well. (but maybe the real issue is lack of XHR2 and SPDY or something in their thread model) I really don't know. All I know is that Chrome does some amazing things in HTTP fetches pipeline.


Comment 79 by pira...@gmail.com, Aug 20, 2013
The usage of base64 is thanks to the hack someone posted on this issue
some months ago, or how it's done? If so, I would be interested on
take a look on it...
Comment 80 by matej.c...@gmail.com, Aug 20, 2013
@78 ... just for the sake of completness. Firefox has never supported WebSQL, so there is no need to provide legacy support.
Comment 81 by ygutfre...@gmail.com, Aug 20, 2013
#79 - Base64 support is built into PouchDB http://pouchdb.com/. It tests to see if the IDB supports binary blobs.

If no blobSupport, then it translates the blob to Base64 and saves it inline to the DB. Blobs are stored by putAttachment(). Of course, if all you are storing are JSON documents, then you just save the doc (with no attachment).


Comment 82 by pira...@gmail.com, Aug 20, 2013
Thanks for the advice. So, seems the storage of Blobs is not transparent,
isn't it?
El 20/08/2013 20:29, <chromium@googlecode.com> escribi
Folks: this bug is tracking blob support in IDB in Chromium. We all agree it should be implemented, and ericu@ is working on it right now. It happens to require some fundamental changes in the way chrome handles blobs - purely an implementation detail, but that is why it is taking a while.

Please don't clutter this bug up with random performance measurements of other browsers, it's not helping anyone.
Comment 84 by ygutfre...@gmail.com, Aug 20, 2013
1. Alec, I understand and agree
2. The demo is meant to be helpful as a debug and test tool for you and ericu not perf test for other browsers

Why? Because in issue #244910, I discovered that when doing bulk downloads with Chrome into IDB, it will get overload the memory. So I had to do some fancy bandwidth throttling with Promises in http://codepen.io/DrYSG/pen/kdzft. You can easily set how many fetch/store "threads" are running concurrently. I hope this is useful to the Chromium team.

#82, piranna - the API does make blob storage transparent.

As mentioned in the thread this requires some fundamental changes but can we have an idea when this will work (months, years...)?
Comment 86 by michaeln@google.com, Oct 16, 2013
months i think, wip can be seen here..

Blob refactoring stuff
https://code.google.com/p/chromium/issues/detail?id=174200

IDB specific stuff
https://codereview.chromium.org/18023022/
https://codereview.chromium.org/18590006/
Comment 87 by vli@chromium.org, Nov 19, 2013
Labels: Hotlist-DevRel
Are we really still months away on this?
Cc: mlamouri@chromium.org
Comment 90 by dpa...@chromium.org, Jan 23, 2014
Cc: arthurhsu@chromium.org
Any news when this is coming?
Anything?
Comment 93 by bert...@gmail.com, Mar 4, 2014
Just finishing a project without it, perverting filesystem and localstorage to work around this bug... Please, fix this
Per #c86 you can continue to track progress by watching the Chromium and Blink changes at:

https://codereview.chromium.org/18023022/
https://codereview.chromium.org/18590006/

We would like to start landing pieces soon.
It's not very easy to read, thanks if you can advertise the first release when it will be there and usable.
Project Member Comment 96 by bugdroid1@chromium.org, Mar 14, 2014
------------------------------------------------------------------
r257044 | ericu@chromium.org | 2014-03-14T06:37:40.455342Z

Changed paths:
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_leveldb_coding.cc?r1=257044&r2=257043&pathrev=257044
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_leveldb_coding.h?r1=257044&r2=257043&pathrev=257044

Add the leveldb coding changes for IDB blob support.

BUG= 108012 

Review URL: https://codereview.chromium.org/198133002
-----------------------------------------------------------------
Project Member Comment 97 by bugdroid1@chromium.org, Mar 14, 2014
------------------------------------------------------------------
r257045 | ericu@chromium.org | 2014-03-14T06:39:45.105412Z

Changed paths:
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/leveldb/leveldb_transaction.h?r1=257045&r2=257044&pathrev=257045
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.cc?r1=257045&r2=257044&pathrev=257045
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/leveldb/leveldb_transaction.cc?r1=257045&r2=257044&pathrev=257045

Change LevelDBWriteOnlyTransaction to be writeable, and change its name to LevelDBDirectTransaction.

BUG= 108012 
R=cmumford,jsbell

Review URL: https://codereview.chromium.org/198243002
-----------------------------------------------------------------
Project Member Comment 99 by bugdroid1@chromium.org, Mar 18, 2014
------------------------------------------------------------------
r257568 | ericu@chromium.org | 2014-03-18T01:20:59.385466Z

Changed paths:
   A http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_pending_connection.h?r1=257568&r2=257567&pathrev=257568
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_database.h?r1=257568&r2=257567&pathrev=257568
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_factory_unittest.cc?r1=257568&r2=257567&pathrev=257568
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_factory.cc?r1=257568&r2=257567&pathrev=257568
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_factory.h?r1=257568&r2=257567&pathrev=257568
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/leveldb/leveldb_transaction.cc?r1=257568&r2=257567&pathrev=257568
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_unittest.cc?r1=257568&r2=257567&pathrev=257568
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_database_unittest.cc?r1=257568&r2=257567&pathrev=257568
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_dispatcher_host.cc?r1=257568&r2=257567&pathrev=257568
   A http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_pending_connection.cc?r1=257568&r2=257567&pathrev=257568
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/content_browser.gypi?r1=257568&r2=257567&pathrev=257568
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_database.cc?r1=257568&r2=257567&pathrev=257568

Added IndexedDBPendingConnection to group up a bunch of parameters that get passed around together.

This includes a convenience method CreateConnection in IndexedDBDatabase.cc that's not strictly needed for this change, but makes the merge of other related CLs easier later.

BUG= 108012 
R=cmumford,jsbell

Review URL: https://codereview.chromium.org/198223002
-----------------------------------------------------------------
Project Member Comment 101 by bugdroid1@chromium.org, Mar 19, 2014
------------------------------------------------------------------
r258120 | ericu@chromium.org | 2014-03-19T22:03:13.948127Z

Changed paths:
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/fileapi/local_file_stream_writer.cc?r1=258120&r2=258119&pathrev=258120
   M http://src.chromium.org/viewvc/chrome/trunk/src/chrome/browser/chromeos/fileapi/file_system_backend.cc?r1=258120&r2=258119&pathrev=258120
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/fileapi/local_file_stream_writer.h?r1=258120&r2=258119&pathrev=258120
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/fileapi/sandbox_file_stream_writer.cc?r1=258120&r2=258119&pathrev=258120
   M http://src.chromium.org/viewvc/chrome/trunk/src/chrome/browser/media_galleries/fileapi/media_file_system_backend.cc?r1=258120&r2=258119&pathrev=258120
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/fileapi/file_stream_writer.h?r1=258120&r2=258119&pathrev=258120
   M http://src.chromium.org/viewvc/chrome/trunk/src/chrome/browser/chromeos/drive/fileapi/webkit_file_stream_writer_impl.cc?r1=258120&r2=258119&pathrev=258120
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/fileapi/copy_or_move_operation_delegate_unittest.cc?r1=258120&r2=258119&pathrev=258120
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/fileapi/isolated_file_system_backend.cc?r1=258120&r2=258119&pathrev=258120
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/fileapi/local_file_stream_writer_unittest.cc?r1=258120&r2=258119&pathrev=258120

Add a parameter to FileStreamWriter::CreateForLocalFile to allow creating new files as well as writing to existing files.
See https://codereview.chromium.org/18023022/ for context; this is needed by upcoming IDB Blob support.

Tzik, please do primary review for filesystem; Kinaba, please review as ChromeOS owner.

BUG= 108012 
R=kinaba,tzik

Review URL: https://codereview.chromium.org/197233008
-----------------------------------------------------------------
Comment 102 by fschw...@gmail.com, Mar 19, 2014
How I feel when I see these commits: http://media0.giphy.com/media/rl0FOxdz7CcxO/giphy.gif

thanks!
Project Member Comment 103 by bugdroid1@chromium.org, Mar 19, 2014
------------------------------------------------------------------
r258139 | ericu@chromium.org | 2014-03-19T23:08:52.182362Z

Changed paths:
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.h?r1=258139&r2=258138&pathrev=258139
   A http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_value.cc?r1=258139&r2=258138&pathrev=258139
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_cursor.cc?r1=258139&r2=258138&pathrev=258139
   A http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_value.h?r1=258139&r2=258138&pathrev=258139
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_callbacks.cc?r1=258139&r2=258138&pathrev=258139
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_cursor.h?r1=258139&r2=258138&pathrev=258139
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_callbacks.h?r1=258139&r2=258138&pathrev=258139
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_dispatcher_host.cc?r1=258139&r2=258138&pathrev=258139
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/content_browser.gypi?r1=258139&r2=258138&pathrev=258139
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_database.cc?r1=258139&r2=258138&pathrev=258139
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_database.h?r1=258139&r2=258138&pathrev=258139
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store_unittest.cc?r1=258139&r2=258138&pathrev=258139
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.cc?r1=258139&r2=258138&pathrev=258139
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_blob_info.h?r1=258139&r2=258138&pathrev=258139

Add IndexedDBValue wrapper class to group blob info with bits.
Depends on https://codereview.chromium.org/197023009.

BUG= 108012 
R=cmumford,jsbell

Review URL: https://codereview.chromium.org/197753011
-----------------------------------------------------------------
Project Member Comment 104 by bugdroid1@chromium.org, Mar 20, 2014
------------------------------------------------------------------
r258256 | pneubeck@chromium.org | 2014-03-20T08:42:18.728419Z

Changed paths:
   M http://src.chromium.org/viewvc/chrome/trunk/src/chrome/browser/media_galleries/fileapi/media_file_system_backend.cc?r1=258256&r2=258255&pathrev=258256
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/fileapi/file_stream_writer.h?r1=258256&r2=258255&pathrev=258256
   M http://src.chromium.org/viewvc/chrome/trunk/src/chrome/browser/chromeos/drive/fileapi/webkit_file_stream_writer_impl.cc?r1=258256&r2=258255&pathrev=258256
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/fileapi/copy_or_move_operation_delegate_unittest.cc?r1=258256&r2=258255&pathrev=258256
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/fileapi/isolated_file_system_backend.cc?r1=258256&r2=258255&pathrev=258256
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/fileapi/local_file_stream_writer_unittest.cc?r1=258256&r2=258255&pathrev=258256
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/fileapi/local_file_stream_writer.cc?r1=258256&r2=258255&pathrev=258256
   M http://src.chromium.org/viewvc/chrome/trunk/src/chrome/browser/chromeos/fileapi/file_system_backend.cc?r1=258256&r2=258255&pathrev=258256
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/fileapi/local_file_stream_writer.h?r1=258256&r2=258255&pathrev=258256
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/fileapi/sandbox_file_stream_writer.cc?r1=258256&r2=258255&pathrev=258256

Revert of Add a parameter to FileStreamWriter::CreateForLocalFile to allow creating new (https://codereview.chromium.org/197233008/)

Reason for revert:
Best guess that this broke
SyncFileSystemApiTest.WriteFileThenGetUsage
on XP Tests(1).

http://build.chromium.org/p/chromium.win/builders/XP%20Tests%20%281%29/builds/30601/steps/browser_tests/logs/WriteFileThenGetUsage

If not, we can just re-revert or reland it after a few cycles.

Original issue's description:
> Add a parameter to FileStreamWriter::CreateForLocalFile to allow creating new files as well as writing to existing files.
> See https://codereview.chromium.org/18023022/ for context; this is needed by upcoming IDB Blob support.
> 
> Tzik, please do primary review for filesystem; Kinaba, please review as ChromeOS owner.
> 
> BUG= 108012 
> R=kinaba,tzik
> 
> Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=258120

TBR=kinaba@chromium.org,tzik@chromium.org,ericu@chromium.org
NOTREECHECKS=true
NOTRY=true
BUG= 108012 

Review URL: https://codereview.chromium.org/206073006
-----------------------------------------------------------------
Project Member Comment 105 by bugdroid1@chromium.org, Mar 20, 2014
------------------------------------------------------------------
r258259 | pneubeck@chromium.org | 2014-03-20T09:11:36.043510Z

Changed paths:
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/fileapi/sandbox_file_stream_writer.cc?r1=258259&r2=258258&pathrev=258259
   M http://src.chromium.org/viewvc/chrome/trunk/src/chrome/browser/media_galleries/fileapi/media_file_system_backend.cc?r1=258259&r2=258258&pathrev=258259
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/fileapi/file_stream_writer.h?r1=258259&r2=258258&pathrev=258259
   M http://src.chromium.org/viewvc/chrome/trunk/src/chrome/browser/chromeos/drive/fileapi/webkit_file_stream_writer_impl.cc?r1=258259&r2=258258&pathrev=258259
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/fileapi/copy_or_move_operation_delegate_unittest.cc?r1=258259&r2=258258&pathrev=258259
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/fileapi/isolated_file_system_backend.cc?r1=258259&r2=258258&pathrev=258259
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/fileapi/local_file_stream_writer_unittest.cc?r1=258259&r2=258258&pathrev=258259
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/fileapi/local_file_stream_writer.cc?r1=258259&r2=258258&pathrev=258259
   M http://src.chromium.org/viewvc/chrome/trunk/src/chrome/browser/chromeos/fileapi/file_system_backend.cc?r1=258259&r2=258258&pathrev=258259
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/fileapi/local_file_stream_writer.h?r1=258259&r2=258258&pathrev=258259

Revert of Revert of Add a parameter to FileStreamWriter::CreateForLocalFile to allow creating new (https://codereview.chromium.org/206073006/)

Reason for revert:
Sorry, I looked through this CL in more detail and it seems that it doesn't change any behavior.

Re-reverting this one and instead trying crrev.com/258064

Original issue's description:
> Revert of Add a parameter to FileStreamWriter::CreateForLocalFile to allow creating new (https://codereview.chromium.org/197233008/)
> 
> Reason for revert:
> Best guess that this broke
> SyncFileSystemApiTest.WriteFileThenGetUsage
> on XP Tests(1).
> 
> http://build.chromium.org/p/chromium.win/builders/XP%20Tests%20%281%29/builds/30601/steps/browser_tests/logs/WriteFileThenGetUsage
> 
> If not, we can just re-revert or reland it after a few cycles.
> 
> Original issue's description:
> > Add a parameter to FileStreamWriter::CreateForLocalFile to allow creating new files as well as writing to existing files.
> > See https://codereview.chromium.org/18023022/ for context; this is needed by upcoming IDB Blob support.
> > 
> > Tzik, please do primary review for filesystem; Kinaba, please review as ChromeOS owner.
> > 
> > BUG= 108012 
> > R=kinaba,tzik
> > 
> > Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=258120
> 
> TBR=kinaba@chromium.org,tzik@chromium.org,ericu@chromium.org
> NOTREECHECKS=true
> NOTRY=true
> BUG= 108012 
> 
> Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=258256

TBR=kinaba@chromium.org,tzik@chromium.org,ericu@chromium.org
NOTREECHECKS=true
NOTRY=true
BUG= 108012 

Review URL: https://codereview.chromium.org/206083004
-----------------------------------------------------------------
Project Member Comment 106 by bugdroid1@chromium.org, Apr 2, 2014
The following revision refers to this bug:
  http://src.chromium.org/viewvc/blink?view=rev&rev=170686

------------------------------------------------------------------
r170686 | ericu@chromium.org | 2014-04-02T19:36:17.009941Z

Changed paths:
   A http://src.chromium.org/viewvc/blink/trunk/public/platform/WebBlobInfo.h?r1=170686&r2=170685&pathrev=170686

Add two classes [as yet unused] needed for upcoming IDB Blob support.

BUG= 108012 
R=cmumford,jsbell,abarth

Review URL: https://codereview.chromium.org/205413004
-----------------------------------------------------------------
Project Member Comment 107 by bugdroid1@chromium.org, Apr 3, 2014
------------------------------------------------------------------
r261440 | ericu@chromium.org | 2014-04-03T16:26:19.904465Z

Changed paths:
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_factory_unittest.cc?r1=261440&r2=261439&pathrev=261440
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_factory.cc?r1=261440&r2=261439&pathrev=261440
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store_unittest.cc?r1=261440&r2=261439&pathrev=261440
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_factory.h?r1=261440&r2=261439&pathrev=261440
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.cc?r1=261440&r2=261439&pathrev=261440
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.h?r1=261440&r2=261439&pathrev=261440
   A http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_active_blob_registry_unittest.cc?r1=261440&r2=261439&pathrev=261440
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_fake_backing_store.cc?r1=261440&r2=261439&pathrev=261440
   A http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_active_blob_registry.cc?r1=261440&r2=261439&pathrev=261440
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_cleanup_on_io_error_unittest.cc?r1=261440&r2=261439&pathrev=261440
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_fake_backing_store.h?r1=261440&r2=261439&pathrev=261440
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/content_tests.gypi?r1=261440&r2=261439&pathrev=261440
   A http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_active_blob_registry.h?r1=261440&r2=261439&pathrev=261440
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/content_browser.gypi?r1=261440&r2=261439&pathrev=261440

Add the IndexedDBActiveBlobRegistry, currently unused, to enable future blob
support.

BUG= 108012 
R=cmumford,jsbell

Review URL: https://codereview.chromium.org/203833003
-----------------------------------------------------------------
Any news on expected release date for blob feature in chrome?
Project Member Comment 111 by bugdroid1@chromium.org, Apr 9, 2014
The following revision refers to this bug:
  http://src.chromium.org/viewvc/blink?view=rev&rev=171190

------------------------------------------------------------------
r171190 | ericu@chromium.org | 2014-04-09T22:27:26.704791Z

Changed paths:
   M http://src.chromium.org/viewvc/blink/trunk/LayoutTests/crypto/clone-rsaKey-private-expected.txt?r1=171190&r2=171189&pathrev=171190
   M http://src.chromium.org/viewvc/blink/trunk/Source/modules/indexeddb/IDBObjectStore.cpp?r1=171190&r2=171189&pathrev=171190
   M http://src.chromium.org/viewvc/blink/trunk/LayoutTests/crypto/clone-rsaHashedKey-public-expected.txt?r1=171190&r2=171189&pathrev=171190
   M http://src.chromium.org/viewvc/blink/trunk/public/web/WebSerializedScriptValueVersion.h?r1=171190&r2=171189&pathrev=171190
   M http://src.chromium.org/viewvc/blink/trunk/LayoutTests/crypto/clone-rsaKey-public-expected.txt?r1=171190&r2=171189&pathrev=171190
   M http://src.chromium.org/viewvc/blink/trunk/Source/core/fileapi/File.h?r1=171190&r2=171189&pathrev=171190
   M http://src.chromium.org/viewvc/blink/trunk/Source/bindings/v8/SerializedScriptValue.cpp?r1=171190&r2=171189&pathrev=171190
   M http://src.chromium.org/viewvc/blink/trunk/LayoutTests/crypto/clone-aesKey-expected.txt?r1=171190&r2=171189&pathrev=171190
   M http://src.chromium.org/viewvc/blink/trunk/LayoutTests/crypto/clone-hmacKey-expected.txt?r1=171190&r2=171189&pathrev=171190
   M http://src.chromium.org/viewvc/blink/trunk/LayoutTests/fast/storage/resources/serialized-script-value.js?r1=171190&r2=171189&pathrev=171190
   M http://src.chromium.org/viewvc/blink/trunk/Source/bindings/v8/SerializedScriptValue.h?r1=171190&r2=171189&pathrev=171190
   M http://src.chromium.org/viewvc/blink/trunk/LayoutTests/crypto/clone-rsaHashedKey-private-expected.txt?r1=171190&r2=171189&pathrev=171190
   M http://src.chromium.org/viewvc/blink/trunk/Source/bindings/v8/IDBBindingUtilities.cpp?r1=171190&r2=171189&pathrev=171190

Add blob serialization support [currently unused] to SerializedScriptValue.
This will be needed by IDB Blob support, in progress.

BUG= 108012 
R=cmumford,jsbell

Review URL: https://codereview.chromium.org/223123002
-----------------------------------------------------------------
Project Member Comment 113 by bugdroid1@chromium.org, Apr 14, 2014
Project Member Comment 114 by bugdroid1@chromium.org, Apr 17, 2014
------------------------------------------------------------------
r264380 | ericu@chromium.org | 2014-04-17T01:42:32.903594Z

Changed paths:
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_fake_backing_store.cc?r1=264380&r2=264379&pathrev=264380
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_dispatcher_host.cc?r1=264380&r2=264379&pathrev=264380
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_database.cc?r1=264380&r2=264379&pathrev=264380
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_dispatcher_host.h?r1=264380&r2=264379&pathrev=264380
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_database.h?r1=264380&r2=264379&pathrev=264380
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store_unittest.cc?r1=264380&r2=264379&pathrev=264380
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.cc?r1=264380&r2=264379&pathrev=264380
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.h?r1=264380&r2=264379&pathrev=264380

Pass blob info through from the IPC to the backing store on put.
It's not used yet; this is all just preparatory plumbing.

BUG= 108012 

Review URL: https://codereview.chromium.org/232343004
-----------------------------------------------------------------
Project Member Comment 115 by bugdroid1@chromium.org, Apr 18, 2014
------------------------------------------------------------------
r264728 | ericu@chromium.org | 2014-04-18T04:58:03.753933Z

Changed paths:
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_callbacks.cc?r1=264728&r2=264727&pathrev=264728
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_callbacks.h?r1=264728&r2=264727&pathrev=264728

Complete registration of blobs before sending back an indexed DB value that contains them.

BUG= 108012 

Review URL: https://codereview.chromium.org/238043007
-----------------------------------------------------------------
Project Member Comment 116 by bugdroid1@chromium.org, Apr 25, 2014
The following revision refers to this bug:
  http://src.chromium.org/viewvc/blink?view=rev&rev=172656

------------------------------------------------------------------
r172656 | ericu@chromium.org | 2014-04-25T20:11:14.211865Z

Changed paths:
   M http://src.chromium.org/viewvc/blink/trunk/Source/bindings/v8/IDBBindingUtilities.cpp?r1=172656&r2=172655&pathrev=172656
   M http://src.chromium.org/viewvc/blink/trunk/Source/modules/indexeddb/IDBCursor.h?r1=172656&r2=172655&pathrev=172656
   M http://src.chromium.org/viewvc/blink/trunk/Source/modules/indexeddb/IDBDatabase.cpp?r1=172656&r2=172655&pathrev=172656
   M http://src.chromium.org/viewvc/blink/trunk/Source/modules/indexeddb/WebIDBCallbacksImpl.h?r1=172656&r2=172655&pathrev=172656
   M http://src.chromium.org/viewvc/blink/trunk/public/platform/WebIDBCallbacks.h?r1=172656&r2=172655&pathrev=172656
   M http://src.chromium.org/viewvc/blink/trunk/Source/bindings/v8/IDBBindingUtilities.h?r1=172656&r2=172655&pathrev=172656
   M http://src.chromium.org/viewvc/blink/trunk/Source/modules/indexeddb/IDBAny.cpp?r1=172656&r2=172655&pathrev=172656
   M http://src.chromium.org/viewvc/blink/trunk/Source/modules/indexeddb/IDBRequest.cpp?r1=172656&r2=172655&pathrev=172656
   M http://src.chromium.org/viewvc/blink/trunk/Source/modules/indexeddb/IDBRequestTest.cpp?r1=172656&r2=172655&pathrev=172656
   M http://src.chromium.org/viewvc/blink/trunk/Source/modules/indexeddb/IDBDatabase.h?r1=172656&r2=172655&pathrev=172656
   M http://src.chromium.org/viewvc/blink/trunk/public/platform/WebIDBDatabase.h?r1=172656&r2=172655&pathrev=172656
   M http://src.chromium.org/viewvc/blink/trunk/Source/modules/indexeddb/IDBAny.h?r1=172656&r2=172655&pathrev=172656
   M http://src.chromium.org/viewvc/blink/trunk/Source/modules/indexeddb/IDBCursor.cpp?r1=172656&r2=172655&pathrev=172656
   M http://src.chromium.org/viewvc/blink/trunk/Source/modules/indexeddb/IDBRequest.h?r1=172656&r2=172655&pathrev=172656
   M http://src.chromium.org/viewvc/blink/trunk/Source/modules/indexeddb/WebIDBCallbacksImpl.cpp?r1=172656&r2=172655&pathrev=172656

Add the backchannel for Blobs to be received into Blink from the database backend.

BUG= 108012 

Review URL: https://codereview.chromium.org/235933013
-----------------------------------------------------------------
Project Member Comment 118 by bugdroid1@chromium.org, Apr 28, 2014
Labels: merge-merged-git-svn
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/63cf86df70fe7ae902810213b44958eb165dbe00

commit 63cf86df70fe7ae902810213b44958eb165dbe00
Author: ericu@chromium.org <ericu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Date: Mon Apr 28 22:38:16 2014 +0000

The chromium-side backchannel plumbing for blobs in IDB.
This requires https://codereview.chromium.org/235933013/.

BUG= 108012 

Review URL: https://codereview.chromium.org/240003010

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@266677 0039d316-1c4b-4281-b951-d872f2087c98


Project Member Comment 119 by bugdroid1@chromium.org, Apr 29, 2014
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/8e215a665c1591ce9230f9124398badd20a58a8c

commit 8e215a665c1591ce9230f9124398badd20a58a8c
Author: ericu@chromium.org <ericu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Date: Tue Apr 29 09:57:07 2014 +0000

Allow BlobDataHandles to be copied, and have their UUIDs read, on any thread.

BUG= 108012 

Review URL: https://codereview.chromium.org/259773006

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@266817 0039d316-1c4b-4281-b951-d872f2087c98


Project Member Comment 121 by bugdroid1@chromium.org, Apr 29, 2014
------------------------------------------------------------------
r266837 | machenbach@chromium.org | 2014-04-29T10:58:20.963890Z

Changed paths:
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/blob/blob_storage_context.h?r1=266837&r2=266836&pathrev=266837
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/blob/blob_data_handle.cc?r1=266837&r2=266836&pathrev=266837
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/blob/blob_data_handle.h?r1=266837&r2=266836&pathrev=266837
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/fileapi/blob_storage_context_unittest.cc?r1=266837&r2=266836&pathrev=266837

Revert of Allow BlobDataHandles to be copied, and have their UUIDs read, on any thread. (https://codereview.chromium.org/259773006/)

Reason for revert:
Causes leaks:
http://build.chromium.org/p/chromium.memory/builders/Linux%20ASan%20LSan%20Tests%20%282%29/builds/2069

Original issue's description:
> Allow BlobDataHandles to be copied, and have their UUIDs read, on any thread.
> 
> BUG= 108012 
> 
> Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=266817

TBR=michaeln@chromium.org,ericu@chromium.org
NOTREECHECKS=true
NOTRY=true
BUG= 108012 

Review URL: https://codereview.chromium.org/252163002
-----------------------------------------------------------------
Project Member Comment 122 by bugdroid1@chromium.org, Apr 29, 2014
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/624bce9623955b66b8556d9e8d6f780da63069b7

commit 624bce9623955b66b8556d9e8d6f780da63069b7
Author: machenbach@chromium.org <machenbach@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Date: Tue Apr 29 10:58:20 2014 +0000

Revert of Allow BlobDataHandles to be copied, and have their UUIDs read, on any thread. (https://codereview.chromium.org/259773006/)

Reason for revert:
Causes leaks:
http://build.chromium.org/p/chromium.memory/builders/Linux%20ASan%20LSan%20Tests%20%282%29/builds/2069

Original issue's description:
> Allow BlobDataHandles to be copied, and have their UUIDs read, on any thread.
> 
> BUG= 108012 
> 
> Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=266817

TBR=michaeln@chromium.org,ericu@chromium.org
NOTREECHECKS=true
NOTRY=true
BUG= 108012 

Review URL: https://codereview.chromium.org/252163002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@266837 0039d316-1c4b-4281-b951-d872f2087c98


Project Member Comment 124 by bugdroid1@chromium.org, Apr 29, 2014
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/de624f8b5de362b1d509f80d00701660abf0ac93

commit de624f8b5de362b1d509f80d00701660abf0ac93
Author: ericu@chromium.org <ericu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Date: Tue Apr 29 17:54:35 2014 +0000

Add blob-writing functionality [as yet un-called] to IDB's backend.

BUG= 108012 
R=cmumford@chromium.org, jsbell@chromium.org

Review URL: https://codereview.chromium.org/240003011

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@266916 0039d316-1c4b-4281-b951-d872f2087c98


Project Member Comment 125 by bugdroid1@chromium.org, Apr 30, 2014
------------------------------------------------------------------
r267031 | ericu@chromium.org | 2014-04-30T01:34:18.933655Z

Changed paths:
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_factory_unittest.cc?r1=267031&r2=267030&pathrev=267031
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_factory.cc?r1=267031&r2=267030&pathrev=267031
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_factory.h?r1=267031&r2=267030&pathrev=267031
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.cc?r1=267031&r2=267030&pathrev=267031
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.h?r1=267031&r2=267030&pathrev=267031
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_cleanup_on_io_error_unittest.cc?r1=267031&r2=267030&pathrev=267031
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_dispatcher_host.cc?r1=267031&r2=267030&pathrev=267031

Track which IndexedDBBackingStores have been opened since boot.
This way we'll know which need to have their live blob journals cleaned, once
blob support is in.

This has a small overlap with https://codereview.chromium.org/240003011/ [currently in the commit queue] for ease of merging.  However, it also fixes a bug in that CL in which GetDatabaseNames didn't have the request_context parameter.

BUG= 108012 

Review URL: https://codereview.chromium.org/259063004
-----------------------------------------------------------------
Project Member Comment 126 by bugdroid1@chromium.org, Apr 30, 2014
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/8b9db116bda68414d122b35bdebb43ac42ef4d7d

commit 8b9db116bda68414d122b35bdebb43ac42ef4d7d
Author: ericu@chromium.org <ericu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Date: Wed Apr 30 01:34:18 2014 +0000

Track which IndexedDBBackingStores have been opened since boot.
This way we'll know which need to have their live blob journals cleaned, once
blob support is in.

This has a small overlap with https://codereview.chromium.org/240003011/ [currently in the commit queue] for ease of merging.  However, it also fixes a bug in that CL in which GetDatabaseNames didn't have the request_context parameter.

BUG= 108012 

Review URL: https://codereview.chromium.org/259063004

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267031 0039d316-1c4b-4281-b951-d872f2087c98


Project Member Comment 127 by bugdroid1@chromium.org, May 1, 2014
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/3cf4bd4d39a7731100fd85c02fb9dd11259462a8

commit 3cf4bd4d39a7731100fd85c02fb9dd11259462a8
Author: ericu@chromium.org <ericu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Date: Thu May 01 04:22:15 2014 +0000

Allow BlobDataHandles to be copied, and have their UUIDs read, on any thread.

BUG= 108012 

Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=266817

Review URL: https://codereview.chromium.org/259773006

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267423 0039d316-1c4b-4281-b951-d872f2087c98


Project Member Comment 129 by bugdroid1@chromium.org, May 1, 2014
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/74c6709366769b2ed7ace4ff9cb5c926bcbaa8fe

commit 74c6709366769b2ed7ace4ff9cb5c926bcbaa8fe
Author: ericu@chromium.org <ericu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Date: Thu May 01 05:28:54 2014 +0000

Some changes to support incognito mode, and some small cleanup.

BUG= 108012 

Review URL: https://codereview.chromium.org/260783003

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267448 0039d316-1c4b-4281-b951-d872f2087c98


Project Member Comment 131 by bugdroid1@chromium.org, May 1, 2014
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/ac6f8c98b9f225ac1c890f94d14ff9e3b17afd0c

commit ac6f8c98b9f225ac1c890f94d14ff9e3b17afd0c
Author: falken@chromium.org <falken@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Date: Thu May 01 08:03:24 2014 +0000

Revert of Allow BlobDataHandles to be copied, and have their UUIDs read, on any thread. (https://codereview.chromium.org/259773006/)

Reason for revert:
I'm sorry to revert this change. It looks like it breaks the ASAN bot:

http://build.chromium.org/p/chromium.memory/builders/Linux%20ASan%20LSan%20Tests%20%282%29/builds/2161/steps/content_unittests/logs/ResolveBlobAndCreateUploadDataStream

Direct leak of 120 byte(s) in 3 object(s) allocated from:
    #0 0x520dbb in operator new(unsigned long) /usr/local/google/work/chromium/src/third_party/llvm/projects/compiler-rt/lib/asan/asan_new_delete.cc:62
    #1 0x3a0f611 in webkit_blob::BlobDataHandle::BlobDataHandle(webkit_blob::BlobData*, webkit_blob::BlobStorageContext*, base::SequencedTaskRunner*) webkit/browser/blob/blob_data_handle.cc:42
    #2 0x3a0fd71 in webkit_blob::BlobStorageContext::GetBlobDataFromUUID(std::string const&) webkit/browser/blob/blob_storage_context.cc:69
    #3 0x268955d in ResolveBlobReference content/browser/loader/upload_data_stream_builder.cc:73
...

Original issue's description:
> Allow BlobDataHandles to be copied, and have their UUIDs read, on any thread.
> 
> BUG= 108012 
> 
> Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=266817
> 
> Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=267423

TBR=michaeln@chromium.org,piman@chromium.org,ericu@chromium.org
NOTREECHECKS=true
NOTRY=true
BUG= 108012 

Review URL: https://codereview.chromium.org/261683005

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267479 0039d316-1c4b-4281-b951-d872f2087c98


Project Member Comment 132 by bugdroid1@chromium.org, May 1, 2014
------------------------------------------------------------------
r267479 | falken@chromium.org | 2014-05-01T08:03:24.202388Z

Changed paths:
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/blob/blob_data_handle.cc?r1=267479&r2=267478&pathrev=267479
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/blob/blob_data_handle.h?r1=267479&r2=267478&pathrev=267479
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/fileapi/blob_storage_context_unittest.cc?r1=267479&r2=267478&pathrev=267479
   M http://src.chromium.org/viewvc/chrome/trunk/src/webkit/browser/blob/blob_storage_context.h?r1=267479&r2=267478&pathrev=267479
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/loader/upload_data_stream_builder_unittest.cc?r1=267479&r2=267478&pathrev=267479

Revert of Allow BlobDataHandles to be copied, and have their UUIDs read, on any thread. (https://codereview.chromium.org/259773006/)

Reason for revert:
I'm sorry to revert this change. It looks like it breaks the ASAN bot:

http://build.chromium.org/p/chromium.memory/builders/Linux%20ASan%20LSan%20Tests%20%282%29/builds/2161/steps/content_unittests/logs/ResolveBlobAndCreateUploadDataStream

Direct leak of 120 byte(s) in 3 object(s) allocated from:
    #0 0x520dbb in operator new(unsigned long) /usr/local/google/work/chromium/src/third_party/llvm/projects/compiler-rt/lib/asan/asan_new_delete.cc:62
    #1 0x3a0f611 in webkit_blob::BlobDataHandle::BlobDataHandle(webkit_blob::BlobData*, webkit_blob::BlobStorageContext*, base::SequencedTaskRunner*) webkit/browser/blob/blob_data_handle.cc:42
    #2 0x3a0fd71 in webkit_blob::BlobStorageContext::GetBlobDataFromUUID(std::string const&) webkit/browser/blob/blob_storage_context.cc:69
    #3 0x268955d in ResolveBlobReference content/browser/loader/upload_data_stream_builder.cc:73
...

Original issue's description:
> Allow BlobDataHandles to be copied, and have their UUIDs read, on any thread.
> 
> BUG= 108012 
> 
> Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=266817
> 
> Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=267423

TBR=michaeln@chromium.org,piman@chromium.org,ericu@chromium.org
NOTREECHECKS=true
NOTRY=true
BUG= 108012 

Review URL: https://codereview.chromium.org/261683005
-----------------------------------------------------------------
Project Member Comment 133 by bugdroid1@chromium.org, May 1, 2014
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/790591d1c8a92f496b43ef87fe2cf48eb09020bb

commit 790591d1c8a92f496b43ef87fe2cf48eb09020bb
Author: ericu@chromium.org <ericu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Date: Thu May 01 23:38:27 2014 +0000

This is the implementation of the primary and secondary blob journals for
IDB/Blob support.  It's not yet used at all, so there are a few fake calls to
eliminate compiler errors until the rest of the code lands.

BUG= 108012 

Review URL: https://codereview.chromium.org/264483002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267665 0039d316-1c4b-4281-b951-d872f2087c98


Project Member Comment 137 by bugdroid1@chromium.org, May 10, 2014
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/496cbfbec18cea8ba588687b355673d35420ab9d

commit 496cbfbec18cea8ba588687b355673d35420ab9d
Author: ericu@chromium.org <ericu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Date: Sat May 10 18:52:58 2014

More changes to support incognito mode in the IDB/Blob code.
Also includes a few small cleanup changes I noticed while I was in there.

BUG= 108012 

Review URL: https://codereview.chromium.org/261843004

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@269605 0039d316-1c4b-4281-b951-d872f2087c98


Project Member Comment 138 by bugdroid1@chromium.org, May 10, 2014
------------------------------------------------------------------
r269605 | ericu@chromium.org | 2014-05-10T18:52:58.035761Z

Changed paths:
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.cc?r1=269605&r2=269604&pathrev=269605
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.h?r1=269605&r2=269604&pathrev=269605

More changes to support incognito mode in the IDB/Blob code.
Also includes a few small cleanup changes I noticed while I was in there.

BUG= 108012 

Review URL: https://codereview.chromium.org/261843004
-----------------------------------------------------------------
Project Member Comment 139 by bugdroid1@chromium.org, May 13, 2014
------------------------------------------------------------------
r270016 | ericu@chromium.org | 2014-05-13T04:59:44.904941Z

Changed paths:
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_leveldb_coding.cc?r1=270016&r2=270015&pathrev=270016
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.cc?r1=270016&r2=270015&pathrev=270016
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.h?r1=270016&r2=270015&pathrev=270016

Add most of the metadata-handling code for blobs.  It's not quite all there, but
this is the biggest chunk I can pull out vaguely cleanly.  It does contain a
couple of fake calls to keep the compiler happy.
This CL also makes SetUpMetadata a member in order to ease testing in a later CL.

This depends on https://codereview.chromium.org/261843004/.

BUG= 108012 

Review URL: https://codereview.chromium.org/266333002
-----------------------------------------------------------------
Project Member Comment 140 by bugdroid1@chromium.org, May 13, 2014
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/9f96c91cd9a9f73d000e1ab35c53974c58fd571b

commit 9f96c91cd9a9f73d000e1ab35c53974c58fd571b
Author: ericu@chromium.org <ericu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Date: Tue May 13 04:59:44 2014

Add most of the metadata-handling code for blobs.  It's not quite all there, but
this is the biggest chunk I can pull out vaguely cleanly.  It does contain a
couple of fake calls to keep the compiler happy.
This CL also makes SetUpMetadata a member in order to ease testing in a later CL.

This depends on https://codereview.chromium.org/261843004/.

BUG= 108012 

Review URL: https://codereview.chromium.org/266333002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@270016 0039d316-1c4b-4281-b951-d872f2087c98


Project Member Comment 141 by bugdroid1@chromium.org, May 13, 2014
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/28e0631885a68d2b0ad3aefbec80a18ada909a9d

commit 28e0631885a68d2b0ad3aefbec80a18ada909a9d
Author: dcheng@chromium.org <dcheng@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Date: Tue May 13 06:55:43 2014

Revert 270016 "Add most of the metadata-handling code for blobs...."

This may have caused indexed_db layout tests to start failing.

> Add most of the metadata-handling code for blobs.  It's not quite all there, but
> this is the biggest chunk I can pull out vaguely cleanly.  It does contain a
> couple of fake calls to keep the compiler happy.
> This CL also makes SetUpMetadata a member in order to ease testing in a later CL.
> 
> This depends on https://codereview.chromium.org/261843004/.
> 
> BUG= 108012 
> 
> Review URL: https://codereview.chromium.org/266333002

TBR=ericu@chromium.org

Review URL: https://codereview.chromium.org/281623004

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@270038 0039d316-1c4b-4281-b951-d872f2087c98


Project Member Comment 142 by bugdroid1@chromium.org, May 13, 2014
------------------------------------------------------------------
r270038 | dcheng@chromium.org | 2014-05-13T06:55:43.383894Z

Changed paths:
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.cc?r1=270038&r2=270037&pathrev=270038
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.h?r1=270038&r2=270037&pathrev=270038
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_leveldb_coding.cc?r1=270038&r2=270037&pathrev=270038

Revert 270016 "Add most of the metadata-handling code for blobs...."

This may have caused indexed_db layout tests to start failing.

> Add most of the metadata-handling code for blobs.  It's not quite all there, but
> this is the biggest chunk I can pull out vaguely cleanly.  It does contain a
> couple of fake calls to keep the compiler happy.
> This CL also makes SetUpMetadata a member in order to ease testing in a later CL.
> 
> This depends on https://codereview.chromium.org/261843004/.
> 
> BUG= 108012 
> 
> Review URL: https://codereview.chromium.org/266333002

TBR=ericu@chromium.org

Review URL: https://codereview.chromium.org/281623004
-----------------------------------------------------------------
Project Member Comment 143 by bugdroid1@chromium.org, May 16, 2014
------------------------------------------------------------------
r271097 | ericu@chromium.org | 2014-05-16T21:29:57.530508Z

Changed paths:
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.h?r1=271097&r2=271096&pathrev=271097
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_leveldb_coding.cc?r1=271097&r2=271096&pathrev=271097
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.cc?r1=271097&r2=271096&pathrev=271097

Add most of the metadata-handling code for blobs.  It's not quite all there, but
this is the biggest chunk I can pull out vaguely cleanly.  It does contain a
couple of fake calls to keep the compiler happy.
This CL also makes SetUpMetadata a member in order to ease testing in a later CL.

This depends on https://codereview.chromium.org/261843004/.

BUG= 108012 

Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=270016

Review URL: https://codereview.chromium.org/266333002
-----------------------------------------------------------------
Project Member Comment 144 by bugdroid1@chromium.org, May 16, 2014
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/a84cd887ba2be0494ffc559d7b7d68381fb3dd7d

commit a84cd887ba2be0494ffc559d7b7d68381fb3dd7d
Author: ericu@chromium.org <ericu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Date: Fri May 16 21:29:57 2014

Add most of the metadata-handling code for blobs.  It's not quite all there, but
this is the biggest chunk I can pull out vaguely cleanly.  It does contain a
couple of fake calls to keep the compiler happy.
This CL also makes SetUpMetadata a member in order to ease testing in a later CL.

This depends on https://codereview.chromium.org/261843004/.

BUG= 108012 

Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=270016

Review URL: https://codereview.chromium.org/266333002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@271097 0039d316-1c4b-4281-b951-d872f2087c98


Project Member Comment 145 by bugdroid1@chromium.org, May 17, 2014
------------------------------------------------------------------
r271146 | dpranke@chromium.org | 2014-05-17T01:53:45.600680Z

Changed paths:
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.cc?r1=271146&r2=271145&pathrev=271146
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.h?r1=271146&r2=271145&pathrev=271146
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_leveldb_coding.cc?r1=271146&r2=271145&pathrev=271146

Revert r271097 - "Add most of the metadata-handling code for blobs."

This change caused most of the indexeddb tests to fail on win7 :(.

TBR=ericu@chromium.org
BUG= 108012 

Review URL: https://codereview.chromium.org/287093004
-----------------------------------------------------------------
r270016 appears to have broken a bunch of layout tests on win7, so I reverted it after discussing w/ Eric.

http://build.chromium.org/p/chromium.webkit/builders/WebKit%20Win7/builds/16179

(and a few other builds around that time).
Project Member Comment 147 by bugdroid1@chromium.org, May 17, 2014
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/f498c2444254cd47c007c56bf5733fcdf905073c

commit f498c2444254cd47c007c56bf5733fcdf905073c
Author: dpranke@chromium.org <dpranke@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Date: Sat May 17 01:53:45 2014

Revert r271097 - "Add most of the metadata-handling code for blobs."

This change caused most of the indexeddb tests to fail on win7 :(.

TBR=ericu@chromium.org
BUG= 108012 

Review URL: https://codereview.chromium.org/287093004

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@271146 0039d316-1c4b-4281-b951-d872f2087c98


Project Member Comment 148 by bugdroid1@chromium.org, May 27, 2014
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/5a910a6e29ddd5a187ee376e3890b05378d02985

commit 5a910a6e29ddd5a187ee376e3890b05378d02985
Author: ericu@chromium.org <ericu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Date: Tue May 27 22:00:54 2014

Add most of the metadata-handling code for blobs.  It's not quite all there, but
this is the biggest chunk I can pull out vaguely cleanly.  It does contain a
couple of fake calls to keep the compiler happy.
This CL also makes SetUpMetadata a member in order to ease testing in a later CL.

This depends on https://codereview.chromium.org/261843004/.

BUG= 108012 

Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=270016

Review URL: https://codereview.chromium.org/266333002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@273048 0039d316-1c4b-4281-b951-d872f2087c98


Project Member Comment 149 by bugdroid1@chromium.org, May 27, 2014
------------------------------------------------------------------
r273048 | ericu@chromium.org | 2014-05-27T22:00:54.231225Z

Changed paths:
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_leveldb_coding.cc?r1=273048&r2=273047&pathrev=273048
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.cc?r1=273048&r2=273047&pathrev=273048
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.h?r1=273048&r2=273047&pathrev=273048

Add most of the metadata-handling code for blobs.  It's not quite all there, but
this is the biggest chunk I can pull out vaguely cleanly.  It does contain a
couple of fake calls to keep the compiler happy.
This CL also makes SetUpMetadata a member in order to ease testing in a later CL.

This depends on https://codereview.chromium.org/261843004/.

BUG= 108012 

Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=270016

Review URL: https://codereview.chromium.org/266333002
-----------------------------------------------------------------
Project Member Comment 150 by bugdroid1@chromium.org, Jun 4, 2014
------------------------------------------------------------------
r274685 | ericu@chromium.org | 2014-06-04T00:34:10.242923Z

Changed paths:
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.cc?r1=274685&r2=274684&pathrev=274685
   M http://src.chromium.org/viewvc/chrome/trunk/src/tools/metrics/histograms/histograms.xml?r1=274685&r2=274684&pathrev=274685
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store.h?r1=274685&r2=274684&pathrev=274685
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/leveldb/leveldb_comparator.h?r1=274685&r2=274684&pathrev=274685
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_fake_backing_store.cc?r1=274685&r2=274684&pathrev=274685
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_fake_backing_store.h?r1=274685&r2=274684&pathrev=274685
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_leveldb_coding.h?r1=274685&r2=274684&pathrev=274685
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_database_unittest.cc?r1=274685&r2=274684&pathrev=274685
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_database.cc?r1=274685&r2=274684&pathrev=274685
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_transaction_unittest.cc?r1=274685&r2=274684&pathrev=274685
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_context_impl.cc?r1=274685&r2=274684&pathrev=274685
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_transaction.cc?r1=274685&r2=274684&pathrev=274685
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_transaction.h?r1=274685&r2=274684&pathrev=274685
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_backing_store_unittest.cc?r1=274685&r2=274684&pathrev=274685

This is the master CL that contains the whole remaining Chromium side.

See https://codereview.chromium.org/18590006/ for the Blink side.
See https://docs.google.com/a/chromium.org/document/d/1Kdr4pcFt4QBDLLQn-fY4kZgw6ptmK23lthGZdQMVh2Y/edit for the big picture document [chromium.org account required].
Read-only view at https://docs.google.com/document/d/1Kdr4pcFt4QBDLLQn-fY4kZgw6ptmK23lthGZdQMVh2Y/pub [no account required].


BUG= 108012 

Review URL: https://codereview.chromium.org/18023022
-----------------------------------------------------------------
Project Member Comment 151 by bugdroid1@chromium.org, Jun 4, 2014
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/67bb75b97060c6e08912b1b1696b45374189535b

commit 67bb75b97060c6e08912b1b1696b45374189535b
Author: ericu@chromium.org <ericu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Date: Wed Jun 04 00:34:10 2014

This is the master CL that contains the whole remaining Chromium side.

See https://codereview.chromium.org/18590006/ for the Blink side.
See https://docs.google.com/a/chromium.org/document/d/1Kdr4pcFt4QBDLLQn-fY4kZgw6ptmK23lthGZdQMVh2Y/edit for the big picture document [chromium.org account required].
Read-only view at https://docs.google.com/document/d/1Kdr4pcFt4QBDLLQn-fY4kZgw6ptmK23lthGZdQMVh2Y/pub [no account required].


BUG= 108012 

Review URL: https://codereview.chromium.org/18023022

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@274685 0039d316-1c4b-4281-b951-d872f2087c98


Project Member Comment 152 by bugdroid1@chromium.org, Jun 5, 2014
The following revision refers to this bug:
  https://chrome-internal.googlesource.com/bling/chromium.git/+/67bb75b97060c6e08912b1b1696b45374189535b

commit 67bb75b97060c6e08912b1b1696b45374189535b
Author: ericu@chromium.org <ericu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Date: Wed Jun 04 00:34:10 2014

Comment 153 by jsbell@google.com, Jun 5, 2014
Hey, bug watchers! We're on the verge of turning on Blob support for Indexed DB. One more patch remains (hopefully) - https://codereview.chromium.org/18590006/

If you're the sort of brave soul who builds Chromium you could try applying the above patch locally. If not, watch here for one last change. We'll want you to try out the next Canary build after that.

Project Member Comment 154 by bugdroid1@chromium.org, Jun 7, 2014
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/7c303f05a12233a23ffbe25c9a36f35dcb7bbb6e

commit 7c303f05a12233a23ffbe25c9a36f35dcb7bbb6e
Author: ericu@chromium.org <ericu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Date: Sat Jun 07 05:15:32 2014

Fix a bug wherein we'd release a scoped_ptr and dereference it in the same line of code.  That worked by luck on some compilers, but failed on OSX, in a way only revealed by tryjobs on a subsequent blink change.

BUG= 108012 

Review URL: https://codereview.chromium.org/320103003

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@275623 0039d316-1c4b-4281-b951-d872f2087c98


Project Member Comment 155 by bugdroid1@chromium.org, Jun 7, 2014
------------------------------------------------------------------
r275623 | ericu@chromium.org | 2014-06-07T05:15:32.893991Z

Changed paths:
   M http://src.chromium.org/viewvc/chrome/trunk/src/content/browser/indexed_db/indexed_db_callbacks.cc?r1=275623&r2=275622&pathrev=275623

Fix a bug wherein we'd release a scoped_ptr and dereference it in the same line of code.  That worked by luck on some compilers, but failed on OSX, in a way only revealed by tryjobs on a subsequent blink change.

BUG= 108012 

Review URL: https://codereview.chromium.org/320103003
-----------------------------------------------------------------
Comment 156 by cos...@gmail.com, Jun 7, 2014
Thank you very much for the hard work! I can try it out after the last CL lands.
Project Member Comment 157 by bugdroid1@chromium.org, Jun 9, 2014
The following revision refers to this bug:
  http://src.chromium.org/viewvc/blink?view=rev&rev=175802

------------------------------------------------------------------
r175802 | ericu@chromium.org | 2014-06-09T16:26:21.735409Z

Changed paths:
   M http://src.chromium.org/viewvc/blink/trunk/LayoutTests/storage/indexeddb/keypath-intrinsic-properties-expected.txt?r1=175802&r2=175801&pathrev=175802
   A http://src.chromium.org/viewvc/blink/trunk/LayoutTests/storage/indexeddb/blob-valid-after-deletion.html?r1=175802&r2=175801&pathrev=175802
   A http://src.chromium.org/viewvc/blink/trunk/LayoutTests/storage/indexeddb/blob-valid-before-commit-expected.txt?r1=175802&r2=175801&pathrev=175802
   A http://src.chromium.org/viewvc/blink/trunk/LayoutTests/storage/indexeddb/blob-delete-objectstore-db-expected.txt?r1=175802&r2=175801&pathrev=175802
   A http://src.chromium.org/viewvc/blink/trunk/LayoutTests/storage/indexeddb/blob-basics-metadata.html?r1=175802&r2=175801&pathrev=175802
   D http://src.chromium.org/viewvc/blink/trunk/LayoutTests/storage/indexeddb/noblobs.html?r1=175802&r2=175801&pathrev=175802
   M http://src.chromium.org/viewvc/blink/trunk/Source/bindings/v8/SerializedScriptValue.h?r1=175802&r2=175801&pathrev=175802
   A http://src.chromium.org/viewvc/blink/trunk/LayoutTests/storage/indexeddb/blob-valid-before-commit.html?r1=175802&r2=175801&pathrev=175802
   M http://src.chromium.org/viewvc/blink/trunk/LayoutTests/storage/indexeddb/resources/keypath-intrinsic-properties.js?r1=175802&r2=175801&pathrev=175802
   A http://src.chromium.org/viewvc/blink/trunk/LayoutTests/storage/indexeddb/blob-delete-objectstore-db.html?r1=175802&r2=175801&pathrev=175802
   M http://src.chromium.org/viewvc/blink/trunk/Source/modules/indexeddb/IDBObjectStore.cpp?r1=175802&r2=175801&pathrev=175802
   A http://src.chromium.org/viewvc/blink/trunk/LayoutTests/storage/indexeddb/blob-valid-after-deletion-expected.txt?r1=175802&r2=175801&pathrev=175802
   A http://src.chromium.org/viewvc/blink/trunk/LayoutTests/storage/indexeddb/blob-basics-metadata-expected.txt?r1=175802&r2=175801&pathrev=175802
   D http://src.chromium.org/viewvc/blink/trunk/LayoutTests/storage/indexeddb/noblobs-expected.txt?r1=175802&r2=175801&pathrev=175802

This is the master CL that contains the whole remaining Blink side.  It turns on Blob support in IDB, so it has to wait until the Chromium side has completely landed.

See https://codereview.chromium.org/18023022/ for the Chromium side.
See https://docs.google.com/a/chromium.org/document/d/1Kdr4pcFt4QBDLLQn-fY4kZgw6ptmK23lthGZdQMVh2Y/edit for the big picture document [chromium.org account required].
Read-only view at https://docs.google.com/document/d/1Kdr4pcFt4QBDLLQn-fY4kZgw6ptmK23lthGZdQMVh2Y/pub [no account required].

BUG= 108012 

Review URL: https://codereview.chromium.org/18590006
-----------------------------------------------------------------
Comment 158 by ericu@chromium.org, Jun 10, 2014
Status: Fixed
Done ;'>.

"If you're the sort of brave soul who builds Chromium you could try applying the above patch locally. If not, watch here for one last change. We'll want you to try out the next Canary build after that."

Is there a build ready to start testing it?
Comment 160 by cos...@gmail.com, Jul 8, 2014
According to omahaproxy, either Dev or Canary should work.
Project Member Comment 161 by bugdroid1@chromium.org, Jul 26, 2014
The following revision refers to this bug:
  http://src.chromium.org/viewvc/blink?view=rev&rev=178979

------------------------------------------------------------------
r178979 | jsbell@chromium.org | 2014-07-26T05:13:44.995631Z

Changed paths:
   M http://src.chromium.org/viewvc/blink/trunk/LayoutTests/storage/indexeddb/structured-clone-expected.txt?r1=178979&r2=178978&pathrev=178979
   M http://src.chromium.org/viewvc/blink/trunk/LayoutTests/storage/indexeddb/structured-clone.html?r1=178979&r2=178978&pathrev=178979

IndexedDB: Enable Blob/File/FileList structured clone tests

These test cases should have been enabled when Blob support landed, but
were missed.

BUG= 108012 
R=cmumford@chromium.org,dgrogan@chromium.org

Review URL: https://codereview.chromium.org/414223008
-----------------------------------------------------------------
I was excited to try this out, as v37 hit the stable channel this week. It isn't stable.

Steps:
• write Blobs to the IndexedDB.
• close the browser.
• wait a few minutes.
• open the browser
Result: All blobs from the database return File not Found errors.

Test data was 1900 images with a total size of 60MiB.

I think I will have to go back to storing data-URIs and converting them into blobs on application load.
Comment 163 by ericu@chromium.org, Aug 30, 2014
@bloodspill if you have a reproducible test case, please log a new bug [don't just comment here].
Please confirm that the writes complete, and the transaction commits, before killing the browser.  If it hasn't committed, of course the blobs won't be there.
I can confirm that the issue is not present in Canary (v39.0.2141.0).
I couldn't find an issue in the tracker that describes this problem, so I don't know what other change led to this being fixed — no idea when it will be in Stable.
Comment 165 by jsb...@chromium.org, Aug 31, 2014
Any chance issue 408601 is the culprit? I landed a fix a couple of days ago, and the fix would be in the v39.0.2141.0 canary. I don't recall any other relevant fixes that'd be in 39 but not 37, but there may have been some.

If you can share a repro - even if it's no longer reproducing in canary - it'd help us identify the fix (and ensure it's really fixed, and not just flaky) and justify merging the fix to earlier versions.
Looking at the change for #408120 again, it's possible?
However I was experiencing different behaviour from the browser before and after closing it.
Before closing the browser I had the mime-type text/plain complaint. <img> tags still loaded them fine.
After restarting the browser I had 404 errors and <img> tags failed completely.
Sign in to add a comment