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

Issue 2601983002: [IndexedDB] Adding transaction and value support to observers (Closed)

Created:
3 years, 11 months ago by dmurph
Modified:
3 years, 11 months ago
Reviewers:
palmer, jsbell, cmumford, pwnall
CC:
Aaron Boodman, abarth-chromium, chromium-reviews, cmumford, darin (slow to review), darin-cc_chromium.org, jam, jsbell+idb_chromium.org, qsr+mojo_chromium.org, viettrungluu+watch_chromium.org, yzshen+watch_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[IndexedDB] Adding transaction and value support to observers BUG=662248, 662246, 609934 R=pwnall@chromium.org,jsbell@chromium.org,cmumford@chromium.org Review-Url: https://codereview.chromium.org/2601983002 Cr-Commit-Position: refs/heads/master@{#444514} Committed: https://chromium.googlesource.com/chromium/src/+/a1319a867978d9700653ecc5a6592d24b6367a2c

Patch Set 1 #

Patch Set 2 : renderer changes done #

Patch Set 3 : added values test #

Patch Set 4 : rebase #

Patch Set 5 : Transactions working #

Total comments: 32

Patch Set 6 : Replying to comments, disallowed observing from versionchange txn #

Total comments: 28

Patch Set 7 : Victor's comments #

Patch Set 8 : Added data consistancy test, and fixed transactions to start at correct time #

Patch Set 9 : Moved transaction creation to SendObservations #

Total comments: 18

Patch Set 10 : Josh's comments #

Patch Set 11 : fixed bit check #

Total comments: 4

Patch Set 12 : Chris's comments, and simplified NewObserverTransactionId method #

Patch Set 13 : rebase #

Total comments: 8

Patch Set 14 : Renaming ConvertValue to ConvertAndEraseValue #

Patch Set 15 : added comments and bug link #

Unified diffs Side-by-side diffs Delta from patch set Stats (+570 lines, -223 lines) Patch
M content/browser/indexed_db/indexed_db_callbacks.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +4 lines, -0 lines 0 comments Download
M content/browser/indexed_db/indexed_db_callbacks.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 5 chunks +13 lines, -12 lines 0 comments Download
M content/browser/indexed_db/indexed_db_connection.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +10 lines, -0 lines 0 comments Download
M content/browser/indexed_db/indexed_db_connection.cc View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +8 lines, -0 lines 0 comments Download
M content/browser/indexed_db/indexed_db_database.h View 1 2 3 4 5 1 chunk +3 lines, -1 line 0 comments Download
M content/browser/indexed_db/indexed_db_database.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 6 chunks +46 lines, -10 lines 0 comments Download
M content/browser/indexed_db/indexed_db_observer.h View 1 2 3 4 1 chunk +4 lines, -0 lines 0 comments Download
M content/browser/indexed_db/indexed_db_transaction.h View 1 2 3 4 5 6 7 3 chunks +8 lines, -4 lines 0 comments Download
M content/browser/indexed_db/indexed_db_transaction.cc View 1 2 3 4 5 6 7 8 9 10 11 12 4 chunks +14 lines, -9 lines 0 comments Download
M content/browser/indexed_db/indexed_db_transaction_coordinator.h View 1 2 3 4 5 6 2 chunks +5 lines, -1 line 0 comments Download
M content/browser/indexed_db/indexed_db_transaction_coordinator.cc View 1 2 3 4 5 6 7 8 9 1 chunk +11 lines, -0 lines 0 comments Download
M content/browser/indexed_db/list_set.h View 1 2 3 4 1 chunk +7 lines, -0 lines 0 comments Download
M content/browser/indexed_db/list_set_unittest.cc View 1 2 3 4 5 6 7 8 9 1 chunk +17 lines, -0 lines 0 comments Download
M content/child/indexed_db/indexed_db_callbacks_impl.h View 1 2 2 chunks +4 lines, -0 lines 0 comments Download
M content/child/indexed_db/indexed_db_callbacks_impl.cc View 1 2 3 4 5 6 7 8 9 3 chunks +14 lines, -11 lines 0 comments Download
M content/child/indexed_db/indexed_db_database_callbacks_impl.cc View 1 2 3 2 chunks +22 lines, -2 lines 0 comments Download
M content/common/indexed_db/indexed_db.mojom View 1 1 chunk +7 lines, -0 lines 0 comments Download
M third_party/WebKit/LayoutTests/storage/indexeddb/observer.html View 1 2 3 4 5 6 1 chunk +3 lines, -1 line 0 comments Download
A third_party/WebKit/LayoutTests/storage/indexeddb/observer-transaction-test.html View 1 2 3 4 5 6 7 1 chunk +49 lines, -0 lines 0 comments Download
M third_party/WebKit/LayoutTests/storage/indexeddb/resources/generic-idb-operations.js View 1 2 3 4 5 6 2 chunks +16 lines, -13 lines 0 comments Download
M third_party/WebKit/LayoutTests/storage/indexeddb/resources/observer.js View 1 2 3 4 5 6 1 chunk +41 lines, -105 lines 0 comments Download
M third_party/WebKit/LayoutTests/storage/indexeddb/resources/observer-actions.js View 1 2 3 4 5 6 7 2 chunks +24 lines, -2 lines 0 comments Download
M third_party/WebKit/LayoutTests/storage/indexeddb/resources/observer-tests.js View 1 2 3 4 5 6 7 10 chunks +107 lines, -25 lines 0 comments Download
M third_party/WebKit/Source/modules/indexeddb/IDBDatabase.h View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +4 lines, -1 line 0 comments Download
M third_party/WebKit/Source/modules/indexeddb/IDBDatabase.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +23 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/modules/indexeddb/IDBDatabaseCallbacks.h View 1 2 3 4 5 6 2 chunks +6 lines, -1 line 0 comments Download
M third_party/WebKit/Source/modules/indexeddb/IDBDatabaseCallbacks.cpp View 1 2 3 4 5 6 1 chunk +6 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/modules/indexeddb/IDBObserver.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +7 lines, -1 line 0 comments Download
M third_party/WebKit/Source/modules/indexeddb/IDBObserverChanges.h View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +12 lines, -5 lines 0 comments Download
M third_party/WebKit/Source/modules/indexeddb/IDBObserverChanges.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +19 lines, -7 lines 0 comments Download
M third_party/WebKit/Source/modules/indexeddb/IDBTransaction.h View 1 2 3 2 chunks +11 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/modules/indexeddb/IDBTransaction.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +29 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/modules/indexeddb/WebIDBDatabaseCallbacksImpl.h View 1 2 3 4 5 6 2 chunks +6 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/modules/indexeddb/WebIDBDatabaseCallbacksImpl.cpp View 1 2 3 4 5 6 2 chunks +4 lines, -2 lines 0 comments Download
M third_party/WebKit/public/platform/modules/indexeddb/WebIDBDatabaseCallbacks.h View 1 2 chunks +6 lines, -1 line 0 comments Download

Messages

Total messages: 67 (50 generated)
dmurph
Hello Josh, Victor, and Chris! Can you all PTAL at this patch? I've added 'value' ...
3 years, 11 months ago (2017-01-07 01:07:14 UTC) #7
cmumford
https://codereview.chromium.org/2601983002/diff/80001/content/browser/indexed_db/indexed_db_connection.cc File content/browser/indexed_db/indexed_db_connection.cc (right): https://codereview.chromium.org/2601983002/diff/80001/content/browser/indexed_db/indexed_db_connection.cc#newcode161 content/browser/indexed_db/indexed_db_connection.cc:161: int64_t IndexedDBConnection::NextObserverTransactionId() { nit: "Next*" might be interpreted as ...
3 years, 11 months ago (2017-01-09 21:31:26 UTC) #12
cmumford
https://codereview.chromium.org/2601983002/diff/80001/content/child/indexed_db/indexed_db_database_callbacks_impl.cc File content/child/indexed_db/indexed_db_database_callbacks_impl.cc (right): https://codereview.chromium.org/2601983002/diff/80001/content/child/indexed_db/indexed_db_database_callbacks_impl.cc#newcode55 content/child/indexed_db/indexed_db_database_callbacks_impl.cc:55: observer_transactions; On 2017/01/09 21:31:26, cmumford wrote: > Is observer_transactions ...
3 years, 11 months ago (2017-01-09 21:33:02 UTC) #13
dmurph
Thanks! Replied to comments. I also now disallow observing on a versionchange transaction, as per ...
3 years, 11 months ago (2017-01-10 00:17:39 UTC) #17
pwnall
Comments on your previous patch. https://codereview.chromium.org/2601983002/diff/80001/content/browser/indexed_db/indexed_db_connection.h File content/browser/indexed_db/indexed_db_connection.h (right): https://codereview.chromium.org/2601983002/diff/80001/content/browser/indexed_db/indexed_db_connection.h#newcode87 content/browser/indexed_db/indexed_db_connection.h:87: int64_t next_observer_transaction_id_ = 1ll ...
3 years, 11 months ago (2017-01-10 01:01:24 UTC) #18
pwnall
Here are a few more small comments. https://codereview.chromium.org/2601983002/diff/100001/third_party/WebKit/LayoutTests/storage/indexeddb/observer.html File third_party/WebKit/LayoutTests/storage/indexeddb/observer.html (right): https://codereview.chromium.org/2601983002/diff/100001/third_party/WebKit/LayoutTests/storage/indexeddb/observer.html#newcode1 third_party/WebKit/LayoutTests/storage/indexeddb/observer.html:1: <html> Please ...
3 years, 11 months ago (2017-01-10 01:41:12 UTC) #19
dmurph
Thanks! https://codereview.chromium.org/2601983002/diff/80001/content/browser/indexed_db/indexed_db_connection.h File content/browser/indexed_db/indexed_db_connection.h (right): https://codereview.chromium.org/2601983002/diff/80001/content/browser/indexed_db/indexed_db_connection.h#newcode87 content/browser/indexed_db/indexed_db_connection.h:87: int64_t next_observer_transaction_id_ = 1ll << 32; On 2017/01/10 ...
3 years, 11 months ago (2017-01-10 20:40:08 UTC) #24
pwnall
https://codereview.chromium.org/2601983002/diff/80001/content/browser/indexed_db/indexed_db_connection.h File content/browser/indexed_db/indexed_db_connection.h (right): https://codereview.chromium.org/2601983002/diff/80001/content/browser/indexed_db/indexed_db_connection.h#newcode87 content/browser/indexed_db/indexed_db_connection.h:87: int64_t next_observer_transaction_id_ = 1ll << 32; On 2017/01/10 20:39:59, ...
3 years, 11 months ago (2017-01-10 23:21:54 UTC) #27
dmurph
As per the test failure, I created a test that specifically tests the data consistency ...
3 years, 11 months ago (2017-01-12 01:34:07 UTC) #30
jsbell
Feedback on the content/ side - I'll look at the tests/blink part tomorrow. https://codereview.chromium.org/2601983002/diff/160001/content/browser/indexed_db/indexed_db_callbacks.cc File ...
3 years, 11 months ago (2017-01-13 00:14:12 UTC) #35
dmurph
https://codereview.chromium.org/2601983002/diff/160001/content/browser/indexed_db/indexed_db_callbacks.cc File content/browser/indexed_db/indexed_db_callbacks.cc (right): https://codereview.chromium.org/2601983002/diff/160001/content/browser/indexed_db/indexed_db_callbacks.cc#newcode134 content/browser/indexed_db/indexed_db_callbacks.cc:134: /* static */ ::indexed_db::mojom::ValuePtr IndexedDBCallbacks::ConvertValue( On 2017/01/13 00:14:12, jsbell ...
3 years, 11 months ago (2017-01-13 01:50:43 UTC) #41
cmumford
lgtm https://codereview.chromium.org/2601983002/diff/200001/content/browser/indexed_db/indexed_db_connection.cc File content/browser/indexed_db/indexed_db_connection.cc (right): https://codereview.chromium.org/2601983002/diff/200001/content/browser/indexed_db/indexed_db_connection.cc#newcode18 content/browser/indexed_db/indexed_db_connection.cc:18: static const int64_t kMaxObserverTransactionId = -1ll; Add newline ...
3 years, 11 months ago (2017-01-17 20:58:11 UTC) #45
dmurph
+palmer for security review of content/common/indexed_db/indexed_db.mojom After chatting with Victor I simplified the ID generation ...
3 years, 11 months ago (2017-01-17 23:28:04 UTC) #49
palmer
LGTM from an IPC security perspective. Some code style nits and comments. https://codereview.chromium.org/2601983002/diff/240001/content/browser/indexed_db/indexed_db_connection.cc File content/browser/indexed_db/indexed_db_connection.cc ...
3 years, 11 months ago (2017-01-18 19:56:01 UTC) #58
dmurph
Thanks! https://codereview.chromium.org/2601983002/diff/240001/content/browser/indexed_db/indexed_db_connection.cc File content/browser/indexed_db/indexed_db_connection.cc (right): https://codereview.chromium.org/2601983002/diff/240001/content/browser/indexed_db/indexed_db_connection.cc#newcode166 content/browser/indexed_db/indexed_db_connection.cc:166: return static_cast<int64_t>(next_observer_transaction_id_++) << 32; On 2017/01/18 19:56:01, palmer ...
3 years, 11 months ago (2017-01-18 21:00:58 UTC) #60
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2601983002/280001
3 years, 11 months ago (2017-01-18 21:02:29 UTC) #64
commit-bot: I haz the power
3 years, 11 months ago (2017-01-18 22:30:40 UTC) #67
Message was sent while issue was closed.
Committed patchset #15 (id:280001) as
https://chromium.googlesource.com/chromium/src/+/a1319a867978d9700653ecc5a659...

Powered by Google App Engine
This is Rietveld 408576698