This CL adds a regression test where PrefetchService::prefetch_queue_ is
not empty and PrefetchService::active_prefetch_ is std::nullopt, but no
additional prefetch is started.
Bug: 400233773, 390329781
Change-Id: Iaf4865c9aad60305d2c3c07da1c921a559c0e825
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6310958
Commit-Queue: Taiyo Mizuhashi <taiyo@chromium.org>
Reviewed-by: Ken Okada <kenoss@chromium.org>
Reviewed-by: Hiroshige Hayashizaki <hiroshige@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1428475}
Its functionality is duplicated by GetUserAgent() these days, but we
could not use the latter while this component depended on //content.
Now that this is no longer an issue, remove the last call to
GetReducedUserAgent(), which also allows removing
GetMajorVersionNumber() from PrefetchServiceDelegate. All overrides had
the same implementation, and GetUserAgent() achieves the same thing
without requiring a version number to be passed.
Bug: 389970327
Change-Id: If7b7946d92eb78b9ff0983ded22699b968d1682e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6244462
Reviewed-by: Bo Liu <boliu@chromium.org>
Reviewed-by: Dave Tapuska <dtapuska@chromium.org>
Commit-Queue: Raphael Kubo da Costa <kubo@igalia.com>
Reviewed-by: Mike Taylor <miketaylr@chromium.org>
Reviewed-by: Max Curran <curranmax@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1428427}
Today all `PrefetchContainer`s will be added to
PrefetchService::owned_prefetches_ once
PrefetchService::AddPrefetchContainer =>
PrefetchService::AddPrefetchContainerWithoutStartingPrefetch is called.
Bug: n/a
Change-Id: I4558bb431c32c2a71d9dfffadbfe28d0ba59fd7d
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6312156
Commit-Queue: Hiroshige Hayashizaki <hiroshige@chromium.org>
Reviewed-by: Hiroshige Hayashizaki <hiroshige@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1428033}
This CL makes `PrefetchNetworkContext::GetURLLoaderFactory()` return
`scoped_refptr<network::SharedURLLoaderFactory>` instead of a raw
pointer, to allow the factory plumbed across tasks asynchronously without passing raw pointers. After https://chromium-review.googlesource.com/c/chromium/src/+/6228199, the URLLoaderFactory can be used after asynchronous ServiceWorker check.
Alternatively, we could call `PrefetchNetworkContext::GetURLLoaderFactory()` when the factory is needed (after ServiceWorker check), but instead we first call `GetURLLoaderFactory()` and then plumb the `scoped_refptr<network::SharedURLLoaderFactory>` asynchronously, to decouple the user of the factory (in `PrefetchStreamingURLLoader`) from its original owner (`PrefetchNetworkContext`).
https://docs.google.com/document/d/1kbs8YJuh93F_K6JqW84YSsjVWcAeU41Mj9nwPr6IXRs/edit?tab=t.0#bookmark=id.kohs7htfumek
This (and the subsequent CL) might extend the lifetime of the returned
URLLoaderFactory a little, but probably it's OK because the
URLLoaderFactory still doesn't outlive `PrefetchStreamingURLLoader`.
Bug: 40947546
Change-Id: I51fc017c9723760fe43881710574dfea3a0dc129
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6177744
Reviewed-by: Ken Okada <kenoss@chromium.org>
Reviewed-by: Taiyo Mizuhashi <taiyo@chromium.org>
Commit-Queue: Hiroshige Hayashizaki <hiroshige@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1428015}
The code in //content was present since the WebKit days, and the split
between //content and //components was unclear.
Move everything into //components/embedder_support:user_agent to make it
easier for callers to determine which functions to use as well as for
ease of maintenance.
The functions from //content have been moved wholesale; some will be
removed or made internal in other CLs in the chain.
NO_IFTT=The functions in embedder_support are called only on Android,
there is no need to update the code in //ios
Bug: 389970327
Change-Id: Ic87e0691f54e392374dcd060faba744ab0ebfedb
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6244461
Commit-Queue: Colin Blundell <blundell@chromium.org>
Reviewed-by: Colin Blundell <blundell@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1427625}
This changes instances of `b ? "true" : "false"` to use `base::ToString(b)`
instead. It's a followup to previous changes to address things that were missed
or regressed in the meantime.
This change applies to the following directories: content
This CL was uploaded by an experimental version of git cl split
(https://crbug.com/389069356).
R=creis@chromium.org
Bug: 335797528
Change-Id: I4d4ec7cd9e8c13d09c91637bca88de27bb637842
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6318187
Auto-Submit: Devon Loehr <dloehr@google.com>
Reviewed-by: Charlie Reis <creis@chromium.org>
Commit-Queue: Charlie Reis <creis@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1427485}
There was an unintentional behavior change introduced by crrev.com/6040420 , which made it impossible to activate speculation rules triggered prerendering on WebView.loadUrl with additional headers.
This CL provides an escape hatch to the behavior change.
Author: nhiroki@chromium.org
Bug: 399478939
Change-Id: Ic9f1a072ab242cfc9f2220965d5d6728c2a75da8
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6306746
Commit-Queue: Hiroki Nakagawa <nhiroki@chromium.org>
Commit-Queue: Kouhei Ueno <kouhei@chromium.org>
Reviewed-by: Lingqi Chi <lingqi@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1425584}
This is part of the process of making user_agent_utils.{cc,h} stop
depending on //content.
The flag has been moved to the main "embedder_support" target, which
does not depend on any other target and has other command-line
switches.
Bug: 389970327
Change-Id: Ib646ada998e8ea2eb23be2b9420d8049aa8f0bac
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6242721
Reviewed-by: Dave Tapuska <dtapuska@chromium.org>
Commit-Queue: Raphael Kubo da Costa <kubo@igalia.com>
Reviewed-by: Bo Liu <boliu@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1425012}
This CL associates Prerender2InNewTab with RuntimeEnabledFeature and put
the feature in the origin trial list.
1. Prerender2InNewTab will work as a kill-switch for the basic
functionality, so it is enabled by default.
2. SpeculationRulesTargetHint is used for origin trial that allows
sites to opt-in the target hint experiment.
3. Only if both Prerender2InNewTab and SpeculationRulesTargetHint
are enabled, the target hint of target="_blank" can be parsed, and
then UA will attempt to prerender the target page in a new tab, or it
will be prerendered into same tab as fallback.
Bug: 40234240
Change-Id: I4ee5768664e7bc13d5069e86b21872adff922719
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6261869
Reviewed-by: Hiroki Nakagawa <nhiroki@chromium.org>
Commit-Queue: Huanpo Lin <robertlin@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1424410}
This is a reland of commit 8ab9806911
The test was failed on linux-bfcache-rel, because The test assumed that
BFCache is used on the navigation we're testing.
This CL fixes to skip the test when disabled.
Original change's description:
> Prefetch: Keep listening cookie changes after the first serve
>
> Before this CL, PrefetchCookieLister stops listening after the first
> serve (more specifically, after first isolated cookie copy is started in
> `PrefetchContainer::Reader::OnIsolatedCookieCopyStart()`).
>
> This CL makes the listener keep listening after the first serve, which
> means that the cookie change for the prefetched site will be monitored
> after the first serve as well and will prevent corresponding prefetch
> being served anymore if changes.
>
> For more information, please see
> https://docs.google.com/document/d/1XuAt1pZ1T8SUyyPLuDZDo1Rb7XaOKa36ChegSAYYk1g/edit?resourcekey=0-VH-Hf_i0EyiVLNNVq9NBfA&tab=t.0#bookmark=id.9fgi9f3gi2gl
>
> Note that PrefetchCookieListener also detects as the default cookie is
> changed when isolated cookie copy itself. This is a false positive, so
> this CL pauses PrefetchCookieListener while the copy is happening.
>
> Bug: 377440445, 377440445
> Change-Id: Ib9262a17ac8726aa8d5405a45e10c3d1c9793771
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6288185
> Reviewed-by: Hiroki Nakagawa <nhiroki@chromium.org>
> Reviewed-by: Ken Okada <kenoss@chromium.org>
> Commit-Queue: Taiyo Mizuhashi <taiyo@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#1423055}
Cq-Include-Trybots: luci.chromium.try:android-bfcache-rel,linux-bfcache-rel
Bug: 377440445, 377440445
Change-Id: I2aa9319acd6ad9c924737350c8b3458ffc5ef4df
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6289350
Reviewed-by: Hiroshige Hayashizaki <hiroshige@chromium.org>
Commit-Queue: Taiyo Mizuhashi <taiyo@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1423415}
Before this CL, PrefetchCookieLister stops listening after the first
serve (more specifically, after first isolated cookie copy is started in
`PrefetchContainer::Reader::OnIsolatedCookieCopyStart()`).
This CL makes the listener keep listening after the first serve, which
means that the cookie change for the prefetched site will be monitored
after the first serve as well and will prevent corresponding prefetch
being served anymore if changes.
For more information, please see
https://docs.google.com/document/d/1XuAt1pZ1T8SUyyPLuDZDo1Rb7XaOKa36ChegSAYYk1g/edit?resourcekey=0-VH-Hf_i0EyiVLNNVq9NBfA&tab=t.0#bookmark=id.9fgi9f3gi2gl
Note that PrefetchCookieListener also detects as the default cookie is
changed when isolated cookie copy itself. This is a false positive, so
this CL pauses PrefetchCookieListener while the copy is happening.
Bug: 377440445, 377440445
Change-Id: Ib9262a17ac8726aa8d5405a45e10c3d1c9793771
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6288185
Reviewed-by: Hiroki Nakagawa <nhiroki@chromium.org>
Reviewed-by: Ken Okada <kenoss@chromium.org>
Commit-Queue: Taiyo Mizuhashi <taiyo@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1423055}
PreloadingDeciderTest.UmaRecallStats checks TruePositives and
FalseNegatives on navigation. Before this CL, the test didn't wait for
UMA to be recorded, hence TruePositive and FalseNegative were 0. But we
should wait for UMA. This CL adds a waiting logic for UMA, and checks
TruePositives and FalseNegatives correctly.
This CL is a preparation CL for an upcoming
feature (https://crbug.com/396998476).
Bug: 396998476
Change-Id: If4e5502a22cad87db62412ef6ce704d9edb21cb8
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6284766
Commit-Queue: Minoru Chikamune <chikamune@chromium.org>
Reviewed-by: Hiroki Nakagawa <nhiroki@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1422418}
Adding the logic for handling the maxPrefetches, this logic is specific
to WebView and //content layer doesn't have a similar logic. This CL
also adds a test to make sure that we are handling it right.
Bug: 376014072
Change-Id: I32e02b6da78b427e000fd3d40a845a7e2f8a9f2c
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6249440
Reviewed-by: Richard (Torne) Coles <torne@chromium.org>
Commit-Queue: Sayed Elabady <elabadysayed@chromium.org>
Reviewed-by: Rakina Zata Amni <rakina@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1419788}
WebView is going to configure its defaults and these values doesn't have
to be aligned but //content later values.
This CL also adds a test to make sure that TTL value is respected in the
prefetch operation.
Bug: 376014072
Change-Id: Idd3c033a6b617990b794dd4354864fc718c20ef1
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6243139
Reviewed-by: Taiyo Mizuhashi <taiyo@chromium.org>
Reviewed-by: Richard (Torne) Coles <torne@chromium.org>
Commit-Queue: Sayed Elabady <elabadysayed@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1419787}
This change cancels all the existing prerenders when browsing data
removal is run on cached data. This can be triggered by the Delete Browsing Data option or with Clear-Site-Data response headers. Developer Tools will now also show the previously successful prerender(s) as failed. A new PrerenderFinalStatus is added specifically for this case.
nav-speculation spec PR: https://github.com/WICG/nav-speculation/pull/361
NO_IFTTT=Changes for PrerenderFinalStatus will be done in separate repositories.
Bug: 40262311
Change-Id: Ie82895e555f3a9d4e2576686223e67443d198353
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6173154
Reviewed-by: Ayu Ishii <ayui@chromium.org>
Reviewed-by: Alex Rudenko <alexrudenko@chromium.org>
Commit-Queue: Steven Wei <stevenwei@microsoft.com>
Cr-Commit-Position: refs/heads/main@{#1419494}
If the navigation URL has an effective URL, it shouldn't activate a
prerendered page.
Before this CL, FindPotentialHostToActivate() in PrerenderHostRegistry
cancels prerendering in the case, and then ReserveHostToActivate()
CHECKs it. However, it turned out that the navigation URL can have an
effective URL during the period, and crashed due to the CHECK.
This CL cancels prerendering instead of CHECK in
ReserveHostToActivate(). The validation code is moved to
CanNavigationActivateHost() that is commonly called from both the
functions.
Bug: 380325632
Change-Id: I838433d79657f892ea82c839ea2f1d2b8c8d5a23
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6239000
Commit-Queue: Hiroki Nakagawa <nhiroki@chromium.org>
Reviewed-by: Lingqi Chi <lingqi@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1417981}
This patch moves `planned_max_pleroading_type` from `PreloadingAttempt`
to `PreloadPipelineInfo`.
Behavioral change: Before this patch, `PrefetchContainer` used
`Sec-Purpose: prefetch` for a HTTP header if preloading attempt is not
available. This occurs a prefetch is queued and started after navigation
as `PreloadingDataImpl` clears `PreloadingAttempt` when
`DidFinishNavigation()`. This patch remedies the behavior.
Bug: 394215571
Change-Id: I58010fae0de6bffa3bad3c97bcaced54c2e5b533
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6229307
Reviewed-by: Rakina Zata Amni <rakina@chromium.org>
Reviewed-by: Hiroki Nakagawa <nhiroki@chromium.org>
Reviewed-by: Max Curran <curranmax@chromium.org>
Commit-Queue: Ken Okada <kenoss@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1417974}
This was previously disabled due to a crash bug with how speculative
RFHs were created for prerendering pages. The crash bug has since been
fixed; while prerendering is somewhat less efficient, there is no
fundamental reason prerendering should be disabled in this case.
NO_IFTTT=deprecating an existing enum; no other changes needed
Bug: 40076091
Change-Id: I904b7aca52f05fb6db5de1abd8e599287892edb4
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6231569
Reviewed-by: Nasko Oskov <nasko@chromium.org>
Reviewed-by: Hiroki Nakagawa <nhiroki@chromium.org>
Commit-Queue: Daniel Cheng <dcheng@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1417429}
Before this CL, on fallback, `ServiceWorkerMainResourceLoader`
asks `NavigationURLLoaderImpl` to restart its `ThrottlingURLLoader`.
After this CL, `ServiceWorkerMainResourceLoader` transfers the initial
request received by itself, by plumbing the original
`URLLoaderFactory::CreateLoaderAndStart` parameters and mojo pipes
to the fallback factory.
This is to simplify the interception/fallback mechanism:
After this CL, `NavigationURLLoaderImpl` just have to provide a
`FallbackCallback` which is more like merely a factory getter,
and `SharedURLLoaderFactory` returned by an interceptor can
perform the loading (and its fallback to the network) mostly on its
own.
this also simplifies the fallback implementation in speculation
rules prefetch + ServiceWorker support (crbug.com/40947546).
Bug: 40251638, 40947546
Change-Id: Iaeadf0c040c7fb06d944dee11f66a9e3c75fbbdf
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5274112
Reviewed-by: Shunya Shishido <sisidovski@chromium.org>
Reviewed-by: Kouhei Ueno <kouhei@chromium.org>
Reviewed-by: Kenichi Ishibashi <bashi@chromium.org>
Commit-Queue: Hiroshige Hayashizaki <hiroshige@chromium.org>
Reviewed-by: Yoshisato Yanagisawa <yyanagisawa@chromium.org>
Reviewed-by: Keita Suzuki <suzukikeita@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1417110}
This CL intends to tidy up the code by removing `is_javascript_enabled`
plumbing to ClientHints impl. The CH currently just refuses to add the
Client Hints headers if Javascript is disabled. This CL modifies to that
the check is done in the caller side.
Bug: None
Change-Id: Icf8b737871325b766c8edf8035e6dd961310de4e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6232361
Commit-Queue: Kouhei Ueno <kouhei@chromium.org>
Reviewed-by: Hiroki Nakagawa <nhiroki@chromium.org>
Reviewed-by: Rakina Zata Amni <rakina@chromium.org>
Reviewed-by: Ari Chivukula <arichiv@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1416653}
This CL adds the TTL customization to PrefetchContainer by adding a new
param to the constructor while setting the default to the old default
for the other constructors. This is only needed for WebView for now but
that should be working for any browser-initiated prefetches that don't
depend on the web content.
Bug: 376014072
Change-Id: Ic58f19c6067cd41366a9dadeb38fba697bcd4fd1
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6190451
Reviewed-by: Bo Liu <boliu@chromium.org>
Commit-Queue: Sayed Elabady <elabadysayed@chromium.org>
Reviewed-by: Taiyo Mizuhashi <taiyo@chromium.org>
Reviewed-by: Arthur Sonzogni <arthursonzogni@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1416084}
This CL allows content embedders to override the max count of in-flight
prerendering. This is used by the WebView embedder that will have an API
to override the limit from AndroidX.
This doesn't change the current limit for Chrome (Omnibox, BookmarkBar,
and NTP).
Bug: 41490450
Change-Id: I7c68b429b52ab2c5a3040312514b72dfbf1abd3a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6204481
Reviewed-by: Richard (Torne) Coles <torne@chromium.org>
Reviewed-by: Taiyo Mizuhashi <taiyo@chromium.org>
Reviewed-by: Kouhei Ueno <kouhei@chromium.org>
Commit-Queue: Hiroki Nakagawa <nhiroki@chromium.org>
Reviewed-by: Lingqi Chi <lingqi@chromium.org>
Reviewed-by: Rakina Zata Amni <rakina@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1414780}
NOTE - This CL is needed for an urgent cherry-pick to M133.
Previously `aw_prefetch_service_delegate` called `NOT_REACHED()`
within its `GetAcceptLanguageHeader()`. Now that the code path is
being hit in production, we need to return the correct "Accept Language"
header from `AwSettings`.
The changes in `//chrome` are strictly because of adding a new
method on `prefetch_service_delegate` to set the "Accept Language"
header. Chrome's version is currently no-op.
Bug: 391284744
Change-Id: I2006d5e38b03fee000719dc257d80e09b3566ce2
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6218547
Reviewed-by: Arthur Sonzogni <arthursonzogni@chromium.org>
Reviewed-by: Lingqi Chi <lingqi@chromium.org>
Reviewed-by: Nate Fischer <ntfschr@chromium.org>
Commit-Queue: Wayne Jackson Jr. <wbjacksonjr@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1414065}
This CL supports CancellationSignal for AwContents.startPrerendering().
To identify which prerendering should be canceled, this CL introduces
the handle id (prerender id) in PrerenderHandle. StartPrerendering()
returns an id when prerendering successfully started. A caller of the
function can cancel prerendering by calling cancelPrerendering() with
the id.
CancellationSignal.OnCancelListener.onCancel() is fired when
CancellationSignal.cancel() is called. The listener takes the handle id
on prerendering start, and calls cancelPrerendering() with the id when
cancel() is called.
Bug: 41490450
Change-Id: Ifebb28089001aa1d02961ff0e7825d4da2452bdf
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6204842
Reviewed-by: Taiyo Mizuhashi <taiyo@chromium.org>
Reviewed-by: Kouhei Ueno <kouhei@chromium.org>
Reviewed-by: Lingqi Chi <lingqi@chromium.org>
Reviewed-by: Rakina Zata Amni <rakina@chromium.org>
Commit-Queue: Hiroki Nakagawa <nhiroki@chromium.org>
Reviewed-by: Richard (Torne) Coles <torne@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1412757}
Before this CL, only one prerendering could be triggered at a time. When
a new request was coming, the predecessor was cancelled.
This CL allows triggering multiple prerendering up to
kMaxNumOfRunningEmbedderPrerenders (currently it's 2). When more
prerendering is triggered, the oldest request is canceled.
Bug: 41490450
Change-Id: I7994d3875e7322e04b4245c66075e6fad7b405a9
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6196998
Reviewed-by: Taiyo Mizuhashi <taiyo@chromium.org>
Reviewed-by: Richard (Torne) Coles <torne@chromium.org>
Reviewed-by: Rakina Zata Amni <rakina@chromium.org>
Commit-Queue: Hiroki Nakagawa <nhiroki@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1412690}
Before this CL, when prerendering was triggered for the same URL twice,
the predecessor request was canceled and then a new request started.
This is obviously wasteful.
This CL deduplicates such requests. When prerendering is triggered for
the same URL, instead of starting a new request, it adds given
activation and error callbacks to PrerenderHandle (not overwrite
existing callbacks) and returns early. When prerendering is activated
or canceled, either the activation callbacks or the error callbacks are
called.
Bug: 41490450
Change-Id: I9a1a5aa1aa1dc72bcd28e681948be546f1c88d22
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6197777
Reviewed-by: Rakina Zata Amni <rakina@chromium.org>
Reviewed-by: Richard (Torne) Coles <torne@chromium.org>
Reviewed-by: Taiyo Mizuhashi <taiyo@chromium.org>
Reviewed-by: Kouhei Ueno <kouhei@chromium.org>
Commit-Queue: Hiroki Nakagawa <nhiroki@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1412683}
This reverts commit 0e5d5e26ab.
Reason for revert:
Causes flaky failures of
PrerenderBrowserTest.CancelOnSpeculationCandidateRemoved
on many bots. On some bots, like Linux CFI, it seems to fail more than half the time.
Bug: 392578265
Original change's description:
> preloading: Firing pagehide when prerendering
>
> This CL makes prerender cancellation fire pagehide by calling
> RenderFrameHostImpl::ClosePage when the prerendered page is
> intentionally canceled (such as removing speculation rules,
> not by failure).
> Another CL https://crrev.com/c/6197678 is created as a follow-up to
> support the new-tab cases.
>
> Bug: 353628449
> Change-Id: Ie2903ec3d0782c102181bccc3ec3d6910207481e
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6108648
> Reviewed-by: Hiroki Nakagawa <nhiroki@chromium.org>
> Reviewed-by: Rakina Zata Amni <rakina@chromium.org>
> Commit-Queue: Huanpo Lin <robertlin@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#1411504}
Bug: 353628449
Change-Id: I3c98c3fd04ad6fa3dd3749ea379512f261d95dfb
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6203506
Auto-Submit: Mark Pearson <mpearson@chromium.org>
Owners-Override: Mark Pearson <mpearson@chromium.org>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Commit-Queue: Mark Pearson <mpearson@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1411932}
This CL makes prerender cancellation fire pagehide by calling
RenderFrameHostImpl::ClosePage when the prerendered page is
intentionally canceled (such as removing speculation rules,
not by failure).
Another CL https://crrev.com/c/6197678 is created as a follow-up to
support the new-tab cases.
Bug: 353628449
Change-Id: Ie2903ec3d0782c102181bccc3ec3d6910207481e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6108648
Reviewed-by: Hiroki Nakagawa <nhiroki@chromium.org>
Reviewed-by: Rakina Zata Amni <rakina@chromium.org>
Commit-Queue: Huanpo Lin <robertlin@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1411504}