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

Side by Side Diff: components/browser_sync/browser/profile_sync_service.cc

Issue 2018623002: [USS] Store supports hosting multiple datatypes per database (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 6 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
« no previous file with comments | « no previous file | sync/api/model_type_store.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #include "components/browser_sync/browser/profile_sync_service.h" 5 #include "components/browser_sync/browser/profile_sync_service.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <cstddef> 8 #include <cstddef>
9 #include <map> 9 #include <map>
10 #include <utility> 10 #include <utility>
(...skipping 281 matching lines...) Expand 10 before | Expand all | Expand 10 after
292 switches::kSyncEnableUSSDeviceInfo)) { 292 switches::kSyncEnableUSSDeviceInfo)) {
293 scoped_refptr<base::SequencedTaskRunner> blocking_task_runner( 293 scoped_refptr<base::SequencedTaskRunner> blocking_task_runner(
294 blocking_pool_->GetSequencedTaskRunnerWithShutdownBehavior( 294 blocking_pool_->GetSequencedTaskRunnerWithShutdownBehavior(
295 blocking_pool_->GetSequenceToken(), 295 blocking_pool_->GetSequenceToken(),
296 base::SequencedWorkerPool::SKIP_ON_SHUTDOWN)); 296 base::SequencedWorkerPool::SKIP_ON_SHUTDOWN));
297 // TODO(skym): Stop creating leveldb files when signed out. 297 // TODO(skym): Stop creating leveldb files when signed out.
298 // TODO(skym): Verify using AsUTF8Unsafe is okay here. Should work as long 298 // TODO(skym): Verify using AsUTF8Unsafe is okay here. Should work as long
299 // as the Local State file is guaranteed to be UTF-8. 299 // as the Local State file is guaranteed to be UTF-8.
300 device_info_service_.reset(new DeviceInfoService( 300 device_info_service_.reset(new DeviceInfoService(
301 local_device_.get(), 301 local_device_.get(),
302 base::Bind(&ModelTypeStore::CreateStore, 302 base::Bind(&ModelTypeStore::CreateStore, syncer::DEVICE_INFO,
303 directory_path_.Append(base::FilePath(kLevelDBFolderName)) 303 directory_path_.Append(base::FilePath(kLevelDBFolderName))
304 .AsUTF8Unsafe(), 304 .AsUTF8Unsafe(),
305 blocking_task_runner), 305 blocking_task_runner),
306 base::Bind(&SharedModelTypeProcessor::CreateAsChangeProcessor))); 306 base::Bind(&SharedModelTypeProcessor::CreateAsChangeProcessor)));
307 } else { 307 } else {
308 device_info_sync_service_.reset( 308 device_info_sync_service_.reset(
309 new DeviceInfoSyncService(local_device_.get())); 309 new DeviceInfoSyncService(local_device_.get()));
310 } 310 }
311 311
312 sync_driver::SyncApiComponentFactory::RegisterDataTypesMethod 312 sync_driver::SyncApiComponentFactory::RegisterDataTypesMethod
(...skipping 2221 matching lines...) Expand 10 before | Expand all | Expand 10 after
2534 } 2534 }
2535 2535
2536 std::string ProfileSyncService::unrecoverable_error_message() const { 2536 std::string ProfileSyncService::unrecoverable_error_message() const {
2537 return unrecoverable_error_message_; 2537 return unrecoverable_error_message_;
2538 } 2538 }
2539 2539
2540 tracked_objects::Location ProfileSyncService::unrecoverable_error_location() 2540 tracked_objects::Location ProfileSyncService::unrecoverable_error_location()
2541 const { 2541 const {
2542 return unrecoverable_error_location_; 2542 return unrecoverable_error_location_;
2543 } 2543 }
OLDNEW
« no previous file with comments | « no previous file | sync/api/model_type_store.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698