• Clark DuVall's avatar
    Reland "Reland "Migrate ResourceRequestAllowedNotifier to NetworkConnectionTracker"" · 34141782
    Clark DuVall authored
    This is a reland of e00fddec
    
    Needed to initialize variables in ChromeBrowserMainBrowserTest for asan/msan.
    Verified this works with msan build.
    
    Original change's description:
    > Reland "Migrate ResourceRequestAllowedNotifier to NetworkConnectionTracker"
    >
    > This is a reland of a9ed46b7
    >
    > ChromeBrowserMainBrowserTest.VariationsServiceStartsRequestOnNetworkChange
    > was flaky in the original change. Added logic in the test to wait for the
    > connection type change.
    >
    > Only diffs from original are in chrome/browser/chrome_browser_main_browsertest.cc
    >
    > Original change's description:
    > > Migrate ResourceRequestAllowedNotifier to NetworkConnectionTracker
    > >
    > > A getter is used for NetworkConnectionTracker because some services that
    > > use ResourceRequestAllowedNotifier are initialized early in browser
    > > startup (e.g. VariationsService), and only perform the initialization
    > > of ResourceRequestAllowedNotifier later on the UI thread. The getter
    > > allows us to run get the connection tracker at that point so we don't get
    > > DCHECKs about being on the UI thread when running
    > > content::GetNetworkConnectionTracker().
    > >
    > > This also moves the NetworkConnectionTracker in ios/ from BrowserState to
    > > ApplicationContext, which is available everywhere. It also matches non-IOS
    > > usage more closely, since we have it as a global there.
    > >
    > > Bug: 868021
    > > Cq-Include-Trybots: luci.chromium.try:ios-simulator-full-configs;master.tryserver.chromium.mac:ios-simulator-cronet
    > > Change-Id: I130c6b47feb90f0f7f0776ccc65666414a1ae802
    > > Reviewed-on: https://chromium-review.googlesource.com/1180360
    > > Reviewed-by: Eugene But <eugenebut@chromium.org>
    > > Reviewed-by: Robert Sesek <rsesek@chromium.org>
    > > Reviewed-by: John Abd-El-Malek <jam@chromium.org>
    > > Reviewed-by: Robbie McElrath <rmcelrath@chromium.org>
    > > Commit-Queue: Clark DuVall <cduvall@chromium.org>
    > > Cr-Commit-Position: refs/heads/master@{#584849}
    >
    > TBR=eugenebut@chromium.org,rsesek@chromium.org,rmcelrath@chromium.org,jam@chromium.org
    >
    > Bug: 868021
    > Change-Id: I5941b72474657159f0d4a1e6667fd77a3c475887
    > Cq-Include-Trybots: luci.chromium.try:ios-simulator-full-configs;master.tryserver.chromium.mac:ios-simulator-cronet
    > Reviewed-on: https://chromium-review.googlesource.com/1185602
    > Reviewed-by: Clark DuVall <cduvall@chromium.org>
    > Reviewed-by: Robbie McElrath <rmcelrath@chromium.org>
    > Commit-Queue: Clark DuVall <cduvall@chromium.org>
    > Cr-Commit-Position: refs/heads/master@{#585387}
    
    TBR=eugenebut@chromium.org,rsesek@chromium.org,rmcelrath@chromium.org,jam@chromium.org
    
    Bug: 868021, 876861
    Change-Id: I46fccf072d0b3080603e97c73ff055ac7c45e723
    Cq-Include-Trybots: luci.chromium.try:ios-simulator-full-configs;master.tryserver.chromium.mac:ios-simulator-cronet
    Reviewed-on: https://chromium-review.googlesource.com/1187081
    Commit-Queue: Clark DuVall <cduvall@chromium.org>
    Reviewed-by: default avatarClark DuVall <cduvall@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#585565}
    34141782
translate_service.cc 4.91 KB