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

Issue 1635873003: Replicating WebFrame::uniqueName across renderers. (Closed)

Created:
4 years, 11 months ago by Łukasz Anforowicz
Modified:
4 years, 10 months ago
CC:
dcheng, blink-reviews, blink-reviews-api_chromium.org, chromium-reviews, creis+watch_chromium.org, darin-cc_chromium.org, dglazkov+blink, jam, mkwst+moarreviews-renderer_chromium.org, mlamouri+watch-content_chromium.org, mlamouri+watch-blink_chromium.org, nasko+codewatch_chromium.org, site-isolation-reviews_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@dump-render-tree3
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Replicating WebFrame::uniqueName across renderers. When a frame is navigated, it might be moved to another renderer process. During such move, the other renderer process will create a local frame object (and the old renderer process will have a remote frame object). It is important that the new local frame object has the same unique name as the frame used to have in the old renderer object. If the unique name is not correctly replicated to the other renderer process, then Layout Tests (i.e. http/tests/security/cross-origin-appcache-allowed.html) fail when run in site isolation mode (i.e. with --additional-drt-flag=--site-per-process flag; note that site isolation mode won't work without extra CLs like crrev.com/1589643003). This CL adds a |unique_name| field to the content::FrameReplicationState struct and plumbs this value from the renderer, through the browser and back to the renderers. BUG=576969 TBR=gene@chromium.org CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel Committed: https://crrev.com/464d869b9576471215c7e4a25137ac47061ade29 Cr-Commit-Position: refs/heads/master@{#376772}

Patch Set 1 #

Patch Set 2 : #

Patch Set 3 : Self-review. #

Patch Set 4 : Rebasing... #

Total comments: 16

Patch Set 5 : Broadcasting updated unique name. #

Patch Set 6 : Removed unnecessary crbug comment. #

Total comments: 20

Patch Set 7 : Rebasing... #

Patch Set 8 : Rebasing... #

Patch Set 9 : Addressed CR feedback from Alex. #

Patch Set 10 : More self-review (i.e. removed |fallbackName| from initializeCoreFrame method). #

Patch Set 11 : Shame on me - the previous patchset didn't compile :-( #

Patch Set 12 : Fixing fallout from the new assert in FrameTree.cpp. #

Total comments: 6

Patch Set 13 : Addressed CR feedback from Charlie. #

Total comments: 12

Patch Set 14 : Addressed some of Daniel's feedback. #

Patch Set 15 : Rebasing... #

Patch Set 16 : Fixing more fallout from the new assert in FrameTree.cpp. #

Patch Set 17 : Added FrameTreeHelpers::createLocalChild. #

Total comments: 6

Patch Set 18 : Addressed feedback from Daniel. #

Patch Set 19 : Rebasing... #

Patch Set 20 : Fixing Android compile failure related to WebString initialization (in FrameTestHelpers.h). #

Patch Set 21 : Rebasing... #

Unified diffs Side-by-side diffs Delta from patch set Stats (+414 lines, -275 lines) Patch
M components/printing/renderer/print_web_view_helper.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 2 chunks +6 lines, -4 lines 0 comments Download
M content/browser/frame_host/frame_tree.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 1 chunk +1 line, -0 lines 0 comments Download
M content/browser/frame_host/frame_tree.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 3 chunks +3 lines, -1 line 0 comments Download
M content/browser/frame_host/frame_tree_node.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 2 chunks +2 lines, -1 line 0 comments Download
M content/browser/frame_host/frame_tree_node.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 3 chunks +11 lines, -3 lines 0 comments Download
M content/browser/frame_host/frame_tree_unittest.cc View 1 2 3 4 5 6 7 8 9 9 chunks +64 lines, -67 lines 0 comments Download
M content/browser/frame_host/navigation_controller_impl_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 7 chunks +7 lines, -7 lines 0 comments Download
M content/browser/frame_host/render_frame_host_impl.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 2 chunks +2 lines, -1 line 0 comments Download
M content/browser/frame_host/render_frame_host_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 3 chunks +13 lines, -3 lines 0 comments Download
M content/browser/frame_host/render_frame_host_manager.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +4 lines, -3 lines 0 comments Download
M content/browser/frame_host/render_frame_host_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 3 chunks +6 lines, -4 lines 0 comments Download
M content/browser/frame_host/render_frame_host_manager_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 11 chunks +17 lines, -17 lines 0 comments Download
M content/browser/frame_host/render_frame_message_filter.h View 2 chunks +3 lines, -7 lines 0 comments Download
M content/browser/frame_host/render_frame_message_filter.cc View 1 3 chunks +7 lines, -9 lines 0 comments Download
M content/browser/site_per_process_browsertest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 2 chunks +4 lines, -0 lines 0 comments Download
M content/browser/web_contents/web_contents_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 1 chunk +5 lines, -1 line 0 comments Download
M content/common/frame_messages.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 5 chunks +19 lines, -10 lines 0 comments Download
M content/common/frame_replication_state.h View 1 2 3 4 5 6 7 8 3 chunks +15 lines, -2 lines 0 comments Download
M content/common/frame_replication_state.cc View 1 chunk +2 lines, -0 lines 0 comments Download
M content/public/test/mock_render_thread.h View 2 chunks +3 lines, -7 lines 0 comments Download
M content/public/test/mock_render_thread.cc View 1 chunk +1 line, -5 lines 0 comments Download
M content/renderer/render_frame_impl.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 1 chunk +5 lines, -3 lines 0 comments Download
M content/renderer/render_frame_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 4 chunks +16 lines, -6 lines 0 comments Download
M content/renderer/render_frame_impl_browsertest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 chunk +9 lines, -6 lines 0 comments Download
M content/renderer/render_frame_proxy.h View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M content/renderer/render_frame_proxy.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 3 chunks +7 lines, -3 lines 0 comments Download
M content/renderer/render_view_browsertest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 10 chunks +44 lines, -10 lines 0 comments Download
M content/test/test_render_frame_host.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +3 lines, -1 line 0 comments Download
M third_party/WebKit/LayoutTests/FlagExpectations/site-per-process View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 1 chunk +0 lines, -8 lines 0 comments Download
M third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/loader/FrameLoaderClient.h View 1 2 3 4 5 6 7 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/page/FrameTree.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 2 chunks +13 lines, -5 lines 0 comments Download
M third_party/WebKit/Source/core/page/FrameTree.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 3 chunks +33 lines, -13 lines 0 comments Download
M third_party/WebKit/Source/web/FrameLoaderClientImpl.h View 1 2 3 4 5 6 7 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/web/FrameLoaderClientImpl.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 1 chunk +2 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/web/WebFrame.cpp View 1 2 3 4 5 6 7 8 9 2 chunks +2 lines, -1 line 0 comments Download
M third_party/WebKit/Source/web/WebFrameImplBase.h View 1 2 3 4 5 6 7 8 9 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/web/WebLocalFrameImpl.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/web/WebLocalFrameImpl.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 3 chunks +10 lines, -8 lines 0 comments Download
M third_party/WebKit/Source/web/WebRemoteFrameImpl.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +4 lines, -4 lines 0 comments Download
M third_party/WebKit/Source/web/WebRemoteFrameImpl.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 3 chunks +8 lines, -9 lines 0 comments Download
M third_party/WebKit/Source/web/tests/FrameTestHelpers.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 4 chunks +11 lines, -1 line 0 comments Download
M third_party/WebKit/Source/web/tests/FrameTestHelpers.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 4 chunks +19 lines, -1 line 0 comments Download
M third_party/WebKit/Source/web/tests/FrameThrottlingTest.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 1 chunk +1 line, -2 lines 0 comments Download
M third_party/WebKit/Source/web/tests/WebFrameTest.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 14 chunks +17 lines, -25 lines 0 comments Download
M third_party/WebKit/Source/web/tests/WebViewTest.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 2 chunks +3 lines, -3 lines 0 comments Download
M third_party/WebKit/public/web/WebFrameClient.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 2 chunks +2 lines, -2 lines 0 comments Download
M third_party/WebKit/public/web/WebRemoteFrame.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +4 lines, -4 lines 0 comments Download

Messages

Total messages: 50 (18 generated)
Łukasz Anforowicz
Charlie, could you please take a look?
4 years, 11 months ago (2016-01-27 21:56:56 UTC) #3
Charlie Reis
On 2016/01/27 21:56:56, Łukasz Anforowicz wrote: > Charlie, could you please take a look? Sure. ...
4 years, 11 months ago (2016-01-27 22:38:07 UTC) #4
Łukasz Anforowicz
On 2016/01/27 22:38:07, Charlie Reis wrote: > On 2016/01/27 21:56:56, Łukasz Anforowicz wrote: > > ...
4 years, 11 months ago (2016-01-27 22:44:24 UTC) #5
Charlie Reis
On 2016/01/27 22:44:24, Łukasz Anforowicz wrote: > On 2016/01/27 22:38:07, Charlie Reis wrote: > > ...
4 years, 11 months ago (2016-01-27 22:54:36 UTC) #6
dcheng
Is there any other renderer code that needs uniqueName() other than dumping the layout tree ...
4 years, 11 months ago (2016-01-27 23:05:55 UTC) #8
Łukasz Anforowicz
On 2016/01/27 23:05:55, dcheng wrote: > Is there any other renderer code that needs uniqueName() ...
4 years, 11 months ago (2016-01-27 23:19:21 UTC) #9
Charlie Reis
On 2016/01/27 23:19:21, Łukasz Anforowicz wrote: > On 2016/01/27 23:05:55, dcheng wrote: > > Is ...
4 years, 11 months ago (2016-01-27 23:25:06 UTC) #10
Charlie Reis
A few thoughts on content/ below. I'd also like to get Alex's eyes on this ...
4 years, 11 months ago (2016-01-27 23:48:48 UTC) #12
Łukasz Anforowicz
On 2016/01/27 23:48:48, Charlie Reis wrote: ... > > Can you add a content_browsertest for ...
4 years, 11 months ago (2016-01-28 01:21:19 UTC) #13
alexmos
Since Lukasz is going to dust off this CL, here are a few comments, mostly ...
4 years, 10 months ago (2016-02-10 00:46:46 UTC) #14
Łukasz Anforowicz
Charlie, can you take another look please? I think I've addressed all comments (from you ...
4 years, 10 months ago (2016-02-10 22:10:51 UTC) #16
Charlie Reis
On 2016/02/10 22:10:51, Łukasz Anforowicz wrote: > Charlie, can you take another look please? Great. ...
4 years, 10 months ago (2016-02-11 00:53:38 UTC) #17
Łukasz Anforowicz
On 2016/02/11 00:53:38, Charlie Reis wrote: > On 2016/02/10 22:10:51, Łukasz Anforowicz wrote: > > ...
4 years, 10 months ago (2016-02-11 20:38:53 UTC) #18
Charlie Reis
Great. content/ LGTM with some thoughts below. On 2016/02/10 22:10:51, Łukasz Anforowicz wrote: > Charlie, ...
4 years, 10 months ago (2016-02-11 22:02:14 UTC) #19
Łukasz Anforowicz
Thanks for reviewing. Daniel, could you please take a look? On 2016/02/11 22:02:14, Charlie Reis ...
4 years, 10 months ago (2016-02-11 23:23:56 UTC) #20
dcheng
https://codereview.chromium.org/1635873003/diff/240001/third_party/WebKit/Source/core/page/FrameTree.cpp File third_party/WebKit/Source/core/page/FrameTree.cpp (right): https://codereview.chromium.org/1635873003/diff/240001/third_party/WebKit/Source/core/page/FrameTree.cpp#newcode184 third_party/WebKit/Source/core/page/FrameTree.cpp:184: name.appendNumber(childCount() - (existingChildFrame ? 1 : 0)); Is it ...
4 years, 10 months ago (2016-02-16 22:17:30 UTC) #21
Łukasz Anforowicz
Daniel, can you look at my replies below? https://codereview.chromium.org/1635873003/diff/240001/third_party/WebKit/Source/core/page/FrameTree.cpp File third_party/WebKit/Source/core/page/FrameTree.cpp (right): https://codereview.chromium.org/1635873003/diff/240001/third_party/WebKit/Source/core/page/FrameTree.cpp#newcode184 third_party/WebKit/Source/core/page/FrameTree.cpp:184: name.appendNumber(childCount() ...
4 years, 10 months ago (2016-02-16 23:39:53 UTC) #22
dcheng
https://codereview.chromium.org/1635873003/diff/240001/third_party/WebKit/Source/web/tests/FrameThrottlingTest.cpp File third_party/WebKit/Source/web/tests/FrameThrottlingTest.cpp (right): https://codereview.chromium.org/1635873003/diff/240001/third_party/WebKit/Source/web/tests/FrameThrottlingTest.cpp#newcode327 third_party/WebKit/Source/web/tests/FrameThrottlingTest.cpp:327: WebLocalFrame* localFrame = rootFrame->createLocalChild(WebTreeScopeType::Document, "name", "uniqueName", WebSandboxFlags::None, &localFrameClient, nullptr, ...
4 years, 10 months ago (2016-02-19 18:14:57 UTC) #23
Łukasz Anforowicz
Daniel, can you take another look please? https://codereview.chromium.org/1635873003/diff/240001/third_party/WebKit/Source/web/tests/FrameThrottlingTest.cpp File third_party/WebKit/Source/web/tests/FrameThrottlingTest.cpp (right): https://codereview.chromium.org/1635873003/diff/240001/third_party/WebKit/Source/web/tests/FrameThrottlingTest.cpp#newcode327 third_party/WebKit/Source/web/tests/FrameThrottlingTest.cpp:327: WebLocalFrame* localFrame ...
4 years, 10 months ago (2016-02-19 19:56:59 UTC) #24
dcheng
https://codereview.chromium.org/1635873003/diff/320001/third_party/WebKit/Source/core/page/FrameTree.cpp File third_party/WebKit/Source/core/page/FrameTree.cpp (right): https://codereview.chromium.org/1635873003/diff/320001/third_party/WebKit/Source/core/page/FrameTree.cpp#newcode144 third_party/WebKit/Source/core/page/FrameTree.cpp:144: const AtomicString& originalRequestedName, Nit: this doesn't match the name ...
4 years, 10 months ago (2016-02-19 21:36:27 UTC) #25
dcheng
https://codereview.chromium.org/1635873003/diff/320001/third_party/WebKit/Source/web/tests/FrameTestHelpers.cpp File third_party/WebKit/Source/web/tests/FrameTestHelpers.cpp (right): https://codereview.chromium.org/1635873003/diff/320001/third_party/WebKit/Source/web/tests/FrameTestHelpers.cpp#newcode239 third_party/WebKit/Source/web/tests/FrameTestHelpers.cpp:239: // |uniqueName| is normally calculated in a somewhat complicated ...
4 years, 10 months ago (2016-02-19 21:37:02 UTC) #26
Łukasz Anforowicz
Daniel, can you take another look please? https://codereview.chromium.org/1635873003/diff/320001/third_party/WebKit/Source/core/page/FrameTree.cpp File third_party/WebKit/Source/core/page/FrameTree.cpp (right): https://codereview.chromium.org/1635873003/diff/320001/third_party/WebKit/Source/core/page/FrameTree.cpp#newcode144 third_party/WebKit/Source/core/page/FrameTree.cpp:144: const AtomicString& ...
4 years, 10 months ago (2016-02-19 22:10:09 UTC) #27
dcheng
lgtm
4 years, 10 months ago (2016-02-19 22:14:08 UTC) #28
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1635873003/360001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1635873003/360001
4 years, 10 months ago (2016-02-22 15:03:52 UTC) #31
commit-bot: I haz the power
Try jobs failed on following builders: chromium_presubmit on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presubmit/builds/148598)
4 years, 10 months ago (2016-02-22 15:15:54 UTC) #33
Łukasz Anforowicz
Gene, could you please take a look? I am sorry for not realizing earlier that ...
4 years, 10 months ago (2016-02-22 15:25:00 UTC) #36
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1635873003/360001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1635873003/360001
4 years, 10 months ago (2016-02-22 15:26:45 UTC) #38
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1635873003/380001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1635873003/380001
4 years, 10 months ago (2016-02-22 16:45:15 UTC) #42
commit-bot: I haz the power
Try jobs failed on following builders: ios_dbg_simulator_ninja on tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/ios_dbg_simulator_ninja/builds/134168) ios_rel_device_ninja on tryserver.chromium.mac (JOB_FAILED, ...
4 years, 10 months ago (2016-02-22 16:49:12 UTC) #44
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1635873003/400001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1635873003/400001
4 years, 10 months ago (2016-02-22 17:45:31 UTC) #47
commit-bot: I haz the power
Committed patchset #21 (id:400001)
4 years, 10 months ago (2016-02-22 19:26:41 UTC) #48
commit-bot: I haz the power
4 years, 10 months ago (2016-02-22 19:28:25 UTC) #50
Message was sent while issue was closed.
Patchset 21 (id:??) landed as
https://crrev.com/464d869b9576471215c7e4a25137ac47061ade29
Cr-Commit-Position: refs/heads/master@{#376772}

Powered by Google App Engine
This is Rietveld 408576698