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

Issue 1425823002: (DEPRECATED) Send navigation_start to browser process in DidStartProvisionalLoad (Closed)

Created:
5 years, 1 month ago by Charlie Harrison
Modified:
5 years, 1 month ago
CC:
chromium-reviews, mlamouri+watch-content_chromium.org, tyoshino+watch_chromium.org, creis+watch_chromium.org, nasko+codewatch_chromium.org, jam, mkwst+moarreviews-renderer_chromium.org, dglazkov+blink, blink-reviews, darin-cc_chromium.org, gavinp+loader_chromium.org, loading-reviews_chromium.org, Nate Chapin, blink-reviews-api_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Send navigation_start to browser process in DidStartProvisionalLoad IPC This CL has been split into three: https://codereview.chromium.org/1432583002/ https://codereview.chromium.org/1423453007/ https://codereview.chromium.org/1427633004/ BUG=548335

Patch Set 1 #

Patch Set 2 : Rebase conflict #

Patch Set 3 : Name change + blink layering #

Total comments: 11

Patch Set 4 : Browser nav-start attached to RequestExtraData #

Total comments: 1

Patch Set 5 : Override navigationStart with NavigationParams. New browsertest. Remove markNavigationStart() in bl… #

Patch Set 6 : Conditionally mark navigationStart #

Patch Set 7 : Same page fix #

Patch Set 8 : Update new NavigationState with same-page navigation #

Patch Set 9 : Cleanup (trybots previous) #

Total comments: 4

Patch Set 10 : Stop calling didCreateDataSource for same-page navs #

Total comments: 4
Unified diffs Side-by-side diffs Delta from patch set Stats (+254 lines, -129 lines) Patch
M content/browser/frame_host/navigation_controller_impl_unittest.cc View 1 2 3 3 chunks +12 lines, -7 lines 0 comments Download
M content/browser/frame_host/navigation_entry_impl.h View 1 2 3 1 chunk +2 lines, -2 lines 0 comments Download
M content/browser/frame_host/navigation_entry_impl.cc View 1 2 3 4 chunks +9 lines, -9 lines 0 comments Download
M content/browser/frame_host/navigation_handle_impl.h View 1 2 3 3 chunks +13 lines, -2 lines 0 comments Download
M content/browser/frame_host/navigation_handle_impl.cc View 1 2 3 3 chunks +14 lines, -5 lines 0 comments Download
M content/browser/frame_host/navigation_handle_impl_unittest.cc View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
M content/browser/frame_host/navigation_request.h View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
M content/browser/frame_host/navigation_request.cc View 1 2 3 4 chunks +6 lines, -8 lines 0 comments Download
M content/browser/frame_host/navigator.h View 1 2 3 1 chunk +4 lines, -2 lines 0 comments Download
M content/browser/frame_host/navigator_impl.h View 1 2 3 1 chunk +4 lines, -2 lines 0 comments Download
M content/browser/frame_host/navigator_impl.cc View 1 2 3 3 chunks +7 lines, -5 lines 0 comments Download
M content/browser/frame_host/render_frame_host_impl.h View 1 2 3 1 chunk +3 lines, -1 line 0 comments Download
M content/browser/frame_host/render_frame_host_impl.cc View 1 2 3 4 4 chunks +11 lines, -8 lines 1 comment Download
M content/common/frame_messages.h View 1 2 3 4 3 chunks +4 lines, -3 lines 0 comments Download
M content/common/navigation_params.h View 1 2 3 4 chunks +8 lines, -5 lines 0 comments Download
M content/common/navigation_params.cc View 1 2 3 6 chunks +6 lines, -6 lines 0 comments Download
M content/public/browser/navigation_handle.h View 1 2 3 2 chunks +5 lines, -0 lines 0 comments Download
M content/public/browser/navigation_handle.cc View 1 2 3 1 chunk +2 lines, -1 line 0 comments Download
M content/public/test/render_view_test.cc View 1 2 3 2 chunks +2 lines, -2 lines 0 comments Download
M content/renderer/render_frame_impl.h View 1 2 3 4 5 6 7 8 9 1 chunk +5 lines, -0 lines 0 comments Download
M content/renderer/render_frame_impl.cc View 1 2 3 4 5 6 7 8 9 15 chunks +76 lines, -48 lines 3 comments Download
M content/renderer/render_view_browsertest.cc View 1 2 3 4 4 chunks +34 lines, -6 lines 0 comments Download
M content/test/test_render_frame_host.cc View 1 2 3 3 chunks +3 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/core/loader/DocumentLoadTiming.cpp View 1 2 3 4 2 chunks +10 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/web/WebDataSourceImpl.h View 1 chunk +1 line, -0 lines 0 comments Download
M third_party/WebKit/Source/web/WebDataSourceImpl.cpp View 1 chunk +5 lines, -0 lines 0 comments Download
M third_party/WebKit/public/web/WebDataSource.h View 1 2 3 1 chunk +6 lines, -0 lines 0 comments Download

Messages

Total messages: 22 (4 generated)
Charlie Harrison
clamy@, could you take a look at this? I'm not sure this is the most ...
5 years, 1 month ago (2015-10-27 22:03:19 UTC) #2
clamy
Thanks! A few comments that should help simplify this a bit. I don't know why ...
5 years, 1 month ago (2015-10-28 12:40:01 UTC) #4
Charlie Harrison
Thanks for the quick review! Adding the timestamp to RequestExtraData and sending it with Common ...
5 years, 1 month ago (2015-10-28 14:45:00 UTC) #5
Charlie Harrison
On 2015/10/28 14:45:00, csharrison wrote: > Thanks for the quick review! Adding the timestamp to ...
5 years, 1 month ago (2015-10-28 15:24:25 UTC) #6
Charlie Harrison
On 2015/10/28 15:24:25, csharrison wrote: > On 2015/10/28 14:45:00, csharrison wrote: > > Thanks for ...
5 years, 1 month ago (2015-10-29 00:13:52 UTC) #7
Charlie Harrison
On 2015/10/29 00:13:52, csharrison wrote: > On 2015/10/28 15:24:25, csharrison wrote: > > On 2015/10/28 ...
5 years, 1 month ago (2015-10-29 00:43:42 UTC) #8
clamy
You can safely cast request->extraData() back to a RequestExtraData. The ExtraData is meant for the ...
5 years, 1 month ago (2015-10-29 13:26:48 UTC) #9
Charlie Harrison
I decided to go with the RequestExtraData route. Using the common_params sounded nice in theory, ...
5 years, 1 month ago (2015-10-29 18:20:29 UTC) #10
clamy
Yes I would prefer to go with the CommonNavigationParams method, because I think it will ...
5 years, 1 month ago (2015-10-30 13:54:48 UTC) #11
Charlie Harrison
On 2015/10/30 13:54:48, clamy wrote: > Yes I would prefer to go with the CommonNavigationParams ...
5 years, 1 month ago (2015-10-30 14:04:46 UTC) #12
Charlie Harrison
Alright, nav start is in common_params now. Some gotchas: - I had to special case ...
5 years, 1 month ago (2015-11-02 16:15:59 UTC) #13
clamy
Thanks! I did not have time to do a full review today, will continue tomorrow. ...
5 years, 1 month ago (2015-11-02 17:34:35 UTC) #14
Charlie Harrison
https://codereview.chromium.org/1425823002/diff/150001/content/common/navigation_params.h File content/common/navigation_params.h (right): https://codereview.chromium.org/1425823002/diff/150001/content/common/navigation_params.h#newcode64 content/common/navigation_params.h:64: const base::TimeTicks& navigation_start); On 2015/11/02 17:34:35, clamy wrote: > ...
5 years, 1 month ago (2015-11-02 18:19:10 UTC) #15
Charlie Harrison
5 years, 1 month ago (2015-11-02 18:19:10 UTC) #16
Charlie Harrison
Looks like removing the call to didCreateDataSource in didNavigateWithinPage worked out okay. The logic there ...
5 years, 1 month ago (2015-11-02 23:06:25 UTC) #18
clamy
Thanks! I think this patch is getting a bit big, and covers a bit too ...
5 years, 1 month ago (2015-11-03 13:33:00 UTC) #19
Charlie Harrison
On 2015/11/03 13:33:00, clamy wrote: > Thanks! I think this patch is getting a bit ...
5 years, 1 month ago (2015-11-03 14:27:08 UTC) #20
Charlie Harrison
5 years, 1 month ago (2015-11-03 14:34:55 UTC) #21
On 2015/11/03 14:27:08, csharrison wrote:
> On 2015/11/03 13:33:00, clamy wrote:
> > Thanks! I think this patch is getting a bit big, and covers a bit too much.
> How
> > about we split it in 3 along the following lines:
> > - Moving navigation start_time from RequestNavigationParams to
> > CommonnavigationParams (with proper initialization).
> > - Changes to the NavigationTiming API use in the renderer.
> > - Adding the navigation start time to the NavigationHandle, including
sending
> it
> > with DidStartProvisionalLoad.
> > 
> > I think it will be easier to review each part separately.
> > 
> >
>
https://codereview.chromium.org/1425823002/diff/170001/content/browser/frame_...
> > File content/browser/frame_host/render_frame_host_impl.cc (right):
> > 
> >
>
https://codereview.chromium.org/1425823002/diff/170001/content/browser/frame_...
> > content/browser/frame_host/render_frame_host_impl.cc:2159:
> > suspended_nav_params_->common_params.navigation_start = proceed_time;
> > This is somewhat problematic. We pushed the navigation start earlier so that
> we
> > capture the time it takes to create a renderer in cross-site navigations.
This
> > just overwrites that time in all cross-site navigations, and it's also
> different
> > from what we do in PlzNavigate. Could you add a TODO to ensure that
> PlzNavigate
> > and the current architecture measure the navigation start in the same way in
> the
> > presence of the BeforeUnload event.
> > 
> >
>
https://codereview.chromium.org/1425823002/diff/170001/content/renderer/rende...
> > File content/renderer/render_frame_impl.cc (right):
> > 
> >
>
https://codereview.chromium.org/1425823002/diff/170001/content/renderer/rende...
> > content/renderer/render_frame_impl.cc:2728: base::TimeTicks navigation_start
=
> > base::TimeTicks::FromInternalValue(
> > Since we always set the start time of the DataSource using the value from
the
> > NavigationState, why not use the timestamp from the NavigationState here?
> > 
> >
>
https://codereview.chromium.org/1425823002/diff/170001/content/renderer/rende...
> > content/renderer/render_frame_impl.cc:4677: // value.
> > Could we check with Navigation Timing API people whether we should also use
> the
> > browser-provided timestamp for reloads and history loads? I think it would
> make
> > sense to do so, and the code would be simpler.
> > 
> >
>
https://codereview.chromium.org/1425823002/diff/170001/content/renderer/rende...
> > content/renderer/render_frame_impl.cc:5016: base::TimeTicks navigation_start
=
> > base::TimeTicks::Now();
> > I don't think this is needed. None of the functions below take time to
> execute,
> > so we can postpone getting the navigation_start time until we construct the
> > CommonNavigationParams.
> 
> Sounds good I'll split this CL into 3 today and close this one. Will send an
> email about the Navigation Timing API.

Though I think the reason that reloads/history navs are not allowed is because
we aren't supposed to log nav start until after the unload event is dispatched
on the previous document (for navigation timing v1).

Powered by Google App Engine
This is Rietveld 408576698