summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--chrome/browser/net/chrome_url_request_context.cc3
-rw-r--r--chrome/browser/net/passive_log_collector.cc35
-rw-r--r--chrome/browser/net/passive_log_collector.h21
-rw-r--r--chrome/browser/net/resolve_proxy_msg_helper_unittest.cc6
-rw-r--r--chrome/browser/net/view_net_internals_job_factory.cc8
-rw-r--r--net/proxy/proxy_service.cc19
-rw-r--r--net/proxy/proxy_service.h15
-rw-r--r--net/proxy/proxy_service_unittest.cc77
-rw-r--r--webkit/tools/test_shell/test_shell_request_context.cc2
9 files changed, 129 insertions, 57 deletions
diff --git a/chrome/browser/net/chrome_url_request_context.cc b/chrome/browser/net/chrome_url_request_context.cc
index 7ad6ecf..81b9fb5 100644
--- a/chrome/browser/net/chrome_url_request_context.cc
+++ b/chrome/browser/net/chrome_url_request_context.cc
@@ -82,6 +82,7 @@ net::ProxyConfigService* CreateProxyConfigService(
// Create a proxy service according to the options on command line.
net::ProxyService* CreateProxyService(
net::NetworkChangeNotifier* network_change_notifier,
+ net::NetLog* net_log,
URLRequestContext* context,
net::ProxyConfigService* proxy_config_service,
const CommandLine& command_line,
@@ -101,6 +102,7 @@ net::ProxyService* CreateProxyService(
use_v8,
context,
network_change_notifier,
+ net_log,
io_loop);
}
@@ -150,6 +152,7 @@ ChromeURLRequestContext* FactoryForOriginal::Create() {
context->set_proxy_service(
CreateProxyService(io_thread()->globals()->network_change_notifier.get(),
+ io_thread()->globals()->net_log.get(),
context,
proxy_config_service_.release(),
command_line,
diff --git a/chrome/browser/net/passive_log_collector.cc b/chrome/browser/net/passive_log_collector.cc
index 2fb4e33..33cc8d1 100644
--- a/chrome/browser/net/passive_log_collector.cc
+++ b/chrome/browser/net/passive_log_collector.cc
@@ -65,6 +65,9 @@ void PassiveLogCollector::OnAddEntry(const net::NetLog::Entry& entry) {
case net::NetLog::SOURCE_CONNECT_JOB:
connect_job_tracker_.OnAddEntry(entry);
break;
+ case net::NetLog::SOURCE_INIT_PROXY_RESOLVER:
+ init_proxy_resolver_tracker_.OnAddEntry(entry);
+ break;
default:
// Drop all other logged events.
break;
@@ -316,3 +319,35 @@ void PassiveLogCollector::RequestTracker::AddConnectJobInfo(
AddEntryToRequestInfo(e, is_unbounded(), live_entry);
}
}
+
+//----------------------------------------------------------------------------
+// InitProxyResolverTracker
+//----------------------------------------------------------------------------
+
+PassiveLogCollector::InitProxyResolverTracker::InitProxyResolverTracker() {}
+
+void PassiveLogCollector::InitProxyResolverTracker::OnAddEntry(
+ const net::NetLog::Entry& entry) {
+ if (entry.type == net::NetLog::Entry::TYPE_EVENT &&
+ entry.event.type == net::NetLog::TYPE_INIT_PROXY_RESOLVER &&
+ entry.event.phase == net::NetLog::PHASE_BEGIN) {
+ // If this is the start of a new InitProxyResolver, overwrite the old data.
+ entries_.clear();
+ entries_.push_back(entry);
+ } else {
+ // Otherwise append it to the log for the latest InitProxyResolver.
+ if (!entries_.empty() && entries_[0].source.id != entry.source.id) {
+ // If this entry doesn't match what we think was the latest
+ // InitProxyResolver, drop it. (This shouldn't happen, but we will guard
+ // against it).
+ return;
+ }
+ entries_.push_back(entry);
+ }
+
+ // Safety net: INIT_PROXY_RESOLVER shouldn't generate many messages, but in
+ // case something goes wrong, avoid exploding the memory usage.
+ if (entries_.size() > kMaxNumEntriesPerLog)
+ entries_.clear();
+}
+
diff --git a/chrome/browser/net/passive_log_collector.h b/chrome/browser/net/passive_log_collector.h
index 2539c27..cfa0d21 100644
--- a/chrome/browser/net/passive_log_collector.h
+++ b/chrome/browser/net/passive_log_collector.h
@@ -110,6 +110,22 @@ class PassiveLogCollector : public ChromeNetLog::Observer {
DISALLOW_COPY_AND_ASSIGN(RequestTracker);
};
+ // Tracks the log entries for the last seen SOURCE_INIT_PROXY_RESOLVER.
+ class InitProxyResolverTracker {
+ public:
+ InitProxyResolverTracker();
+
+ void OnAddEntry(const net::NetLog::Entry& entry);
+
+ const std::vector<net::NetLog::Entry>& entries() const {
+ return entries_;
+ }
+
+ private:
+ std::vector<net::NetLog::Entry> entries_;
+ DISALLOW_COPY_AND_ASSIGN(InitProxyResolverTracker);
+ };
+
PassiveLogCollector();
~PassiveLogCollector();
@@ -127,10 +143,15 @@ class PassiveLogCollector : public ChromeNetLog::Observer {
return &socket_stream_tracker_;
}
+ InitProxyResolverTracker* init_proxy_resolver_tracker() {
+ return &init_proxy_resolver_tracker_;
+ }
+
private:
ConnectJobTracker connect_job_tracker_;
RequestTracker url_request_tracker_;
RequestTracker socket_stream_tracker_;
+ InitProxyResolverTracker init_proxy_resolver_tracker_;
DISALLOW_COPY_AND_ASSIGN(PassiveLogCollector);
};
diff --git a/chrome/browser/net/resolve_proxy_msg_helper_unittest.cc b/chrome/browser/net/resolve_proxy_msg_helper_unittest.cc
index 4d2eeb8..9017f59 100644
--- a/chrome/browser/net/resolve_proxy_msg_helper_unittest.cc
+++ b/chrome/browser/net/resolve_proxy_msg_helper_unittest.cc
@@ -55,7 +55,7 @@ class MyDelegate : public ResolveProxyMsgHelper::Delegate {
TEST(ResolveProxyMsgHelperTest, Sequential) {
net::MockAsyncProxyResolver* resolver = new net::MockAsyncProxyResolver;
scoped_refptr<net::ProxyService> service(
- new net::ProxyService(new MockProxyConfigService, resolver, NULL));
+ new net::ProxyService(new MockProxyConfigService, resolver, NULL, NULL));
MyDelegate delegate;
ResolveProxyMsgHelper helper(&delegate, service);
@@ -118,7 +118,7 @@ TEST(ResolveProxyMsgHelperTest, Sequential) {
TEST(ResolveProxyMsgHelperTest, QueueRequests) {
net::MockAsyncProxyResolver* resolver = new net::MockAsyncProxyResolver;
scoped_refptr<net::ProxyService> service(
- new net::ProxyService(new MockProxyConfigService, resolver, NULL));
+ new net::ProxyService(new MockProxyConfigService, resolver, NULL, NULL));
MyDelegate delegate;
ResolveProxyMsgHelper helper(&delegate, service);
@@ -185,7 +185,7 @@ TEST(ResolveProxyMsgHelperTest, QueueRequests) {
TEST(ResolveProxyMsgHelperTest, CancelPendingRequests) {
net::MockAsyncProxyResolver* resolver = new net::MockAsyncProxyResolver;
scoped_refptr<net::ProxyService> service(
- new net::ProxyService(new MockProxyConfigService, resolver, NULL));
+ new net::ProxyService(new MockProxyConfigService, resolver, NULL, NULL));
MyDelegate delegate;
scoped_ptr<ResolveProxyMsgHelper> helper(
diff --git a/chrome/browser/net/view_net_internals_job_factory.cc b/chrome/browser/net/view_net_internals_job_factory.cc
index 987a54b..aa39f1f 100644
--- a/chrome/browser/net/view_net_internals_job_factory.cc
+++ b/chrome/browser/net/view_net_internals_job_factory.cc
@@ -50,6 +50,11 @@ PassiveLogCollector::RequestTracker* GetSocketStreamTracker(
return GetPassiveLogCollector(context)->socket_stream_tracker();
}
+PassiveLogCollector::InitProxyResolverTracker* GetInitProxyResolverTracker(
+ URLRequestContext* context) {
+ return GetPassiveLogCollector(context)->init_proxy_resolver_tracker();
+}
+
std::string GetDetails(const GURL& url) {
DCHECK(ViewNetInternalsJobFactory::IsSupportedURL(url));
size_t start = strlen(chrome::kNetworkViewInternalsURL);
@@ -254,9 +259,8 @@ class ProxyServiceLastInitLogSubSection : public SubSection {
}
virtual void OutputBody(URLRequestContext* context, std::string* out) {
- net::ProxyService* proxy_service = context->proxy_service();
OutputTextInPre(net::NetLogUtil::PrettyPrintAsEventTree(
- proxy_service->init_proxy_resolver_log().entries(), 0), out);
+ GetInitProxyResolverTracker(context)->entries(), 0), out);
}
};
diff --git a/net/proxy/proxy_service.cc b/net/proxy/proxy_service.cc
index bc4a708..4e7a342 100644
--- a/net/proxy/proxy_service.cc
+++ b/net/proxy/proxy_service.cc
@@ -199,14 +199,15 @@ class ProxyService::PacRequest
ProxyService::ProxyService(ProxyConfigService* config_service,
ProxyResolver* resolver,
- NetworkChangeNotifier* network_change_notifier)
+ NetworkChangeNotifier* network_change_notifier,
+ const BoundNetLog& init_proxy_resolver_log)
: config_service_(config_service),
resolver_(resolver),
next_config_id_(1),
should_use_proxy_resolver_(false),
ALLOW_THIS_IN_INITIALIZER_LIST(init_proxy_resolver_callback_(
this, &ProxyService::OnInitProxyResolverComplete)),
- init_proxy_resolver_log_(kMaxNumNetLogEntries),
+ init_proxy_resolver_log_(init_proxy_resolver_log),
network_change_notifier_(network_change_notifier) {
// Register to receive network change notifications.
if (network_change_notifier_)
@@ -219,6 +220,7 @@ ProxyService* ProxyService::Create(
bool use_v8_resolver,
URLRequestContext* url_request_context,
NetworkChangeNotifier* network_change_notifier,
+ NetLog* net_log,
MessageLoop* io_loop) {
ProxyResolver* proxy_resolver;
@@ -238,7 +240,8 @@ ProxyService* ProxyService::Create(
proxy_resolver = new SingleThreadedProxyResolver(proxy_resolver);
ProxyService* proxy_service = new ProxyService(
- proxy_config_service, proxy_resolver, network_change_notifier);
+ proxy_config_service, proxy_resolver, network_change_notifier,
+ BoundNetLog::Make(net_log, NetLog::SOURCE_INIT_PROXY_RESOLVER));
if (proxy_resolver->expects_pac_bytes()) {
// Configure PAC script downloads to be issued using |url_request_context|.
@@ -252,7 +255,8 @@ ProxyService* ProxyService::Create(
// static
ProxyService* ProxyService::CreateFixed(const ProxyConfig& pc) {
- return Create(new ProxyConfigServiceFixed(pc), false, NULL, NULL, NULL);
+ return Create(new ProxyConfigServiceFixed(pc), false, NULL, NULL,
+ NULL, NULL);
}
// static
@@ -260,7 +264,8 @@ ProxyService* ProxyService::CreateNull() {
// Use a configuration fetcher and proxy resolver which always fail.
return new ProxyService(new ProxyConfigServiceNull,
new ProxyResolverNull,
- NULL);
+ NULL,
+ BoundNetLog());
}
int ProxyService::ResolveProxy(const GURL& raw_url,
@@ -636,11 +641,9 @@ void ProxyService::StartInitProxyResolver() {
init_proxy_resolver_.reset(
new InitProxyResolver(resolver_.get(), proxy_script_fetcher_.get()));
- init_proxy_resolver_log_.Clear();
-
int rv = init_proxy_resolver_->Init(
config_, &init_proxy_resolver_callback_,
- init_proxy_resolver_log_.bound());
+ init_proxy_resolver_log_);
if (rv != ERR_IO_PENDING)
OnInitProxyResolverComplete(rv);
diff --git a/net/proxy/proxy_service.h b/net/proxy/proxy_service.h
index 2cf3f95..bf176c8 100644
--- a/net/proxy/proxy_service.h
+++ b/net/proxy/proxy_service.h
@@ -40,7 +40,8 @@ class ProxyService : public base::RefCountedThreadSafe<ProxyService>,
// with it to detect when the network setup has changed. This is used to
// decide when to re-configure the proxy discovery.
ProxyService(ProxyConfigService* config_service, ProxyResolver* resolver,
- NetworkChangeNotifier* network_change_notifier);
+ NetworkChangeNotifier* network_change_notifier,
+ const BoundNetLog& init_proxy_resolver_log);
// Used internally to handle PAC queries.
// TODO(eroman): consider naming this simply "Request".
@@ -108,13 +109,6 @@ class ProxyService : public base::RefCountedThreadSafe<ProxyService>,
// Tells the resolver to purge any memory it does not need.
void PurgeMemory();
- // Returns the log for the most recent WPAD + PAC initialization.
- // (This shows how much time was spent downloading and parsing the
- // PAC scripts for the current configuration).
- const CapturingBoundNetLog& init_proxy_resolver_log() const {
- return init_proxy_resolver_log_;
- }
-
// Returns true if we have called UpdateConfig() at least once.
bool config_has_been_initialized() const {
return config_.id() != ProxyConfig::INVALID_ID;
@@ -161,6 +155,7 @@ class ProxyService : public base::RefCountedThreadSafe<ProxyService>,
bool use_v8_resolver,
URLRequestContext* url_request_context,
NetworkChangeNotifier* network_change_notifier,
+ NetLog* net_log,
MessageLoop* io_loop);
// Convenience method that creates a proxy service using the
@@ -286,8 +281,8 @@ class ProxyService : public base::RefCountedThreadSafe<ProxyService>,
// |proxy_resolver_| must outlive |init_proxy_resolver_|.
scoped_ptr<InitProxyResolver> init_proxy_resolver_;
- // Log from the *last* time |init_proxy_resolver_.Init()| was called, or NULL.
- CapturingBoundNetLog init_proxy_resolver_log_;
+ // Log for events generated by |init_proxy_resolver_|.
+ BoundNetLog init_proxy_resolver_log_;
// The (possibly NULL) network change notifier that we use to decide when
// to refetch PAC scripts or re-run WPAD.
diff --git a/net/proxy/proxy_service_unittest.cc b/net/proxy/proxy_service_unittest.cc
index d4a6326..d608a44 100644
--- a/net/proxy/proxy_service_unittest.cc
+++ b/net/proxy/proxy_service_unittest.cc
@@ -92,7 +92,8 @@ class MockProxyScriptFetcher : public ProxyScriptFetcher {
TEST(ProxyServiceTest, Direct) {
MockAsyncProxyResolver* resolver = new MockAsyncProxyResolver;
scoped_refptr<ProxyService> service(
- new ProxyService(new MockProxyConfigService, resolver, NULL));
+ new ProxyService(new MockProxyConfigService, resolver, NULL,
+ BoundNetLog()));
GURL url("http://www.google.com/");
@@ -120,7 +121,7 @@ TEST(ProxyServiceTest, PAC) {
MockAsyncProxyResolver* resolver = new MockAsyncProxyResolver;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, NULL));
+ new ProxyService(config_service, resolver, NULL, BoundNetLog()));
GURL url("http://www.google.com/");
@@ -167,7 +168,7 @@ TEST(ProxyServiceTest, PAC_NoIdentityOrHash) {
MockAsyncProxyResolver* resolver = new MockAsyncProxyResolver;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, NULL));
+ new ProxyService(config_service, resolver, NULL, BoundNetLog()));
GURL url("http://username:password@www.google.com/?ref#hash#hash");
@@ -195,7 +196,7 @@ TEST(ProxyServiceTest, PAC_FailoverWithoutDirect) {
MockAsyncProxyResolver* resolver = new MockAsyncProxyResolver;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, NULL));
+ new ProxyService(config_service, resolver, NULL, BoundNetLog()));
GURL url("http://www.google.com/");
@@ -252,7 +253,7 @@ TEST(ProxyServiceTest, PAC_FailoverAfterDirect) {
MockAsyncProxyResolver* resolver = new MockAsyncProxyResolver;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, NULL));
+ new ProxyService(config_service, resolver, NULL, BoundNetLog()));
GURL url("http://www.google.com/");
@@ -314,7 +315,7 @@ TEST(ProxyServiceTest, ProxyResolverFails) {
MockAsyncProxyResolver* resolver = new MockAsyncProxyResolver;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, NULL));
+ new ProxyService(config_service, resolver, NULL, BoundNetLog()));
// Start first resolve request.
GURL url("http://www.google.com/");
@@ -367,7 +368,7 @@ TEST(ProxyServiceTest, ProxyFallback) {
MockAsyncProxyResolver* resolver = new MockAsyncProxyResolver;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, NULL));
+ new ProxyService(config_service, resolver, NULL, BoundNetLog()));
GURL url("http://www.google.com/");
@@ -453,7 +454,7 @@ TEST(ProxyServiceTest, ProxyFallbackToDirect) {
MockAsyncProxyResolver* resolver = new MockAsyncProxyResolver;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, NULL));
+ new ProxyService(config_service, resolver, NULL, BoundNetLog()));
GURL url("http://www.google.com/");
@@ -513,7 +514,7 @@ TEST(ProxyServiceTest, ProxyFallback_NewSettings) {
MockAsyncProxyResolver* resolver = new MockAsyncProxyResolver;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, NULL));
+ new ProxyService(config_service, resolver, NULL, BoundNetLog()));
GURL url("http://www.google.com/");
@@ -602,7 +603,7 @@ TEST(ProxyServiceTest, ProxyFallback_BadConfig) {
MockAsyncProxyResolver* resolver = new MockAsyncProxyResolver;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, NULL));
+ new ProxyService(config_service, resolver, NULL, BoundNetLog()));
GURL url("http://www.google.com/");
@@ -687,7 +688,8 @@ TEST(ProxyServiceTest, ProxyBypassList) {
config.proxy_rules().bypass_rules.ParseFromString("*.org");
scoped_refptr<ProxyService> service(new ProxyService(
- new MockProxyConfigService(config), new MockAsyncProxyResolver, NULL));
+ new MockProxyConfigService(config), new MockAsyncProxyResolver, NULL,
+ BoundNetLog()));
int rv;
GURL url1("http://www.webkit.org");
@@ -711,7 +713,8 @@ TEST(ProxyServiceTest, PerProtocolProxyTests) {
config.set_auto_detect(false);
{
scoped_refptr<ProxyService> service(new ProxyService(
- new MockProxyConfigService(config), new MockAsyncProxyResolver, NULL));
+ new MockProxyConfigService(config), new MockAsyncProxyResolver, NULL,
+ BoundNetLog()));
GURL test_url("http://www.msn.com");
ProxyInfo info;
TestCompletionCallback callback;
@@ -722,7 +725,8 @@ TEST(ProxyServiceTest, PerProtocolProxyTests) {
}
{
scoped_refptr<ProxyService> service(new ProxyService(
- new MockProxyConfigService(config), new MockAsyncProxyResolver, NULL));
+ new MockProxyConfigService(config), new MockAsyncProxyResolver, NULL,
+ BoundNetLog()));
GURL test_url("ftp://ftp.google.com");
ProxyInfo info;
TestCompletionCallback callback;
@@ -733,7 +737,8 @@ TEST(ProxyServiceTest, PerProtocolProxyTests) {
}
{
scoped_refptr<ProxyService> service(new ProxyService(
- new MockProxyConfigService(config), new MockAsyncProxyResolver, NULL));
+ new MockProxyConfigService(config), new MockAsyncProxyResolver, NULL,
+ BoundNetLog()));
GURL test_url("https://webbranch.techcu.com");
ProxyInfo info;
TestCompletionCallback callback;
@@ -745,7 +750,8 @@ TEST(ProxyServiceTest, PerProtocolProxyTests) {
{
config.proxy_rules().ParseFromString("foopy1:8080");
scoped_refptr<ProxyService> service(new ProxyService(
- new MockProxyConfigService(config), new MockAsyncProxyResolver, NULL));
+ new MockProxyConfigService(config), new MockAsyncProxyResolver, NULL,
+ BoundNetLog()));
GURL test_url("http://www.microsoft.com");
ProxyInfo info;
TestCompletionCallback callback;
@@ -767,7 +773,8 @@ TEST(ProxyServiceTest, DefaultProxyFallbackToSOCKS) {
{
scoped_refptr<ProxyService> service(new ProxyService(
- new MockProxyConfigService(config), new MockAsyncProxyResolver, NULL));
+ new MockProxyConfigService(config), new MockAsyncProxyResolver, NULL,
+ BoundNetLog()));
GURL test_url("http://www.msn.com");
ProxyInfo info;
TestCompletionCallback callback;
@@ -778,7 +785,8 @@ TEST(ProxyServiceTest, DefaultProxyFallbackToSOCKS) {
}
{
scoped_refptr<ProxyService> service(new ProxyService(
- new MockProxyConfigService(config), new MockAsyncProxyResolver, NULL));
+ new MockProxyConfigService(config), new MockAsyncProxyResolver, NULL,
+ BoundNetLog()));
GURL test_url("ftp://ftp.google.com");
ProxyInfo info;
TestCompletionCallback callback;
@@ -789,7 +797,8 @@ TEST(ProxyServiceTest, DefaultProxyFallbackToSOCKS) {
}
{
scoped_refptr<ProxyService> service(new ProxyService(
- new MockProxyConfigService(config), new MockAsyncProxyResolver, NULL));
+ new MockProxyConfigService(config), new MockAsyncProxyResolver, NULL,
+ BoundNetLog()));
GURL test_url("https://webbranch.techcu.com");
ProxyInfo info;
TestCompletionCallback callback;
@@ -800,7 +809,8 @@ TEST(ProxyServiceTest, DefaultProxyFallbackToSOCKS) {
}
{
scoped_refptr<ProxyService> service(new ProxyService(
- new MockProxyConfigService(config), new MockAsyncProxyResolver, NULL));
+ new MockProxyConfigService(config), new MockAsyncProxyResolver, NULL,
+ BoundNetLog()));
GURL test_url("unknown://www.microsoft.com");
ProxyInfo info;
TestCompletionCallback callback;
@@ -819,7 +829,7 @@ TEST(ProxyServiceTest, CancelInProgressRequest) {
MockAsyncProxyResolver* resolver = new MockAsyncProxyResolver;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, NULL));
+ new ProxyService(config_service, resolver, NULL, BoundNetLog()));
// Start 3 requests.
@@ -894,7 +904,7 @@ TEST(ProxyServiceTest, InitialPACScriptDownload) {
new MockAsyncProxyResolverExpectsBytes;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, NULL));
+ new ProxyService(config_service, resolver, NULL, BoundNetLog()));
MockProxyScriptFetcher* fetcher = new MockProxyScriptFetcher;
service->SetProxyScriptFetcher(fetcher);
@@ -973,7 +983,7 @@ TEST(ProxyServiceTest, ChangeScriptFetcherWhilePACDownloadInProgress) {
new MockAsyncProxyResolverExpectsBytes;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, NULL));
+ new ProxyService(config_service, resolver, NULL, BoundNetLog()));
MockProxyScriptFetcher* fetcher = new MockProxyScriptFetcher;
service->SetProxyScriptFetcher(fetcher);
@@ -1030,7 +1040,7 @@ TEST(ProxyServiceTest, CancelWhilePACFetching) {
new MockAsyncProxyResolverExpectsBytes;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, NULL));
+ new ProxyService(config_service, resolver, NULL, BoundNetLog()));
MockProxyScriptFetcher* fetcher = new MockProxyScriptFetcher;
service->SetProxyScriptFetcher(fetcher);
@@ -1118,7 +1128,7 @@ TEST(ProxyServiceTest, FallbackFromAutodetectToCustomPac) {
MockAsyncProxyResolverExpectsBytes* resolver =
new MockAsyncProxyResolverExpectsBytes;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, NULL));
+ new ProxyService(config_service, resolver, NULL, BoundNetLog()));
MockProxyScriptFetcher* fetcher = new MockProxyScriptFetcher;
service->SetProxyScriptFetcher(fetcher);
@@ -1189,7 +1199,7 @@ TEST(ProxyServiceTest, FallbackFromAutodetectToCustomPac2) {
MockAsyncProxyResolverExpectsBytes* resolver =
new MockAsyncProxyResolverExpectsBytes;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, NULL));
+ new ProxyService(config_service, resolver, NULL, BoundNetLog()));
MockProxyScriptFetcher* fetcher = new MockProxyScriptFetcher;
service->SetProxyScriptFetcher(fetcher);
@@ -1265,7 +1275,7 @@ TEST(ProxyServiceTest, FallbackFromAutodetectToCustomToManual) {
MockAsyncProxyResolverExpectsBytes* resolver =
new MockAsyncProxyResolverExpectsBytes;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, NULL));
+ new ProxyService(config_service, resolver, NULL, BoundNetLog()));
MockProxyScriptFetcher* fetcher = new MockProxyScriptFetcher;
service->SetProxyScriptFetcher(fetcher);
@@ -1323,7 +1333,7 @@ TEST(ProxyServiceTest, BypassDoesntApplyToPac) {
MockAsyncProxyResolverExpectsBytes* resolver =
new MockAsyncProxyResolverExpectsBytes;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, NULL));
+ new ProxyService(config_service, resolver, NULL, BoundNetLog()));
MockProxyScriptFetcher* fetcher = new MockProxyScriptFetcher;
service->SetProxyScriptFetcher(fetcher);
@@ -1391,7 +1401,7 @@ TEST(ProxyServiceTest, DeleteWhileInitProxyResolverHasOutstandingFetch) {
MockAsyncProxyResolverExpectsBytes* resolver =
new MockAsyncProxyResolverExpectsBytes;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, NULL));
+ new ProxyService(config_service, resolver, NULL, BoundNetLog()));
MockProxyScriptFetcher* fetcher = new MockProxyScriptFetcher;
service->SetProxyScriptFetcher(fetcher);
@@ -1427,7 +1437,7 @@ TEST(ProxyServiceTest, DeleteWhileInitProxyResolverHasOutstandingSet) {
MockAsyncProxyResolver* resolver = new MockAsyncProxyResolver;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, NULL));
+ new ProxyService(config_service, resolver, NULL, BoundNetLog()));
GURL url("http://www.google.com/");
@@ -1450,7 +1460,7 @@ TEST(ProxyServiceTest, ResetProxyConfigService) {
scoped_refptr<ProxyService> service(new ProxyService(
new MockProxyConfigService(config1),
new MockAsyncProxyResolverExpectsBytes,
- NULL));
+ NULL, BoundNetLog()));
ProxyInfo info;
TestCompletionCallback callback1;
@@ -1482,7 +1492,7 @@ TEST(ProxyServiceTest, UpdateConfigAfterFailedAutodetect) {
MockProxyConfigService* config_service = new MockProxyConfigService(config);
MockAsyncProxyResolver* resolver = new MockAsyncProxyResolver;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, NULL));
+ new ProxyService(config_service, resolver, NULL, BoundNetLog()));
// Start 1 requests.
@@ -1528,7 +1538,7 @@ TEST(ProxyServiceTest, UpdateConfigFromPACToDirect) {
MockProxyConfigService* config_service = new MockProxyConfigService(config);
MockAsyncProxyResolver* resolver = new MockAsyncProxyResolver;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, NULL));
+ new ProxyService(config_service, resolver, NULL, BoundNetLog()));
// Start 1 request.
@@ -1583,7 +1593,8 @@ TEST(ProxyServiceTest, NetworkChangeTriggersPacRefetch) {
MockNetworkChangeNotifier network_change_notifier;
scoped_refptr<ProxyService> service(
- new ProxyService(config_service, resolver, &network_change_notifier));
+ new ProxyService(config_service, resolver, &network_change_notifier,
+ BoundNetLog()));
MockProxyScriptFetcher* fetcher = new MockProxyScriptFetcher;
service->SetProxyScriptFetcher(fetcher);
diff --git a/webkit/tools/test_shell/test_shell_request_context.cc b/webkit/tools/test_shell/test_shell_request_context.cc
index deb19287..3db6dac 100644
--- a/webkit/tools/test_shell/test_shell_request_context.cc
+++ b/webkit/tools/test_shell/test_shell_request_context.cc
@@ -58,7 +58,7 @@ void TestShellRequestContext::Init(
#endif
host_resolver_ = net::CreateSystemHostResolver(NULL);
proxy_service_ = net::ProxyService::Create(proxy_config_service.release(),
- false, NULL, NULL, NULL);
+ false, NULL, NULL, NULL, NULL);
ssl_config_service_ = net::SSLConfigService::CreateSystemSSLConfigService();
http_auth_handler_factory_ = net::HttpAuthHandlerFactory::CreateDefault();