Index: components/data_reduction_proxy/core/browser/data_reduction_proxy_config_service_client.cc |
diff --git a/components/data_reduction_proxy/core/browser/data_reduction_proxy_config_service_client.cc b/components/data_reduction_proxy/core/browser/data_reduction_proxy_config_service_client.cc |
index 51d50f28e56b1d3df91ac51fec91280663f2caee..97f4f2b445006981d419b759c7493046fd7f635b 100644 |
--- a/components/data_reduction_proxy/core/browser/data_reduction_proxy_config_service_client.cc |
+++ b/components/data_reduction_proxy/core/browser/data_reduction_proxy_config_service_client.cc |
@@ -9,7 +9,6 @@ |
#include "base/bind.h" |
#include "base/bind_helpers.h" |
-#include "base/command_line.h" |
#include "base/json/json_writer.h" |
#include "base/location.h" |
#include "base/logging.h" |
@@ -51,9 +50,6 @@ const char kUMAConfigServiceFetchFailedAttemptsBeforeSuccess[] = |
const char kUMAConfigServiceFetchLatency[] = |
"DataReductionProxy.ConfigService.FetchLatency"; |
-// Default URL for retrieving the Data Reduction Proxy configuration. |
-const char kClientConfigURL[] = ""; |
- |
// Used in all Data Reduction Proxy URLs to specify API Key. |
const char kApiKeyName[] = "key"; |
@@ -118,23 +114,6 @@ const net::BackoffEntry::Policy& GetBackoffPolicy() { |
return kDefaultBackoffPolicy; |
} |
-// static |
-GURL DataReductionProxyConfigServiceClient::GetConfigServiceURL( |
- const base::CommandLine& command_line) { |
- if (!command_line.HasSwitch(switches::kDataReductionProxyConfigURL)) |
- return GURL(kClientConfigURL); |
- |
- std::string value( |
- command_line.GetSwitchValueASCII(switches::kDataReductionProxyConfigURL)); |
- GURL result(value); |
- if (result.is_valid()) |
- return result; |
- |
- LOG(WARNING) << "The following client config URL specified at the " |
- << "command-line is invalid: " << value; |
- return GURL(kClientConfigURL); |
-} |
- |
DataReductionProxyConfigServiceClient::DataReductionProxyConfigServiceClient( |
scoped_ptr<DataReductionProxyParams> params, |
const net::BackoffEntry::Policy& backoff_policy, |
@@ -152,8 +131,8 @@ DataReductionProxyConfigServiceClient::DataReductionProxyConfigServiceClient( |
net_log_(net_log), |
config_storer_(config_storer), |
backoff_entry_(&backoff_policy), |
- config_service_url_(AddApiKeyToUrl( |
- GetConfigServiceURL(*base::CommandLine::ForCurrentProcess()))), |
+ config_service_url_( |
+ AddApiKeyToUrl(DataReductionProxyParams::GetConfigServiceURL())), |
use_local_config_(!config_service_url_.is_valid()), |
remote_config_applied_(false), |
url_request_context_getter_(nullptr), |