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

Side by Side Diff: chrome/browser/chromeos/policy/device_cloud_policy_manager_chromeos.h

Issue 1193333017: Added system log uploader. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Moved SystemLogUploadJob creation to DeviceCloudPolicyManager. Created 5 years, 5 months 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #ifndef CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_CLOUD_POLICY_MANAGER_CHROMEOS_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_CLOUD_POLICY_MANAGER_CHROMEOS_H_
6 #define CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_CLOUD_POLICY_MANAGER_CHROMEOS_H_ 6 #define CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_CLOUD_POLICY_MANAGER_CHROMEOS_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 19 matching lines...) Expand all
30 30
31 class PrefRegistrySimple; 31 class PrefRegistrySimple;
32 class PrefService; 32 class PrefService;
33 33
34 namespace policy { 34 namespace policy {
35 35
36 class DeviceCloudPolicyStoreChromeOS; 36 class DeviceCloudPolicyStoreChromeOS;
37 class EnterpriseInstallAttributes; 37 class EnterpriseInstallAttributes;
38 class HeartbeatScheduler; 38 class HeartbeatScheduler;
39 class StatusUploader; 39 class StatusUploader;
40 class SystemLogUploader;
40 41
41 // CloudPolicyManager specialization for device policy on Chrome OS. 42 // CloudPolicyManager specialization for device policy on Chrome OS.
42 class DeviceCloudPolicyManagerChromeOS : public CloudPolicyManager { 43 class DeviceCloudPolicyManagerChromeOS : public CloudPolicyManager {
43 public: 44 public:
44 class Observer { 45 class Observer {
45 public: 46 public:
46 // Invoked when the device cloud policy manager connects. 47 // Invoked when the device cloud policy manager connects.
47 virtual void OnDeviceCloudPolicyManagerConnected() = 0; 48 virtual void OnDeviceCloudPolicyManagerConnected() = 0;
48 // Invoked when the device cloud policy manager disconnects. 49 // Invoked when the device cloud policy manager disconnects.
49 virtual void OnDeviceCloudPolicyManagerDisconnected() = 0; 50 virtual void OnDeviceCloudPolicyManagerDisconnected() = 0;
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
115 116
116 // Initializes requisition settings at OOBE with values from VPD. 117 // Initializes requisition settings at OOBE with values from VPD.
117 void InitializeRequisition(); 118 void InitializeRequisition();
118 119
119 void NotifyConnected(); 120 void NotifyConnected();
120 void NotifyDisconnected(); 121 void NotifyDisconnected();
121 122
122 // Factory function to create the StatusUploader. 123 // Factory function to create the StatusUploader.
123 void CreateStatusUploader(); 124 void CreateStatusUploader();
124 125
126 // Factory function to create the SystemLogUploader.
127 void CreateSystemLogUploader();
128
125 // Points to the same object as the base CloudPolicyManager::store(), but with 129 // Points to the same object as the base CloudPolicyManager::store(), but with
126 // actual device policy specific type. 130 // actual device policy specific type.
127 scoped_ptr<DeviceCloudPolicyStoreChromeOS> device_store_; 131 scoped_ptr<DeviceCloudPolicyStoreChromeOS> device_store_;
128 ServerBackedStateKeysBroker* state_keys_broker_; 132 ServerBackedStateKeysBroker* state_keys_broker_;
129 133
130 // Helper object that handles updating the server with our current device 134 // Helper object that handles updating the server with our current device
131 // state. 135 // state.
132 scoped_ptr<StatusUploader> status_uploader_; 136 scoped_ptr<StatusUploader> status_uploader_;
133 137
138 // Helper object that handles uploading system logs to the server.
139 scoped_ptr<SystemLogUploader> syslog_uploader_;
140
134 // Helper object that handles sending heartbeats over the GCM channel to 141 // Helper object that handles sending heartbeats over the GCM channel to
135 // the server, to monitor connectivity. 142 // the server, to monitor connectivity.
136 scoped_ptr<HeartbeatScheduler> heartbeat_scheduler_; 143 scoped_ptr<HeartbeatScheduler> heartbeat_scheduler_;
137 144
138 // The TaskRunner used to do device status uploads. 145 // The TaskRunner used to do device status and logs uploads.
Andrew T Wilson (Slow) 2015/06/29 15:06:08 nit: "log uploads"
Polina Bondarenko 2015/07/02 15:28:03 Done.
139 scoped_refptr<base::SequencedTaskRunner> task_runner_; 146 scoped_refptr<base::SequencedTaskRunner> task_runner_;
140 147
141 ServerBackedStateKeysBroker::Subscription state_keys_update_subscription_; 148 ServerBackedStateKeysBroker::Subscription state_keys_update_subscription_;
142 149
143 // PrefService instance to read the policy refresh rate from. 150 // PrefService instance to read the policy refresh rate from.
144 PrefService* local_state_; 151 PrefService* local_state_;
145 152
146 scoped_ptr<chromeos::attestation::AttestationPolicyObserver> 153 scoped_ptr<chromeos::attestation::AttestationPolicyObserver>
147 attestation_policy_observer_; 154 attestation_policy_observer_;
148 155
149 base::ObserverList<Observer, true> observers_; 156 base::ObserverList<Observer, true> observers_;
150 157
151 DISALLOW_COPY_AND_ASSIGN(DeviceCloudPolicyManagerChromeOS); 158 DISALLOW_COPY_AND_ASSIGN(DeviceCloudPolicyManagerChromeOS);
152 }; 159 };
153 160
154 } // namespace policy 161 } // namespace policy
155 162
156 #endif // CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_CLOUD_POLICY_MANAGER_CHROMEOS_H _ 163 #endif // CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_CLOUD_POLICY_MANAGER_CHROMEOS_H _
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698