Bug 154351

Summary: Modern IDB: Encoder/Decoder/Messaging scaffolding for WK2 IPC
Product: WebKit Reporter: Brady Eidson <beidson>
Component: WebCore Misc.Assignee: Brady Eidson <beidson>
Status: RESOLVED FIXED    
Severity: Normal CC: achristensen, alecflett, commit-queue, jsbell
Priority: P2    
Version: Safari 9   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 149117, 153808    
Attachments:
Description Flags
Patch v1 none

Description Brady Eidson 2016-02-17 12:23:23 PST
Modern IDB: Encoder/Decoder/Messaging scaffolding
Comment 1 Brady Eidson 2016-02-17 12:26:01 PST
Created attachment 271578 [details]
Patch v1
Comment 2 Alex Christensen 2016-02-17 12:38:23 PST
Comment on attachment 271578 [details]
Patch v1

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

> Source/WebCore/Modules/indexeddb/shared/IDBRequestData.h:143
> +        request.m_requestIdentifier = std::make_unique<IDBResourceIdentifier>(identifier);

There ought to be a better way to do this without requiring the use of the copy constructor.
Comment 3 Brady Eidson 2016-02-17 12:39:37 PST
(In reply to comment #2)
> Comment on attachment 271578 [details]
> Patch v1
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=271578&action=review
> 
> > Source/WebCore/Modules/indexeddb/shared/IDBRequestData.h:143
> > +        request.m_requestIdentifier = std::make_unique<IDBResourceIdentifier>(identifier);
> 
> There ought to be a better way to do this without requiring the use of the
> copy constructor.

As discussed in person, but here for the record: YES PLEASE... MessageEncoder and MessageDecoder should have built-in ways for encoding/decoding "optionally null objects on the heap"
Comment 4 Brady Eidson 2016-02-17 12:39:56 PST
(In reply to comment #3)
> (In reply to comment #2)
> > Comment on attachment 271578 [details]
> > Patch v1
> > 
> > View in context:
> > https://bugs.webkit.org/attachment.cgi?id=271578&action=review
> > 
> > > Source/WebCore/Modules/indexeddb/shared/IDBRequestData.h:143
> > > +        request.m_requestIdentifier = std::make_unique<IDBResourceIdentifier>(identifier);
> > 
> > There ought to be a better way to do this without requiring the use of the
> > copy constructor.
> 
> As discussed in person, but here for the record: YES PLEASE...
> MessageEncoder and MessageDecoder should have built-in ways for
> encoding/decoding "optionally null objects on the heap"

But, outside the scope of this patch to add that.
Comment 5 WebKit Commit Bot 2016-02-17 12:42:53 PST
Comment on attachment 271578 [details]
Patch v1

Clearing flags on attachment: 271578

Committed r196715: <http://trac.webkit.org/changeset/196715>
Comment 6 WebKit Commit Bot 2016-02-17 12:42:57 PST
All reviewed patches have been landed.  Closing bug.