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

Issue 2144533002: Convert network hints to Mojo (Closed)

Created:
4 years, 5 months ago by tibell
Modified:
4 years, 4 months ago
CC:
chromium-reviews, qsr+mojo_chromium.org, droger+watchlist_chromium.org, viettrungluu+watch_chromium.org, blundell+watchlist_chromium.org, lcwu+watch_chromium.org, sdefresne+watchlist_chromium.org, jam, yzshen+watch_chromium.org, abarth-chromium, Aaron Boodman, darin-cc_chromium.org, halliwell+watch_chromium.org, alokp+watch_chromium.org, darin (slow to review), ben+mojo_chromium.org, Pat Meenan
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Convert network hints to Mojo Previously landed as: refs/heads/master@{#406780} Committed: https://crrev.com/1efd0ad3153587609220eeec1be6c1b2bbf9964b Cr-Commit-Position: refs/heads/master@{#407030}

Patch Set 1 #

Total comments: 20

Patch Set 2 : Remove left-over reference to NetworkHintsMsgStart #

Patch Set 3 : Add typemap for gyp #

Patch Set 4 : Handle messages on the IO thread #

Patch Set 5 : Address sammc's review comments #

Patch Set 6 : Fix compilation error #

Patch Set 7 : Rebase #

Total comments: 12

Patch Set 8 : Address review comments #

Patch Set 9 : Remove left-over reference to network_hints in fuzzer #

Patch Set 10 : Change ownership of PrescientNetworkingDispatcher for proper shutdown #

Total comments: 20

Patch Set 11 : Address review comments #

Total comments: 4

Patch Set 12 : Rebase #

Patch Set 13 : Address sammc's review comments #

Total comments: 12

Patch Set 14 : Address dcheng's review comments #

Patch Set 15 : Merge #

Patch Set 16 : Add untracked dependency on mojom #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+260 lines, -420 lines) Patch
M chrome/browser/BUILD.gn View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/chrome_content_browser_client.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +8 lines, -1 line 1 comment Download
M chrome/browser/extensions/BUILD.gn View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/renderer_host/chrome_render_message_filter.h View 1 2 3 4 5 6 7 8 9 10 4 chunks +12 lines, -3 lines 0 comments Download
M chrome/browser/renderer_host/chrome_render_message_filter.cc View 1 2 3 4 5 6 7 8 9 10 5 chunks +12 lines, -11 lines 0 comments Download
M chrome/chrome_browser.gypi View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +3 lines, -0 lines 0 comments Download
M chrome/renderer/chrome_content_renderer_client.h View 1 2 3 4 5 6 7 8 9 1 chunk +0 lines, -3 lines 0 comments Download
M chrome/renderer/chrome_content_renderer_client.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +1 line, -3 lines 0 comments Download
M chrome/renderer/chrome_render_thread_observer.h View 1 2 3 4 5 6 7 8 9 4 chunks +13 lines, -0 lines 0 comments Download
M chrome/renderer/chrome_render_thread_observer.cc View 1 2 3 4 5 6 7 8 9 3 chunks +9 lines, -1 line 0 comments Download
M chromecast/browser/cast_content_browser_client.h View 1 2 3 4 5 6 3 chunks +8 lines, -2 lines 0 comments Download
M chromecast/browser/cast_content_browser_client.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 4 chunks +18 lines, -11 lines 0 comments Download
M components/network_hints.gypi View 1 2 3 4 5 6 7 8 9 10 4 chunks +44 lines, -7 lines 0 comments Download
M components/network_hints/browser/BUILD.gn View 1 2 3 4 5 6 7 8 9 10 1 chunk +3 lines, -2 lines 0 comments Download
M components/network_hints/browser/DEPS View 1 chunk +1 line, -0 lines 0 comments Download
A + components/network_hints/browser/network_hints_impl.h View 1 2 3 4 5 6 7 8 9 10 2 chunks +14 lines, -9 lines 0 comments Download
A + components/network_hints/browser/network_hints_impl.cc View 1 2 3 4 5 6 7 2 chunks +8 lines, -18 lines 0 comments Download
M components/network_hints/browser/network_hints_message_filter.h View 1 2 3 4 5 6 7 1 chunk +0 lines, -40 lines 0 comments Download
M components/network_hints/browser/network_hints_message_filter.cc View 1 2 3 4 5 6 7 1 chunk +0 lines, -96 lines 0 comments Download
M components/network_hints/common/BUILD.gn View 1 2 3 4 5 6 7 8 9 10 1 chunk +0 lines, -8 lines 0 comments Download
M components/network_hints/common/network_hints_message_generator.h View 1 2 3 4 5 6 7 1 chunk +0 lines, -7 lines 0 comments Download
D components/network_hints/common/network_hints_message_generator.cc View 1 2 3 4 5 6 7 1 chunk +0 lines, -39 lines 0 comments Download
D components/network_hints/common/network_hints_messages.h View 1 chunk +0 lines, -50 lines 0 comments Download
D components/network_hints/common/network_hints_messages.cc View 1 chunk +0 lines, -43 lines 0 comments Download
A + components/network_hints/public/cpp/BUILD.gn View 1 2 3 4 5 6 7 8 9 10 1 chunk +6 lines, -6 lines 0 comments Download
A + components/network_hints/public/cpp/OWNERS View 1 2 3 4 5 6 7 8 9 10 1 chunk +2 lines, -6 lines 0 comments Download
A + components/network_hints/public/cpp/network_hints.typemap View 1 2 3 4 5 6 7 8 9 10 1 chunk +10 lines, -19 lines 0 comments Download
A + components/network_hints/public/cpp/network_hints_param_traits.h View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +12 lines, -14 lines 0 comments Download
A + components/network_hints/public/cpp/network_hints_param_traits.cc View 1 2 3 4 5 6 7 8 9 10 2 chunks +8 lines, -2 lines 0 comments Download
A + components/network_hints/public/interfaces/BUILD.gn View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +3 lines, -5 lines 0 comments Download
A + components/network_hints/public/interfaces/OWNERS View 1 2 3 4 5 6 7 8 9 10 0 chunks +-1 lines, --1 lines 0 comments Download
A components/network_hints/public/interfaces/network_hints.mojom View 1 2 3 4 5 6 7 8 9 10 1 chunk +22 lines, -0 lines 0 comments Download
M components/network_hints/renderer/BUILD.gn View 1 2 3 4 5 6 7 8 9 10 1 chunk +2 lines, -0 lines 0 comments Download
M components/network_hints/renderer/DEPS View 1 chunk +2 lines, -0 lines 0 comments Download
M components/network_hints/renderer/renderer_dns_prefetch.h View 1 2 3 4 5 6 7 8 9 10 3 chunks +9 lines, -0 lines 0 comments Download
M components/network_hints/renderer/renderer_dns_prefetch.cc View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +11 lines, -2 lines 0 comments Download
M components/network_hints/renderer/renderer_preconnect.h View 1 2 3 4 5 6 7 8 9 10 2 chunks +6 lines, -0 lines 0 comments Download
M components/network_hints/renderer/renderer_preconnect.cc View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +12 lines, -3 lines 0 comments Download
M components/typemaps.gni View 1 2 3 4 5 6 7 8 9 10 1 chunk +1 line, -0 lines 0 comments Download
M ipc/ipc_message_start.h View 1 chunk +0 lines, -1 line 0 comments Download
M tools/ipc_fuzzer/fuzzer/fuzzer.cc View 1 2 3 4 5 6 7 8 1 chunk +0 lines, -9 lines 0 comments Download
A + tools/ipc_fuzzer/message_lib/OWNERS View 1 2 3 4 5 6 7 0 chunks +-1 lines, --1 lines 0 comments Download
M tools/ipc_fuzzer/message_lib/all_messages.h View 1 2 3 4 5 6 7 1 chunk +0 lines, -1 line 0 comments Download

Messages

Total messages: 88 (47 generated)
tibell
It would also be possible to split the two messages into two interfaces, depending on ...
4 years, 5 months ago (2016-07-12 04:50:13 UTC) #2
tibell
4 years, 5 months ago (2016-07-12 04:52:13 UTC) #4
tibell
halliwell@chromium.org: Please review changes in
4 years, 5 months ago (2016-07-12 04:56:38 UTC) #6
tibell
halliwell@chromium.org: Please review changes in chromecast/
4 years, 5 months ago (2016-07-12 04:56:46 UTC) #7
Sam McNally
https://codereview.chromium.org/2144533002/diff/1/chrome/browser/chrome_content_browser_client.cc File chrome/browser/chrome_content_browser_client.cc (right): https://codereview.chromium.org/2144533002/diff/1/chrome/browser/chrome_content_browser_client.cc#newcode971 chrome/browser/chrome_content_browser_client.cc:971: host->GetInterfaceRegistry()->AddInterface( I think you want this interface to live ...
4 years, 5 months ago (2016-07-12 05:25:30 UTC) #8
tibell
Thanks for reviewing! PTAL https://codereview.chromium.org/2144533002/diff/1/chrome/browser/chrome_content_browser_client.cc File chrome/browser/chrome_content_browser_client.cc (right): https://codereview.chromium.org/2144533002/diff/1/chrome/browser/chrome_content_browser_client.cc#newcode971 chrome/browser/chrome_content_browser_client.cc:971: host->GetInterfaceRegistry()->AddInterface( On 2016/07/12 05:25:29, Sam ...
4 years, 5 months ago (2016-07-12 07:14:24 UTC) #9
tibell
+sky for chrome/browser/BUILD.gn chrome/browser/chrome_content_browser_client.cc chrome/browser/renderer_host/chrome_render_message_filter.h chrome/browser/renderer_host/chrome_render_message_filter.c chrome/chrome_browser.gypi
4 years, 5 months ago (2016-07-13 05:12:11 UTC) #11
Julia Tuttle
components/network_hints lgtm. I left a few nits/questions that are probably just due to my unfamiliarity ...
4 years, 5 months ago (2016-07-18 14:39:29 UTC) #16
sky
https://codereview.chromium.org/2144533002/diff/120001/chrome/browser/chrome_content_browser_client.cc File chrome/browser/chrome_content_browser_client.cc (right): https://codereview.chromium.org/2144533002/diff/120001/chrome/browser/chrome_content_browser_client.cc#newcode970 chrome/browser/chrome_content_browser_client.cc:970: auto chrome_render = new ChromeRenderMessageFilter(id, profile); Who owns ChromeRenderMessageFilter, ...
4 years, 5 months ago (2016-07-18 16:35:02 UTC) #17
tibell
Thanks for reviewing. PTAL https://codereview.chromium.org/2144533002/diff/120001/chrome/browser/chrome_content_browser_client.cc File chrome/browser/chrome_content_browser_client.cc (right): https://codereview.chromium.org/2144533002/diff/120001/chrome/browser/chrome_content_browser_client.cc#newcode970 chrome/browser/chrome_content_browser_client.cc:970: auto chrome_render = new ChromeRenderMessageFilter(id, ...
4 years, 5 months ago (2016-07-19 01:55:37 UTC) #20
tibell
+mbarbella for ipc_fuzzer
4 years, 5 months ago (2016-07-19 03:11:50 UTC) #26
tibell
+blundell for components/typemaps.gni +amistry for ipc/ipc_message_start.h
4 years, 5 months ago (2016-07-19 03:15:20 UTC) #28
tibell
On 2016/07/19 03:15:20, tibell wrote: > +blundell for components/typemaps.gni > +amistry for ipc/ipc_message_start.h -amistry for ...
4 years, 5 months ago (2016-07-19 03:16:42 UTC) #29
mbarbella (wrong one)
ipc_fuzzer lgtm with a nit https://codereview.chromium.org/2144533002/diff/180001/tools/ipc_fuzzer/message_lib/OWNERS File tools/ipc_fuzzer/message_lib/OWNERS (right): https://codereview.chromium.org/2144533002/diff/180001/tools/ipc_fuzzer/message_lib/OWNERS#newcode1 tools/ipc_fuzzer/message_lib/OWNERS:1: per-file *_messages*.h=set noparent We ...
4 years, 5 months ago (2016-07-19 04:32:54 UTC) #33
tibell
https://codereview.chromium.org/2144533002/diff/180001/tools/ipc_fuzzer/message_lib/OWNERS File tools/ipc_fuzzer/message_lib/OWNERS (right): https://codereview.chromium.org/2144533002/diff/180001/tools/ipc_fuzzer/message_lib/OWNERS#newcode1 tools/ipc_fuzzer/message_lib/OWNERS:1: per-file *_messages*.h=set noparent On 2016/07/19 04:32:53, mbarbella (wrong one) ...
4 years, 5 months ago (2016-07-19 04:38:40 UTC) #34
tibell
I believe this is ready for "final" review. Reviewers please review the following: sky: chrome/* ...
4 years, 5 months ago (2016-07-19 04:58:04 UTC) #35
Martin Barbella
lgtm from the right account
4 years, 5 months ago (2016-07-19 05:58:06 UTC) #38
blundell
I'm not that familiar with Mojo in Chromium so maybe my question has a good ...
4 years, 5 months ago (2016-07-19 06:28:35 UTC) #39
tibell
https://codereview.chromium.org/2144533002/diff/180001/components/typemaps.gni File components/typemaps.gni (right): https://codereview.chromium.org/2144533002/diff/180001/components/typemaps.gni#newcode7 components/typemaps.gni:7: "//components/network_hints/common/network_hints.typemap", On 2016/07/19 06:28:35, blundell wrote: > Why the ...
4 years, 5 months ago (2016-07-19 07:06:10 UTC) #40
sky
LGTM with a comment. https://codereview.chromium.org/2144533002/diff/120001/chrome/browser/chrome_content_browser_client.cc File chrome/browser/chrome_content_browser_client.cc (right): https://codereview.chromium.org/2144533002/diff/120001/chrome/browser/chrome_content_browser_client.cc#newcode970 chrome/browser/chrome_content_browser_client.cc:970: auto chrome_render = new ChromeRenderMessageFilter(id, ...
4 years, 5 months ago (2016-07-19 17:38:44 UTC) #41
halliwell
On 2016/07/19 17:38:44, sky wrote: > LGTM with a comment. > > https://codereview.chromium.org/2144533002/diff/120001/chrome/browser/chrome_content_browser_client.cc > File ...
4 years, 5 months ago (2016-07-19 19:08:37 UTC) #42
Sam McNally
https://codereview.chromium.org/2144533002/diff/180001/chrome/browser/chrome_content_browser_client.cc File chrome/browser/chrome_content_browser_client.cc (right): https://codereview.chromium.org/2144533002/diff/180001/chrome/browser/chrome_content_browser_client.cc#newcode970 chrome/browser/chrome_content_browser_client.cc:970: auto chrome_render = new ChromeRenderMessageFilter(id, profile); This could use ...
4 years, 5 months ago (2016-07-20 00:03:02 UTC) #43
tibell
PTAL https://codereview.chromium.org/2144533002/diff/120001/chrome/browser/chrome_content_browser_client.cc File chrome/browser/chrome_content_browser_client.cc (right): https://codereview.chromium.org/2144533002/diff/120001/chrome/browser/chrome_content_browser_client.cc#newcode970 chrome/browser/chrome_content_browser_client.cc:970: auto chrome_render = new ChromeRenderMessageFilter(id, profile); On 2016/07/19 ...
4 years, 5 months ago (2016-07-20 00:29:35 UTC) #45
Sam McNally
LGTM https://codereview.chromium.org/2144533002/diff/200001/components/network_hints/renderer/renderer_dns_prefetch.cc File components/network_hints/renderer/renderer_dns_prefetch.cc (right): https://codereview.chromium.org/2144533002/diff/200001/components/network_hints/renderer/renderer_dns_prefetch.cc#newcode48 components/network_hints/renderer/renderer_dns_prefetch.cc:48: return *network_hints_.get(); *network_hints_ should work. https://codereview.chromium.org/2144533002/diff/200001/components/network_hints/renderer/renderer_preconnect.cc File components/network_hints/renderer/renderer_preconnect.cc ...
4 years, 5 months ago (2016-07-20 00:44:49 UTC) #48
tibell
https://codereview.chromium.org/2144533002/diff/200001/components/network_hints/renderer/renderer_dns_prefetch.cc File components/network_hints/renderer/renderer_dns_prefetch.cc (right): https://codereview.chromium.org/2144533002/diff/200001/components/network_hints/renderer/renderer_dns_prefetch.cc#newcode48 components/network_hints/renderer/renderer_dns_prefetch.cc:48: return *network_hints_.get(); On 2016/07/20 00:44:49, Sam McNally wrote: > ...
4 years, 5 months ago (2016-07-20 01:56:00 UTC) #51
dcheng
https://codereview.chromium.org/2144533002/diff/240001/chrome/browser/chrome_content_browser_client.cc File chrome/browser/chrome_content_browser_client.cc (right): https://codereview.chromium.org/2144533002/diff/240001/chrome/browser/chrome_content_browser_client.cc#newcode972 chrome/browser/chrome_content_browser_client.cc:972: auto chrome_render_filter = new ChromeRenderMessageFilter(id, profile); Nit: auto* https://codereview.chromium.org/2144533002/diff/240001/chrome/browser/renderer_host/chrome_render_message_filter.h ...
4 years, 5 months ago (2016-07-20 13:59:50 UTC) #54
tibell
PTAL https://codereview.chromium.org/2144533002/diff/240001/chrome/browser/chrome_content_browser_client.cc File chrome/browser/chrome_content_browser_client.cc (right): https://codereview.chromium.org/2144533002/diff/240001/chrome/browser/chrome_content_browser_client.cc#newcode972 chrome/browser/chrome_content_browser_client.cc:972: auto chrome_render_filter = new ChromeRenderMessageFilter(id, profile); On 2016/07/20 ...
4 years, 5 months ago (2016-07-21 00:12:07 UTC) #55
dcheng
The mojom lgtm but the duplicated code makes me quite sad. It feels like we're ...
4 years, 5 months ago (2016-07-21 02:43:14 UTC) #60
tibell
https://codereview.chromium.org/2144533002/diff/240001/chromecast/browser/cast_content_browser_client.cc File chromecast/browser/cast_content_browser_client.cc (right): https://codereview.chromium.org/2144533002/diff/240001/chromecast/browser/cast_content_browser_client.cc#newcode234 chromecast/browser/cast_content_browser_client.cc:234: base::Unretained(network_hints_.get())), On 2016/07/21 02:43:13, dcheng wrote: > On 2016/07/21 ...
4 years, 5 months ago (2016-07-21 05:09:45 UTC) #61
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2144533002/280001
4 years, 5 months ago (2016-07-21 05:43:04 UTC) #67
commit-bot: I haz the power
Committed patchset #15 (id:280001)
4 years, 5 months ago (2016-07-21 06:20:33 UTC) #68
commit-bot: I haz the power
Patchset 15 (id:??) landed as https://crrev.com/bfeea28401c9741b878f33b585dcef911ad03f7e Cr-Commit-Position: refs/heads/master@{#406780}
4 years, 5 months ago (2016-07-21 06:21:50 UTC) #70
tibell
A revert of this CL (patchset #15 id:280001) has been created in https://codereview.chromium.org/2165023005/ by tibell@chromium.org. ...
4 years, 5 months ago (2016-07-21 06:41:39 UTC) #71
tibell
On 2016/07/21 06:41:39, tibell wrote: > A revert of this CL (patchset #15 id:280001) has ...
4 years, 5 months ago (2016-07-21 08:13:10 UTC) #77
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2144533002/300001
4 years, 5 months ago (2016-07-22 01:42:30 UTC) #80
commit-bot: I haz the power
Committed patchset #16 (id:300001)
4 years, 5 months ago (2016-07-22 03:36:09 UTC) #82
commit-bot: I haz the power
Patchset 16 (id:??) landed as https://crrev.com/1efd0ad3153587609220eeec1be6c1b2bbf9964b Cr-Commit-Position: refs/heads/master@{#407030}
4 years, 5 months ago (2016-07-22 03:38:01 UTC) #84
tibell
A revert of this CL (patchset #16 id:300001) has been created in https://codereview.chromium.org/2179693002/ by tibell@chromium.org. ...
4 years, 5 months ago (2016-07-24 23:51:59 UTC) #85
dcheng
https://codereview.chromium.org/2144533002/diff/300001/chrome/browser/chrome_content_browser_client.cc File chrome/browser/chrome_content_browser_client.cc (right): https://codereview.chromium.org/2144533002/diff/300001/chrome/browser/chrome_content_browser_client.cc#newcode975 chrome/browser/chrome_content_browser_client.cc:975: base::Unretained(chrome_render_filter)), Btw, I think we should just remove the ...
4 years, 5 months ago (2016-07-25 02:50:47 UTC) #86
Ben Goodger (Google)
On 2016/07/25 02:50:47, dcheng wrote: > https://codereview.chromium.org/2144533002/diff/300001/chrome/browser/chrome_content_browser_client.cc > File chrome/browser/chrome_content_browser_client.cc (right): > > https://codereview.chromium.org/2144533002/diff/300001/chrome/browser/chrome_content_browser_client.cc#newcode975 > ...
4 years, 5 months ago (2016-07-25 18:25:14 UTC) #87
Charlie Harrison
4 years, 4 months ago (2016-08-25 03:47:19 UTC) #88
Message was sent while issue was closed.
On 2016/07/25 18:25:14, Ben Goodger (Google) wrote:
> On 2016/07/25 02:50:47, dcheng wrote:
> >
>
https://codereview.chromium.org/2144533002/diff/300001/chrome/browser/chrome_...
> > File chrome/browser/chrome_content_browser_client.cc (right):
> > 
> >
>
https://codereview.chromium.org/2144533002/diff/300001/chrome/browser/chrome_...
> > chrome/browser/chrome_content_browser_client.cc:975:
> > base::Unretained(chrome_render_filter)),
> > Btw, I think we should just remove the base::Unretained() here:
> > ChromeRenderMessageFilter is refcounted.
> 
> BTW this is being hooked up in the wrong place (RenderProcessWillLaunch).
> Instead the interface should be exposed in ExposeInterfacesToRender. not-lgtm
> until that's fixed.

FYI I have a similar patch here that was blocked on similar u-a-f concerns
https://codereview.chromium.org/2043753002/
Let's sync up before landing either one.

Powered by Google App Engine
This is Rietveld 408576698