Bug 149603

Summary: Add an IDB Server that can roundtrip a request back to the client
Product: WebKit Reporter: Brady Eidson <beidson>
Component: WebCore Misc.Assignee: Brady Eidson <beidson>
Status: RESOLVED FIXED    
Severity: Normal CC: achristensen, alecflett, bfulgham, commit-queue, japhet, jsbell
Priority: P2    
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 149117    
Attachments:
Description Flags
Patch v1
none
Patch v2 - Style and CMakeList
none
Patch v3 achristensen: review+, achristensen: commit-queue-

Description Brady Eidson 2015-09-28 13:49:36 PDT
Add an IDB Server that can roundtrip a request back to the client

This is a critical piece of IDB infrastructure that:
-Puts a database client/server divide in place.
-Client synchronously sends requests to the server, and asynchronously receives a response back from it.
-Introduces a class structure that makes it easy for WebKit2 to add a thin layer to replace the in-process server with an out-of-process server.

To allow for the most basic of tests, the "delete database" request is hard coded as always failing with an indeterminate error.
Comment 1 Brady Eidson 2015-09-28 13:53:08 PDT
Created attachment 262016 [details]
Patch v1
Comment 2 WebKit Commit Bot 2015-09-28 13:55:16 PDT
Attachment 262016 [details] did not pass style-queue:


ERROR: Source/WebCore/page/Page.cpp:30:  Alphabetical sorting problem.  [build/include_order] [4]
ERROR: Source/WebCore/Modules/indexeddb/shared/IDBRequestIdentifier.h:49:  Place brace on its own line for function definitions.  [whitespace/braces] [4]
ERROR: Source/WebCore/Modules/indexeddb/shared/IDBRequestIdentifier.h:59:  Place brace on its own line for function definitions.  [whitespace/braces] [4]
ERROR: Source/WebCore/Modules/indexeddb/client/IDBOpenDBRequestImpl.cpp:72:  One line control clauses should not use braces.  [whitespace/braces] [4]
Total errors found: 4 in 45 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 3 Brady Eidson 2015-09-28 14:22:04 PDT
Created attachment 262021 [details]
Patch v2 - Style and CMakeList
Comment 4 WebKit Commit Bot 2015-09-28 14:25:41 PDT
Attachment 262021 [details] did not pass style-queue:


ERROR: Source/WebCore/Modules/indexeddb/shared/IDBRequestIdentifier.h:49:  Place brace on its own line for function definitions.  [whitespace/braces] [4]
ERROR: Source/WebCore/Modules/indexeddb/shared/IDBRequestIdentifier.h:59:  Place brace on its own line for function definitions.  [whitespace/braces] [4]
Total errors found: 2 in 46 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 5 Brady Eidson 2015-09-28 14:35:04 PDT
Created attachment 262022 [details]
Patch v3
Comment 6 WebKit Commit Bot 2015-09-28 14:37:50 PDT
Attachment 262022 [details] did not pass style-queue:


ERROR: Source/WebCore/Modules/indexeddb/shared/IDBRequestIdentifier.h:49:  Place brace on its own line for function definitions.  [whitespace/braces] [4]
ERROR: Source/WebCore/Modules/indexeddb/shared/IDBRequestIdentifier.h:59:  Place brace on its own line for function definitions.  [whitespace/braces] [4]
Total errors found: 2 in 46 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 7 Alex Christensen 2015-09-28 15:39:38 PDT
Comment on attachment 262022 [details]
Patch v3

View in context: https://bugs.webkit.org/attachment.cgi?id=262022&action=review

r=me with these changes.

> Source/WebCore/Modules/indexeddb/IDBOpenDBRequest.cpp:31
> +#include "Logging.h"

Don't touch this file and don't include it in the ChangeLog.

> Source/WebCore/Modules/indexeddb/IDBRequest.h:-33
> -#include "DOMRequestState.h"

ditto

> Source/WebCore/Modules/indexeddb/shared/IDBRequestIdentifier.h:49
> +    bool isEmpty() const {

stylebot doesn't like { on the same line

> Source/WebCore/Modules/indexeddb/shared/IDBRequestIdentifier.h:59
> +    bool operator==(const IDBRequestIdentifier& other) const {

ditto
Comment 8 Brady Eidson 2015-09-28 16:40:12 PDT
https://trac.webkit.org/changeset/190291

But the build is broken after that because of reverting the change to IDBRequest.h!  lol

Following up.
Comment 9 Brady Eidson 2015-09-28 16:41:54 PDT
(In reply to comment #8)
> https://trac.webkit.org/changeset/190291
> 
> But the build is broken after that because of reverting the change to
> IDBRequest.h!  lol
> 
> Following up.

Followup in https://trac.webkit.org/changeset/190295
Comment 10 Brent Fulgham 2015-09-28 16:58:37 PDT
This broke the Windows build. Alex, you should know better!
Comment 11 Brent Fulgham 2015-09-28 17:05:39 PDT
Alex just showed me we need to add a missing ForwardingHeader location. I'll check in a fix shortly.
Comment 12 Brent Fulgham 2015-09-28 17:06:49 PDT
Windows build fix in https://trac.webkit.org/changeset/190298.