OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/policy/component_cloud_policy_updater.h" | 5 #include "chrome/browser/policy/cloud/component_cloud_policy_updater.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/location.h" | 10 #include "base/location.h" |
11 #include "base/logging.h" | 11 #include "base/logging.h" |
12 #include "base/sequenced_task_runner.h" | 12 #include "base/sequenced_task_runner.h" |
13 #include "base/stl_util.h" | 13 #include "base/stl_util.h" |
14 #include "chrome/browser/policy/component_cloud_policy_store.h" | 14 #include "chrome/browser/policy/cloud/component_cloud_policy_store.h" |
15 #include "chrome/browser/policy/proto/chrome_extension_policy.pb.h" | 15 #include "chrome/browser/policy/proto/chrome_extension_policy.pb.h" |
16 #include "chrome/browser/policy/proto/device_management_backend.pb.h" | 16 #include "chrome/browser/policy/proto/device_management_backend.pb.h" |
17 #include "googleurl/src/gurl.h" | 17 #include "googleurl/src/gurl.h" |
18 #include "net/base/backoff_entry.h" | 18 #include "net/base/backoff_entry.h" |
19 #include "net/base/load_flags.h" | 19 #include "net/base/load_flags.h" |
20 #include "net/base/net_errors.h" | 20 #include "net/base/net_errors.h" |
21 #include "net/url_request/url_fetcher.h" | 21 #include "net/url_request/url_fetcher.h" |
22 #include "net/url_request/url_fetcher_delegate.h" | 22 #include "net/url_request/url_fetcher_delegate.h" |
23 #include "net/url_request/url_request_context_getter.h" | 23 #include "net/url_request/url_request_context_getter.h" |
24 #include "net/url_request/url_request_status.h" | 24 #include "net/url_request/url_request_status.h" |
(...skipping 393 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
418 DCHECK(fetch_jobs_[job->policy_namespace()] == job); | 418 DCHECK(fetch_jobs_[job->policy_namespace()] == job); |
419 DCHECK(!job_queue_.empty() && job_queue_.front() == job); | 419 DCHECK(!job_queue_.empty() && job_queue_.front() == job); |
420 // The job isn't deleted when it fails because a retry attempt may have been | 420 // The job isn't deleted when it fails because a retry attempt may have been |
421 // scheduled. It's also kept so that UpdateExternalPolicy() can see the | 421 // scheduled. It's also kept so that UpdateExternalPolicy() can see the |
422 // current data, and avoid a new fetch if the data hasn't changed. | 422 // current data, and avoid a new fetch if the data hasn't changed. |
423 job_queue_.pop(); | 423 job_queue_.pop(); |
424 StartNextJob(); | 424 StartNextJob(); |
425 } | 425 } |
426 | 426 |
427 } // namespace policy | 427 } // namespace policy |
OLD | NEW |