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

Issue 2917643002: PlzNavigate: Fix ServiceWorkerHandler not finding WebContents. (Closed)

Created:
3 years, 6 months ago by arthursonzogni
Modified:
3 years, 6 months ago
Reviewers:
falken, clamy
CC:
chromium-reviews, michaeln, jsbell+serviceworker_chromium.org, shimazu+serviceworker_chromium.org, serviceworker-reviews, jam, kinuko+serviceworker, nhiroki, darin-cc_chromium.org, pfeldman, devtools-reviews_chromium.org, blink-reviews, horo+watch_chromium.org, kinuko+watch, tzik, blink-worker-reviews_chromium.org, nasko, clamy
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

PlzNavigate: Fix ServiceWorkerHandler not finding WebContents. With PlzNavigate, the RenderFrameHost associated with a navigation is known only at commit time. For this reason, in ServiceWorkerHandler::OnWorkerVersionUpdated(), client's process_id(-1) and route_id(-2) are invalid. They will be set to something meaningful as soon as ServiceWorkerProviderHost::FinalizeInitialization will be called with PlzNavigate, but it's too late. The solution with PlzNavigate is to use a WebContentsGetter instead. In this way, there is no need to know the RenderFrameHost. BUG=725818 TEST=http/tests/inspector/service-workers/service-workers-redundant.html CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_chromium_browser_side_navigation_rel Review-Url: https://codereview.chromium.org/2917643002 Cr-Commit-Position: refs/heads/master@{#476331} Committed: https://chromium.googlesource.com/chromium/src/+/a7dc4e822a4cddc14b9929a6f7aa2a85e69252d8

Patch Set 1 #

Total comments: 4

Patch Set 2 : falken@ suggestions #

Patch Set 3 : Shorter comment. #

Messages

Total messages: 22 (15 generated)
arthursonzogni
Hi falken@, Could you please review this? +CC clamy@, nasko@
3 years, 6 months ago (2017-05-31 13:57:49 UTC) #5
falken
lgtm, thanks for fixing this test! https://codereview.chromium.org/2917643002/diff/1/content/browser/service_worker/service_worker_context_observer.h File content/browser/service_worker/service_worker_context_observer.h (right): https://codereview.chromium.org/2917643002/diff/1/content/browser/service_worker/service_worker_context_observer.h#newcode75 content/browser/service_worker/service_worker_context_observer.h:75: const ConsoleMessage& message) ...
3 years, 6 months ago (2017-06-01 07:37:27 UTC) #8
arthursonzogni
Thanks falken@! https://codereview.chromium.org/2917643002/diff/1/content/browser/service_worker/service_worker_context_observer.h File content/browser/service_worker/service_worker_context_observer.h (right): https://codereview.chromium.org/2917643002/diff/1/content/browser/service_worker/service_worker_context_observer.h#newcode75 content/browser/service_worker/service_worker_context_observer.h:75: const ConsoleMessage& message) {} On 2017/06/01 07:37:27, ...
3 years, 6 months ago (2017-06-01 08:14:08 UTC) #11
arthursonzogni
Hi Camille, I still need an OWNER for content/browser/devtools/protocol/service_worker_handler.cc. Please, do you think you could ...
3 years, 6 months ago (2017-06-01 10:47:09 UTC) #15
clamy
lgtm
3 years, 6 months ago (2017-06-01 14:44:56 UTC) #16
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/2917643002/40001
3 years, 6 months ago (2017-06-01 14:45:39 UTC) #19
commit-bot: I haz the power
3 years, 6 months ago (2017-06-01 17:06:39 UTC) #22
Message was sent while issue was closed.
Committed patchset #3 (id:40001) as
https://chromium.googlesource.com/chromium/src/+/a7dc4e822a4cddc14b9929a6f7aa...

Powered by Google App Engine
This is Rietveld 408576698