New issue
Advanced search Search tips

Issue 720374 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: May 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 2
Type: Bug
Proj-Servicification

Blocking:
issue 598073



Sign in to add a comment

Add support for multiple contexts to network service

Project Member Reported by jam@chromium.org, May 10 2017

Issue description

Currently it has a simple context that is shared among all profiles. Probably better to have multiple contexts sooner rather than later, as it affects how callers connect to the network service. i.e. currently now the renderers connect directly, but we probably want to change that to be mediated through the browser.
 

Comment 1 by jam@chromium.org, May 10 2017

Cc: mmenke@chromium.org
Matt: I think this is orthogonal from your work. i.e. as I understand, you're working on making the URLLRequestContext in the network service to be equivalent to the one we use today in chrome. I'm looking into just creating n instead of 1.

Comment 2 by mmenke@chromium.org, May 10 2017

I had been thinking of this as something I'd need to do in the process of my work, if no one got to it first.  If you (Or anyone else) takes this on before I get there, I don't think we'd be stepping on each other's toes, and it would certainly make my life easier.

Comment 3 by jam@chromium.org, May 11 2017

Status: Started (was: Assigned)
Ok I'll start on this then.
Project Member

Comment 4 by bugdroid1@chromium.org, May 16 2017

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

commit c190586208cdae9ddecfd8d33d5aee3fc7c4dd92
Author: jam <jam@chromium.org>
Date: Tue May 16 14:45:30 2017

Add support in the network service for different contexts.

Now each StoragePartition has its own network context (which owns the net::URLRequestContext). The renderer connects to the network service through the browser instead of directly, which securely annotates the factory with the render process ID.

BUG= 720374 

Review-Url: https://codereview.chromium.org/2874163004
Cr-Commit-Position: refs/heads/master@{#472101}

[modify] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/browser/BUILD.gn
[modify] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/browser/loader/navigation_url_loader_network_service.cc
[modify] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/browser/loader/navigation_url_loader_network_service.h
[modify] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/browser/renderer_host/render_process_host_impl.cc
[modify] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/browser/renderer_host/render_process_host_impl.h
[modify] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/browser/site_per_process_browsertest.cc
[modify] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/browser/storage_partition_impl.cc
[modify] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/browser/storage_partition_impl.h
[add] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/browser/url_loader_factory_getter.cc
[add] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/browser/url_loader_factory_getter.h
[modify] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/browser/webui/web_ui_url_loader_factory.cc
[modify] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/common/network_service.mojom
[modify] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/network/cache_url_loader.cc
[modify] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/network/cache_url_loader.h
[modify] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/network/network_context.cc
[modify] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/network/network_context.h
[modify] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/network/network_service.cc
[modify] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/network/network_service.h
[modify] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/network/network_service_url_loader_factory_impl.cc
[modify] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/network/network_service_url_loader_factory_impl.h
[modify] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/network/url_loader_unittest.cc
[modify] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/public/app/mojo/content_renderer_manifest.json
[modify] https://crrev.com/c190586208cdae9ddecfd8d33d5aee3fc7c4dd92/content/renderer/renderer_blink_platform_impl.cc

Comment 5 by jam@chromium.org, May 16 2017

Status: Fixed (was: Started)
Project Member

Comment 6 by bugdroid1@chromium.org, May 23 2017

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

commit 34b5e4d8973b34420533e465f0124504349ac72e
Author: jam <jam@chromium.org>
Date: Tue May 23 01:21:23 2017

Fix host resolver being initialized after network requests arrive to the network service.

This regressed in r472101 wich made the network service pointer get initialized in non-test code earlier.

BUG= 720374 

Review-Url: https://codereview.chromium.org/2895353002
Cr-Commit-Position: refs/heads/master@{#473774}

[modify] https://crrev.com/34b5e4d8973b34420533e465f0124504349ac72e/content/public/common/network_service_test.mojom
[modify] https://crrev.com/34b5e4d8973b34420533e465f0124504349ac72e/content/shell/utility/shell_content_utility_client.cc

Comment 7 by laforge@google.com, Nov 7 2017

Components: Internals>Network>Service

Comment 8 by laforge@google.com, Nov 7 2017

Components: -Internals>Network>Service Internals>Services>Network
Apologies, applied the wrong component in bulk.

Sign in to add a comment