Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(10)

Unified Diff: chrome/browser/profiles/profile_io_data.cc

Issue 2536723009: Make net::URLRequestContext a MemoryDumpProvider (Closed)
Patch Set: self review Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/profiles/profile_io_data.cc
diff --git a/chrome/browser/profiles/profile_io_data.cc b/chrome/browser/profiles/profile_io_data.cc
index 7f94c7eff327b7a64b009e23207e98222f953b1a..0751e9001765c14eea552c3f95fcccb79817bb6f 100644
--- a/chrome/browser/profiles/profile_io_data.cc
+++ b/chrome/browser/profiles/profile_io_data.cc
@@ -560,6 +560,7 @@ ProfileIOData::MediaRequestContext::MediaRequestContext() {
void ProfileIOData::MediaRequestContext::SetHttpTransactionFactory(
std::unique_ptr<net::HttpTransactionFactory> http_factory) {
http_factory_ = std::move(http_factory);
+ set_name("media");
mmenke 2016/12/02 15:47:28 This contradicts my above suggestion, but the main
mmenke 2016/12/02 15:47:28 "SetHttpTransactionFactory" seems a weird place to
xunjieli 2016/12/02 16:13:13 That's a very good point. I've explained this brie
xunjieli 2016/12/02 16:13:14 I've considered that. However, URLRequestContext's
mmenke 2016/12/05 17:59:25 Given what you told me about how this works, I don
xunjieli 2016/12/05 18:15:16 I am not sure if sharing the same name is a good i
mmenke 2016/12/05 18:18:51 I'm not following. There can be multiple app requ
xunjieli 2016/12/05 19:01:33 Done. Thanks for the clarifying this offline. I di
set_http_transaction_factory(http_factory_.get());
}
@@ -590,6 +591,7 @@ void ProfileIOData::AppRequestContext::SetHttpNetworkSession(
void ProfileIOData::AppRequestContext::SetHttpTransactionFactory(
std::unique_ptr<net::HttpTransactionFactory> http_factory) {
http_factory_ = std::move(http_factory);
+ set_name("app_request");
mmenke 2016/12/05 17:59:25 Naming these in SetHttpTransactionFactory seems we
mmenke 2016/12/05 18:02:13 Note that you would need to add a parameter to med
xunjieli 2016/12/05 18:15:16 Done.
set_http_transaction_factory(http_factory_.get());
}
@@ -1022,6 +1024,8 @@ void ProfileIOData::Init(
main_request_context_storage_.reset(
new net::URLRequestContextStorage(main_request_context_.get()));
extensions_request_context_.reset(new net::URLRequestContext());
+ main_request_context_->set_name("main");
+ extensions_request_context_->set_name("extensions");
main_request_context_->set_enable_brotli(io_thread_globals->enable_brotli);

Powered by Google App Engine
This is Rietveld 408576698