New issue
Advanced search Search tips

Issue 901835 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Nov 28
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 2
Type: Bug



Sign in to add a comment

Custom Tabs: Allow detached resource requests even when the browser is not initialized

Project Member Reported by lizeb@chromium.org, Nov 5

Issue description

This allows to increase coverage of the parallel resource request features.

Tracking bug.
 
Project Member

Comment 1 by bugdroid1@chromium.org, Nov 21

The following revision refers to this bug:
  https://chrome-internal.googlesource.com/clank/internal/apps/+/1267fcf31a8d12ccf57a34f8312cbebc690b5ce9

commit 1267fcf31a8d12ccf57a34f8312cbebc690b5ce9
Author: Benoît Lizé <lizeb@chromium.org>
Date: Wed Nov 21 15:54:19 2018

Project Member

Comment 2 by bugdroid1@chromium.org, Nov 21

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/b209311eff04ba4399765a6ce2edcd92f232032e

commit b209311eff04ba4399765a6ce2edcd92f232032e
Author: Benoît Lizé <lizeb@chromium.org>
Date: Wed Nov 21 19:33:36 2018

customtabs: Remove feature for parallel request, as it's launched.

We don't need the feature anymore, especially since this will be available
before native is loaded. In this case the feature flag would be at best
misleading (because its setting would not be respected), and at worst cause
crashes (calling a native method before native is loaded).

Bug:  901835 
Change-Id: I5e07931674ac1344e3ff3eff805c6b9d15e159d0
Reviewed-on: https://chromium-review.googlesource.com/c/1341833
Reviewed-by: Alexandr Ilin <alexilin@chromium.org>
Commit-Queue: Benoit L <lizeb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#610161}
[modify] https://crrev.com/b209311eff04ba4399765a6ce2edcd92f232032e/chrome/android/java/src/org/chromium/chrome/browser/ChromeFeatureList.java
[modify] https://crrev.com/b209311eff04ba4399765a6ce2edcd92f232032e/chrome/android/java/src/org/chromium/chrome/browser/customtabs/CustomTabsConnection.java
[modify] https://crrev.com/b209311eff04ba4399765a6ce2edcd92f232032e/chrome/android/javatests/src/org/chromium/chrome/browser/customtabs/CustomTabActivityTest.java
[modify] https://crrev.com/b209311eff04ba4399765a6ce2edcd92f232032e/chrome/browser/android/chrome_feature_list.cc
[modify] https://crrev.com/b209311eff04ba4399765a6ce2edcd92f232032e/chrome/browser/android/chrome_feature_list.h

Project Member

Comment 3 by bugdroid1@chromium.org, Nov 27

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/8ae5c3fbe86af701c95e2f1b4c41b136b7451158

commit 8ae5c3fbe86af701c95e2f1b4c41b136b7451158
Author: Benoît Lizé <lizeb@chromium.org>
Date: Tue Nov 27 09:30:08 2018

customtabs: Allow parallel requests to be processed before native is available.

Parallel requests are initiated when an intent is dispatched to a CustomTabs
activity. At that point, native is not guaranteed to be initialized, but the
request needs the browser to be initialized, not merely the native library to be
loaded. In this case, delay the call until this condition is fullfilled.

To that end, add a delayed task mechanism to ChromeBrowserInitializer. Add tests
to this class, and while in the neighborhood, convert Runnable to lambdas.

Note that this is not exposed to clients yet, as enabling the feature still
requires the browser to be initialized. This first CL introduces the mechanism
and ensures that existing behavior is preserved.

Bug:  901835 
Change-Id: I184e1da5ae974458d19f6a88a3f26ba6c443cb57
Reviewed-on: https://chromium-review.googlesource.com/c/1349227
Reviewed-by: Yusuf Ozuysal <yusufo@chromium.org>
Reviewed-by: Alexandr Ilin <alexilin@chromium.org>
Commit-Queue: Benoit L <lizeb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#611054}
[modify] https://crrev.com/8ae5c3fbe86af701c95e2f1b4c41b136b7451158/chrome/android/java/src/org/chromium/chrome/browser/customtabs/CustomTabsConnection.java
[modify] https://crrev.com/8ae5c3fbe86af701c95e2f1b4c41b136b7451158/chrome/android/java/src/org/chromium/chrome/browser/init/ChromeBrowserInitializer.java
[modify] https://crrev.com/8ae5c3fbe86af701c95e2f1b4c41b136b7451158/chrome/android/java_sources.gni
[add] https://crrev.com/8ae5c3fbe86af701c95e2f1b4c41b136b7451158/chrome/android/javatests/src/org/chromium/chrome/browser/init/ChromeBrowserInitializerTest.java

Project Member

Comment 4 by bugdroid1@chromium.org, Nov 27

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/257cdc8f360d9a4a6f587a0c1a31cd823398cfb8

commit 257cdc8f360d9a4a6f587a0c1a31cd823398cfb8
Author: Benoît Lizé <lizeb@chromium.org>
Date: Tue Nov 27 13:15:38 2018

customtabs: Allow detached requests before native is fully initialized.

Relax the restriction on parallel requests.
Most of the changes are in tests:
- Don't always initialize the browser in tests
- Detached requests are tried before and after native is loaded.

Bug:  901835 
Change-Id: Iecd16e976eb3bdea44871097528ef799b9678051
Reviewed-on: https://chromium-review.googlesource.com/c/1350891
Reviewed-by: Alexandr Ilin <alexilin@chromium.org>
Commit-Queue: Benoit L <lizeb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#611085}
[modify] https://crrev.com/257cdc8f360d9a4a6f587a0c1a31cd823398cfb8/chrome/android/java/src/org/chromium/chrome/browser/customtabs/CustomTabsConnection.java
[modify] https://crrev.com/257cdc8f360d9a4a6f587a0c1a31cd823398cfb8/chrome/android/javatests/src/org/chromium/chrome/browser/customtabs/DetachedResourceRequestTest.java

Labels: Target-72
Project Member

Comment 6 by bugdroid1@chromium.org, Nov 27

The following revision refers to this bug:
  https://chrome-internal.googlesource.com/clank/internal/apps/+/0432ca7c44dd9eda1a26410f00c38b4dd550b1d7

commit 0432ca7c44dd9eda1a26410f00c38b4dd550b1d7
Author: Benoît Lizé <lizeb@chromium.org>
Date: Tue Nov 27 18:08:17 2018

Status: Fixed (was: Assigned)

Sign in to add a comment