|
|
Chromium Code Reviews
DescriptionV8ScriptValueSerializer: Add a separate version 'envelope' for Blink format version.
With this change, Blink will write out a wire format version of its own before,
and separate from, V8's. This will enable Blink to change the format it uses
when writing DOM objects, without requiring a corresponding V8-side change to
increment the wire format version.
Versions less than 16 will continue to have only one envelope, with a version
shared between V8 and Blink.
BUG=686159
TBR=skyostil@chromium.org
Review-Url: https://codereview.chromium.org/2712783002
Cr-Commit-Position: refs/heads/master@{#453123}
Committed: https://chromium.googlesource.com/chromium/src/+/faff3132ee3d5a89a85baab94d99d80fa54559d1
Patch Set 1 #Patch Set 2 : . #Patch Set 3 : Merge branch 'master' into ssv-separate-version #
Total comments: 4
Messages
Total messages: 31 (18 generated)
The CQ bit was checked by jbroman@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
jbroman@chromium.org changed reviewers: + haraken@chromium.org
This, plus a v8-side change to prefix all host objects encoded by Blink with a special tag, should allow Blink and v8 to change wire format versions and serialization tags without needing to worry about interfering with one another. (At present, they have to worry about changing the common version number, and about not colliding tags.)
The CQ bit was checked by jbroman@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: win_chromium_rel_ng on master.tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_rel_...)
The CQ bit was checked by jbroman@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
Note that two changes were needed due to things that are sensitive to the wire format: darin's independent implementation for WebView message ports, and the WebCrypto tests. Both changes are small.
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: This issue passed the CQ dry run.
Sorry, I missed reviewing this... LGTM. https://codereview.chromium.org/2712783002/diff/40001/third_party/WebKit/Sour... File third_party/WebKit/Source/bindings/core/v8/serialization/V8ScriptValueDeserializer.cpp (right): https://codereview.chromium.org/2712783002/diff/40001/third_party/WebKit/Sour... third_party/WebKit/Source/bindings/core/v8/serialization/V8ScriptValueDeserializer.cpp:44: // kMinVersionForSeparateEnveloped. For safety, I'd prefer adding DCHECK to check that the version number is within one byte.
https://codereview.chromium.org/2712783002/diff/40001/third_party/WebKit/Sour... File third_party/WebKit/Source/bindings/core/v8/serialization/V8ScriptValueDeserializer.cpp (right): https://codereview.chromium.org/2712783002/diff/40001/third_party/WebKit/Sour... third_party/WebKit/Source/bindings/core/v8/serialization/V8ScriptValueDeserializer.cpp:44: // kMinVersionForSeparateEnveloped. On 2017/02/24 at 02:45:13, haraken wrote: > For safety, I'd prefer adding DCHECK to check that the version number is within one byte. I'm not sure I understand what unsafe behavior you would like the DCHECK to catch. Something like DCHECK(!(rawData[1] & 0x80)) seems like it would break when/if we reach version 128 (though the code can handle that), but I'm not sure what bugs it would catch.
On 2017/02/24 15:38:47, jbroman wrote: > https://codereview.chromium.org/2712783002/diff/40001/third_party/WebKit/Sour... > File > third_party/WebKit/Source/bindings/core/v8/serialization/V8ScriptValueDeserializer.cpp > (right): > > https://codereview.chromium.org/2712783002/diff/40001/third_party/WebKit/Sour... > third_party/WebKit/Source/bindings/core/v8/serialization/V8ScriptValueDeserializer.cpp:44: > // kMinVersionForSeparateEnveloped. > On 2017/02/24 at 02:45:13, haraken wrote: > > For safety, I'd prefer adding DCHECK to check that the version number is > within one byte. > > I'm not sure I understand what unsafe behavior you would like the DCHECK to > catch. Something like DCHECK(!(rawData[1] & 0x80)) seems like it would break > when/if we reach version 128 (though the code can handle that), but I'm not sure > what bugs it would catch. Ah, sorry, I was confused! LGTM!
The CQ bit was checked by jbroman@chromium.org
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Try jobs failed on following builders: chromium_presubmit on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presub...)
jbroman@chromium.org changed reviewers: + skyostil@chromium.org
+skyostil for content/browser/android/
On second thought, I'm going to TBR the content change because it's a simple consequence of the rest of the change, and this is blocking another change.
Description was changed from ========== V8ScriptValueSerializer: Add a separate version 'envelope' for Blink format version. With this change, Blink will write out a wire format version of its own before, and separate from, V8's. This will enable Blink to change the format it uses when writing DOM objects, without requiring a corresponding V8-side change to increment the wire format version. Versions less than 16 will continue to have only one envelope, with a version shared between V8 and Blink. BUG=686159 ========== to ========== V8ScriptValueSerializer: Add a separate version 'envelope' for Blink format version. With this change, Blink will write out a wire format version of its own before, and separate from, V8's. This will enable Blink to change the format it uses when writing DOM objects, without requiring a corresponding V8-side change to increment the wire format version. Versions less than 16 will continue to have only one envelope, with a version shared between V8 and Blink. BUG=686159 TBR=skyostil@chromium.org ==========
The CQ bit was checked by jbroman@chromium.org
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
CQ is committing da patch.
Bot data: {"patchset_id": 40001, "attempt_start_ts": 1488134955949450,
"parent_rev": "cf4d55cb4fdbcd75a00b70f32fbd13eda955ae2d", "commit_rev":
"faff3132ee3d5a89a85baab94d99d80fa54559d1"}
Message was sent while issue was closed.
Description was changed from ========== V8ScriptValueSerializer: Add a separate version 'envelope' for Blink format version. With this change, Blink will write out a wire format version of its own before, and separate from, V8's. This will enable Blink to change the format it uses when writing DOM objects, without requiring a corresponding V8-side change to increment the wire format version. Versions less than 16 will continue to have only one envelope, with a version shared between V8 and Blink. BUG=686159 TBR=skyostil@chromium.org ========== to ========== V8ScriptValueSerializer: Add a separate version 'envelope' for Blink format version. With this change, Blink will write out a wire format version of its own before, and separate from, V8's. This will enable Blink to change the format it uses when writing DOM objects, without requiring a corresponding V8-side change to increment the wire format version. Versions less than 16 will continue to have only one envelope, with a version shared between V8 and Blink. BUG=686159 TBR=skyostil@chromium.org Review-Url: https://codereview.chromium.org/2712783002 Cr-Commit-Position: refs/heads/master@{#453123} Committed: https://chromium.googlesource.com/chromium/src/+/faff3132ee3d5a89a85baab94d99... ==========
Message was sent while issue was closed.
Committed patchset #3 (id:40001) as https://chromium.googlesource.com/chromium/src/+/faff3132ee3d5a89a85baab94d99...
Message was sent while issue was closed.
content/browser/android/ lgtm. https://codereview.chromium.org/2712783002/diff/40001/third_party/WebKit/Sour... File third_party/WebKit/Source/bindings/core/v8/serialization/V8ScriptValueSerializer.cpp (right): https://codereview.chromium.org/2712783002/diff/40001/third_party/WebKit/Sour... third_party/WebKit/Source/bindings/core/v8/serialization/V8ScriptValueSerializer.cpp:71: m_serializer.WriteHeader(); Should this still be inside the try-catch?
Message was sent while issue was closed.
https://codereview.chromium.org/2712783002/diff/40001/third_party/WebKit/Sour... File third_party/WebKit/Source/bindings/core/v8/serialization/V8ScriptValueSerializer.cpp (right): https://codereview.chromium.org/2712783002/diff/40001/third_party/WebKit/Sour... third_party/WebKit/Source/bindings/core/v8/serialization/V8ScriptValueSerializer.cpp:71: m_serializer.WriteHeader(); On 2017/02/27 at 17:35:04, Sami wrote: > Should this still be inside the try-catch? It can't throw, so it doesn't matter. |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
