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

Issue 325683002: [IndexedDB] Use consistent enums on both sides of IPC. (Closed)

Created:
6 years, 6 months ago by Pritam Nikam
Modified:
6 years, 6 months ago
Reviewers:
dglazkov, jsbell
CC:
abarth-chromium, alecflett, blink-reviews, cmumford, dglazkov+blink, dgrogan, ericu+idb_chromium.org, jamesr, jsbell+idb_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/blink.git@master
Visibility:
Public.

Description

[IndexedDB] Use consistent enums on both sides of IPC. Numerous IndexedDB IPC messages sent renderer->browser are defined members that are enums from Blink (public/platform), and on receipt are static_cast to types defined in Chromium: blink::WebIDBCursor::Direction => indexed_db::CursorDirection blink::WebIDBDatabase::TaskType => IndexedDBDatabase::TaskType blink::WebIDBDatabase::PutMode => IndexedDBDatabase::PutMode blink::WebIDBDatabase::TransactionMode => uint16 => indexed_db::TransactionMode Nothing enforces the equality of these enums at compile time. So the approach adopted here is to move the Blink-side enums into public/platform/WebIDBTypes.h and use it everywhere. Patch spread across chromium content side as well as on Blink side. Chromium side: https://codereview.chromium.org/320833002 Blink side: https://codereview.chromium.org/325683002 BUG=381848 R=dglazkov@chromium.org, jsbell@chromium.org Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=176435

Patch Set 1 #

Total comments: 18

Patch Set 2 : Incorporated review comments. #

Total comments: 2

Patch Set 3 : Incorporated review comments. #

Patch Set 4 : rebase patch. #

Patch Set 5 : Incorporated review comments as build bot was failing with previous patch. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+135 lines, -97 lines) Patch
M Source/modules/indexeddb/IDBCursor.h View 1 4 chunks +5 lines, -4 lines 0 comments Download
M Source/modules/indexeddb/IDBCursor.cpp View 1 5 chunks +14 lines, -14 lines 0 comments Download
M Source/modules/indexeddb/IDBCursorWithValue.h View 1 3 chunks +3 lines, -2 lines 0 comments Download
M Source/modules/indexeddb/IDBCursorWithValue.cpp View 1 1 chunk +2 lines, -2 lines 0 comments Download
M Source/modules/indexeddb/IDBDatabase.cpp View 1 2 3 4 2 chunks +2 lines, -1 line 0 comments Download
M Source/modules/indexeddb/IDBIndex.h View 1 2 chunks +2 lines, -1 line 0 comments Download
M Source/modules/indexeddb/IDBIndex.cpp View 1 4 chunks +5 lines, -5 lines 0 comments Download
M Source/modules/indexeddb/IDBObjectStore.h View 1 3 chunks +4 lines, -3 lines 0 comments Download
M Source/modules/indexeddb/IDBObjectStore.cpp View 1 8 chunks +12 lines, -12 lines 0 comments Download
M Source/modules/indexeddb/IDBRequest.h View 1 2 3 4 3 chunks +3 lines, -2 lines 0 comments Download
M Source/modules/indexeddb/IDBRequest.cpp View 1 2 3 4 2 chunks +2 lines, -2 lines 0 comments Download
M Source/modules/indexeddb/IDBTransaction.h View 1 2 3 6 chunks +8 lines, -7 lines 0 comments Download
M Source/modules/indexeddb/IDBTransaction.cpp View 1 2 3 5 chunks +12 lines, -12 lines 0 comments Download
M Source/modules/indexeddb/IDBTransactionTest.cpp View 1 2 chunks +2 lines, -2 lines 0 comments Download
M Source/modules/indexeddb/InspectorIndexedDBAgent.cpp View 1 2 chunks +3 lines, -2 lines 0 comments Download
M public/platform/WebIDBCursor.h View 1 2 3 4 2 chunks +8 lines, -7 lines 0 comments Download
M public/platform/WebIDBDatabase.h View 1 2 3 4 3 chunks +20 lines, -19 lines 0 comments Download
M public/platform/WebIDBTypes.h View 1 2 1 chunk +28 lines, -0 lines 0 comments Download

Messages

Total messages: 41 (0 generated)
Pritam Nikam
Hi, I've adopted 2nd approach i.e. to move the Blink-side enums into public/platform/WebIDBTypes.h and use ...
6 years, 6 months ago (2014-06-09 10:43:36 UTC) #1
jsbell
Initial feedback. Does Chromium compile with only this change (but not the Chromium one?) or ...
6 years, 6 months ago (2014-06-09 16:27:09 UTC) #2
Pritam Nikam
Thanks jsbell! Incorporated review comments and new patch is ready for review. Please have a ...
6 years, 6 months ago (2014-06-11 14:07:47 UTC) #3
Pritam Nikam
On 2014/06/09 16:27:09, jsbell wrote: > Initial feedback. > > Does Chromium compile with only ...
6 years, 6 months ago (2014-06-11 14:12:03 UTC) #4
jsbell
On 2014/06/11 14:12:03, Pritam Nikam wrote: > In my opinion both patches are needed as ...
6 years, 6 months ago (2014-06-11 16:21:40 UTC) #5
jsbell
l*g*t*m but will need to be split up for landing You can probably define the ...
6 years, 6 months ago (2014-06-11 16:28:07 UTC) #6
Pritam Nikam
Thanks jsbell! I've uploaded a new patch (#3) with only blink side changes incorporating review ...
6 years, 6 months ago (2014-06-12 09:36:03 UTC) #7
Pritam Nikam
On 2014/06/11 16:21:40, jsbell wrote: > On 2014/06/11 14:12:03, Pritam Nikam wrote: > > In ...
6 years, 6 months ago (2014-06-12 09:37:58 UTC) #8
jsbell
lgtm! I just submitted some try jobs. dglazkov@ - can you OWNERS stamp the public ...
6 years, 6 months ago (2014-06-12 16:20:46 UTC) #9
dglazkov
lgtm
6 years, 6 months ago (2014-06-12 16:22:29 UTC) #10
Pritam Nikam
The CQ bit was checked by pritam.nikam@samsung.com
6 years, 6 months ago (2014-06-12 18:07:54 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/pritam.nikam@samsung.com/325683002/40001
6 years, 6 months ago (2014-06-12 18:08:29 UTC) #12
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 6 months ago (2014-06-12 18:08:51 UTC) #13
commit-bot: I haz the power
Failed to apply patch for Source/modules/indexeddb/IDBTransaction.cpp: While running patch -p1 --forward --force --no-backup-if-mismatch; patching file ...
6 years, 6 months ago (2014-06-12 18:08:53 UTC) #14
Pritam Nikam
The CQ bit was checked by pritam.nikam@samsung.com
6 years, 6 months ago (2014-06-12 18:18:22 UTC) #15
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/pritam.nikam@samsung.com/325683002/40001
6 years, 6 months ago (2014-06-12 18:19:52 UTC) #16
jsbell
Just needs a rebase due to r176011
6 years, 6 months ago (2014-06-12 18:20:30 UTC) #17
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 6 months ago (2014-06-12 18:21:13 UTC) #18
commit-bot: I haz the power
Failed to apply patch for Source/modules/indexeddb/IDBTransaction.cpp: While running patch -p1 --forward --force --no-backup-if-mismatch; patching file ...
6 years, 6 months ago (2014-06-12 18:21:15 UTC) #19
Pritam Nikam
The CQ bit was unchecked by pritam.nikam@samsung.com
6 years, 6 months ago (2014-06-12 18:21:26 UTC) #20
Pritam Nikam
The CQ bit was checked by pritam.nikam@samsung.com
6 years, 6 months ago (2014-06-13 04:35:32 UTC) #21
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/pritam.nikam@samsung.com/325683002/60001
6 years, 6 months ago (2014-06-13 04:35:59 UTC) #22
commit-bot: I haz the power
FYI, CQ is re-trying this CL (attempt #1). The failing builders are: android_blink_compile_dbg on tryserver.blink ...
6 years, 6 months ago (2014-06-13 06:12:21 UTC) #23
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 6 months ago (2014-06-13 06:29:49 UTC) #24
commit-bot: I haz the power
Try jobs failed on following builders: linux_gpu on tryserver.chromium.gpu (http://build.chromium.org/p/tryserver.chromium.gpu/builders/linux_gpu/builds/27290)
6 years, 6 months ago (2014-06-13 06:29:50 UTC) #25
Pritam Nikam
The CQ bit was checked by pritam.nikam@samsung.com
6 years, 6 months ago (2014-06-13 07:21:28 UTC) #26
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/pritam.nikam@samsung.com/325683002/80001
6 years, 6 months ago (2014-06-13 07:22:28 UTC) #27
commit-bot: I haz the power
FYI, CQ is re-trying this CL (attempt #1). The failing builders are: linux_blink_dbg on tryserver.blink ...
6 years, 6 months ago (2014-06-13 08:41:28 UTC) #28
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 6 months ago (2014-06-13 09:07:01 UTC) #29
commit-bot: I haz the power
Try jobs failed on following builders: mac_blink_rel on tryserver.blink (http://build.chromium.org/p/tryserver.blink/builders/mac_blink_rel/builds/11330)
6 years, 6 months ago (2014-06-13 09:07:02 UTC) #30
jsbell
I dunno why the bots were showing timeouts for the tests. Maybe a slight enum ...
6 years, 6 months ago (2014-06-17 19:30:23 UTC) #31
Pritam Nikam
The CQ bit was checked by pritam.nikam@samsung.com
6 years, 6 months ago (2014-06-18 12:15:43 UTC) #32
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/pritam.nikam@samsung.com/325683002/100001
6 years, 6 months ago (2014-06-18 12:16:11 UTC) #33
Pritam Nikam
Thanks jsbell! All cases failing due to this mismatch.Patch you have suggested will solve this ...
6 years, 6 months ago (2014-06-18 12:29:54 UTC) #34
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 6 months ago (2014-06-18 14:00:15 UTC) #35
commit-bot: I haz the power
Try jobs failed on following builders: mac_blink_rel on tryserver.blink (http://build.chromium.org/p/tryserver.blink/builders/mac_blink_rel/builds/11859)
6 years, 6 months ago (2014-06-18 14:00:16 UTC) #36
Pritam Nikam
Hi jsbell! Are these failures related to IndexedDB changes made with this patch? MAC Rel: ...
6 years, 6 months ago (2014-06-18 14:02:37 UTC) #37
jsbell
On 2014/06/18 14:02:37, Pritam Nikam wrote: > Hi jsbell! > > Are these failures related ...
6 years, 6 months ago (2014-06-18 16:21:13 UTC) #38
Pritam Nikam
On 2014/06/18 16:21:13, jsbell wrote: > On 2014/06/18 14:02:37, Pritam Nikam wrote: > > Hi ...
6 years, 6 months ago (2014-06-18 16:54:58 UTC) #39
jsbell
Committed patchset #5 manually as r176435 (presubmit successful).
6 years, 6 months ago (2014-06-18 17:12:31 UTC) #40
Pritam Nikam
6 years, 6 months ago (2014-06-19 05:36:33 UTC) #41
Message was sent while issue was closed.
On 2014/06/18 17:12:31, jsbell wrote:
> Committed patchset #5 manually as r176435 (presubmit successful).

Thanks jsbell! 
I'll wait till it rolled out and then submit one in chromium side.

Powered by Google App Engine
This is Rietveld 408576698