chore: cache URLLoaderFactory per-session (#19998)
* cache the URLLoaderFactory in AtomBrowserContext * use cached loader factory in AtomURLLoaderFactory
This commit is contained in:
parent
eed72c35d7
commit
b3947d6a83
4 changed files with 50 additions and 40 deletions
|
@ -396,12 +396,9 @@ void AtomURLLoaderFactory::StartLoadingHttp(
|
|||
}
|
||||
}
|
||||
|
||||
scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory =
|
||||
content::BrowserContext::GetDefaultStoragePartition(browser_context.get())
|
||||
->GetURLLoaderFactoryForBrowserProcess();
|
||||
new URLPipeLoader(
|
||||
url_loader_factory, std::move(request), std::move(loader),
|
||||
std::move(client),
|
||||
browser_context->GetURLLoaderFactory(), std::move(request),
|
||||
std::move(loader), std::move(client),
|
||||
static_cast<net::NetworkTrafficAnnotationTag>(traffic_annotation),
|
||||
std::move(upload_data));
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue